Setting Pixel Shader Constant with nv parse

Hi,

I’m trying to use nvparse for ps.1.1, but I don’t now how to set constant.

My pixel shader is :
"ps.1.1
"
"mov r0, v0
"
I’ve tryed :
float p[4] = { 1.0f, 0.5f, 0.0f, 1.0f};
glCombinerParameterfvNV(GL_CONSTANT_COLOR0_NV, p);
but it doesn’t work

For Vertex Program I use :
glProgramParameter4fNV(GL_VERTEX_PROGRAM_NV, k, data[k].x, data[k].y, data[k].z, data[k].w);

Does anyone knoes how to do this for pixel shader ?

melchizedek.

I’m no expert with register combiners, but I can say one thing for sure. Your pixel shader does not use any constants, so how can you tell if what you tried works?

Originally posted by Asgard:
I’m no expert with register combiners, but I can say one thing for sure. Your pixel shader does not use any constants, so how can you tell if what you tried works?

oups, I made a mistake, the shader is :
"ps.1.1
"
"mov r0, c0
"

Download this document (and possibly the new version of nvparse that got posted on NVIDIA’s developer site a couple of days ago): http://developer.nvidia.com/docs/IO/1747/ATT/nvparse_pixelshader_howto.txt

It should explain what you want to know.
Regards.