Struct pipewire_wrapper::spa::buffers::meta::MetaBitmapRef
source · #[repr(transparent)]pub struct MetaBitmapRef { /* private fields */ }
Expand description
Bitmap information. This metadata contains a bitmap image in the given format and size. It is typically used for cursor images or other small images that are better transferred inline.
Implementations§
source§impl MetaBitmapRef
impl MetaBitmapRef
sourcepub fn format(&self) -> VideoFormat
pub fn format(&self) -> VideoFormat
bitmap video format, 0 is and invalid format should be handled as if there is no new bitmap information.
pub fn set_format(&mut self, format: VideoFormat)
sourcepub fn size(&self) -> &RectangleRef
pub fn size(&self) -> &RectangleRef
width and height of bitmap
pub fn size_mut(&mut self) -> &mut RectangleRef
pub fn set_stride(&mut self, stride: i32)
sourcepub fn offset(&self) -> u32
pub fn offset(&self) -> u32
offset of bitmap data in this structure. An offset of 0 means no image data (invisible), an offset >= sizeof(struct spa_meta_bitmap) contains valid bitmap info.
pub fn set_offset(&mut self, offset: u32)
pub fn is_valid(&self) -> bool
Trait Implementations§
source§impl Debug for MetaBitmapRef
impl Debug for MetaBitmapRef
source§impl From<MetaBitmapRef> for spa_meta_bitmap
impl From<MetaBitmapRef> for spa_meta_bitmap
source§fn from(value: MetaBitmapRef) -> Self
fn from(value: MetaBitmapRef) -> Self
Converts to this type from the input type.
source§impl From<spa_meta_bitmap> for MetaBitmapRef
impl From<spa_meta_bitmap> for MetaBitmapRef
source§fn from(value: spa_meta_bitmap) -> Self
fn from(value: spa_meta_bitmap) -> Self
Converts to this type from the input type.
source§impl RawWrapper for MetaBitmapRef
impl RawWrapper for MetaBitmapRef
§type CType = spa_meta_bitmap
type CType = spa_meta_bitmap
External type
source§fn as_raw_ptr(&self) -> *mut Self::CType
fn as_raw_ptr(&self) -> *mut Self::CType
Raw ptr to the external type
source§fn from_raw(raw: Self::CType) -> Self
fn from_raw(raw: Self::CType) -> Self
Creates wrapper from the external value, can be use when external type has no raw pointers.
source§unsafe fn mut_from_raw_ptr<'lft>(raw: *mut Self::CType) -> &'lft mut Self
unsafe fn mut_from_raw_ptr<'lft>(raw: *mut Self::CType) -> &'lft mut Self
Cast external pointer to the borrowed mutable wrapper.
Panic when pointer is null.
Lifetime is not reliable and should be guaranteed explicitly. Read more
Auto Trait Implementations§
impl RefUnwindSafe for MetaBitmapRef
impl Send for MetaBitmapRef
impl Sync for MetaBitmapRef
impl Unpin for MetaBitmapRef
impl UnwindSafe for MetaBitmapRef
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