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

Author: José Fonseca <jfons...@vmware.com>
Date:   Wed Feb 18 17:58:42 2009 +0000

gdi: Update for texture/surface interface changes.

---

 src/gallium/winsys/gdi/gdi_softpipe_winsys.c |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/src/gallium/winsys/gdi/gdi_softpipe_winsys.c 
b/src/gallium/winsys/gdi/gdi_softpipe_winsys.c
index 4924dbf..2d961f7 100644
--- a/src/gallium/winsys/gdi/gdi_softpipe_winsys.c
+++ b/src/gallium/winsys/gdi/gdi_softpipe_winsys.c
@@ -273,14 +273,17 @@ gdi_softpipe_flush_frontbuffer(struct pipe_screen *screen,
                                struct pipe_surface *surface,
                                HDC hDC)
 {
+    struct softpipe_texture *texture;
     struct gdi_softpipe_buffer *buffer;
     BITMAPINFO bmi;
 
-    buffer = gdi_softpipe_buffer(softpipe_texture(surface->texture)->buffer);
+    texture = softpipe_texture(surface->texture);
+                                               
+    buffer = gdi_softpipe_buffer(texture->buffer);
 
     memset(&bmi, 0, sizeof(BITMAPINFO));
     bmi.bmiHeader.biSize = sizeof(BITMAPINFOHEADER);
-    bmi.bmiHeader.biWidth = surface->stride / pf_get_size(surface->format);
+    bmi.bmiHeader.biWidth = texture->stride[surface->level] / 
pf_get_size(surface->format);
     bmi.bmiHeader.biHeight= -(long)surface->height;
     bmi.bmiHeader.biPlanes = 1;
     bmi.bmiHeader.biBitCount = pf_get_bits(surface->format);

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to