summaryrefslogtreecommitdiff
path: root/src/gallium/auxiliary/draw/draw_pipe.c
AgeCommit message (Collapse)Author
2010-08-22draw: Don't assert if indices point outside vertex buffer.José Fonseca
This is valid input, and asserting here does causes the test suites that verify this to crash. Also, the assert was wrongly accepting the case max_index == vert_info->count which, IIUC, is the first vertex outside the buffer. Assuming the vert_info->count is precise (which often is not the case).
2010-08-16draw: Remove DRAW_PIPE_MAX_VERTICES and DRAW_PIPE_FLAG_MASK.Chia-I Wu
The higher bits of draw elements are no longer used for the stipple or edge flags.
2010-08-16draw: Replace vcache by vsplit.Chia-I Wu
vcache decomposes primitives while vsplit splits primitives. Splitting is generally easier to do and is faster. More importantly, vcache depends on flatshade_first to decompose. The outputs may have incorrect vertex order which is significant to GS.
2010-08-16draw: Add flags to draw_prim_info.Chia-I Wu
A primitive may be splitted in frontends. The splitted primitives should convey certain flag bits so that the decomposer can correctly decide the stipple or edge flags. This commit adds flags to draw_prim_info and updates the decomposer to honor the flags. Frontends and middle ends will be updated later.
2010-08-07draw: Assert that only the first vetex may have flags set.Chia-I Wu
642d5ba79abc6a231a5fdabb3454b9b082b0d7f8 removed flags masking for vertices other than the first one. Add assertions to be on the safe side.
2010-08-06draw: Remove unnecessary vertex flag ANDs.Chia-I Wu
Vertex flags are a contract between vcache and the pipeline. They are set only for the first vertex of a primitive.
2010-08-06draw: Include draw_decompose_tmp.h in draw_pt_decompose.h.Chia-I Wu
Use draw_decompose_tmp.h to replace pipeline primitive decomposer.
2010-07-29draw: do bounds checking of array elements (debug only)Brian Paul
Make sure that all the element indexes actually lie inside the vertex buffer. Also, rename pipe_run() to pipe_run_elts() to be more specific. And assert/check the vertex count for the non-indexed case.
2010-06-25draw: initialize vertex headerZack Rusin
2010-06-23draw: mask off DRAW_PIPE_FLAG_MASK bits in prim decompose codeBrian Paul
Any elt may potentially have flags bits set so mask off those bits everywhere. Fixes crashes with demos/gamma.c, redbook/polys.c, etc. but polygon stippling is still broken.
2010-06-15draw: run the pipeline with the correct number of vertsZack Rusin
verts per primitive, not total count
2010-06-15draw: fix primitive indexing in the pipelineZack Rusin
spotted by Keith
2010-06-15draw wipKeith Whitwell
2010-05-05gallium: rework provoking vertex codeBrian Paul
Builds on commit ddb0e18f6c5582d4d2cc59ffd16ad9c4639ed059 and fixes regressions in glean clipFlat test. We assume that Gallium drivers observe flatshade_first for all triangles and that all the assorted per-triangle calls in the 'draw' module also follow flatshade_first. Everything else builds on those rules. Gallium does not use follow flatshade_first for GL quads, quad strips and polygons; the "last" vertex is always the provoking vertex for those prims. So now there are separate QUAD_FIRST_PV and QUAD_LAST_PV macros in the draw primitive decomposition code instead of one QUAD macro.
2010-04-21gallium/draw: fix point sprite handlingBrian Paul
New draw API function to indicate whether or not to convert points to quads for sprite rasterization. Fix point-to-quad conversion regression in the wide-point stage. We need to check the pipe_rasterizer_state::point_quad_rasterization flag.
2010-04-18draw: Cosmetic cleanups and comments.José Fonseca
2010-02-02gallium: Make pipe_atomic a regular int32_t.José Fonseca
2010-01-22gallium/draw: apply DRAW_PIPE_FLAG_MASK to all vertex elementsBrian Paul
Depending on first/last provoking vertex either the first or last element/index may have the extra DRAW_PIPE_x flags. Mask off those bits for all vertex elements to be safe (esp. for the quad case). This may be overly cautious, but it's a cheap operation. Fixes a segfault caused by large/bogus vertex indexes otherwise.
2010-01-22gallium/draw: added comments, whitespace fixesBrian Paul
2009-08-13draw: Remove unused variable.José Fonseca
2009-08-13Merge branch 'mesa_7_5_branch'Keith Whitwell
2009-08-13draw: cope with more primitives in draw_pipeline_runKeith Whitwell
This previously was used only for decomposed (POINT/LINE/TRI) primitives, but for some time a full range of primitives could end up in here. Fixes trivial/lineloop-clip on softpipe, among others. (cherry picked from commit 87cd8a3b8a2407b30916be418ff2f95dfea5d2ad)
2009-06-18draw: clean up indentationBrian Paul
2008-08-24gallium: refactor/replace p_util.h with util/u_memory.h and util/u_math.hBrian Paul
Also, rename p_tile.[ch] to u_tile.[ch]
2008-08-20gallium: fix typo in LINE() macro (replace i+1 with i1 var)Brian Paul
We were sometimes referencing an invalid vertex. Fixes progs/trivial/line-clip.c test among others.
2008-06-02draw: Fix MSVC warnings.José Fonseca
2008-05-13decomposition from keith, adds decomposition of more prim to the pipelineZack Rusin
2008-05-08redo the linear pathsZack Rusin
2008-04-24gallium: commentsBrian Paul
2008-04-24draw: handle edgeflags and reset-line-stipple againKeith Whitwell
2008-04-21draw: consolidate all the passthrough line/tri/point funcsKeith Whitwell
2008-04-19draw: make draw_reset_vertex_ids private to the draw_pipe_* codeKeith Whitwell
2008-04-19draw: put pipeline flushing behind a new interfaceKeith Whitwell
2008-04-19draw: move pt_pipeline code to draw_pipe.cKeith Whitwell
This is now the drawing interface to the pipeline. No more calling into pipeline.first->tri(), etc.
2008-04-19draw: move some pipeline-specific code & state to draw_pipe.[ch]Keith Whitwell