1
0
Fork 0
forked from wry/wry

render: implement a vulkan renderer

This commit is contained in:
Julian Orth 2024-02-03 15:19:20 +01:00
parent 4ba8550da8
commit cf332e8436
66 changed files with 4287 additions and 239 deletions

View file

@ -198,10 +198,10 @@ impl WlBuffer {
};
match storage {
WlBufferStorage::Shm { mem, stride } => {
self.texture.set(None);
let old = self.texture.take();
if let Some(ctx) = self.client.state.render_ctx.get() {
let tex = mem.access(|mem| {
ctx.shmem_texture(mem, self.format, self.width, self.height, *stride)
ctx.shmem_texture(old, mem, self.format, self.width, self.height, *stride)
})??;
self.texture.set(Some(tex));
}