From 96c6637a1360f146bbf49ffb207ae943ecbbdf49 Mon Sep 17 00:00:00 2001 From: Chia-I Wu Date: Sun, 28 Nov 2010 01:37:35 +0800 Subject: st/vega: Use st_framebuffer for fb width/height. This allows us to eventually make g3d states opaque. --- src/gallium/state_trackers/vega/api_masks.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/gallium/state_trackers/vega/api_masks.c') diff --git a/src/gallium/state_trackers/vega/api_masks.c b/src/gallium/state_trackers/vega/api_masks.c index 45f77d7d70..3cc4a0b5a3 100644 --- a/src/gallium/state_trackers/vega/api_masks.c +++ b/src/gallium/state_trackers/vega/api_masks.c @@ -81,7 +81,7 @@ void vegaClear(VGint x, VGint y, VGint width, VGint height) { struct vg_context *ctx = vg_current_context(); - struct pipe_framebuffer_state *fb; + struct st_framebuffer *stfb = ctx->draw_buffer; if (width <= 0 || height <= 0) { vg_set_error(ctx, VG_ILLEGAL_ARGUMENT_ERROR); @@ -98,10 +98,9 @@ void vegaClear(VGint x, VGint y, ctx->state.vg.clear_color[3]); #endif - fb = &ctx->state.g3d.fb; /* check for a whole surface clear */ if (!ctx->state.vg.scissoring && - (x == 0 && y == 0 && width == fb->width && height == fb->height)) { + (x == 0 && y == 0 && width == stfb->width && height == stfb->height)) { ctx->pipe->clear(ctx->pipe, PIPE_CLEAR_COLOR | PIPE_CLEAR_DEPTHSTENCIL, ctx->state.vg.clear_color, 1., 0); } else if (renderer_clear_begin(ctx->renderer)) { -- cgit v1.2.3