how to make *.bmp as background
hello members...how can i use *.bmp file as my background in openGL...let say i use sea scenary (bmp file) and others objects like peoples, birds and so on i use openGL coding...how can i make it? please guide me...
its easy...
1. switch to ortho view.
2. load identity.
3. draw the quad background to fit the ortho coords.
4. switch back to normal view.
5. clear the depth buffer.
6. draw your scene...
"The Railgun Master"
DaHeR
Edited by - DaHeR on February 2, 2002 2:53:24 AM
1. switch to ortho view.
2. load identity.
3. draw the quad background to fit the ortho coords.
4. switch back to normal view.
5. clear the depth buffer.
6. draw your scene...
"The Railgun Master"
DaHeR
Edited by - DaHeR on February 2, 2002 2:53:24 AM
step 5 is very costly... it would be a lot easier to either disable depth testing, or disable depth writing when drawing the objects. you just have to make sure you draw them in the order you want. assuming it''s a simple scene, this would be faster.
Hi,
On my site, I''ve a example who display a BMP in background like a splash screen.
========================
Leyder Dylan
http://ibelgique.ifrance.com/Slug-Production/
On my site, I''ve a example who display a BMP in background like a splash screen.
========================
Leyder Dylan
http://ibelgique.ifrance.com/Slug-Production/
quote:Original post by RipTorn
step 5 is very costly... it would be a lot easier to either disable depth testing, or disable depth writing when drawing the objects. you just have to make sure you draw them in the order you want. assuming it''s a simple scene, this would be faster.
yeah thanx i think i missed that one ! disabling the depth buffer write is better before 3 and enabling it ( if you want to ) in step 5 ....
"The Railgun Master"
DaHeR
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement