Blending
Hi! I have a terrain, and now I want to render a transparent sphere(this would be a checkpoint like in GTA: Vice City). It is rendered successfully, but the FPS decreases from 75 to 30. Here is what my code like: set_camera_poz(); render_sky_box(); render_the_terrain(); render_the_actor(); glDisable(GL_LIGHTING); glDisable(GL_TEXTURE_2D); glEnable(GL_BLEND); glDepthMask(0); glBlendFunc(GL_ONE,GL_ONE); glColor4ub(0,255,0,20); gluSphere(sphere,60.0f,8,8); glDisable(GL_BLEND); glDepthMask(1); The terrain and the actor are textured, and lighted. I have a Gforce FX5600, so I think that can not be a problem. What am I doing wrong? Or am I using wrong method for this task? I am quite a new to opengl, so I need detailed describtion. Thanks, Lutyo
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement