Mesa (master): r300g: don't use pipe_screen::winsys

Marek Olšák mareko at kemper.freedesktop.org
Thu Feb 16 16:40:35 PST 2012


Module: Mesa
Branch: master
Commit: e05bc52b9ccbbf0ca7fa25196c5137b35d2c5c2e
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=e05bc52b9ccbbf0ca7fa25196c5137b35d2c5c2e

Author: Marek Olšák <maraeo at gmail.com>
Date:   Fri Feb 17 01:39:48 2012 +0100

r300g: don't use pipe_screen::winsys

---

 src/gallium/drivers/r300/r300_texture.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/gallium/drivers/r300/r300_texture.c b/src/gallium/drivers/r300/r300_texture.c
index 289c71f..75749e7 100644
--- a/src/gallium/drivers/r300/r300_texture.c
+++ b/src/gallium/drivers/r300/r300_texture.c
@@ -843,7 +843,7 @@ boolean r300_resource_get_handle(struct pipe_screen* screen,
                                  struct pipe_resource *texture,
                                  struct winsys_handle *whandle)
 {
-    struct radeon_winsys *rws = (struct radeon_winsys *)screen->winsys;
+    struct radeon_winsys *rws = r300_screen(screen)->rws;
     struct r300_resource* tex = (struct r300_resource*)texture;
 
     if (!tex) {
@@ -948,8 +948,8 @@ struct pipe_resource *r300_texture_from_handle(struct pipe_screen *screen,
                                                const struct pipe_resource *base,
                                                struct winsys_handle *whandle)
 {
-    struct radeon_winsys *rws = (struct radeon_winsys*)screen->winsys;
     struct r300_screen *rscreen = r300_screen(screen);
+    struct radeon_winsys *rws = rscreen->rws;
     struct pb_buffer *buffer;
     enum radeon_bo_layout microtile, macrotile;
     unsigned stride;



More information about the mesa-commit mailing list