projects
/
gtk4.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
895d427
)
gsk: Fix handling of large textures
author
Matthias Clasen
<mclasen@redhat.com>
Wed, 15 Mar 2023 19:33:32 +0000
(15:33 -0400)
committer
Matthias Clasen
<mclasen@redhat.com>
Wed, 15 Mar 2023 19:33:32 +0000
(15:33 -0400)
When the texture is too large, actually
shrink the size to max_texture_size.
gsk/gl/gskglcommandqueue.c
patch
|
blob
|
history
diff --git
a/gsk/gl/gskglcommandqueue.c
b/gsk/gl/gskglcommandqueue.c
index 30617898e801a5cd8e5b4f72e5979b0b48f4b13e..39917877ad9b4150c58f780752ed37e973ac5da2 100644
(file)
--- a/
gsk/gl/gskglcommandqueue.c
+++ b/
gsk/gl/gskglcommandqueue.c
@@
-1469,8
+1469,8
@@
gsk_gl_command_queue_upload_texture (GskGLCommandQueue *self,
g_warning ("Attempt to create texture of size %ux%u but max size is %d. "
"Clipping will occur.",
width, height, self->max_texture_size);
- width = M
AX
(width, self->max_texture_size);
- height = M
AX
(height, self->max_texture_size);
+ width = M
IN
(width, self->max_texture_size);
+ height = M
IN
(height, self->max_texture_size);
}
texture_id = gsk_gl_command_queue_create_texture (self, width, height, GL_RGBA8, min_filter, mag_filter);
if (texture_id == -1)