Results 1 to 2 of 2

Thread: let there be LIGHT.

  1. #1
    Junior Member Newbie
    Join Date
    Dec 2002
    Location
    Greece
    Posts
    9

    let there be LIGHT.

    Hi.

    Imagine a torus and a icosahedron on a 3d scene. Say ,for example, that each facet of the above objects is rendered with a slightly different color so that the torus
    is colored with shades of blue and the icosahedron with shades of green.
    When i enable lighting on OpenGL , both objects look different from what they were colored.They are colored in a shade of gray.
    Is it possible to have lighting enabled and both objects be colored with their original color shades ?

  2. #2
    Senior Member OpenGL Guru
    Join Date
    Feb 2000
    Location
    Sweden
    Posts
    2,978

    Re: let there be LIGHT.

    When lighting is enabled, you use materials to set the color of the objects. Have a look at glMaterial.

Similar Threads

  1. What's different between ambient light and diffuse light,?
    By reader1 in forum OpenGL: Basic Coding
    Replies: 11
    Last Post: 06-12-2015, 08:41 AM
  2. How to add a light if white ambient light is active?
    By FedorSymkin in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 11-21-2014, 03:40 PM
  3. Positioned spot light - white light appearing from nowhere behind
    By windchine in forum OpenGL: Basic Coding
    Replies: 9
    Last Post: 08-03-2012, 02:30 AM
  4. Fixed light and moving spot light with the mouse
    By Jorcelangelo in forum OpenGL: Basic Coding
    Replies: 0
    Last Post: 04-18-2012, 09:56 PM
  5. Point light VP -> Spot light VP: ?
    By Freelancer in forum OpenGL: Advanced Coding
    Replies: 1
    Last Post: 01-27-2004, 11:43 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Proudly hosted by Digital Ocean