I have following problem: I have a 3D model using a bunch of colored textures. And I need to display the model in greyscale instead.
I thought I could use the pixel shader/register combiner for this, but I can’t access the RGB channels seperately =/.
r*.333 + g*.333 + b*.333 is one way. thats a 3 component dotproduct… you can do that in a pixelshader…
you can use another “grayscaler”, there are documents about this… dunno wich constant vector is the one wich adobts normal grayscale look the best… but there are documents about this on ati.com, i remember there seen it in some pixelshader (right before the sepiafilter, wich is a brownscaler )
Thanks a bunch… just one problem:
I converted it to PS1.0 now but anyway the nvparse doesn’t take ps.1.0 at all and I searched my to death to find the dp3 function for register combiners =/. They are able to do it… after all it’s also enabled in the ps10 parse sourcecode… but what is the command for a dp3 for a general combiner? Or how else to do it in GL?
BlackJack
p.s. Doesn’t matter what pixel shader code I pass, it always fails with “error in line” 0… which line 0??? =/ May be it has got problems with 0x0D and 0x0A or so?
[This message has been edited by BlackJack (edited 07-24-2002).]
Hm… Any !!RC1.0 or 1.1 command reffering to this? I searched already a lot, but couldn’t find it within this heavy sourcecode. I would prefer to keep everything inside scripts… ok… in worst case I’ll simply add it to the parser myself… but would normally prefer to don’t do any changes on nvparse.