summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/llvmpipe/lp_setup_tri.c
AgeCommit message (Collapse)Author
2010-09-07llvmpipe: enforce fixed memory limit on scenesKeith Whitwell
2010-09-07llvmpipe: move whole-tile emit into a functionKeith Whitwell
2010-08-27llvmpipe: update line rasterization code to current masterKeith Whitwell
2010-08-27llvmpipe: native rasterization for linesHui Qi Tay
Rasterize lines directly by treating them as 4-sided polygons. Still need to check the exact pixel rasteration.
2010-08-27llvmpipe: intrinsics version of triangle coeficient calculationKeith Whitwell
Looks nice, but makes almost no impact on performance - maybe a percent or so in isosurf, nothing elsewhere. May be of use later on.
2010-08-25llvmpipe: track drawing region as a single u_rectKeith Whitwell
2010-08-25llvmpipe: better triangle debuggingKeith Whitwell
2010-08-25llvmpipe: cull zero-area triangles earlyKeith Whitwell
2010-08-15llvmpipe: special case triangles which fall in a single 16x16 blockKeith Whitwell
Check for these and route them to a dedicated handler with one fewer levels of recursive rasterization.
2010-08-15llvmpipe: remove all traces of step arrays, pos_tablesKeith Whitwell
No need to calculate these values any longer, nor to store them in the bin data. Improves isosurf a bit more, 115->123 fps.
2010-08-11llvmpipe: Debug code to dump interpolation coefficients.José Fonseca
2010-08-11llvmpipe: Use single precision divide for one over area computation.José Fonseca
2010-07-14llvmpipe: Remove redundant alignments.José Fonseca
The lp_rast_shader_inputs' alignment is irrelevant now that it contains pointers instead of actual data. Likewise, lp_rast_triangle's size alignment is meaningless.
2010-07-13llvmpipe: eliminate the set_state rasterizer commandKeith Whitwell
Just put a pointer to the state in the tri->inputs struct. Remove some complex logic for eliminating unused statechanges in bins at the expense of a slightly larger triangle struct.
2010-07-13llvmpipe: pass mask into fragment shaderKeith Whitwell
Move this code back out to C for now, will generate separately. Shader now takes a mask parameter instead of C0/C1/C2/etc. Shader does not currently use that parameter and rasterizes whole pixel stamps always.
2010-06-30llvmpipe: Don't reset the bin when there's a zsbuf bound.José Fonseca
The previous rendering may have secondary effects on the zsbuf. Fixes the missing tiles on gearbox.
2010-06-01llvmpipe: Use struct lp_shader_input in the interpolator.José Fonseca
Eliminates all this identical yet slightly different code to decide how shader inputs should be interpolated. As bonus, don't interpolate the position twice when it is listed in the TGSI shader inputs.
2010-06-01llvmpipe: Don't waste time interpolating unused input channels.José Fonseca
2010-05-30llvmpipe: Pass the fs variant to the rasterizer.José Fonseca
2010-05-28llvmpipe: add out of memory checking to triangle setup pathBrian Paul
2010-05-17llvmpipe: fix front/back tri culling mix-upBrian Paul
2010-05-14gallium: convert rasterizer state to use gl-style front/back conceptsKeith Whitwell
Use front/back instead of cw/ccw throughout. Also, use offset_point/line/fill instead of offset_cw/ccw. Brings gallium representation of this state into line with its main user, and also what turns out to be the most common hardware representation. This fixes a long-standing bias in the interface towards the architecture of the software rasterizer.
2010-05-05llvmpipe: update driver's provoking vertex codeBrian Paul
Note that the lp_setup_vbuf.c code is very, very similar to the corresponding code in softpipe. It could probably be shared.
2010-04-20llvmpipe: fix incorrect front-facing value for fragment shaderBrian Paul
The TGSI convention is +1 for front-facing, -1 for back-facing Fixes glean glsl1 gl_FrontFacing tests.
2010-04-19llvmpipe: triangle function commentsBrian Paul
2010-04-16llvmpipe: print_triangle() func (disabled)Brian Paul
2010-03-18gallivm/llvmpipe: added lp_rast_shader_inputs::facing and pass throughBrian Paul
The triangle rasterizer sets this field to indicate front/back-facing. It gets passed into the generated fragment code as another parameter. Used now for stencil front/back selection but will also be used for fragment shaders in general (see TGSI_SEMANTIC_FACE). With this commit two-sided stenciling mostly works but there's still a bug or two...
2010-03-13llvmpipe: Obey rasterization rules.José Fonseca
Replicates softpipe.
2010-03-13llvmpipe: setup_context -> lp_setup_contextJosé Fonseca
Otherwise IDEs and debuggers have trouble distinguishing from softpipe's setup_context.
2010-03-03llvmpipe: Store the original triangle coordinates in the debug build.José Fonseca
For debugging purposes only.
2010-02-11llvmpipe: Clamp both extremes of triangles to framebuffer size.José Fonseca
Fix segmentation fault when triangles crossed the axis.
2010-01-21llvmpipe: s/inline/INLINE/Brian Paul
2010-01-21llvmpipe: consolidate lp_scene_alloc_aligned() callsBrian Paul
Use just one call instead of four. Good for a few more fps.
2010-01-21llvmpipe: re-use a1 var in linear_coef()Brian Paul
2010-01-21llvmpipe: area is an int here, not floatBrian Paul
2010-01-21llvmpipe: manually unroll the inputs.step[] setup codeBrian Paul
Good for a few more fps in some tests.
2010-01-21llvmpipe: added simple perf/statistics counting facilityBrian Paul
Currently counting number of tris, how many tiles of each size are fully covered, partially covered or empty, etc. Set LP_DEBUG=counters to enable. Results are printed upon context destruction.
2010-01-19llvmpipe: updated commentsBrian Paul
2010-01-15llvmpipe: implement scissor test in triangle setupBrian Paul
2010-01-15llvmpipe: remove lp_rast_triangle::min/max fieldsBrian Paul
These values aren't needed outside the do_triangle_ccw() function.
2010-01-15llvmpipe: change 'in' to boolean, add commentsBrian Paul
2010-01-14llvmpipe: minor comment updateBrian Paul
2010-01-13llvmpipe: minor assorted clean-upsBrian Paul
2010-01-13llvmpipe: Reset the bin when shading a whole tile with an opaque shader.José Fonseca
2010-01-13llvmpipe: tweak subpixel_snap() arithmeticBrian Paul
This adjustment fixes some rasterization differences between llvmpipe and softpipe (and other renderers).
2010-01-12llvmpipe: clamp maxx,maxy to framebuffer size (in terms of tiles)Brian Paul
In some corner cases the right-most / bottom-most vertex can be right on the edge of the framebuffer. Because the maxx, maxy vals are computed with a series of float/int, pixel/tile transformations we can end up with maxx >= scene->x_tiles or maxy >= scene->y_tiles. This leads to putting data into bins that never get processed, or reset. This becomes stale data that can lead to segfaults. Clamping fixes this.
2010-01-11llvmpipe: remove opencoded constantKeith Whitwell
2010-01-08Merge remote branch 'origin/master' into lp-binningJosé Fonseca
Conflicts: src/gallium/auxiliary/util/u_surface.c src/gallium/drivers/llvmpipe/Makefile src/gallium/drivers/llvmpipe/SConscript src/gallium/drivers/llvmpipe/lp_bld_arit.c src/gallium/drivers/llvmpipe/lp_bld_flow.c src/gallium/drivers/llvmpipe/lp_bld_interp.c src/gallium/drivers/llvmpipe/lp_clear.c src/gallium/drivers/llvmpipe/lp_context.c src/gallium/drivers/llvmpipe/lp_context.h src/gallium/drivers/llvmpipe/lp_draw_arrays.c src/gallium/drivers/llvmpipe/lp_jit.c src/gallium/drivers/llvmpipe/lp_jit.h src/gallium/drivers/llvmpipe/lp_prim_vbuf.c src/gallium/drivers/llvmpipe/lp_setup.c src/gallium/drivers/llvmpipe/lp_setup_point.c src/gallium/drivers/llvmpipe/lp_state.h src/gallium/drivers/llvmpipe/lp_state_blend.c src/gallium/drivers/llvmpipe/lp_state_derived.c src/gallium/drivers/llvmpipe/lp_state_fs.c src/gallium/drivers/llvmpipe/lp_state_sampler.c src/gallium/drivers/llvmpipe/lp_state_surface.c src/gallium/drivers/llvmpipe/lp_tex_cache.c src/gallium/drivers/llvmpipe/lp_tex_cache.h src/gallium/drivers/llvmpipe/lp_tex_sample.h src/gallium/drivers/llvmpipe/lp_tile_cache.c
2009-12-16llvmpipe: do final the pixel in/out triangle test in the fragment shaderBrian Paul
The test to determine which of the pixels in a 2x2 quad is now done in the fragment shader rather than in the calling C code. This is a little faster but there's a few more things to do. Note that the step[] array elements are in a different order now. Rather than being in row-major order for the 4x4 grid, they're in "quad-major" order. The setup of the step arrays is a little more complicated now. So is the course/intermediate tile test code, but some lookup tables help with that. Next steps: - early-cull 2x2 quads which are totally outside the triangle. - skip the in/out test for fully contained quads - make the in/out comparison code tighter/faster.
2009-12-13llvmpipe: rename bins to sceneKeith Whitwell
It was pretty confusing having an entity named "bin" and another named "bins", not least because sometimes there was a need to talk about >1 of the "bins" objects, which couldn't be pluralized any further... Scene is a term used in a bunch of places to talk about what a binner operates on, so it's a decent choice here.