librashader/librashader-runtime-gl/src/texture.rs

16 lines
355 B
Rust
Raw Normal View History

2022-11-27 18:10:11 +11:00
use librashader_common::{FilterMode, WrapMode};
2022-11-30 16:39:42 +11:00
use crate::framebuffer::GLImage;
2022-11-27 18:10:11 +11:00
#[derive(Default, Debug, Copy, Clone)]
pub struct Texture {
2022-11-30 16:39:42 +11:00
pub image: GLImage,
2022-11-27 18:10:11 +11:00
pub filter: FilterMode,
pub mip_filter: FilterMode,
pub wrap_mode: WrapMode,
}
impl Texture {
pub fn is_bound(&self) -> bool {
return self.image.handle != 0
}
}