Struct rsmpeg::avutil::AVFrame [−][src]
pub struct AVFrame { /* fields omitted */ }
Implementations
impl AVFrame
[src]
impl AVFrame
[src]pub fn as_ptr(&self) -> *const AVFrame
[src]
pub fn as_mut_ptr(&mut self) -> *mut AVFrame
[src]
pub unsafe fn set_ptr(&mut self, ptr: NonNull<AVFrame>)
[src]
pub unsafe fn set_ptr(&mut self, ptr: NonNull<AVFrame>)
[src]Safety
This function should only be called when the pointer is valid and the data it’s pointing to can be dropped.
pub unsafe fn from_raw(raw: NonNull<AVFrame>) -> Self
[src]
pub unsafe fn from_raw(raw: NonNull<AVFrame>) -> Self
[src]Safety
This function should only be called when the pointer is valid and the data it’s pointing to can be dropped.
pub fn into_raw(self) -> NonNull<AVFrame>
[src]
impl AVFrame
[src]
impl AVFrame
[src]pub fn set_width(&mut self, width: i32)
[src]
pub fn set_height(&mut self, height: i32)
[src]
pub fn set_pts(&mut self, pts: i64)
[src]
pub fn set_pict_type(&mut self, pict_type: AVPictureType)
[src]
pub fn set_nb_samples(&mut self, nb_samples: i32)
[src]
pub fn set_format(&mut self, format: i32)
[src]
pub fn set_channel_layout(&mut self, channel_layout: u64)
[src]
pub fn set_sample_rate(&mut self, sample_rate: i32)
[src]
impl AVFrame
[src]
impl AVFrame
[src]pub fn new() -> Self
[src]
pub fn is_allocated(&self) -> bool
[src]
pub fn is_allocated(&self) -> bool
[src]Return true if the data and buffer of current frame is allocated.
pub fn alloc_buffer(&mut self) -> Result<()>
[src]
pub fn alloc_buffer(&mut self) -> Result<()>
[src]Allocate new buffer(s) for audio or video data. The following fields must be set on frame before calling this function:
- format (pixel format for video, sample format for audio)
- width and height for video
- nb_samples and channel_layout for audio
Return Error when the some of the frame settings are invalid, allocating buffer for an already initialized frame or allocation fails because of no memory.
pub fn data_mut(&mut self) -> &mut [*mut u8; 8]
[src]
pub fn linesize_mut(&mut self) -> &mut [c_int; 8]
[src]
pub unsafe fn fill_arrays(
&mut self,
src: *const u8,
pix_fmt: AVPixelFormat,
width: i32,
height: i32
) -> Result<()>
[src]
pub unsafe fn fill_arrays(
&mut self,
src: *const u8,
pix_fmt: AVPixelFormat,
width: i32,
height: i32
) -> Result<()>
[src]Setup the data pointers and linesizes based on the specified image parameters and the provided array.
Safety
The buffer src points to cannot outlive the AVFrame. Recommend using fill_image_buffer() instead.
impl<'frame> AVFrame
[src]
impl<'frame> AVFrame
[src]pub fn get_side_data(
&'frame self,
side_data_type: AVFrameSideDataType
) -> Option<AVFrameSideDataRef<'frame>>
[src]
&'frame self,
side_data_type: AVFrameSideDataType
) -> Option<AVFrameSideDataRef<'frame>>
pub fn get_motion_vectors(&'frame self) -> Option<&'frame [AVMotionVector]>
[src]
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for AVFrame
impl !Send for AVFrame
impl !Sync for AVFrame
impl Unpin for AVFrame
impl UnwindSafe for AVFrame
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more