diff options
author | marha <marha@users.sourceforge.net> | 2012-02-24 08:16:00 +0100 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2012-02-24 08:16:00 +0100 |
commit | 5fb4fb602bde5140dcea45464e3b70a49078ad2e (patch) | |
tree | 24db226b5f69e9a8c9c3aea11e7a27a82620fa2c /mesalib/src/mesa/state_tracker | |
parent | 6baac61e6ca9cd314e689dfe7f84771aad08c66e (diff) | |
download | vcxsrv-5fb4fb602bde5140dcea45464e3b70a49078ad2e.tar.gz vcxsrv-5fb4fb602bde5140dcea45464e3b70a49078ad2e.tar.bz2 vcxsrv-5fb4fb602bde5140dcea45464e3b70a49078ad2e.zip |
fontconfig libX11 pixman xserver git update 24 Feb 2012
Diffstat (limited to 'mesalib/src/mesa/state_tracker')
-rw-r--r-- | mesalib/src/mesa/state_tracker/st_cb_fbo.c | 9 | ||||
-rw-r--r-- | mesalib/src/mesa/state_tracker/st_cb_texture.c | 18 |
2 files changed, 13 insertions, 14 deletions
diff --git a/mesalib/src/mesa/state_tracker/st_cb_fbo.c b/mesalib/src/mesa/state_tracker/st_cb_fbo.c index 300c3f0eb..953295c0e 100644 --- a/mesalib/src/mesa/state_tracker/st_cb_fbo.c +++ b/mesalib/src/mesa/state_tracker/st_cb_fbo.c @@ -278,9 +278,16 @@ st_new_renderbuffer_fb(enum pipe_format format, int samples, boolean sw) case PIPE_FORMAT_R16G16_UNORM: strb->Base.InternalFormat = GL_RG16; break; + case PIPE_FORMAT_R32G32B32A32_FLOAT: + strb->Base.InternalFormat = GL_RGBA32F; + break; + case PIPE_FORMAT_R16G16B16A16_FLOAT: + strb->Base.InternalFormat = GL_RGBA16F; + break; default: _mesa_problem(NULL, - "Unexpected format in st_new_renderbuffer_fb"); + "Unexpected format %s in st_new_renderbuffer_fb", + util_format_name(format)); free(strb); return NULL; } diff --git a/mesalib/src/mesa/state_tracker/st_cb_texture.c b/mesalib/src/mesa/state_tracker/st_cb_texture.c index 74ae2d11d..d887455e6 100644 --- a/mesalib/src/mesa/state_tracker/st_cb_texture.c +++ b/mesalib/src/mesa/state_tracker/st_cb_texture.c @@ -137,15 +137,7 @@ st_DeleteTextureObject(struct gl_context *ctx, if (stObj->pt) pipe_resource_reference(&stObj->pt, NULL); if (stObj->sampler_view) { - if (stObj->sampler_view->context != st->pipe) { - /* Take "ownership" of this texture sampler view by setting - * its context pointer to this context. This avoids potential - * crashes when the texture object is shared among contexts - * and the original/owner context has already been destroyed. - */ - stObj->sampler_view->context = st->pipe; - } - pipe_sampler_view_reference(&stObj->sampler_view, NULL); + pipe_sampler_view_release(st->pipe, &stObj->sampler_view); } _mesa_delete_texture_object(ctx, texObj); } @@ -450,7 +442,7 @@ st_AllocTextureImageBuffer(struct gl_context *ctx, /* The parent texture object does not have space for this image */ pipe_resource_reference(&stObj->pt, NULL); - pipe_sampler_view_reference(&stObj->sampler_view, NULL); + pipe_sampler_view_release(st->pipe, &stObj->sampler_view); if (!guess_and_alloc_texture(st, stObj, stImage)) { /* Probably out of memory. @@ -717,7 +709,7 @@ decompress_with_blit(struct gl_context * ctx, /* destroy the temp / dest surface */ util_destroy_rgba_surface(dst_texture, dst_surface); - pipe_sampler_view_reference(&src_view, NULL); + pipe_sampler_view_release(pipe, &src_view); } @@ -1260,7 +1252,7 @@ st_finalize_texture(struct gl_context *ctx, firstImage->pt != stObj->pt && (!stObj->pt || firstImage->pt->last_level >= stObj->pt->last_level)) { pipe_resource_reference(&stObj->pt, firstImage->pt); - pipe_sampler_view_reference(&stObj->sampler_view, NULL); + pipe_sampler_view_release(st->pipe, &stObj->sampler_view); } /* Find gallium format for the Mesa texture */ @@ -1300,7 +1292,7 @@ st_finalize_texture(struct gl_context *ctx, * gallium texture now. We'll make a new one below. */ pipe_resource_reference(&stObj->pt, NULL); - pipe_sampler_view_reference(&stObj->sampler_view, NULL); + pipe_sampler_view_release(st->pipe, &stObj->sampler_view); st->dirty.st |= ST_NEW_FRAMEBUFFER; } } |