[][src]Enum mumble_protocol::voice::VoicePacket

pub enum VoicePacket<Dst: VoicePacketDst> {
    Ping {
        timestamp: u64,
    },
    Audio {
        _dst: PhantomData<Dst>,
        target: u8,
        session_id: Dst::SessionId,
        seq_num: u64,
        payload: VoicePacketPayload,
        position_info: Option<Bytes>,
    },
}

A packet transmitted via Mumble's voice channel.

Variants

Ping

Ping packets contain opaque timestamp-like values which should simply be echoed back.

Fields of Ping

timestamp: u64

Opaque timestamp-like value. Unless this is the echo, no assumptions about it should be made.

Audio

Packet containing audio data.

Fields of Audio

_dst: PhantomData<Dst>

Destination. Required due to encoding differences depending on packet flow direction.

target: u8

The target.

Only values 0-31 are valid (when serialized, this field is 5-bits long).

session_id: Dst::SessionId

Session ID. Absent when packet is Serverbound.

seq_num: u64

Sequence number of the first audio frame in this packet.

Packets may contain multiple frames, so this may increase by more than one per packet.

payload: VoicePacketPayload

The actual audio data

position_info: Option<Bytes>

Positional audio information.

Usually [f32; 3] but may contain additional or different data if all clients receiving this packet can deal with such values (e.g. games with builtin Mumble client may use this field to transmit additional data to other game clients).

Trait Implementations

impl<Dst: Clone + VoicePacketDst> Clone for VoicePacket<Dst> where
    Dst::SessionId: Clone
[src]

impl<Dst: Debug + VoicePacketDst> Debug for VoicePacket<Dst> where
    Dst::SessionId: Debug
[src]

impl<EncodeDst: VoicePacketDst, DecodeDst: VoicePacketDst> Encoder<VoicePacket<EncodeDst>> for CryptState<EncodeDst, DecodeDst>[src]

type Error = Error

The type of encoding errors. Read more

impl<EncodeDst: VoicePacketDst, DecodeDst: VoicePacketDst> Encoder<VoicePacket<EncodeDst>> for VoiceCodec<EncodeDst, DecodeDst>[src]

type Error = Error

The type of encoding errors. Read more

impl<Dst: VoicePacketDst> From<VoicePacket<Dst>> for RawControlPacket[src]

impl<Dst: VoicePacketDst> From<VoicePacket<Dst>> for ControlPacket<Dst>[src]

impl<Dst: PartialEq + VoicePacketDst> PartialEq<VoicePacket<Dst>> for VoicePacket<Dst> where
    Dst::SessionId: PartialEq
[src]

impl<Dst: VoicePacketDst> StructuralPartialEq for VoicePacket<Dst>[src]

impl<Dst: VoicePacketDst> TryFrom<Bytes> for VoicePacket<Dst>[src]

type Error = Error

The type returned in the event of a conversion error.

impl<Dst: VoicePacketDst> TryFrom<RawControlPacket> for VoicePacket<Dst>[src]

type Error = Error

The type returned in the event of a conversion error.

Auto Trait Implementations

impl<Dst> RefUnwindSafe for VoicePacket<Dst> where
    Dst: RefUnwindSafe,
    <Dst as VoicePacketDst>::SessionId: RefUnwindSafe
[src]

impl<Dst> Send for VoicePacket<Dst> where
    Dst: Send,
    <Dst as VoicePacketDst>::SessionId: Send
[src]

impl<Dst> Sync for VoicePacket<Dst> where
    Dst: Sync,
    <Dst as VoicePacketDst>::SessionId: Sync
[src]

impl<Dst> Unpin for VoicePacket<Dst> where
    Dst: Unpin,
    <Dst as VoicePacketDst>::SessionId: Unpin
[src]

impl<Dst> UnwindSafe for VoicePacket<Dst> where
    Dst: UnwindSafe,
    <Dst as VoicePacketDst>::SessionId: UnwindSafe
[src]

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.