Struct webrender_api::units::TexelRect
source · #[repr(C)]pub struct TexelRect {
pub uv0: DevicePoint,
pub uv1: DevicePoint,
}
Expand description
Stores two coordinates in texel space. The coordinates are stored in texel coordinates because the texture atlas may grow. Storing them as texel coords and normalizing the UVs in the vertex shader means nothing needs to be updated on the CPU when the texture size changes.
Fields§
§uv0: DevicePoint
§uv1: DevicePoint
Implementations§
Trait Implementations§
source§impl<'de> Deserialize<'de> for TexelRect
impl<'de> Deserialize<'de> for TexelRect
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Into<TexelRect> for DeviceIntRect
impl Into<TexelRect> for DeviceIntRect
source§impl PartialEq for TexelRect
impl PartialEq for TexelRect
impl Copy for TexelRect
impl StructuralPartialEq for TexelRect
Auto Trait Implementations§
impl Freeze for TexelRect
impl RefUnwindSafe for TexelRect
impl Send for TexelRect
impl Sync for TexelRect
impl Unpin for TexelRect
impl UnwindSafe for TexelRect
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