1
0
Fork 0
forked from wry/wry

gfx: add ShmGfxTexture

This commit is contained in:
Julian Orth 2024-09-07 20:22:30 +02:00
parent ed4ef3c8e7
commit c968024905
10 changed files with 51 additions and 22 deletions

View file

@ -1,7 +1,7 @@
use {
crate::{
format::Format,
gfx_api::{GfxError, GfxTexture},
gfx_api::{GfxError, GfxTexture, ShmGfxTexture},
gfx_apis::gl::{
gl::texture::GlTexture,
renderer::{context::GlRenderContext, framebuffer::Framebuffer},
@ -82,3 +82,9 @@ impl GfxTexture for Texture {
self.format
}
}
impl ShmGfxTexture for Texture {
fn into_texture(self: Rc<Self>) -> Rc<dyn GfxTexture> {
self
}
}