Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


Vertex Shaded, Textures + Lighting

This topic is 6186 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Argh! I''m trying to combine vertex based shading with a blended texture and lighting and it''s not working..but.. I can sucessfully combine any 2 out of these 3 (ie vertex shading +texture belnding works fine, vertex shading+lighting works fine, lighting+texture works fine). What happens is that when I enable lighting the texture seems to dominate the surface color - the vertex shades seem to be ignored. If I disable lighting then the surface is nicely shaded and blended with the texture. I''m fairly sure the lighting normals and the light is set up correctly as the surfaces are correctly shadowed - they just don''t show any coloration from the vertex shades (ie all surfaces are a uniform gray - the same color as the texture). I am using the GL_MODULATE texture environment mode and a single light with diffuse and ambient components. The texture is RGBA , the surfaces are simple GL_TRIANGLES and I''m using the GL_SMOOTH shade model. Is there anything obvious I have missed here? Cheers Keef ----------------------- glDisable(WORK); glEnable(GL_CODING);

Share this post

Link to post
Share on other sites
Guest Anonymous Poster
Try changing material properties... ...?

glMaterialfv(GL_FRONT, GL_DIFFUSE, something);

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!