struct Backend {
backend: VaapiBackend<Header>,
}
Fields
backend: VaapiBackend<Header>
Implementations
sourceimpl Backend
impl Backend
fn get_rt_format(
profile: Profile,
bit_depth: BitDepth,
subsampling_x: bool,
subsampling_y: bool
) -> Result<u32>
sourcefn surface_id(picture: &GenericBackendHandle) -> VASurfaceID
fn surface_id(picture: &GenericBackendHandle) -> VASurfaceID
Gets the VASurfaceID for the given picture
.
fn build_pic_param(
hdr: &Header,
reference_frames: &[Option<<Backend as VideoDecoderBackend>::Handle>; 8]
) -> Result<BufferType>
fn build_slice_param(
seg: &[Segmentation; 8],
slice_size: usize
) -> Result<BufferType>
Trait Implementations
sourceimpl StatelessDecoderBackend for Backend
impl StatelessDecoderBackend for Backend
sourcefn new_sequence(&mut self, header: &Header) -> StatelessBackendResult<()>
fn new_sequence(&mut self, header: &Header) -> StatelessBackendResult<()>
Called when new stream parameters are found.
sourcefn submit_picture(
&mut self,
picture: &Header,
reference_frames: &[Option<Self::Handle>; 8],
bitstream: &[u8],
timestamp: u64,
segmentation: &[Segmentation; 8],
block: BlockingMode
) -> StatelessBackendResult<Self::Handle>
fn submit_picture(
&mut self,
picture: &Header,
reference_frames: &[Option<Self::Handle>; 8],
bitstream: &[u8],
timestamp: u64,
segmentation: &[Segmentation; 8],
block: BlockingMode
) -> StatelessBackendResult<Self::Handle>
Called when the decoder wants the backend to finish the decoding
operations for
picture
. The argument block
dictates whether this
call should wait until the current decode finishes, or whether it should
return immediately. Read moresourceimpl VideoDecoderBackend for Backend
impl VideoDecoderBackend for Backend
type Handle = DecodedHandle
type Handle = DecodedHandle
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
sourcefn coded_resolution(&self) -> Option<Resolution>
fn coded_resolution(&self) -> Option<Resolution>
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
sourcefn display_resolution(&self) -> Option<Resolution>
fn display_resolution(&self) -> Option<Resolution>
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
sourcefn num_resources_total(&self) -> usize
fn num_resources_total(&self) -> usize
Gets the number of output resources allocated by the backend.
sourcefn num_resources_left(&self) -> usize
fn num_resources_left(&self) -> usize
Gets the number of output resources left in the backend.
sourcefn format(&self) -> Option<DecodedFormat>
fn format(&self) -> Option<DecodedFormat>
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
sourcefn try_format(&mut self, format: DecodedFormat) -> DecoderResult<()>
fn try_format(&mut self, format: DecodedFormat) -> DecoderResult<()>
Try altering the decoded format.
sourcefn poll(
&mut self,
blocking_mode: BlockingMode
) -> DecoderResult<VecDeque<Self::Handle>>
fn poll(
&mut self,
blocking_mode: BlockingMode
) -> DecoderResult<VecDeque<Self::Handle>>
Poll for any ready pictures.
block
dictates whether this call should
block on the operation or return immediately. Read moresourcefn handle_is_ready(&self, handle: &Self::Handle) -> bool
fn handle_is_ready(&self, handle: &Self::Handle) -> bool
Whether the handle is ready for presentation. The decoder will check
this before returning the handle to clients. Read more
sourcefn block_on_handle(
&mut self,
handle: &Self::Handle
) -> StatelessBackendResult<()>
fn block_on_handle(
&mut self,
handle: &Self::Handle
) -> StatelessBackendResult<()>
Block on handle
handle
.Auto Trait Implementations
impl !RefUnwindSafe for Backend
impl !Send for Backend
impl !Sync for Backend
impl Unpin for Backend
impl !UnwindSafe for Backend
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more