summaryrefslogtreecommitdiff
path: root/src/gallium/auxiliary/draw/draw_pt_fetch_emit.c
AgeCommit message (Collapse)Author
2011-02-14gallium: remove pipe_vertex_buffer::max_indexMarek Olšák
This is redundant to pipe_draw_info::max_index and doesn't really fit in the optimizations I plan.
2010-08-25draw: Remove UNDEFINED_VERTEX_ID checks in emit pathes.Chia-I Wu
UNDEFINED_VERTEX_ID is used by draw_pipe_vbuf to decide whether a vertex has been emitted or not. The non-pipeline pathes do not use it (they tell the frontend the max vertex count when prepare() is called).
2010-08-16draw: No need to make max_vertices even.Chia-I Wu
Triangle strip alternates the front/back orientation of its triangles. max_vertices was made even so that varray never splitted a triangle strip at the wrong positions. It did not work with triangle strips with adjacencies. And it is no longer relevant with vsplit.
2010-08-16draw: Add prim flags to middle ends.Chia-I Wu
Update the middle end interface to pass the primitive flags from the frontends to the pipeline. No frontend sets the flags yet.
2010-06-23draw: don't try to precalculate the pipeline output primitiveKeith Whitwell
We were previously calculating a value which was either the geometry shader output primitive or the application's input primitive, and passing that to the various front/middle/back components for use as the ultimate rendering primtive. Unfortunately, this was not correct -- if the vcache decomposition path is active and geometry shaders are *not* active, we can end up with a third primitive -- specifically the decomposed version of the input primitive. Rather than trying to precalculate this, just let the individual components inform their successors about which primitive type they are recieving.
2010-06-09geometry shaders: make gs work with changable primitives and variable number ↵Zack Rusin
of vertices lots and lots of fixes for geometry shaders. in particular now we work when the gs emits a different primitive than the one the pipeline was started with and also we work when gs emits more vertices than would fit in the original buffer.
2010-05-05gallium: rename draw() to draw_elements() in vbuf codeBrian Paul
Now we have draw_elements() and draw_arrays() to be consistent with the pipe_context drawing functions.
2010-04-26draw: Pass-through pipe_buffer::max_index to translate.José Fonseca
max_index must be observed to prevent crashes due to bad index data. I've been using this patch for some time without regressions. Some places, where we use internal vertex buffer, it is not entirely clear what max_index should be, so passing just ~0 to avoid regressions for now.
2010-03-26draw: Use translate function instead of switch casesJakob Bornecrantz
2009-12-30Add lame support for instanceID to draw module.Michal Krol
It's all screaming for integer support -- fake it with float for now.
2009-12-30Implement instanced indexed draw.Michal Krol
2009-12-29Implement draw_arrays_instanced() in softpipe.Michal Krol
Modify the translate module to respect instance divisors and accept instance id as a parameter to calculate input vertex offset.
2009-05-27draw: Fix assertion failure at fetch_emit_prepareMike Kaplinksiy
2009-02-17draw: second argument to unmap is max, not countKeith Whitwell
2009-02-17draw: add map/unmap directives for swtnl driver interfaceKeith Whitwell
Previously draw module asked for a pointer into (mapped) vertex data, which it would incrementally fill and emit draw commands against. This was hard for the drivers to deal with, especially in the case where a draw command would force a flush and thus an unmap of the vertex data. With this change, the draw module explicitly maps & then unmaps vertex data prior to emitting draw commands.
2009-01-27gallium: standardize on stride instead of pitch in the interfaceZack Rusin
2008-12-10gallium: added missing brace to fix broken buildBrian Paul
2008-12-10gallium: change 65535 to UNDEFINED_VERTEX_IDAlan Hourihane
2008-12-10gallium: more vertex count checksAlan Hourihane
2008-12-10gallium: temporary check for > 65535 verticesAlan Hourihane
2008-10-06make draw's vertex_info struct smaller/quicker to compare with memcmp()Keith Whitwell
2008-08-26draw: attempt atomic submit of large drawelements callsKeith Whitwell
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-06-18gallium: additional fixes to ensure even number of vertices per bufferBrian Paul
2008-06-04draw: respect driver's max vertex buffer sizeKeith Whitwell
2008-05-29draw: draw_range_elements trialKeith Whitwell
2008-05-12draw: mimize cost of translate key compares, use cache universallyKeith Whitwell
2008-05-09draw: fix translate double-free, minor cleanupsKeith Whitwell
2008-05-08redo the linear pathsZack Rusin
2008-05-08implement linear path for fetch_emit pipelineZack Rusin
2008-04-23Add translate cache to fetch_emit stage and add out of memoryZack Rusin
checks to code creating the cache.
2008-04-21draw: squash a couple of memory leaksKeith Whitwell
2008-04-21draw: propogate lots of errorsKeith Whitwell
2008-04-19draw: rearrange debug codeKeith Whitwell
2008-04-19draw: add missing translate->set_buffer for fetch emit pathKeith Whitwell
2008-04-19draw: move incoming vertex state into draw->ptKeith Whitwell
This state is effectively private to the vertex processing part of the draw module.
2008-04-19draw: make draw_pt_fetch_emit use translate facilityKeith Whitwell
2008-04-17draw: add commentKeith Whitwell
2008-04-16draw: make pt run pipeline when need_pipeline is true, not just when clippedKeith Whitwell
2008-04-14silence some warningsZack Rusin
2008-04-14draw: flush pipeline before trying to allocate more hw verticesKeith Whitwell
2008-04-10remove usage of vertex_headerKeith Whitwell
2008-04-07draw: strip edgeflags out of fetch-emit pathKeith Whitwell
2008-04-03draw: add passthrough path to the pipelineKeith Whitwell
This handles the case where bypass_vs is set, but vertices need to go through the pipeline for some reason - eg unfilled polygon mode. Demonstrates how to drive the pipeline from inside one of these things.
2008-04-02draw: add missing break statementKeith Whitwell
2008-04-02draw: Set the backend prim in the pt 'prepare' operationKeith Whitwell
Leaving it until 'run' is bad as the primitive is pretty much state for some drivers and so needs to get set early. In some drivers this is used to determine things like vertex format, etc -- by the time we get to 'run', it's too late to change this.
2008-03-27gallium: replace PIPE_ATTRIB_MAX with PIPE_MAX_ATTRIBSBrian
The later follows the naming scheme of other limits. Keep the old definition until all possible usage is updated.
2008-03-23draw: rename emit functions to match pipe_format namesKeith Whitwell
2008-03-23draw: restructure fetch/emit as a pair of function callsKeith Whitwell
2008-03-23gallium: beginnings of draw module vertex reworkKeith Whitwell
Trying to put a structure in place that we can actually optimize. Initially just implementing a passthrough mode, this will fairly soon replace all the vertex_cache/prim_queue/shader_queue stuff that's so hard to understand... Split the vertex processing into a couple of distinct stages: - Frontend - Prepares two lists of elements (fetch and draw) to be processed by the next stage. This stage doesn't fetch or draw vertices, but makes the decision which to draw. Multiple implementations of this will implement different strategies, currently just a vcache implementation. - MiddleEnd - Takes the list of fetch elements, fetches them, runs the vertex shader, cliptest, viewport transform on them to produce a linear array of vertex_header vertices. - Passes that list of vertices, plus the draw_elements (which index into that list) onto the backend - Backend - Either the existing primitive/clipping pipeline, or the vbuf_render hardware backend provided by the driver. Currently, the middle-end is the old passthrough code, and it build hardware vertices, not vertex_header vertices as above. It may be that passthrough is a special case in this respect.