use crate::sys;
#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
pub struct TextureRect {
pub x: u16,
pub y: u16,
pub w: u16,
pub h: u16,
}
impl From<sys::ImTextureRect> for TextureRect {
fn from(rect: sys::ImTextureRect) -> Self {
Self {
x: rect.x,
y: rect.y,
w: rect.w,
h: rect.h,
}
}
}
impl From<TextureRect> for sys::ImTextureRect {
fn from(rect: TextureRect) -> Self {
Self {
x: rect.x,
y: rect.y,
w: rect.w,
h: rect.h,
}
}
}