Skip to main content
GameDev.net gamedev.net
🔒 Locked

Static background in a 3D world (OpenGL)

Started by Memloop Mar 23, 2009 at 12:37 PM 0 replies 1.8k views
Original Post
Memloop
Memloop
I would like to set a static background that is not rotated or translated along with other game objects. How would you accomplish that in OpenGL?
Zakwayda
Zakwayda
Quote:
I would like to set a static background that is not rotated or translated along with other game objects. How would you accomplish that in OpenGL?
By using a different transform for the background than for the other objects (most likely one that does not include the camera/view transform).

This can be accomplished either by simply doing things in a particular order (e.g. set up the 'background' transform and render the background, then set up the camera/view transform and render everything else), or by using glPushMatrix() and glPopMatrix() to isolate the background transform from any previous transforms.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.