[gtk/wip/chergert/glproto] use split_draw() when processing glyphs
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/chergert/glproto] use split_draw() when processing glyphs
- Date: Mon, 1 Feb 2021 18:45:30 +0000 (UTC)
commit 3a34e9e53fe7a174e4bf14c1fb9342ce5400b21c
Author: Christian Hergert <chergert redhat com>
Date: Mon Feb 1 10:36:33 2021 -0800
use split_draw() when processing glyphs
only if we change atlas texture, but use the split draw instead of the
full state tracking end_draw/begin_draw
gsk/next/gskglrenderjob.c | 9 ++-------
1 file changed, 2 insertions(+), 7 deletions(-)
---
diff --git a/gsk/next/gskglrenderjob.c b/gsk/next/gskglrenderjob.c
index 2e5ba9196a..c5225e0155 100644
--- a/gsk/next/gskglrenderjob.c
+++ b/gsk/next/gskglrenderjob.c
@@ -2657,18 +2657,13 @@ gsk_gl_render_job_visit_text_node (GskGLRenderJob *job,
if G_UNLIKELY (last_texture != texture_id)
{
- gsk_gl_program_end_draw (program);
+ if G_LIKELY (last_texture != 0)
+ gsk_gl_program_split_draw (program);
gsk_gl_program_set_uniform_texture (program,
UNIFORM_SHARED_SOURCE,
GL_TEXTURE_2D,
GL_TEXTURE0,
texture_id);
- gsk_gl_program_begin_draw (program,
- &job->viewport,
- &job->projection,
- gsk_gl_render_job_get_modelview_matrix (job),
- gsk_gl_render_job_get_clip (job),
- job->alpha);
last_texture = texture_id;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]