summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/textureview.c
Commit message (Collapse)AuthorAgeFilesLines
* mesa: add numLevels, numSamples to Driver.TestProxyTexImage()Brian Paul2016-07-151-2/+3
| | | | | | | | | | | | | So that the function can work properly with glTexStorage(), where we know how many mipmap levels there are. And so we can compute storage for MSAA textures. Also, remove the obsolete texture border parameter. A subsequent patch will update _mesa_test_proxy_teximage() to use these new parameters. Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
* mesa: add view classes for 3d astc formatsIlia Mirkin2016-05-231-2/+26
| | | | | Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
* mesa/textureview: move error checks up higherDave Airlie2016-05-031-24/+26
| | | | | | | | | | | | GL43-CTS.texture_view.errors checks for GL_INVALID_VALUE here but we catch these problems in the dimensionsOK check and return the wrong error value. This fixes: GL43-CTS.texture_view.errors. Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
* mesa: add GL_OES_copy_image supportIlia Mirkin2016-03-301-0/+86
| | | | | Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Dave Airlie <airlied@redhat.com>
* mesa/textureview: Make _lookup_view_class publicAntia Puentes2016-03-031-8/+4
| | | | | | | It will be used by the ARB_internalformat_query2 implementation to implement the VIEW_COMPATIBILITY_CLASS <pname> query. Reviewed-by: Dave Airlie <airlied@redhat.com>
* mesa: simplify some code with new _mesa_cube_face_target() functionBrian Paul2016-02-121-7/+2
| | | | | Reviewed-by: Roland Scheidegger <sroland@vmware.com> Reviewed-by: Timothy Arceri <timothy.arceri@collabora.com>
* mesa,meta: move gl_texture_object::TargetIndex initializationsBrian Paul2015-10-081-0/+2
| | | | | | | | | | | | | | | Before, we were unconditionally assigning the TargetIndex field in _mesa_BindTexture(), even if it was already set properly. Now we initialize TargetIndex wherever we initialize the Target field, in _mesa_initialize_texture_object(), finish_texture_init(), etc. v2: also update the meta_copy_image code. In make_view() the view_tex_obj->Target field was set, but not the TargetIndex field. Also, remove a second, redundant assignment to view_tex_obj->Target. Add sanity check assertions too. Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com> Tested-by: Mark Janes <mark.a.janes@intel.com>
* mesa: Rename _mesa_lookup_enum_by_nr() to _mesa_enum_to_string().Kenneth Graunke2015-07-201-5/+5
| | | | | | | Generated by sed; no manual changes. Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Brian Paul <brianp@vmware.com>
* mesa: code clean-ups in textureview.[ch]Brian Paul2015-05-261-31/+52
| | | | Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
* mesa: const qualify, return bool for _mesa_texture_view_compatible_format()Brian Paul2015-05-261-6/+6
| | | | Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
* mesa: remove unused ctx parameter for _mesa_select_tex_image()Brian Paul2015-01-051-3/+2
| | | | Reviewed-by: Eric Anholt <eric@anholt.net>
* mesa: force height of 1D textures to be 1 in texture viewsIlia Mirkin2014-09-011-0/+3
| | | | | Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Chris Forbes <chrisf@ijw.co.nz>
* mesa: Add GL API support for ARB_copy_imageJason Ekstrand2014-08-111-19/+17
| | | | | | | | | | | | | | | | | This adds the API entrypoint, error checking logic, and a driver hook for the ARB_copy_image extension. v2: Fix a typo in ARB_copy_image.xml and add it to the makefile v3: Put ARB_copy_image.xml in the right place alphebetically in the makefile and properly prefix the commit message v4: Fixed some line wrapping and added a check for null v5: Check for incomplete renderbuffers Signed-off-by: Jason Ekstrand <jason.ekstrand@intel.com> Reviewed-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com> Reviewed-by: Neil Roberts <neil@linux.intel.com> v6: Update dispatch_sanity for the addition of CopyImageSubData
* mesa: change gl_format to mesa_formatMark Mueller2014-01-271-2/+2
| | | | s/\bgl_format\b/mesa_format/g. Use better name for Mesa Formats enum
* mesa: fix texture view use of _mesa_get_tex_image()Chris Forbes2013-12-141-2/+7
| | | | | | | | | | | | | | The target parameter to _mesa_get_tex_image() is a target enum, not an index. When we're setting up faces for a cubemap, it should be CUBE_MAP_POSITIVE_X .. CUBE_MAP_NEGATIVE_Z; for all other targets it should be the same as the texobj's target. Fixes broken cubemaps [had only +X face but claimed to have all] produced by glTextureView, which then caused various crashes in the driver when we tried to use them. Signed-off-by: Chris Forbes <chrisf@ijw.co.nz> Reviewed-by: Brian Paul <brianp@vmware.com>
* mesa: s/uint/GLuint/ to fix MSVC errorBrian Paul2013-12-131-1/+1
|
* mesa: add texture_view helper function for TexStorageCourtney Goeltzenleuchter2013-12-131-0/+61
| | | | | | | | | Add helper function to set texture_view state from TexStorage calls. Include review feedback. Signed-off-by: Courtney Goeltzenleuchter <courtney@LunarG.com> Reviewed-by: Brian Paul <brianp@vmware.com>
* mesa: Fill out ARB_texture_view entry pointsCourtney Goeltzenleuchter2013-12-131-1/+538
| | | | | | | | | | | | | | | | Add Mesa TextureView logic. Incorporate feedback on ARB_texture_view: - Add S3TC VIEW_CLASSes to compatibility table - Use existing _mesa_get_tex_image - Clean up error strings - Use bool instead of GLboolean for internal functions - Split compound level & layer test into individual tests - eliminate helper macro for VIEW_CLASS table - do not call driver if ptr null. Signed-off-by: Courtney Goeltzenleuchter <courtney@LunarG.com> Reviewed-by: Brian Paul <brianp@vmware.com>
* mesa: Add API definitions for ARB_texture_viewCourtney Goeltzenleuchter2013-12-131-0/+65
Stub in glTextureView API call to go with the glTextureView API xml definition. Includes dispatch test for glTextureView Signed-off-by: Courtney Goeltzenleuchter <courtney@LunarG.com> Reviewed-by: Brian Paul <brianp@vmware.com>