FORUM CLOSED, PLEASE REGISTER AT FORUM.SIO2INTERACTIVE.COM
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Material colors and lighting

2 posters

Go down

Material colors and lighting Empty Material colors and lighting

Post  matt Wed Oct 01, 2008 6:15 pm

When I enable lighting using glEnable(GL_LIGHTING), material colors seem to be ignored. I'm not an OpenGL expert, so: is this correct?

Best,
Matt

Edited: I meant material colors, not vertex colors.

matt

Posts : 155
Join date : 2008-09-30

http://elfrun.net

Back to top Go down

Material colors and lighting Empty Re: Material colors and lighting

Post  sio2interactive Thu Oct 02, 2008 6:00 am

Try to use the build in lighting method that I demonstrate in the tutorial08.
sio2interactive
sio2interactive

Posts : 1526
Join date : 2008-08-26
Age : 45
Location : Shanghai

http://sio2interactive.com

Back to top Go down

Material colors and lighting Empty Re: Material colors and lighting

Post  matt Thu Oct 02, 2008 3:34 pm

Thanks, the important thing was to use sio2LampEnableLight. It seems to work now for materials which only have a color. A textured object isn't colored by a lamp at all. Do you have another clue what I should look after?

Best,
Matt

matt

Posts : 155
Join date : 2008-09-30

http://elfrun.net

Back to top Go down

Material colors and lighting Empty Re: Material colors and lighting

Post  sio2interactive Thu Oct 02, 2008 4:17 pm

Hummm maybe review tutorial08 and try to find out what you are doing differently... Cuz in that tutorial as you can see the floor & walls are textured and you can see the difference when the light pass on top of it. Maybe double check your face normals? And use "set smooth" or "set solid" depending on region and the appropriate type of normal will be exported.
sio2interactive
sio2interactive

Posts : 1526
Join date : 2008-08-26
Age : 45
Location : Shanghai

http://sio2interactive.com

Back to top Go down

Material colors and lighting Empty Re: Material colors and lighting

Post  Sponsored content


Sponsored content


Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum