summaryrefslogtreecommitdiff
path: root/src/mesa/tnl/t_vp_build.c
AgeCommit message (Collapse)Author
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.
2005-05-18Eliminate a couple of swizzles.Keith Whitwell
2005-05-17don't include strings.hBrian Paul
2005-05-12Turn disassem off (oops).Keith Whitwell
2005-05-12When lighting is enabled, but no lights are enabled, the scenecolorKeith Whitwell
becomes the result of lighting. When lighting is disabled, pass-through incoming color value. Likewise, pass through incoming texture values. (Based on patch by Aapo Tahkola) Add compile-time configuration to switch between DP4 and MUL/MAD for matrix-vector multiplications.
2005-05-11Use _mesa_memset rather than memsetKeith Whitwell
2005-05-11Rename temp_flag to temp_in_use. Use ctx->Const.MaxVertexProgramTempsKeith Whitwell
rather than MAX_NV_VERTEX_PROGRAM_TEMPS and deal with this possibly being greater than 32.
2005-05-10Ensure programs don't overflow allocated instruction store.Keith Whitwell
2005-05-10Improved detection of program changes.Keith Whitwell
2005-05-10Double-buffer generated instructions and only notify driver when theKeith Whitwell
generated program differs from the previous one.
2005-05-10Missing from previous commitKeith Whitwell
2005-05-04Add a facility to route all rasterization through a fragment programKeith Whitwell
which is automatically generated to match the current texture environment state. Introduces a new value ctx->FragmentProgram._Active which is true when either _Enabled is true or there is such a fragment program ready to run. To test out on a driver running the software rasterizer, set MESA_TEX_PROG=t in the environment. It goes without saying that performance is lower for the software rasterizer in this mode.
2005-04-29Format for 80 columns. Add alternate matrix mul based on MAD rather than DP4.Keith Whitwell
2005-04-22Simplify the pipeline_stage structureKeith Whitwell
- remove input/output fields, input tracking removed. - remove state fields, the validate function now called on every statechange. - add an explicit 'create' function. Add in code to build vertex program to implement current t&l state. Still disabled, but turn on with a #define in t_vp_build.h.
2005-04-21Facility to construct a vertex program which executes the currentKeith Whitwell
fixed function t&l pipeline. Currently runs most of the Mesa demos OK, but still needs debugging & polishing.