kon
05-03-2002, 01:06 AM
Hi,
having an RGBA texture, I want to render only the parts which are in an alpha range of [a,b]. Two pass algorithm is working (using glAlphaFunc) but I want to do it in a single pass.
By using the register combiners' mux operations this could be done, but the mux selects A*B or C*D by comparing spare0's alpha to 0.5. So, my question is how to map the a and b so that they can be used in the mux operator, instead of 0.5?
Or is there another one pass algorithm to do it?
Thanks
kon
/edit adding/subtracting the difference of a,b and 0.5 to the texture's alpha values is possible but it takes a register combiner and I've got only two of them and these are needed for the two muxs!
[This message has been edited by kon (edited 05-03-2002).]
having an RGBA texture, I want to render only the parts which are in an alpha range of [a,b]. Two pass algorithm is working (using glAlphaFunc) but I want to do it in a single pass.
By using the register combiners' mux operations this could be done, but the mux selects A*B or C*D by comparing spare0's alpha to 0.5. So, my question is how to map the a and b so that they can be used in the mux operator, instead of 0.5?
Or is there another one pass algorithm to do it?
Thanks
kon
/edit adding/subtracting the difference of a,b and 0.5 to the texture's alpha values is possible but it takes a register combiner and I've got only two of them and these are needed for the two muxs!
[This message has been edited by kon (edited 05-03-2002).]