summaryrefslogtreecommitdiff
path: root/src/mesa/pipe/softpipe/sp_prim_setup.c
AgeCommit message (Collapse)Author
2008-01-26gallium: Fix build on Windows.Michal Krol
2008-01-25gallium: replace prim pipeline begin/end() functions with flush()Brian
This is basically half of Keith's draw/flush patch. The stage->point/line/tri() functions are now self-validating, the validator functions are installed by the flush() function. There were excessive calls to validate_pipeline(), however. This was caused by draw_prim_queue_flush() keeping a local 'first' variable that always pointed to the validate functions. Replaced 'first' with 'draw->pipeline.first'. Performance in gears is up just slightly with this patch.
2008-01-23gallium: improved vertex layout and interpolant setup in softpipeBrian
2008-01-23gallium: rework compute_vertex_layout() to intelligently map vs outputs to ↵Brian
fs inputs Some follow-on simplification in prim setup is possible...
2008-01-23gallium: restore/rewrite vbuf code for softpipeBrian
Now based on the draw_vbuf code, instead being a custom one-off. Disabled by default, enable with SP_VBUF env var.
2008-01-23gallium: overhaul usage of vertex_info in draw module.Brian
Remove all dependencies on vertex_info, except for draw_vbuf. Drawing stages now strictly operate on post-transformed vertices and don't know anything about hw vertices. Use vertex program output info for two-side/flat/etc stages. Temporarily disable vbuf module in softpipe driver.
2008-01-21gallium: remove per-fragment line stipple codeBrian
2008-01-21fix broken point rendering in sp_vbuf_render()Brian
2008-01-17Back-port miscellaneous fixes from internal branch (mostly portability fixes).José Fonseca
These are changes that are in our internal branch, but somehow were skipped so far. It was done using visual comparison of the branches -- it is likely that changes are being carried on the wrong way
2008-01-16Fix broken fog.Brian
Note that fogcoord and front-facing attribs are in the same register, in the X and Y channels, respectively.
2008-01-10clean-up comments, codeBrian
2007-12-18setup the frontface register (fog.y, ATM)Brian
2007-12-14Added origin_lower_left field to pipe_rasterizer_stateBrian
This controls whether the window origin is considered to be the lower-left or upper-left corner. This effects computation of gl_FragCoord and the application of polygon stipple.
2007-12-14Don't always declare frag shader INPUT[0] as fragment position.Brian
We were doing this for the sake of softpipe and the tgsi intergrepter since we always need the fragment position and W-coordinate information in order to compute fragment interpolants. But that's not appropriate for hardware drivers. The tgsi interpreter now get x,y,w information from a separate tgsi_exec_vector variable setup by softpipe. The new pipe_shader_state->input_map[] defines how vert shader outputs map to frag shader inputs. It may go away though, since one can also examine the semantic label on frag shader input[0] to figure things out.
2007-12-10minor clean-ups, commentsBrian
2007-12-09gallium: add draw_stage::destroy().Michal
2007-10-29Make gallium compile in win32.Michal Krol
Use FREE, MALLOC, CALLOC, GETENV wrappers. Silence compiler warnings. Add proper copyrights.
2007-10-29Remove typedefs from enums.Zack Rusin
typedefs are rather evil, remove them and use the enum keyword explicitely.
2007-10-27Silence compiler warnings.michal
2007-10-17fix square point rasterizationBrian
2007-10-16Update mask calculations for point drawing.Brian
2007-10-16Redefine QUAD_TOP_LEFT, TOP_RIGHT, etc. to reflect Y=0=TOP raster layout.Brian
2007-10-16fix perspective-interpolated attribs for points, liensBrian
2007-09-27restore primitive trimming in sp_draw_arrays.ckeithw
2007-09-27Make flushing more lazy in the draw module.Keith Whitwell
2007-09-25First attempt at building vertex buffers post-clip.Keith Whitwell
Build a buffer of contigous vertices and indices at the backend of our software transformation/clipping path. This will become the mechanism for emitting buffers of vertices to rasterization hardware. This is similar to but not the same as the post-transform vertex cache. In particular, these vertices are subject to clipping, culling, poly offset, etc. The vertices emitted will all be used by hardware. TODOs include the actual transformation to hardware vertex formats, moving this out of softpipe to somewhere more useful and allowing >1 primitive to share the generated VB.
2007-09-21Fix up some point size breakage. Start on fogcoord too.Brian
2007-09-20checkpoint: TGSI_ATTRIB_x tokens no longer usedBrian
2007-09-20Checkpoint: vertex attribute clean-up.Brian
Remove/disable the attrib/slot mapping arrays in a few places. Work in progress...
2007-09-18Checkpoint: rework shader input/output register mapping.Brian
This is a step toward removing TGSI_ATTRIB_ tokens. Basically, when translating Mesa programs to TGSI programs, pass in input and output register re-maps, plus interpolation info. There's some known breakage (cubemap.c) so more to be done...
2007-09-18additional comments for tri_persp_coeff()Brian
2007-09-18converting the setup state to immutable object and renaming it to rasterizer ↵Zack Rusin
state
2007-08-31Define attrib_format and interp_mode enum typedefs and use where appropriate.Brian
2007-08-30fix unhandled switch/case warningBrian
2007-08-30In draw_flatshade.c use vertex_info->interp_mode[] to choose attribs/colors ↵Brian
to cpy. One less dependency on the TGSI_ATTRIB_x flags. This requires setting the vertex_info->interp_mode[] values in the i915 driver and passing them to draw_set_vertex_attributes().
2007-08-30Sketch out per-vertex point size.Brian
The code is all in place, but mostly disabled for now: In t_vp_build.c, write the VERT_RESULT_PSIZE register In sp_state_derived.c, need to emit vertex point size if drawing points. In setup_point() use the point size from the vertex.
2007-08-23Use vertex_info struct for softpipe - lots of clean-up.Brian
2007-08-23Checkpoint: new vertex/fragment attribute namingBrian
Replace VF_ATTRIB_x with TGSI_ATTRIB_x When converting mesa programs to TGSI programs, also convert the InputsRead and OutputsWritten to a mask of TGSI_ATTRIB_ bits. Still need to do conversion for vertex programs...
2007-08-20remove some of the #ifndef MESA stuffBrian
2007-08-16Silence compiler warnings.michal
2007-08-16Remove many dependencies on mesa headers.Brian
To build with mesa, need -DMESA in makefile/config file.
2007-08-15Remove mesa include directories, be stricter about include paths.Keith Whitwell
2007-08-15Add UsageMask to DECLARATION in TGSI.michal
Interpolate FS attributes in the shader. Do not copy WPOS in FS.
2007-08-14Continue reducing dependencies on core mesa include files.Keith Whitwell
Mainly down to the support for legacy TNL processing now.
2007-08-08print_vertex func for debuggingBrian
2007-08-08Add a quad_stage::begin() method to do per-primitive preparations (like ↵Brian
setting up samplers).
2007-07-30Merge branch 'softpipe_0_1_branch' of ↵Brian
git+ssh://brianp@git.freedesktop.org/git/mesa/mesa into softpipe_0_1_branch
2007-07-30remove old commentsBrian
2007-07-27renaming, comments, clean-upBrian
2007-07-27Clip triangles against softpipe->cliprect which includes scissor and surface ↵Brian
bounds. This prevents rendering out of bounds when the viewport is partially outside the surface bounds.