Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Pexi

Isometric drawing withn OpenGL?

This topic is 6547 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I''m having performance problems with OpenGL. I draw isometric view someting like this I set screen by using glOrtho(0,800,600,0,1-1); glBegin(GL_STRIANGLE_STRIP); for ly :=CurrentY to ScreenYTiles do begin If Odd(ly) then ScreenX :=64 else ScreenX :=128; for lx :=CurrentX to ScreenXTiles do begin glVertex2i(ScreenX, ScreenY+32); glVertex2i(ScreenX+64, ScreenY); glVertex2i(ScreenX+64, ScreenY+64); Inc(CurrentX); Inc(ScreenX, 128); end; glVertex2i(ScreenX, ScreenY+32); //This is the last point of //triangle strip Inc(CurrentY); Inc(ScreenY+32); end; glEnd(); This gives me with textures on about 2 fps and I can''t think what i''m doing wrong? I use cglib for gl in initialization and TCGTexture for texturing. Pekka Heikura pekka@heikura.com

Share this post


Link to post
Share on other sites
Advertisement
Your OpenGL is probably not hardware-accelerated, make sure you are in a screen/depth/resolution combination that is accelerated by your video card for acceleration (for instance Voodoo3 only accelerate 16bits modes etc.)...

... or you are loosing fps somewhere else in your code (like re-generating the texture for each frame)


Share this post


Link to post
Share on other sites
Why don’t you use TCGTextureObject for texturing? That way the textures get loaded into video memory, the first time you bind them with a texture object.

Pascalix;

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!