diff options
author | Cooper Yuan <cooperyuan@gmail.com> | 2009-10-21 15:32:30 +0800 |
---|---|---|
committer | Cooper Yuan <cooperyuan@gmail.com> | 2009-10-21 15:32:30 +0800 |
commit | 4c458c263dca0f761f31a3c1c16a1f6bcbd02801 (patch) | |
tree | 528cffc3f0c71b1c5dffb5d273b16515ecda9495 | |
parent | f12cba15932d319c4c006bdbb1aed41136ab11fd (diff) |
xvmc: prepare to flush front buffer
-rw-r--r-- | src/gallium/winsys/g3dvl/radeon/radeon_vl.c | 11 | ||||
-rw-r--r-- | src/gallium/winsys/g3dvl/radeon/radeon_vl.h | 7 |
2 files changed, 11 insertions, 7 deletions
diff --git a/src/gallium/winsys/g3dvl/radeon/radeon_vl.c b/src/gallium/winsys/g3dvl/radeon/radeon_vl.c index 57b4c168c..269a9577a 100644 --- a/src/gallium/winsys/g3dvl/radeon/radeon_vl.c +++ b/src/gallium/winsys/g3dvl/radeon/radeon_vl.c @@ -102,7 +102,10 @@ static void radeon_mpeg12_clear_surface(struct pipe_video_context *vpipe, assert(vpipe); assert(surface); - ctx->pipe->surface_fill(ctx->pipe, surface, x, y, width, height, value); + if (ctx->pipe->surface_fill) + ctx->pipe->surface_fill(ctx->pipe, surface, x, y, width, height, value); + else + util_surface_fill(ctx->pipe, surface, x, y, width, height, value); } static void @@ -313,6 +316,7 @@ struct pipe_screen *vl_screen_create(Display *display, int screen) struct r300_winsys *r300; struct radeon_winsys *p_winsys; int drmFD; + /* just a temp code, should use dri2 client interface */ drmFD = open("/dev/dri/card0", O_RDWR); @@ -347,11 +351,10 @@ struct pipe_video_context *vl_video_create(struct pipe_screen *screen, return NULL; } - /* create radeon_vl_context, but it seems not necessary..... - */ + /* create radeon_vl_context */ rvl_ctx = calloc(1, sizeof(struct radeon_vl_context)); rvl_ctx->screen = screen; - + rvl_ctx->vpipe = vpipe; vpipe->priv = rvl_ctx; return vpipe; diff --git a/src/gallium/winsys/g3dvl/radeon/radeon_vl.h b/src/gallium/winsys/g3dvl/radeon/radeon_vl.h index 7fc285f11..d4693907d 100644 --- a/src/gallium/winsys/g3dvl/radeon/radeon_vl.h +++ b/src/gallium/winsys/g3dvl/radeon/radeon_vl.h @@ -31,9 +31,10 @@ struct radeon_vl_context { - Display *display; - int screen; - Drawable drawable; + Display *display; + struct pipe_screen *screen; + Drawable drawable; + struct pipe_video_context *vpipe; }; struct radeon_vl_screen |