// Bumpmapping DOT3 setup gl.texEnvf(GL.TEXTURE_ENV, GL.TEXTURE_ENV_MODE, GL.COMBINE_ARB ); gl.texEnvf(GL.TEXTURE_ENV, GL.COMBINE_RGB_ARB , GL.DOT3_RGB_ARB ); gl.texEnvf(GL.TEXTURE_ENV, GL.SOURCE0_RGB_ARB , GL.TEXTURE ); gl.texEnvf(GL.TEXTURE_ENV, GL.OPERAND0_RGB_ARB, GL.SRC_COLOR ); gl.texEnvf(GL.TEXTURE_ENV, GL.SOURCE1_RGB_ARB , GL.PRIMARY_COLOR_ARB ); gl.texEnvf(GL.TEXTURE_ENV, GL.OPERAND1_RGB_ARB, GL.SRC_COLOR );
This is used to perform DOT3 lighting, using a normal map texture and a regular texture (Google DOT3 bumpmapping and you''ll get better explanations). They allow limited programability, but only as far as selecting certain pre-defined modes (like the GL.DOT3_RGB_ARB which performs a dot product using the rgb values as the input vectors). And on a GF2 you''re further restricted because you''ve only got two texture units (stuck using one of them myself )
Vertex programs are separate however, since they''re emulated on GF2 and earlier on the CPU, so you really don''t gain anything you couldn''t do before.