summaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary/util/u_prim.h
Commit message (Collapse)AuthorAgeFilesLines
* gallium/util: add a helper for calculating primitive count from vertex countMarek Olšák2014-07-281-0/+15
| | | | | | This is needed by the following commit which is a candidate for stable too. Cc: mesa-stable@lists.freedesktop.org
* s/Tungsten Graphics/VMware/José Fonseca2014-01-171-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Tungsten Graphics Inc. was acquired by VMware Inc. in 2008. Leaving the old copyright name is creating unnecessary confusion, hence this change. This was the sed script I used: $ cat tg2vmw.sed # Run as: # # git reset --hard HEAD && find include scons src -type f -not -name 'sed*' -print0 | xargs -0 sed -i -f tg2vmw.sed # # Rename copyrights s/Tungsten Gra\(ph\|hp\)ics,\? [iI]nc\.\?\(, Cedar Park\)\?\(, Austin\)\?\(, \(Texas\|TX\)\)\?\.\?/VMware, Inc./g /Copyright/s/Tungsten Graphics\(,\? [iI]nc\.\)\?\(, Cedar Park\)\?\(, Austin\)\?\(, \(Texas\|TX\)\)\?\.\?/VMware, Inc./ s/TUNGSTEN GRAPHICS/VMWARE/g # Rename emails s/alanh@tungstengraphics.com/alanh@vmware.com/ s/jens@tungstengraphics.com/jowen@vmware.com/g s/jrfonseca-at-tungstengraphics-dot-com/jfonseca-at-vmware-dot-com/ s/jrfonseca\?@tungstengraphics.com/jfonseca@vmware.com/g s/keithw\?@tungstengraphics.com/keithw@vmware.com/g s/michel@tungstengraphics.com/daenzer@vmware.com/g s/thomas-at-tungstengraphics-dot-com/thellstom-at-vmware-dot-com/ s/zack@tungstengraphics.com/zackr@vmware.com/ # Remove dead links s@Tungsten Graphics (http://www.tungstengraphics.com)@Tungsten Graphics@g # C string src/gallium/state_trackers/vega/api_misc.c s/"Tungsten Graphics, Inc"/"VMware, Inc"/ Reviewed-by: Brian Paul <brianp@vmware.com>
* util: s/int/unsigned/ to silence some MSVC warningsBrian Paul2013-06-261-2/+2
|
* util/prim: add u_reduced_prims_for_vertices()Chia-I Wu2013-05-031-0/+20
| | | | | | | | The function returns the number of reduced/tessellated primitives for the given vertex count. Signed-off-by: Chia-I Wu <olvaffe@gmail.com> Acked-by: Zack Rusin <zackr@vmware.com>
* util/prim: assorted fixes for u_decomposed_prims_for_vertices()Chia-I Wu2013-05-031-11/+11
| | | | | | | | | | | Switch to '>=' for comparisons, and it becomes obvious that the comparison for PIPE_PRIM_QUAD_STRIP was wrong. Add minimum vertex count check for PIPE_PRIM_LINE_LOOP. Return 1 for PIPE_PRIM_POLYGON with 3 vertices. Signed-off-by: Chia-I Wu <olvaffe@gmail.com> Acked-by: Zack Rusin <zackr@vmware.com>
* util/prim: use vertex count info in u_validate_pipe_prim()Chia-I Wu2013-05-031-32/+2
| | | | | | | As a side effect, primitives with adjacency are now correctly validated. Signed-off-by: Chia-I Wu <olvaffe@gmail.com> Acked-by: Zack Rusin <zackr@vmware.com>
* util/prim: fix the name of the include guardChia-I Wu2013-05-031-2/+2
| | | | | | | It should be U_PRIM_H, not U_BLIT_H. Signed-off-by: Chia-I Wu <olvaffe@gmail.com> Acked-by: Zack Rusin <zackr@vmware.com>
* draw: use u_assembled_prim() instead of u_assembled_primitive()Chia-I Wu2013-05-031-8/+0
| | | | | | | The latter function is also removed as a result of the change. Signed-off-by: Chia-I Wu <olvaffe@gmail.com> Acked-by: Zack Rusin <zackr@vmware.com>
* util/prim: clean up and add commentsChia-I Wu2013-05-031-60/+107
| | | | | | | | | | | | | Move together (or add) functions to decompose/reduce/assemble a primitive, give them consistent names, and document them. Add u_prim_vertex_count() so that the vertex count information can be used elsewhere. u_assembled_primitive() will be removed in a folow-on commit. [olv: fix a warning when -Wold-style-declaration is enabled] Signed-off-by: Chia-I Wu <olvaffe@gmail.com> Acked-by: Zack Rusin <zackr@vmware.com>
* util/prim: fix primitive trimming for triangles with adjacencyChia-I Wu2013-05-031-2/+2
| | | | | | | Fix for PIPE_PRIM_TRIANGLES_ADJACENCY and PIPE_PRIM_TRIANGLE_STRIP_ADJACENCY. Signed-off-by: Chia-I Wu <olvaffe@gmail.com> Acked-by: Zack Rusin <zackr@vmware.com>
* draw: implement primitive assemblerZack Rusin2013-04-181-0/+21
| | | | | | | | | | | | | | | | | | | | Input assembler needs to be able to decompose adjacency primitives into something that can be understood by the rest of the pipeline. The specs say that the adjacency primitives are *only* visible in the geometry shader, for everything else they need to be decomposed. Which in most of the cases is not an issue, because the geometry shader always decomposes them for us, but without geometry shader we were passing unchanged adjacency primitives to the rest of the pipeline and causing crashes everywhere. This commit introduces a primitive assembler which, if geometry shader is missing and the input primitive is one of the adjacency primitives, decomposes them into something that the rest of the pipeline can understand. Signed-off-by: Zack Rusin <zackr@vmware.com> Reviewed-by: Jose Fonseca <jfonseca@vmware.com> Reviewed-by: Roland Scheidegger <sroland@vmware.com> Reviewed-by: Brian Paul <brianp@vmware.com>
* util/prim: fix decomposed counts for adjacency primitivesZack Rusin2013-04-181-4/+4
| | | | | | Signed-off-by: Zack Rusin <zackr@vmware.com> Reviewed-by: Brian Paul <brianp@vmware.com> Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
* draw: implement pipeline statistics in the draw moduleZack Rusin2013-04-161-15/+20
| | | | | | | | | | | | | This is a basic implementation of the pipeline statistics in the draw module. The interface is similar to the stream output statistics and also requires that the callers explicitly enable it. Included is the implementation of the interface in llvmpipe and softpipe. Only softpipe enables the pipeline statistics capability though because llvmpipe is lacking gathering of the fragment shading and rasterization statistics. Signed-off-by: Zack Rusin <zackr@vmware.com> Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
* util: Fix reduction of line adjacency primitives.José Fonseca2012-11-091-0/+2
| | | | | Reviewed-by: Brian Paul <brianp@vmware.com> Reviewed-by: Roland Scheidegger <sroland@vmware.com>
* util: Avoid signed/unsigned comparison in u_trim_pipe_prim().José Fonseca2011-11-141-1/+1
|
* u_prim: convert u_trim_pipe_prim to table driven.Dave Airlie2011-06-031-47/+24
| | | | | | | | This makes this function not be an always miss for the branch predictor. Noticed using cachegrind, makes a minor difference to gears numbers on r600g. Signed-off-by: Dave Airlie <airlied@redhat.com>
* gallium/draw: forgot about PIPE_PRIM_LINE_STRIP_ADJACENCYZack Rusin2010-08-031-0/+1
|
* gallium/util: add extra primitives to the trimmerZack Rusin2010-08-031-0/+13
|
* draw: geometry shader fixesZack Rusin2010-06-101-0/+46
| | | | | don't overwrite the inputs and make sure the correct primitive is used on entry
* util: Don't include system headers inside extern "C" { ... }José Fonseca2010-02-031-3/+3
| | | | That breaks when some of the system headers have C++ code.
* util: Add missing includes.José Fonseca2010-02-011-0/+1
|
* util: put vertices_per_primitive function in its proper locationZack Rusin2009-12-251-0/+33
|
* i965g: more work on compiling, particularly the brw_draw filesKeith Whitwell2009-10-251-0/+2
|
* gallium/util: s/boolean/unsigned/Brian Paul2009-06-191-1/+1
|
* util: add reduced prim helperKeith Whitwell2009-01-191-0/+16
|
* util: new funcs for triming/validating primitivesKeith Whitwell2008-12-101-0/+122