public override void BindProgramParameters(GpuProgramParameters parms, GpuProgramParameters.GpuParamVariability mask)
{
// Register combiners uses 2 constants per texture stage (0 and 1)
// We have stored these as (stage * 2) + const_index
if ( parms.HasFloatConstants )
{
for ( int index = 0; index < parms.FloatConstantCount; index++ )
{
GpuProgramParameters.FloatConstantEntry entry = parms.GetFloatConstant( index );
if ( entry.isSet )
{
int combinerStage = Gl.GL_COMBINER0_NV + ( index / 2 );
int pname = Gl.GL_CONSTANT_COLOR0_NV + ( index % 2 );
// send the params 4 at a time
Gl.glCombinerStageParameterfvNV( combinerStage, pname, entry.val );
}
}
}
}