summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/svga
Commit message (Collapse)AuthorAgeFilesLines
* svga: implement blitMarek Olšák2012-09-304-0/+78
| | | | Reviewed-by: Brian Paul <[email protected]>
* gallium: add PIPE_CAP_TEXTURE_MULTISAMPLEMarek Olšák2012-09-301-0/+1
| | | | | Tested-by: Michel Dänzer <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* svga: minor code reformattingBrian Paul2012-08-161-2/+3
| | | | To be consistent with other functions.
* svga: add 'start' parameter to bind_sampler_states/views()Brian Paul2012-08-161-24/+65
|
* svga: move result->key expression after result != NULL checkBrian Paul2012-08-161-1/+3
|
* svga: fix result==NULL logic in emit_fs_consts()Brian Paul2012-08-161-23/+25
| | | | | | | | The previous test for result != NULL was kind of bogus since we dereferenced the pointer earlier in the code. Now, check for result != NULL first, then get the result->key info. Also, remove the useless "offset +=" code at the end.
* svga: update comment (s/SVGA_NEW_VS_RESULT/SVGA_NEW_VS_PRESCALE/)Brian Paul2012-08-161-1/+1
|
* svga: rename svga_hw_vs_parameters -> svga_hw_vs_constantsBrian Paul2012-08-163-6/+6
| | | | and similarly for svga_hw_fs_parameters
* svga: remove unused svga_shader::use_sm30 field, add commentsBrian Paul2012-08-082-4/+9
| | | | Reviewed-by: José Fonseca <[email protected]>
* svga: remove unused svga_winsys_handle typeBrian Paul2012-08-081-3/+0
| | | | Reviewed-by: José Fonseca <[email protected]>
* svga: remove questionable INLINE qualifiersBrian Paul2012-08-021-2/+2
|
* svga: sort #includesBrian Paul2012-08-021-4/+4
|
* svga: add some comments in svga_screen_cache.cBrian Paul2012-08-021-1/+14
|
* svga: whitespace, formatting fixesBrian Paul2012-08-021-52/+54
|
* svga: remove unneeded 'struct svga_screen' declarationsBrian Paul2012-08-022-2/+0
|
* svga: initialize svga_compile_key to zeros to be safeBrian Paul2012-07-261-0/+4
|
* svga: fix invalid memory reference in needs_to_create_zero()Brian Paul2012-07-261-5/+5
| | | | | | | | | | | | | | The emit->key.fkey info is only valid if we're generating a fragment shader. We should not look at it if we're generating a vertex shader. When generating a vertex shader, the value of emit->key.fkey.num_textures was garbage and the loop over num_textures would read invalid data. At best this would cause us to emit an unused constant. At worse, we could segfault. Just by dumb luck, fkey.num_textures was usually a smallish integer. NOTE: This is a candidate for the 8.0 branch. Reviewed-by: José Fonseca <[email protected]>
* gallium: add QUERY_TIMESTAMP cap and get_timestamp screen functionMarek Olšák2012-07-101-0/+1
|
* svga: whitespace fixesBrian Paul2012-07-051-114/+90
|
* svga: implement TGSI_OPCODE_ROUNDBrian Paul2012-07-051-15/+51
| | | | | | | ROUND and TRUNC are implemented with one function to reduce code duplication. Note: ROUND isn't actually used yet, but probably will be soon. Reviewed-by: José Fonseca <[email protected]>
* svga: fix CMP translation for vertex shadersBrian Paul2012-07-051-36/+37
| | | | | | | | | | Converting CMP to SLT+LRP didn't work when src2 or src3 was Inf/NaN. That's the case for GLSL sqrt(0). sqrt(0) actually happens in many piglit auto-generated tests that use the distance() function. v2: remove debug/devel code, per Jose Reviewed-by: José Fonseca <[email protected]>
* svga: properly implement TRUNC instructionBrian Paul2012-07-051-1/+54
| | | | | | | | | | Was previously implemented with FLOOR. Fixes quite a few piglit tests of float->int conversion, integer division, etc. v2: clean up left over debug/devel code, per Jose Reviewed-by: José Fonseca <[email protected]>
* svga: fix register collision issue in emit_conditional()Brian Paul2012-07-051-0/+24
| | | | | | | If the 'dst' register is the same as the 'pass' register we'll generate invalid code. Use a temporary register in that case. Reviewed-by: José Fonseca <[email protected]>
* svga: emit some debug messages when shader compilation failsBrian Paul2012-07-051-4/+10
|
* svga: return 120 for PIPE_CAP_GLSL_FEATURE_LEVELBrian Paul2012-06-261-1/+3
| | | | Reviewed-by: Marek Olšák <[email protected]>
* svga: handle missing PIPE_CAP_x queriesBrian Paul2012-06-261-9/+14
| | | | | | And fix incorrect error message for a bad shader type/number. Reviewed-by: Marek Olšák <[email protected]>
* svga: return 1 for PIPE_CAP_MIXED_COLORBUFFER_FORMATSBrian Paul2012-06-261-1/+3
| | | | | | | | | | | This is actually required for GL_ARB_framebuffer_object, but the state tracker doesn't currently check it. Direct3D 9 allows mixed format color buffers with some restrictions. Setting this allows Unigine Heaven 2.5 and 3.0 to run. Tested both on GL and D3D hosts. Reviewed-by: Jose Fonseca <[email protected]> Reviewed-by: Jakob Bornecrantz <[email protected]>
* svga: init pointer to NULL to silence MSVC warningBrian Paul2012-06-221-1/+1
|
* gallium: Add PIPE_CAP_START_INSTANCEFredrik Höglund2012-06-191-0/+1
| | | | Reviewed-by: Brian Paul <[email protected]>
* scons: Do not build svga if using Solaris Studio C compiler.Vinson Lee2012-06-181-0/+4
| | | | | | | | Solaris Studio C compiler does not support anonymous structs and anonymous unions. Signed-off-by: Vinson Lee <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* svga: fix synchronization bug between sampler views and surfacesBrian Paul2012-06-181-0/+5
| | | | | | | | | | This fixes a bug where a sampler view was using stale texture/resource data when the texture was modified through a surface (render to texture). Bumping the texture and layer ages triggers sampler view revalidation. Fixes piglit fbo-blit failure. Reviewed-by: José Fonseca <[email protected]>
* svga: make svga_surface_needs_propagation() surface constBrian Paul2012-06-142-3/+3
|
* svga: add svga_surface_const() cast wrapperBrian Paul2012-06-141-0/+8
|
* svga: fix comment typoBrian Paul2012-06-141-1/+1
|
* automake: Globally add stub automake targets to the old Makefiles.Eric Anholt2012-06-111-3/+0
| | | | | | | | | I tried to update all the old Makefiles that included the default config to be sure they had a default target if they didn't previously have one, since this new all target will always point at it. Almost everything had one. Reviewed-by: Kenneth Graunke <[email protected]>
* svga: fix saturated TEX instructionsBrian Paul2012-05-311-6/+13
| | | | | | | TEX instructions can't do saturation. Do the TEX into a temp reg w/out saturation, then do a MOV_SAT. Reviewed-by: Jakob Bornecrantz <[email protected]>
* draw: simplify index buffer specificationBrian Paul2012-05-311-5/+4
| | | | | Replace draw_set_index_buffer() and draw_set_mapped_index_buffer() with draw_set_indexes() which simply takes a pointer and an index size.
* svga: remove the special zero-stride vertex array codeBrian Paul2012-05-259-153/+12
| | | | | This code actually hasn't been needed for some time now. We can just treat a zero-stride vertex array like any other non-zero-stride array.
* svga: whitespace, comments, formatting clean-upsBrian Paul2012-05-191-38/+31
|
* svga: return PIPE_OK instead of 0Brian Paul2012-05-195-11/+11
| | | | And fix the emit_rss() function's return type.
* svga: fix zero-stride vertex array bugBrian Paul2012-05-191-2/+6
| | | | | | | | | | | | | | For zero-stride vertex arrays, the svga driver copies the value into the constant value and uses that value in the shader. The recent gallium-userbuf changes caused a regression in this. An example symptom was per-primitive glColor3f() calls getting ignored. Where we copied the vertex value from the vertex buffer to the constant buffer we neglected to take into account the pipe_vertex_buffer::buffer_offset field. Adding that value to the source offset fixes the problem. Actually, it looks like we should have been doing this all along, but it never was an issue before for some reason.
* svga: fix FBO / viewport bugsBrian Paul2012-05-151-7/+24
| | | | | | | | | | | When drawing to a FBO, the viewport wasn't always set correctly. It was fine in the usual case of the viewport dims matching the surface dims but broken otherwise. In particular, this was happening because the viewport scale is negative for FBO rendering. The piglit fbo-viewport test exercises this. Reviewed-by: José Fonseca <[email protected]>
* gallium: remove user_buffer_create from the interfaceMarek Olšák2012-05-121-1/+0
| | | | Nothing uses it now.
* Merge branch 'gallium-userbuf'Marek Olšák2012-05-117-35/+31
|\ | | | | | | | | | | | | | | Conflicts: src/gallium/docs/source/screen.rst src/gallium/drivers/nv50/nv50_state.c src/gallium/include/pipe/p_defines.h src/mesa/state_tracker/st_draw.c
| * svga: check for and skip null vertex buffer pointersBrian Paul2012-05-011-8/+12
| | | | | | | | | | | | Fixes regressions with google earth and other things. Reviewed-by: José Fonseca <[email protected]>
| * svga: cast away const to silence warningBrian Paul2012-05-011-1/+2
| |
| * gallium: remove pipe_resource::user_ptrMarek Olšák2012-04-301-1/+0
| | | | | | | | It's unused now.
| * gallium: add void *user_buffer to pipe_constant_bufferMarek Olšák2012-04-301-0/+11
| | | | | | | | This reduces CPU overhead when updating constants.
| * gallium: add void *user_buffer in pipe_index_bufferMarek Olšák2012-04-301-1/+1
| | | | | | | | | | | | | | Adapted drivers: i915, llvmpipe, r300, r600, radeonsi, softpipe. User index buffers have been disabled in nv30, nv50, nvc0 and svga to keep things working.
| * gallium: remove pipe_context::redefine_user_bufferMarek Olšák2012-04-303-25/+0
| |