summaryrefslogtreecommitdiff
path: root/src/mesa/tnl/t_vp_build.c
AgeCommit message (Collapse)Author
2007-02-23s/GLint/gl_state_index/, length is now 5 not 6Brian
2007-02-22Undo some STATE_POINT/FOG changes. Max length of state token array is now 5.Brian
2007-02-22Merge branch 'origin' into glsl-compiler-1Brian
Conflicts: src/mesa/main/state.c src/mesa/shader/program.c src/mesa/shader/program.h src/mesa/shader/programopt.c src/mesa/shader/slang/slang_execute.c src/mesa/sources src/mesa/swrast/s_arbshader.c src/mesa/swrast/s_context.c src/mesa/swrast/s_span.c src/mesa/swrast/s_zoom.c src/mesa/tnl/t_context.c src/mesa/tnl/t_save_api.c src/mesa/tnl/t_vb_arbprogram.c src/mesa/tnl/t_vp_build.c src/mesa/tnl/t_vtx_eval.c
2007-02-21more minor changes to STATE_ indexingBrian
2007-02-21adjustments to STATE_ token layout/format so token[1] is always the array indexBrian
2007-02-17Lots of changes to prog_print.c code.Brian
Mainly, allow printing programs in either ARB, NV or "debug" formats.
2007-02-14fix stupid bug in the optimized per-vertex fog generation codeRoland Scheidegger
2007-02-09optimize generated vertex programs a bitRoland Scheidegger
Use new internal state to avoid per-vertex normalization of static spot direction vector. Use internal state for simpler per-vertex fog computations (MAD instead of SUB/MUL for linear fog, EX2 instead of POW for EXP/EXP2 fog). Simplify point size calc (2 MADs instead of MOV, MUL, MUL, DP3), and while there fix it up (RSQ instead of RCP). All untested...
2007-02-05Initial implementation of high-level flow-control instructions.Brian
IF/ELSE/ENDIF and BEGIN_LOOP/END_LOOP/BREAK instructions seem to work. Disabled by default though until better tested. Implemented IR_NOT, but needs optimization.
2007-01-24remove some parenthesisBrian
2007-01-24use FRAG_BIT_TEX()Brian
2006-12-15updated includesBrian
2006-12-13Checkpoint work for new GLSL compiler back-end.Brian
Among changes: Remove ctx->FragmentProgram._Active Remove _UseTexEnvProgram Move _MaintainTnlProgram, _MaintainTexEnvProgram, _TexEnvProgram and _TnlProgram fields. Remove/disable old GLSL interpreter code.
2006-11-15Add a size parameter to _mesa_add_unnamed_constant() andBrian Paul
_mesa_add_named_constant() to indicate vector size (1, 2, 3 or 4). Always 4 for now...
2006-08-10Fixup more PROGRAM_UNDEFINED problems.Alan Hourihane
2006-07-20Some structure renaming. Prefix vertex/fragment-related structs withBrian Paul
"gl_" to match other structs.
2006-06-18fix broken negateAapo Tahkola
2006-06-06prevent run_arb_vertex_program from running tnl programs unless ↵Aapo Tahkola
ctx->_MaintainTnlProgram is set
2006-05-23Add const qualifiers in a number of places.Brian Paul
2006-05-05Release temporaryKeith Whitwell
2006-04-25Put color index attribute into the 6th attribute slot.Brian Paul
Update a lot of loops, conditionals to use the _TNL_FIRST/LAST_* values instead of specific vertex attributes. Remove the EdgeFlagv function from the GLvertexformat struct.
2006-04-13silence minor warningsBrian Paul
2005-12-06C++ fixes, mostly casts (Stephane Conversy)Brian Paul
2005-12-05Add guard before calling ctx->Driver.BindProgramKeith Whitwell
2005-12-01Call ProgramStringNotify after creating tnl programs.Keith Whitwell
2005-11-19Remove the _mesa_parse_arb_vertex/fragment_program() functions intoBrian Paul
arbprogparse.c and remove arbvertparse.[ch] and arbfragparse.[ch]. Clean up quite a bit of the arb parsing code. Rewrite parser extension code to avoid a mess of string operations every time the parser was used.
2005-11-18Fix typo causing secondary color not to work properly.Aapo Tahkola
2005-11-12Move stuff common to vertex/fragment_program into the base class, including:Brian Paul
Instructions, InputsRead, OutputsWritten, and Parameters. Also, added debug functions: _mesa_print_instruction(), _mesa_print_program_parameters() and revamp _mesa_print_program().
2005-11-05s/_mesa_debug_vp_inst/_mesa_print_program/Brian Paul
2005-11-05Unify vertex/fragment program instuctions.Brian Paul
Based on patch by Ian (#4967) but also unify instruction opcodes.
2005-11-02Remove some ghost code and adjust things a bit.Aapo Tahkola
2005-11-01Several fp and vp tweaks:Keith Whitwell
- Renumber VERT_RESULT_* values so that they match the numbers of the corresponding FRAG_ATTRIB_ values. - Add ctx->VertexProgram._Current and FragmentProgram._Current values which point to either the current client-supplied program if enabled, or otherwise to the current mesa-internal program. Thus this program is always the correct one for the current state, providing that the mesa flags to turn on automatic generation are enabled. - Add callbacks to ctx->Driver.BindProgram() in texenvprogram.c and t_vp_build.c so that the driver knows when the generated program changes. This is cleaner than trying to code all the possible _NEW_* flags into the driver, and more precise as well. - Add a UsesKill flag to identify fragment programs with that instruction, as these can require special treatment. - Move the FRAG_OUTPUT values to mtypes.h, near to similar defn's.
2005-11-01Fix segmentation fault in _tnl_ProgramCacheDestroy().Aapo Tahkola
2005-11-01Re-org and clean-up of vertx/fragment program limits (instructions,Brian Paul
temporaries, parameters, etc). glGetProgramivARB() now returns all the right things. Updated i915 and r300 code to initialize program native limits and current program's native instruction/temporary/etc counts.
2005-10-31Need more than 200 instructions.Aapo Tahkola
2005-10-31Improve tnl program searching performance.Aapo Tahkola
2005-09-19additional wrapper updates, bug 4468Brian Paul
2005-09-16use mesa import wrappers, bug 4468Brian Paul
2005-08-06Follow suggestion by Aapo Tahkola to fix giant memory leak from forgetting ↵Vladimir Dergachev
to free the key when entry was already found (presumably a common case).
2005-07-22some GLuint idx -> GLint idx changesBrian Paul
2005-07-22Make the vertex program source register Index field a signed int sinceBrian Paul
relative addressing can be negative. Change some GLuint indexes to GLint in the t_vp_build.c file. Added PROGRAM_UNDEFINED token for initializing the register File field to avoid a gcc 4.0 warning.
2005-06-27make create_new_program() staticBrian Paul
2005-06-19Define __FUNCTION__ as a preprocessor symbol in glheader.h if we're notBrian Paul
using GCC or VMS.
2005-06-14 Committing in .Jouk Jansen
OpenVMS updates Modified Files: Mesa/src/mesa/tnl/descrip.mms Mesa/src/mesa/tnl/t_vp_build.c ----------------------------------------------------------------------
2005-06-10remove debug printsKeith Whitwell
2005-06-10Fix typo in spot attenuationKeith Whitwell
2005-06-10Correct test for attenuation.Keith Whitwell
DISSASEM changes.
2005-06-10Fix colormaterial flag calculations.Keith Whitwell
Fix lighting alpha result.
2005-06-09Fix a couple of bugletsKeith Whitwell
2005-06-09Build vertex programs using state from a 'state key' struct which isKeith Whitwell
distilled from the current state. Maintain a list of vertex programs for various different tnl states indexed by these state keys. This cuts down the number of vertex programs generated and means that time spent optimizing vertex programs for execution isn't wasted each time the state changes.