mesa: add texobj support for ARB_texture_multisample
Adds the new texture targets, and per-image state for GL_TEXTURE_SAMPLES and GL_TEXTURE_FIXED_SAMPLE_LOCATIONS. V2: - Allow multisample texture targets in glInvalidateTexSubImage too. This was already partly there, but I missed it the first time around since the interaction is defined in a newer extension. Fixed weird indentation. - Allow multisample array textures in glFramebufferTextureLayer. This was overlooked as the tests originally only used 2d multisample textures. V3: - Set min/mag filters sensibly for multisample textures. This can't actually be changed by the user, so it's more sensible to initialize it correctly than to hack around it being bogus later. V4: - Tidy up initial min/mag filter setup. Setup in _mesa_initialize_texture_object was bogus, but benign since finish_texture_init() clobbered everything with correct values. For V4, just do the setup in finish_texture_init(). V5: - Don't break glPopAttrib(GL_TEXTURE_BIT) Signed-off-by: Chris Forbes <chrisf@ijw.co.nz> [V2] Reviewed-by: Paul Berry <stereotype441@gmail.com> Reviewed-by: Eric Anholt <eric@anholt.net> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
This commit is contained in:
@@ -92,6 +92,8 @@ _mesa_alloc_shared_state(struct gl_context *ctx)
|
||||
for (i = 0; i < NUM_TEXTURE_TARGETS; i++) {
|
||||
/* NOTE: the order of these enums matches the TEXTURE_x_INDEX values */
|
||||
static const GLenum targets[] = {
|
||||
GL_TEXTURE_2D_MULTISAMPLE,
|
||||
GL_TEXTURE_2D_MULTISAMPLE_ARRAY,
|
||||
GL_TEXTURE_CUBE_MAP_ARRAY,
|
||||
GL_TEXTURE_BUFFER,
|
||||
GL_TEXTURE_2D_ARRAY_EXT,
|
||||
|
Reference in New Issue
Block a user