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

Author: Luca Barbieri <l...@luca-barbieri.com>
Date:   Mon Apr 12 11:45:50 2010 +0200

nvfx: fix bind flags

---

 src/gallium/drivers/nvfx/nvfx_miptree.c  |    2 +-
 src/gallium/drivers/nvfx/nvfx_transfer.c |    4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/gallium/drivers/nvfx/nvfx_miptree.c 
b/src/gallium/drivers/nvfx/nvfx_miptree.c
index 385551c..602a476 100644
--- a/src/gallium/drivers/nvfx/nvfx_miptree.c
+++ b/src/gallium/drivers/nvfx/nvfx_miptree.c
@@ -302,7 +302,7 @@ nvfx_miptree_surface_del(struct pipe_surface *ps)
        if(ns->backing)
        {
                struct nvfx_screen* screen = (struct 
nvfx_screen*)ps->texture->screen;
-               if(ns->backing->base.usage & PIPE_BIND_RENDER_TARGET)
+               if(ns->backing->base.usage & PIPE_BIND_BLIT_DESTINATION)
                        screen->eng2d->copy(screen->eng2d, &ns->backing->base, 
0, 0, ps, 0, 0, ns->base.width, ns->base.height);
                nvfx_miptree_surface_del(&ns->backing->base);
        }
diff --git a/src/gallium/drivers/nvfx/nvfx_transfer.c 
b/src/gallium/drivers/nvfx/nvfx_transfer.c
index 320f9a8..a776ab5 100644
--- a/src/gallium/drivers/nvfx/nvfx_transfer.c
+++ b/src/gallium/drivers/nvfx/nvfx_transfer.c
@@ -41,10 +41,10 @@ static unsigned nvfx_transfer_bind_flags( unsigned 
transfer_usage )
        unsigned bind = 0;
 
        if (transfer_usage & PIPE_TRANSFER_WRITE)
-               bind |= PIPE_BIND_BLIT_DESTINATION;
+               bind |= PIPE_BIND_BLIT_SOURCE;
 
        if (transfer_usage & PIPE_TRANSFER_READ)
-               bind |= PIPE_BIND_BLIT_SOURCE;
+               bind |= PIPE_BIND_BLIT_DESTINATION;
 
        return bind;
 }

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

Reply via email to