Struct ac_ffmpeg::packet::Packet

source ·
pub struct Packet { /* private fields */ }
Expand description

Packet with immutable data.

Implementations§

Get stream index.

Set stream index.

Get packet time base.

Set packet time base. (This will rescale the current timestamps into a given time base.)

Get packet presentation timestamp.

Set packet presentation timestamp.

Set packet presentation timestamp without time base.

Get packet decoding timestamp.

Set packet decoding timestamp.

Set packet decoding timestamp without time base.

Get packet duration.

The method returns None if the duration is lower or equal to zero.

Set packet duration.

Get packet duration in time base units.

Set packet duration in time base units.

Check if the key flag is set.

Get packet data.

Try to make this packet mutable.

The method returns PacketMut if the packet can be made mutable without copying the data, otherwise it returns Packet.

Make this packet mutable.

If there are no other references to the packet data, the mutable packet will be created without copying the data.

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Executes the destructor for this type. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.