mbuf_coded_video_frame_get_packed_buffer

Function mbuf_coded_video_frame_get_packed_buffer 

Source
pub unsafe extern "C" fn mbuf_coded_video_frame_get_packed_buffer(
    frame: *mut mbuf_coded_video_frame,
    data: *mut *const c_void,
    len: *mut usize,
) -> c_int
Expand description

Get a read-only buffer of the full frame.

This function only works if the frame is packed, meaning that all NALUs should have consecutive memory addresses, without gaps between them.

If the frame is not packed, this function returns -EPROTO, but will still set len to the size of the equivalent packed frame. This allows the creation of a big enough mbuf_mem for a call to mbuf_coded_video_frame_copy(), which will create a packed frame.

@param frame: The frame. @param data: [out] The frame buffer. @param len: [out] The frame buffer size.

@return 0 on success, negative errno on error.