summaryrefslogtreecommitdiffstats
path: root/src/mesa/main
Commit message (Collapse)AuthorAgeFilesLines
* mesa: add null ptr checks in GetTexParameterI[u]iv() functionsBrian Paul2011-08-041-0/+4
|
* mesa: condense GL_TEXTURE_RESIDENT query codeBrian Paul2011-08-041-16/+4
|
* mesa: make error handling in glGetTexParameter() a bit more conciseBrian Paul2011-08-041-170/+96
|
* mesa: Ensure that gl_shader_program::InfoLog is never NULLIan Romanick2011-08-021-5/+6
| | | | | | | | | | | | | | | | This prevents assertion failures in ralloc_strcat. The ralloc_free in _mesa_free_shader_program_data can be omitted because freeing the gl_shader_program in _mesa_delete_shader_program will take care of this automatically. A bunch of this code could use a refactor to use ralloc a bit more effectively. A bunch of the things that are allocated with malloc and owned by the gl_shader_program should be allocated with ralloc (using the gl_shader_program as the context). Signed-off-by: Ian Romanick <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
* mesa: minor comment changes in teximage.cBrian Paul2011-07-291-7/+2
|
* mesa: add missing breaks for GL_TEXTURE_CUBE_MAP_SEAMLESS queriesBrian Paul2011-07-291-6/+8
| | | | | | And fix indentation. NOTE: This is a candidate for the 7.11 branch.
* mesa: Fix ff fragment shader inputs calculation when enabling a VS.Eric Anholt2011-07-281-2/+1
| | | | | | | | | | | | | | | | | | The FF VS generation happens just after the FF FS generation in state.c, so the ctx->VP._Current value is for the previous state update's vertex shader, not the one that will be chosen as a result of this state update. The vertexShader and vertexProgram variables should be accurately telling us whether there's going to be a ctx->VP._Current (except on _MaintainTnlProgram drivers, where it's always true). The glsl-vs-statechange-1 test was created to test for this, but it turns out that the bug is hidden by the fact that we call _mesa_update_state() twice per draw call -- once from _mesa_valid_to_render() and once from vbo_draw_arrays(), and the second one was fixing up the first one. Reviewed-by: Brian Paul <[email protected]>
* mesa: test against MESA_FORMAT_NONE in _mesa_GetTexLevelParameteriv()Brian Paul2011-07-281-1/+1
|
* mesa: don't forget about sampleBuffers in framebuffer visual updateChristoph Bumiller2011-07-271-0/+1
| | | | | | | Otherwise multisample will never been enabled for multisample renderbuffers. Reviewed-by: Brian Paul <[email protected]>
* mesa: Make _mesa_get_compressed_formats match the texture compression specsIan Romanick2011-07-253-30/+93
| | | | | | | | | | | The implementation deviated slightly from the GL_EXT_texture_sRGB spec and from other implementations. A giant comment block was added to justify the somewhat odd behavior of this function. In addition, the interface had unnecessary cruft. The 'all' parameter was false at all callers, so it has been removed. Reviewed-by: Brian Paul <[email protected]>
* mesa: Return the correct internal fmt when a generic compressed fmt was usedIan Romanick2011-07-251-3/+17
| | | | | | | | | | If an application requests a generic compressed format for a texture and the driver does not pick a specific compressed format, return the generic base format (e.g., GL_RGBA) for the GL_TEXTURE_INTERNAL_FORMAT query. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=3165 Reviewed-by: Brian Paul <[email protected]>
* mesa: Add utility function to get base format from a GL compressed formatIan Romanick2011-07-252-0/+91
| | | | Reviewed-by: Brian Paul <[email protected]>
* mesa: Add an ifndef guard around the definition of the INLINE macroPaul Berry2011-07-221-20/+22
| | | | | | | | | Several Mesa headers redundantly define the INLINE macro. Adding this guard prevents the compiler from complaining about macro redefinition. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* Merge branch 'remove-copyteximage-hook'Brian Paul2011-07-213-41/+35
|\
| * mesa: remove unused dd_function_table::CopyTexImage1D/2D() hooksBrian Paul2011-07-191-18/+0
| |
| * mesa: remove comments referring to Driver.TexImage1D/2DBrian Paul2011-07-191-6/+3
| |
| * mesa: stop using ctx->Driver.CopyTexImage1D/2D() hooksBrian Paul2011-07-191-17/+32
| |
* | mesa: GLES2 should return different error enums for invalid fbo queriesMarek Olšák2011-07-211-7/+16
|/ | | | | | | | | | | | | | ES 2.0.25 page 127 says: If the value of FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE is NONE, then querying any other pname will generate INVALID_ENUM. See also: b9e9df78a03edb35472c2e231aef4747e09db792 NOTE: This is a candidate for the 7.10 and 7.11 branches. Reviewed-by: Ian Romanick <[email protected]>
* mesa: update, shorten some comments in dd.hBrian Paul2011-07-191-38/+13
|
* mesa: fix unused-but-set-variable warnings in dlist.cMarek Olšák2011-07-151-6/+6
|
* mesa: use inline function wrapper for _mesa_reference_texobj()Brian Paul2011-07-142-7/+15
|
* mesa: use inline function wrapper for _mesa_reference_renderbuffer()Brian Paul2011-07-142-9/+14
|
* mesa: use inline function wrapper for _mesa_reference_framebuffer()Brian Paul2011-07-142-9/+13
|
* main: use inline function wrapper for _mesa_reference_buffer_object()Brian Paul2011-07-142-7/+16
|
* mesa: Fix assertion failure in X8_Z24/Z24_X8 texfetch.Eric Anholt2011-07-121-2/+4
| | | | Reviewed-by: Ian Romanick <[email protected]>
* mesa: fix assertion failure in delete_wrapperMarek Olšák2011-07-111-1/+2
|
* mesa: add a comment in _mesa_test_formatsMarek Olšák2011-07-111-0/+1
|
* mesa: fix assertion failure in _mesa_test_formatsMarek Olšák2011-07-111-1/+2
| | | | Z32_FLOAT_X24S8 has DataType of GL_NONE.
* mesa: implement packing of DEPTH_STENCIL & FLOAT_32_UNSIGNED_INT_24_8_REV comboMarek Olšák2011-07-112-7/+18
| | | | Tested with the new piglit fbo-depthstencil test.
* mesa: return early if mask is cleared to zero in BlitFramebufferMarek Olšák2011-07-101-0/+4
| | | | | | | From ARB_framebuffer_object: If a buffer is specified in <mask> and does not exist in both the read and draw framebuffers, the corresponding bit is silently ignored.
* mesa: implement depth/stencil renderbuffer wrapper accessors for Z32F_X24S8Marek Olšák2011-07-103-24/+313
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: implement generatemipmap for GL_FLOAT_32_UNSIGNED_INT_24_8_REVMarek Olšák2011-07-101-0/+20
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: implement texstore for DEPTH32F_STENCIL8Marek Olšák2011-07-101-1/+67
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: implement texstore for DEPTH_COMPONENT32FMarek Olšák2011-07-101-5/+7
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: implement depth unpacking for GL_FLOAT_32_UNSIGNED_INT_24_8_REVMarek Olšák2011-07-101-2/+25
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: implement stencil unpacking for GL_FLOAT_32_UNSIGNED_INT_24_8_REVMarek Olšák2011-07-101-3/+32
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: implement texfetch functions for depth_buffer_floatMarek Olšák2011-07-102-8/+31
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: initial ARB_depth_buffer_float supportMarek Olšák2011-07-109-6/+125
| | | | | | | Using GL_NONE as DataType of Z32_FLOAT_X24S8, not sure what I should put there. The spec says the type is n/a. Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: Fix the BindSampler unit limit.Henri Verbeet2011-07-071-1/+1
| | | | | | | | | | | I'm not sure about this one. The current code actually follows the spec, but considering the spec is supposed to be written against GL 3.2 I'd say the spec is broken. I filled out a spec feedback form over a month ago, but either the form is broken, or nobody cares. Signed-off-by: Henri Verbeet <[email protected]> Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* mesa: Fix a couple of TexEnv unit limits.Henri Verbeet2011-07-071-3/+3
| | | | | | | | NOTE: This is a candidate for the 7.11 branch. Signed-off-by: Henri Verbeet <[email protected]> Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* mesa: Use the Elements macro for the sampler index assert in ↵Henri Verbeet2011-07-071-1/+1
| | | | | | | | | | | | validate_samplers(). This is probably nicer if the array size ever changes. NOTE: This is a candidate for the 7.11 branch. Signed-off-by: Henri Verbeet <[email protected]> Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* mesa: Allow sampling from units >= MAX_TEXTURE_UNITS in shaders.Henri Verbeet2011-07-073-4/+4
| | | | | | | | | | | | The total number of units used by a shader is limited to MAX_TEXTURE_UNITS, but the actual indices are only limited by MAX_COMBINED_TEXTURE_IMAGE_UNITS, since they're shared between vertex and fragment shaders. NOTE: This is a candidate for the 7.11 branch. Signed-off-by: Henri Verbeet <[email protected]> Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* mesa: Check the texture against all units in unbind_texobj_from_texunits().Henri Verbeet2011-07-071-1/+1
| | | | | | | | NOTE: This is a candidate for the 7.11 branch. Signed-off-by: Henri Verbeet <[email protected]> Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* mesa: fix texstore addressing bugs for depth/stencil formatsBrian Paul2011-07-061-12/+9
| | | | | | | | | | Using GLuint pointers worked when the pixel size was four bytes or the row stride was a multiple of four but was otherwise broken. Fixes failures found with the piglit fbo-stencil test. This helps to fix https://bugs.freedesktop.org/show_bug.cgi?id=38729 NOTE: This is a candidate for the 7.11 branch.
* mesa: Don't error on glFeedbackBuffer(size = 0, buffer = NULL)Eric Anholt2011-07-061-1/+1
| | | | | | | | | | | The existing error result doesn't appear in the GL 2.1 or 3.2 compatibility specs, and triggers an unexpected GL error in Intel's oglconform when it tries to reset the feedback state after usage so that the "diff the state at error time vs. context init time" code doesn't generate spurious diffs. The unexpected GL error then translates into testcase failure. Brian wants the safety check on buffer = NULL, though, so that people can't as easily set up a broken buffer.
* mesa: Don't skip glGetProgramLocalParam4dvARB if there was already an error.Eric Anholt2011-07-061-64/+53
| | | | | | | Like the previous commit, but fixes ARB_vertex_program/getlocal4d-with-error. v2: Move the success case line into the conditional, use ASSIGN_4V more.
* mesa: Don't skip glGetProgramEnvParam4dvARB if there was already an error.Eric Anholt2011-07-061-66/+46
| | | | | | | | | | Fixes a bug caught by oglconform, and now piglit ARB_vertex_program/getenv4d-with-error. The wrapping of an existing GL function made it so that we couldn't distinguish an error in looking up our arguments from an existing error. Instead, make a helper function to choose the param, and use it from multiple callers. v2: Move the success case line into the conditional, use COPY_4V more.
* mesa: bump version to 7.12 (devel)Brian Paul2011-06-291-2/+2
|
* mesa: don't allocate memory in _mesa_unpack_depth_span if we don't need itMarek Olšák2011-06-241-7/+7
| | | | Reviewed-by: Brian Paul <[email protected]>
* mesa: fix a memory leak in _mesa_unpack_depth_spanMarek Olšák2011-06-241-0/+1
| | | | | | NOTE: This is a candidate for the 7.10 branch. Reviewed-by: Brian Paul <[email protected]>