Keith Whitwell
ad6730fadb
llvmpipe: fail gracefully on oom in scene creation
2010-10-08 17:26:29 +01:00
Keith Whitwell
7225838778
llvmpipe: handle up to 8 planes in triangle binner
2010-09-25 12:22:09 +01:00
Keith Whitwell
59ca1ae84b
llvmpipe: return zero from floor_pot(zero)
2010-09-15 16:28:49 +01:00
Witold Baryluk
c40858fa0d
llvmpipe: Change asm to __asm__.
...
According to gcc documentation both are equivalent,
second are prefered as first can make conflict with existing symbols.
Signed-off-by: José Fonseca <jfonseca@vmware.com>
2010-09-13 18:58:50 +01:00
José Fonseca
501d43028e
llvmpipe: Unbreak rasterization on 64bit.
2010-09-13 12:03:35 +01:00
José Fonseca
b97c75e6a3
llvmpipe: use gcc asm only with gcc
2010-09-13 09:24:09 +01:00
Keith Whitwell
c4046d4fda
llvmpipe: introduce tri_3_4 for tiny triangles
2010-09-12 15:03:50 +01:00
Keith Whitwell
4b56e86e67
llvmpipe: allow tri_3_16 at any 4-aligned location within a tile
...
Doesn't require 16-alignment, so catch more cases.
2010-09-12 15:03:49 +01:00
Keith Whitwell
9df8a7565d
llvmpipe: move more coef setup into lp_setup_coef.c
2010-09-07 14:02:29 +01:00
Keith Whitwell
9f6e8e1d6b
llvmpipe: use opcodes instead of function pointers in bins
...
Also, move some state from rasterizer struct to the scene.
2010-09-07 14:02:15 +01:00
Keith Whitwell
6419ecd02c
llvmpipe: enforce fixed memory limit on scenes
2010-09-07 14:01:43 +01:00
Keith Whitwell
5024d9b90e
llvmpipe: move whole-tile emit into a function
2010-09-07 13:22:55 +01:00
Keith Whitwell
3783053fa5
llvmpipe: update line rasterization code to current master
2010-08-27 13:08:54 +01:00
Hui Qi Tay
5286dd7016
llvmpipe: native rasterization for lines
...
Rasterize lines directly by treating them as 4-sided polygons.
Still need to check the exact pixel rasteration.
2010-08-27 13:08:54 +01:00
Keith Whitwell
0be0ad5d58
llvmpipe: intrinsics version of triangle coeficient calculation
...
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-27 09:47:22 +01:00
Keith Whitwell
29bcbf5e79
llvmpipe: track drawing region as a single u_rect
2010-08-25 10:29:27 +01:00
Keith Whitwell
d808f7b53e
llvmpipe: better triangle debugging
2010-08-25 10:29:27 +01:00
Keith Whitwell
c25151dd6a
llvmpipe: cull zero-area triangles early
2010-08-25 10:29:27 +01:00
Keith Whitwell
c9b7bece05
llvmpipe: special case triangles which fall in a single 16x16 block
...
Check for these and route them to a dedicated handler with one fewer
levels of recursive rasterization.
2010-08-15 23:02:10 +01:00
Keith Whitwell
ff26594a92
llvmpipe: remove all traces of step arrays, pos_tables
...
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-15 17:31:13 +01:00
José Fonseca
66f57235d5
llvmpipe: Debug code to dump interpolation coefficients.
2010-08-11 15:14:10 +01:00
José Fonseca
3deca2e284
llvmpipe: Use single precision divide for one over area computation.
2010-08-11 15:14:10 +01:00
José Fonseca
d023fb3928
llvmpipe: Remove redundant alignments.
...
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-14 14:53:35 +01:00
Keith Whitwell
e21e7ab4da
llvmpipe: eliminate the set_state rasterizer command
...
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-13 17:28:54 +01:00
Keith Whitwell
d4b64167b5
llvmpipe: pass mask into fragment shader
...
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-07-13 17:23:49 +01:00
José Fonseca
4ca3e0d84b
llvmpipe: Don't reset the bin when there's a zsbuf bound.
...
The previous rendering may have secondary effects on the zsbuf.
Fixes the missing tiles on gearbox.
2010-06-30 10:19:50 +01:00
José Fonseca
6ce68ad3ca
llvmpipe: Use struct lp_shader_input in the interpolator.
...
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-01 21:30:57 +01:00
José Fonseca
149cb7682e
llvmpipe: Don't waste time interpolating unused input channels.
2010-06-01 16:39:03 +01:00
José Fonseca
18fb9ff6d8
llvmpipe: Pass the fs variant to the rasterizer.
2010-05-30 10:30:01 +01:00
Brian Paul
151b3bb3af
llvmpipe: add out of memory checking to triangle setup path
2010-05-28 12:52:41 -06:00
Brian Paul
e5ee8b4fae
llvmpipe: fix front/back tri culling mix-up
2010-05-17 11:43:43 -06:00
Keith Whitwell
0bd1cbcd0d
gallium: convert rasterizer state to use gl-style front/back concepts
...
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-14 13:04:42 +01:00
Brian Paul
246d39059e
llvmpipe: update driver's provoking vertex code
...
Note that the lp_setup_vbuf.c code is very, very similar to the
corresponding code in softpipe. It could probably be shared.
2010-05-05 18:19:30 -06:00
Brian Paul
db4ccc004a
llvmpipe: fix incorrect front-facing value for fragment shader
...
The TGSI convention is +1 for front-facing, -1 for back-facing
Fixes glean glsl1 gl_FrontFacing tests.
2010-04-20 11:44:01 -06:00
Brian Paul
a59771fb53
llvmpipe: triangle function comments
2010-04-19 08:53:13 -06:00
Brian Paul
8ba14fab9a
llvmpipe: print_triangle() func (disabled)
2010-04-16 09:27:58 -06:00
Brian Paul
22e6dc3870
gallivm/llvmpipe: added lp_rast_shader_inputs::facing and pass through
...
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-18 13:06:32 -06:00
José Fonseca
a80e33f407
llvmpipe: Obey rasterization rules.
...
Replicates softpipe.
2010-03-13 11:23:52 +00:00
José Fonseca
3160cbabcc
llvmpipe: setup_context -> lp_setup_context
...
Otherwise IDEs and debuggers have trouble distinguishing from softpipe's
setup_context.
2010-03-13 11:23:52 +00:00
José Fonseca
4053d33703
llvmpipe: Store the original triangle coordinates in the debug build.
...
For debugging purposes only.
2010-03-03 19:55:49 +00:00
José Fonseca
764c172aa9
llvmpipe: Clamp both extremes of triangles to framebuffer size.
...
Fix segmentation fault when triangles crossed the axis.
2010-02-11 10:58:46 +00:00
Brian Paul
1d23954a08
llvmpipe: s/inline/INLINE/
2010-01-21 19:05:54 -07:00
Brian Paul
e24ea786fa
llvmpipe: consolidate lp_scene_alloc_aligned() calls
...
Use just one call instead of four. Good for a few more fps.
2010-01-21 19:04:55 -07:00
Brian Paul
798a9d3f94
llvmpipe: re-use a1 var in linear_coef()
2010-01-21 18:25:31 -07:00
Brian Paul
ff9b55da9a
llvmpipe: area is an int here, not float
2010-01-21 17:31:43 -07:00
Brian Paul
a904a7b990
llvmpipe: manually unroll the inputs.step[] setup code
...
Good for a few more fps in some tests.
2010-01-21 16:21:33 -07:00
Brian Paul
cd9d9e2436
llvmpipe: added simple perf/statistics counting facility
...
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-21 15:39:57 -07:00
Brian Paul
75f262b8b4
llvmpipe: updated comments
2010-01-19 09:30:13 -07:00
Brian Paul
fdfe06ad80
llvmpipe: implement scissor test in triangle setup
2010-01-15 12:06:00 -07:00
Brian Paul
adb48d5350
llvmpipe: remove lp_rast_triangle::min/max fields
...
These values aren't needed outside the do_triangle_ccw() function.
2010-01-15 11:52:14 -07:00