pub struct DmaBufEncoder {
receiver: Option<Receiver<RawVideoFrame>>,
}Expand description
“Encoder” which provides the raw DMA-Buf pointers directly.
Allows for using the image directly on the GPU, which makes it far more performant when, for example, trying to display it to a user.
The implementations of crate::NvencEncoder and crate::VaapiEncoder show how a RawVideoFrame can be used.
Fields§
§receiver: Option<Receiver<RawVideoFrame>>Trait Implementations§
Source§impl Default for DmaBufEncoder
impl Default for DmaBufEncoder
Source§fn default() -> DmaBufEncoder
fn default() -> DmaBufEncoder
Returns the “default value” for a type. Read more
Source§impl PipewireSPA for DmaBufEncoder
impl PipewireSPA for DmaBufEncoder
fn get_spa_definition() -> Result<Object>
Source§impl StartVideoEncoder for DmaBufEncoder
impl StartVideoEncoder for DmaBufEncoder
fn start_processing( capture: &mut Capture<Self>, input: Receiver<RawVideoFrame>, ) -> Result<()>
Auto Trait Implementations§
impl Freeze for DmaBufEncoder
impl RefUnwindSafe for DmaBufEncoder
impl Send for DmaBufEncoder
impl Sync for DmaBufEncoder
impl Unpin for DmaBufEncoder
impl UnsafeUnpin for DmaBufEncoder
impl UnwindSafe for DmaBufEncoder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian().