summaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/auxiliary')
-rw-r--r--src/gallium/auxiliary/util/u_surface.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gallium/auxiliary/util/u_surface.c b/src/gallium/auxiliary/util/u_surface.c
index 8c2c2279150..85e443204e3 100644
--- a/src/gallium/auxiliary/util/u_surface.c
+++ b/src/gallium/auxiliary/util/u_surface.c
@@ -90,9 +90,9 @@ util_create_rgba_surface(struct pipe_screen *screen,
return FALSE;
/* create surface / view into texture */
- *surfaceOut = screen->get_tex_surface(screen, *textureOut, 0, 0, 0, usage);
+ *surfaceOut = screen->get_tex_surface(screen, *textureOut, 0, 0, 0, PIPE_BUFFER_USAGE_GPU_WRITE);
if (!*surfaceOut) {
- screen->texture_destroy(*textureOut);
+ pipe_texture_reference(textureOut, NULL);
return FALSE;
}