PDA

View Full Version : new JOGL doesn't have same features...



TEMP USER
10-30-2010, 04:55 PM
hello,

a very long time ago i created an openGL game using JOGL .
i wanted to get back and re-learn JOGL, and discovered that things have changed ever since, and there is a new version (i think its numbered 2) .
i've installed it correctly (i think) using this (https://sites.google.com/site/justinscsstuff/jogl-tutorial-1) tutorial and now eclipse can run a JOGL application (it works and can show triangles etc...) .
i'm having some problems with it and i hope that anyone here could help me:
1.from some reason though , i can't find some constants that were available in the previews versions - not only eclipse doesn't offer them, but even when i write them, they cannot be compiled .
examples for such constants: GL.GL_POLYGON,GL.GL_POLYGON,GL.GL_QUADS
2.it seems that for glVertex2f , 0,0 (for 2d mode) is actually in the middle . is it really true? it's quite confusing... it was confusing enough to think that the bottom( and not upper) left corner is the 0,0 point, but now it was changed to this??? i think that the textures coordinates have also changed and are now more intuitive - 0,0 is the top left , 1,0 is top right , etc... , just like in any other GUI "engine" .
3.i remember that i had problems last time of getting light+textures for my 3d models , and even putting simple 2d pictures/text on the screen . is it any easier now than it was before? is there a proper guide for such things?
4.a little off the topic:i wonder:is joGL(or openGL) the only solution to create 2d animations using the GPU ? does AWT/SWT/SWING use the GPU at all ? maybe for some cases, it's better to use them ?

if needed , attached my current code, which doesn't do much . it just draws a 2d picture on the window using JOGL (using triangles) , and also captures mouse clicks and writes them into the console.

please help me.
i still consider myself as a newb when talking about openGL .

mfort
10-31-2010, 12:36 AM
1. moved to GL2.GL_POLYGON, GL2.GL_QUADS
2. coodinate 0,0 depends on your projection matrix. You can have it where you want it. Texture coordinates 0,0 is still bottom/left.
3. probably not. You can write shaders now, so you have complete control over your materials.
4. swing has GPU acceleration of some primitives. Mostly through DirectX.

TEMP USER
10-31-2010, 05:26 PM
1.really? wonder why they did it. do you know of any other changes? maybe a "what's new" section for JOGL 2 ? i also wonder if there are any new tutorials that use this version.
2.i see. it's still confusing me a lot .
3.did they at least add a physics engine? it could worth a lot of coding time and have a more standard way to handle many cases. in so many cases, i need to use google to find a solution , but i always find a specific solution to a specific problem, and therefore i need to adjust the code and also look even more on websites.
4.i see .

btw, i'm quite new to this forum. i can't find how to notify me be email of new posts. i've found how to notify of the watch list, but how can i add a new thread that i make (for example) to the watch list by default?