diff options
author | Cooper Yuan <cooperyuan@gmail.com> | 2009-10-23 14:49:53 +0800 |
---|---|---|
committer | Cooper Yuan <cooperyuan@gmail.com> | 2009-10-23 14:49:53 +0800 |
commit | 8245267eccbe66656a3c3cee265b89bcc1f4adea (patch) | |
tree | a814d2d475869b4fcba0adef21352f79269ea244 | |
parent | 4c458c263dca0f761f31a3c1c16a1f6bcbd02801 (diff) |
xvmc: adjust video context creating argument
-rw-r--r-- | src/gallium/winsys/g3dvl/radeon/radeon_vl.c | 11 | ||||
-rw-r--r-- | src/gallium/winsys/g3dvl/radeon/radeon_vl.h | 14 |
2 files changed, 10 insertions, 15 deletions
diff --git a/src/gallium/winsys/g3dvl/radeon/radeon_vl.c b/src/gallium/winsys/g3dvl/radeon/radeon_vl.c index 269a9577a..65fad38f5 100644 --- a/src/gallium/winsys/g3dvl/radeon/radeon_vl.c +++ b/src/gallium/winsys/g3dvl/radeon/radeon_vl.c @@ -34,7 +34,6 @@ #include <fcntl.h> - #include "radeon_buffer.h" #include "radeon_r300.h" #include "r300_screen.h" @@ -328,7 +327,8 @@ struct pipe_screen *vl_screen_create(Display *display, int screen) return screen_pipe; } -struct pipe_video_context *vl_video_create(struct pipe_screen *screen, +struct pipe_video_context *vl_video_create(Display *display, int screen, + struct pipe_screen *p_screen, enum pipe_video_profile profile, enum pipe_video_chroma_format chr_f, unsigned int width, @@ -337,14 +337,14 @@ struct pipe_video_context *vl_video_create(struct pipe_screen *screen, struct pipe_video_context *vpipe; struct radeon_vl_context *rvl_ctx; - assert(screen); + assert(p_screen); assert(width && height); /* create radeon pipe_context */ switch(u_reduce_video_profile(profile)) { case PIPE_VIDEO_CODEC_MPEG12: - vpipe = radeon_mpeg12_context_create(screen, profile, chr_f, + vpipe = radeon_mpeg12_context_create(p_screen, profile, chr_f, width, height); break; default: @@ -353,8 +353,9 @@ struct pipe_video_context *vl_video_create(struct pipe_screen *screen, /* create radeon_vl_context */ rvl_ctx = calloc(1, sizeof(struct radeon_vl_context)); + rvl_ctx->display = display; 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 d4693907d..a25dc27e7 100644 --- a/src/gallium/winsys/g3dvl/radeon/radeon_vl.h +++ b/src/gallium/winsys/g3dvl/radeon/radeon_vl.h @@ -31,15 +31,9 @@ struct radeon_vl_context { - Display *display; - struct pipe_screen *screen; - Drawable drawable; - struct pipe_video_context *vpipe; -}; - -struct radeon_vl_screen -{ - struct pipe_screen base; + Display *display; + int screen; + Drawable drawable; }; struct radeon_mpeg12_context @@ -54,4 +48,4 @@ struct radeon_mpeg12_context void *blend; }; -#endif //__RADEON_VL_H__
\ No newline at end of file +#endif //__RADEON_VL_H__ |