[Mesa-dev] RFC: ctx->Driver.Map/UnmapTextureImage() hooks

Eric Anholt eric at anholt.net
Fri Jul 22 12:32:56 PDT 2011


On Thu, 23 Jun 2011 19:08:51 -0600, Brian Paul <brianp at vmware.com> wrote:
> 
> I'd like to overhaul the part of Mesa related to texture memory 
> reading/writing.

OK, I'm taking a look at map-texture-image-v4.  I like what I'm seeing
overall, I just want to be sure that this isn't something that gets
squash-merged.  There's going to be breakage, and I want to be able to
bisect into it.

In the metaops code, please use glBufferData instead of
glBufferSubData.  If you BufferSubData, I have to block on the GPU if it
was using that buffer already.

In the comments for void (*MapTextureImage), please note what the units
of rowStride are.  I see that's present in swrast later, but I think the
mtypes.h and dd.h files are used for reference a lot (I do, certainly).

c029312ad62039904818a8b1765c6bcdf50044df is huge, and it doesn't even
build.  Ouch.  I think there's some room for splitting some of this up
so that we can get a nice series.

2025416f5090ee776a5c3291201f003e7c090718 -- if we're going to have
asserts that the array got initialized in the right order, I think I'd
rather see the array initialized by hand in an init function so that we
don't even need them (assuming tha the reason for this is that you're
still supporting compilers that don't do array[] = { [ELEMENT] = value,
}).
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20110722/382ff0d4/attachment.pgp>


More information about the mesa-dev mailing list