skia_safe::gpu::ganesh

Type Alias YUVABackendTextureInfo

Source
pub type YUVABackendTextureInfo = Handle<GrYUVABackendTextureInfo>;
Expand description

A description of a set BackendTextures that hold the planar data described by a YUVAInfo.

Aliased Type§

struct YUVABackendTextureInfo(/* private fields */);

Implementations§

Source§

impl YUVABackendTextureInfo

Source

pub const MAX_PLANES: usize = 4usize

Source

pub fn new( info: &YUVAInfo, formats: &[BackendFormat], mip_mapped: Mipmapped, origin: SurfaceOrigin, ) -> Option<Self>

Initializes a YUVABackendTextureInfo to describe a set of textures that can store the planes indicated by the YUVAInfo. The texture dimensions are taken from the YUVAInfo’s plane dimensions. All the described textures share a common origin. The planar image this describes will be mip mapped if all the textures are individually mip mapped as indicated by Mipmapped. This will return None if the passed formats’ channels don’t agree with YUVAInfo.

Source

pub fn yuva_info(&self) -> &YUVAInfo

Source

pub fn yuv_color_space(&self) -> YUVColorSpace

Source

pub fn mipmapped(&self) -> Mipmapped

Source

pub fn texture_origin(&self) -> SurfaceOrigin

Source

pub fn num_planes(&self) -> usize

The number of crate::Pixmap planes.

Source

pub fn plane_format(&self, i: usize) -> Option<&BackendFormat>

Format of the ith plane, or None if i >= Self::num_planes()

Source

pub fn plane_formats(&self) -> &[BackendFormat]

All plane formats.

Trait Implementations§

Source§

impl Debug for YUVABackendTextureInfo

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Send for YUVABackendTextureInfo

Source§

impl Sync for YUVABackendTextureInfo