LWJGL Forum

Programming => OpenGL => Topic started by: straightXedge on March 04, 2007, 15:05:41

Title: noob needs help: strange drawing
Post by: straightXedge on March 04, 2007, 15:05:41
Title: Re: noob needs help: strange drawing
Post by: Matzon on March 04, 2007, 22:42:39
probably your GL initialization that is different ?
Title: Re: noob needs help: strange drawing
Post by: Fool Running on March 05, 2007, 16:22:12
The normal Display.create() path does a little initialization of OpenGL:
Code: [Select]
GL11.glMatrixMode(GL11.GL_PROJECTION);
GL11.glLoadIdentity();
GL11.glOrtho(0.0, current_mode.getWidth(), 0.0, current_mode.getHeight(), -1.0, 1.0);
GL11.glMatrixMode(GL11.GL_MODELVIEW);
GL11.glLoadIdentity();
GL11.glViewport(0, 0, current_mode.getWidth(), current_mode.getHeight());
I could not find something similar in the AWTGLCanvas initialization. So you probably need to set up your view this way (or similar) to get it to work the same.

To the Devs: Should the 2 paths be different? ???
Title: Re: noob needs help: strange drawing
Post by: straightXedge on March 06, 2007, 14:49:59
thx guys, fool running were right, it works now ^^

thx