Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 2 of 2

Thread: Missing color ......

  1. #1
    Junior Member Newbie
    Join Date
    May 2001
    Location
    VietNam
    Posts
    9

    Missing color ......

    Hi all,
    First, I draw some object, text, with shading .. It works well,.
    But in the next call of the function RenderScene (main drawing), it cause my object painted with an unexpected color
    and lose 3D effect.(the first call is good).

    I don't know what to do.
    Please help me.
    Thanks in advance.

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

    Re: Missing color ......

    First you draw your scene, which is OK. Then you draw your text, probably changing the projection matrix and the current color, which ends up OK. When drawing the scene the second time, you probably haven't restored the state changes from the text drawing function, which will mess up the scene.

    Make sure every state change is restored before leaving the text drawing function, aswell as any other function changing states.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •