From c96b0ffac368ac6f17884c2e4992372fc01f1787 Mon Sep 17 00:00:00 2001 From: David Herrmann Date: Fri, 20 Jan 2012 15:52:54 +0100 Subject: [PATCH] terminal: replace GL functions with new context subs We should use the context of the compositor instead of directly calling the GL functions to avoid direct dependencies. Signed-off-by: David Herrmann --- src/terminal.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/terminal.c b/src/terminal.c index 5ae144f..b95b8eb 100644 --- a/src/terminal.c +++ b/src/terminal.c @@ -31,8 +31,6 @@ */ #include -#include -#include #include #include @@ -68,8 +66,10 @@ static void draw_all(struct kmscon_idle *idle, void *data) struct kmscon_terminal *term = data; struct term_out *iter; struct kmscon_output *output; + struct kmscon_context *ctx; int ret; + ctx = kmscon_compositor_get_context(term->comp); kmscon_eloop_rm_idle(idle); kmscon_console_draw(term->console); @@ -83,9 +83,7 @@ static void draw_all(struct kmscon_idle *idle, void *data) if (ret) continue; - glClearColor(0.0, 0.0, 0.0, 1.0); - glClear(GL_COLOR_BUFFER_BIT); - + kmscon_context_clear(ctx); kmscon_console_map(term->console); kmscon_output_swap(output); }