summaryrefslogtreecommitdiffstats
path: root/src/mesa/main
Commit message (Collapse)AuthorAgeFilesLines
* mesa/main: Add function to find next higher power of two.Pauli Nieminen2010-02-061-0/+46
| | | | | | | | | With gcc implementation uses __builtin_clr which counts number of leading zeros. Fallback implementation uses bit manipulation. First it duplicates the highest bit to all lower bits and then adds one to get the power of two number.
* mesa: change ctx->Driver.ProgramStringNotify() to return GLbooleanBrian Paul2010-02-042-5/+16
| | | | | | | | | | | | | GL_TRUE indicates that the driver accepts the program. GL_FALSE indicates the program can't be compiled/translated by the driver for some reason (too many resources used, etc). Propogate this result up to the GL API: set GL_INVALID_OPERATION error if glProgramString() was called. Set shader program link status to GL_FALSE if glLinkProgram() was called. At this point, drivers still don't do any program checking and always return GL_TRUE.
* mesa: increase number of texture units to MAX_COMBINED_TEXTURE_IMAGE_UNITSBrian Paul2010-02-034-13/+25
| | | | | | | | | | | | | | | | | | | We were misinterpretting GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS previously. It's the number of texture units for which we need to keep state; not just the total number of texture units addressable by the vertex shader plus fragment shader. Since sw Mesa independently supports 16 texture units in vertex shaders and 16 texture units in fragment shaders, the max combined units is 32. Note that the docs for glActiveTexture() indicate the max legal unit is MAX(GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS, MAX_TEXTURE_COORDS) - 1. A new piglit test (texunits.c) tests the various texture unit limits. I'm pretty sure I've got this all right now, but additional reviews are welcome...
* mesa: re-dimension RasterTexCoords and CoordReplaceBrian Paul2010-02-031-2/+2
| | | | These are limited to the number of texture coordinate units.
* mesa: added texcoord unit assertionBrian Paul2010-02-031-0/+2
|
* mesa: use Elements() instead of MAX_TEXTURE_COORD_UNITSBrian Paul2010-02-031-1/+1
|
* mesa: added tex unit assert, use Elements() macroBrian Paul2010-02-031-1/+2
|
* mesa: check for invalid texture coord unit in glGet queriesBrian Paul2010-02-032-56/+147
|
* mesa: add error check for querying invalid texture matrixBrian Paul2010-02-032-5/+41
|
* mesa: use Elements() as limit in loops over texture/program matrix stacksBrian Paul2010-02-031-4/+4
|
* mesa: add out of bounds assertions for accessing texture matrix stackBrian Paul2010-02-031-0/+2
|
* mesa: Factor out the fb initialization details from _mesa_new_framebuffer.Francisco Jerez2010-02-032-13/+34
| | | | | | | | | | | This should make things easier for drivers wanting to work with a "subclass" of gl_framebuffer. The complementary "_mesa_initialize_framebuffer" function is now called "_mesa_initialize_window_framebuffer" for the sake of symmetry. Signed-off-by: Brian Paul <[email protected]>
* mesa: Add a BITSET_FFS function.Francisco Jerez2010-02-021-1/+24
| | | | | | | It will be useful for the nouveau DRI driver and IMHO there's no reason to keep it private. Signed-off-by: Brian Paul <[email protected]>
* mesa: Remove unnecessary headers.Vinson Lee2010-02-013-7/+0
|
* mesa: Remove unnecessary headers.Vinson Lee2010-01-314-10/+0
|
* Merge commit 'lb2/arb_fragment_coord_conventions'Keith Whitwell2010-01-291-1/+2
|\
| * mesa: don't expose GL_ARB_fragment_coord_conventions until the GLSL part is doneLuca Barbieri2010-01-291-1/+2
| | | | | | | | | | | | | | | | Exposing it was incorrect, as the GLSL part of the extension is missing. We still keep the ARB_fragment_coord_conventions field, so that the ARBfp parser can know whether to accept or reject the keywords.
* | mesa: do state validation in _mesa_valid_to_render()Brian Paul2010-01-292-9/+4
|/ | | | | | | | | ...rather than checking/validating before all the calls to _mesa_valid_to_render() and valid_to_render(). The next patch will actually fix some bugs... (cherry picked from commit 23eda89ec89e2bd5bc26077bd56e8d6b5d4040d4)
* mesa: fix double->float assignment warningsBrian Paul2010-01-271-3/+3
| | | | Reported by Karl Schultz.
* mesa: fix int/uint comparison warningsBrian Paul2010-01-272-7/+7
| | | | Reported by Karl Schultz.
* mesa: more info in glActiveTexture error msgBrian Paul2010-01-271-1/+2
|
* Merge branch 'mesa_7_7_branch'Brian Paul2010-01-262-14/+19
|\ | | | | | | Merging was easier than cherry picking in this instance.
| * mesa: Don't bind DRAW/READ_FRAMEBUFFER separately without FBO blit supportErik Wien2010-01-261-8/+19
| | | | | | | | | | | | | | | | | | | | | | If GL_EXT_framebuffer_blit was not supported _mesa_DeleteFramebuffersEXT would raise an error when deleting the currently bound framebuffer. This because it tried to bind the default DRAW- and READ_FRAMEBUFFER separately. This patch binds the default FRAMEBUFFER instead in that case. Encountered in the fbo/fbo-copyteximage piglit test on R600. Patch cleaned up a bit by Brian Paul.
| * mesa: remove redundant _MaxElement computationBrian Paul2010-01-261-6/+0
| | | | | | | | | | | | | | | | Eric added some new code to check if offset < obj_size before computing _MaxElement but my original code was still present afterward and it clobbered the _MaxElement value. Not sure if this came from a bad merge or what.
* | Merge branch 'mesa_7_7_branch'Brian Paul2010-01-251-3/+3
|\| | | | | | | | | | | | | | | | | | | | | Conflicts: src/mesa/drivers/dri/intel/intel_screen.c src/mesa/drivers/dri/intel/intel_swapbuffers.c src/mesa/drivers/dri/r300/r300_emit.c src/mesa/drivers/dri/r300/r300_ioctl.c src/mesa/drivers/dri/r300/r300_tex.c src/mesa/drivers/dri/r300/r300_texstate.c
| * mesa: move _mesa_debug() call earlier in _mesa_ScissorBrian Paul2010-01-241-3/+3
| | | | | | | | Part of a patch from Xavier Chantry <[email protected]>
* | Merge branch 'arb_half_float_vertex'Dave Airlie2010-01-234-2228/+2255
|\ \
| * | mesa: add core support for ARB_half_float_vertex.Dave Airlie2010-01-233-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | Adds the extension to the list + support to the APIs. also add t_draw.c support to convert for sw rast. Signed-off-by: Dave Airlie <[email protected]>
| * | glapi: add GL_HALF_FLOAT enum support.Dave Airlie2010-01-231-2228/+2231
| | | | | | | | | | | | | | | | | | Regenerate enums files and GLX indirect. Signed-off-by: Dave Airlie <[email protected]>
* | | Merge branch 'mesa_7_7_branch'Brian Paul2010-01-2228-63/+3
|\ \ \ | | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gallium/auxiliary/draw/draw_context.c src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline.c src/gallium/auxiliary/pipebuffer/Makefile src/gallium/auxiliary/pipebuffer/SConscript src/gallium/auxiliary/pipebuffer/pb_buffer_fenced.c src/gallium/auxiliary/tgsi/tgsi_scan.c src/gallium/drivers/i915/i915_surface.c src/gallium/drivers/i915/i915_texture.c src/gallium/drivers/llvmpipe/lp_setup.c src/gallium/drivers/llvmpipe/lp_tex_sample_c.c src/gallium/drivers/llvmpipe/lp_texture.c src/gallium/drivers/softpipe/sp_prim_vbuf.c src/gallium/state_trackers/xorg/xorg_dri2.c src/gallium/winsys/drm/intel/gem/intel_drm_api.c src/gallium/winsys/drm/nouveau/drm/nouveau_drm_api.c src/gallium/winsys/drm/radeon/core/radeon_drm.c src/gallium/winsys/drm/vmware/core/vmw_screen_dri.c src/mesa/state_tracker/st_cb_clear.c
| * | mesa: Remove unnecessary header from attrib.c.Vinson Lee2010-01-181-1/+0
| | |
| * | mesa: Remove unnecessary header from blend.c.Vinson Lee2010-01-181-1/+0
| | |
| * | mesa: Remove unnecessary headers from buffers.c.Vinson Lee2010-01-181-2/+0
| | |
| * | mesa: Remove unnecessary header from convolve.c.Vinson Lee2010-01-181-1/+0
| | |
| * | mesa: Fix typo of 'unknown' in debug.c.Vinson Lee2010-01-181-1/+1
| | |
| * | mesa: Remove unnecessary headers from debug.c.Vinson Lee2010-01-181-2/+0
| | |
| * | mesa: Remove unnecessary header from depthstencil.c.Vinson Lee2010-01-181-1/+0
| | |
| * | mesa: Remove unnecessary headers from dlist.c.Vinson Lee2010-01-181-21/+0
| | |
| * | mesa: Remove unnecessary header from drawpix.c.Vinson Lee2010-01-181-1/+0
| | |
| * | mesa: Remove unnecessary header from enable.c.Vinson Lee2010-01-181-1/+0
| | |
| * | mesa: Remove unnecessary headers from fbobject.c.Vinson Lee2010-01-181-3/+0
| | |
| * | mesa: Remove unnecessary header from formats.c.Vinson Lee2010-01-181-1/+0
| | |
| * | mesa: Remove unnecessary header from image.c.Vinson Lee2010-01-181-1/+0
| | |
| * | mesa: Remove unnecessary headers from lines.c.Vinson Lee2010-01-181-2/+0
| | |
| * | mesa: Remove unnecessary header from mipmap.c.Vinson Lee2010-01-181-1/+0
| | |
| * | mesa: Remove unnecessary header from pixel.c.Vinson Lee2010-01-181-1/+0
| | |
| * | mesa: Remove unnecessary headers from pixelstore.c.Vinson Lee2010-01-181-3/+0
| | |
| * | mesa: Remove unnecessary header from points.c.Vinson Lee2010-01-181-1/+0
| | |
| * | mesa: Remove unnecessary header from polygon.c.Vinson Lee2010-01-181-1/+0
| | |
| * | mesa: Remove unnecessary header from state.c.Vinson Lee2010-01-181-1/+0
| | |