struct Backend {
    backend: VaapiBackend<Sps>,
    current_picture: Option<VaPicture<PictureNew>>,
}
Expand description

H.264 stateless decoder backend for VA-API.

Fields

backend: VaapiBackend<Sps>current_picture: Option<VaPicture<PictureNew>>

The current picture being worked on.

Implementations

Creates a new codec backend for H.264.

Gets the VASurfaceID for the given picture.

Fills the internal va_pic picture parameter with data from h264_pic

Builds an invalid VaPictureH264. These pictures are used to fill empty array slots there is no data to fill them with.

Trait Implementations

Called when a new SPS is parsed.
Called by the decoder for every frame or field found.
Called to dispatch a decode operation to the backend.
Called when the decoder wants the backend to finish the decoding operations for picture. At this point, decode_slice has been called for all slices. The argument block dictates whether this call should wait until the current decode finishes, or whether it should return immediately. Read more
Called when the decoder determines that a frame or field was found.
Called when the decoder determines that a second field was found. Indicates that the underlying BackendHandle is to be shared between the two pictures. This is so both fields decode to the same underlying resource and can thus be presented together as a single frame. Read more
The type that the backend returns as a result of a decode operation. This will usually be some backend-specific type with a resource and a resource pool so that said buffer can be reused for another decode operation when it goes out of scope. Read more
Gets the number of output resources allocated by the backend.
Gets the number of output resources left in the backend.
Gets the chosen format. This is set to a default after the decoder reads enough stream metadata from the bitstream. Some buffers need to be processed first before the default format can be set. Read more
Try altering the decoded format.
Returns the current coded resolution of the bitstream being processed. This may be None if we have not read the stream parameters yet. Read more
Returns the current display resolution of the bitstream being processed. This may be None if we have not read the stream parameters yet. Read more
Poll for any ready pictures. block dictates whether this call should block on the operation or return immediately. Read more
Whether the handle is ready for presentation. The decoder will check this before returning the handle to clients. Read more
Block on handle handle.

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 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.