stop recreating the framebuffer every frame if the aspect ratio is not 1:1
This commit is contained in:
parent
2adf75973a
commit
3d85440aac
@ -2374,7 +2374,7 @@ static void render(WGPUTexture surface_texture) {
|
||||
|
||||
u32vec2 surface_size = { wgpuTextureGetWidth(surface_texture), wgpuTextureGetHeight(surface_texture) };
|
||||
|
||||
if (framebuffer_size.x != surface_size.x || framebuffer_size.x != surface_size.y) {
|
||||
if (framebuffer_size.x != surface_size.x || framebuffer_size.y != surface_size.y) {
|
||||
if (framebuffer) wgpuTextureRelease(framebuffer);
|
||||
|
||||
WGPUTextureDescriptor descriptor = {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user