I'm busy reading OpenGL ES 2.0 Programming Guide and decided to try and work in Java (since I'm more comfortable with it). Trying to get JOGL up and running with GL2ES2 has been a case of trial and error (almost all the tutorials I find are not GLSL based and when they are they are using those glBegin() and glEnd() methods, which I can't use). I can display a single coloured triangle, but I'm not able to translate/rotate it because I don't know how to do it with JOGL.
Can anyone provide me with a link/sample code of how to correctly implement JOGL for OpenGL ES 2.0? I'm pretty sure (well, 70% sure) that I'll be able to continue with the book if I can get a simple rotating coloured triangle up and running.
Well, it was complaining about a missing parameter and I deleted the project. Now I see the repository has been updated (and that there is an extra parameter). My JOGL might also just be out-dated...
It might be better for me to study OpenGL first before I try using tools that assume I already know what's going on. Therefore, I've decided to take a more direct approach and try and copy the OpenGL ES 2.0 book's examples line-for-line (that is, I'm not trying to use the JOGL utilities package for setting up shaders etc). So far I've got the hello triangle up and running :)
The only thing I did not 'port' was eglSwapBuffers(); I'm just assuming Jogl takes care of that.
On Saturday, August 20, 2011 01:17:12 PM Francois [via jogamp] wrote:
> I'm busy reading OpenGL ES 2.0 Programming Guide and decided to try and work
> in Java (since I'm more comfortable with it). Trying to get JOGL up and
> running with GL2ES2 has been a case of trial and error (almost all the
> tutorials I find are not GLSL based and when they are they are using those
> glBegin() and glEnd() methods, which I can't use). I can display a single
> coloured triangle, but I'm not able to translate/rotate it because I don't
> know how to do it with JOGL.
I can now recommend reading the Gears ES1 and ES2 demo's within JOGL's unit tests.
Both variants will run on desktop either with GL2ES1 (fixed function pipeline)
or with GL2ES2 (programmable shader pipeline).
They also shall run on devices offering ES1 and/or ES2.
Both variation use the same data set, interleaved VBOs.
They utilize the util classes GLArrayData* providing easy VBO construction.
The ES2 variation provides the per pixel lighting (ambient, diffuse and specular),
where the ES1 version uses the only ambient and diffuse fixed function ligthing.
The ES2 variation also demonstrates the use of our PMVMatrix util class,
supporting fixed function like matrix operations.
It also uses the ShaderUtils and ShaderState util classes for easy shader and data management.
The 'Building JOGL on the command line' instructions are awesome, especially for a Windows monkey like myself. Well done guys. There is just one step left out (it might be obvious to some) and that is to install 7z and add it to your CLASSPATH otherwise it will say your Build has failed.
On Tuesday, August 23, 2011 12:09:47 PM Francois [via jogamp] wrote:
> Thanks Sven, your feedback has inspired me to "do this right".
great, glad to help
> On my journey I went to
> http://jogamp.org/wiki/index.php/Building_JOGL_on_the_command_line and
> followed the steps. So this is my first time using Git and Ant (I usually
> work on small projects in Eclipse) and I managed to get it all working.
> The 'Building JOGL on the command line' instructions are awesome, especially
> for a Windows monkey like myself. Well done guys. There is just one step
> left out (it might be obvious to some) and that is to install 7z and add it
> to your CLASSPATH otherwise it will say your Build has failed.
> Why is the 'Building JOGL' link not on
> http://jogamp.org/wiki/index.php/Main_Page or even http://jogamp.org/ ??
I wasn't comfortable doing a complete rewrite of Sven's HTML page at http://jogamp.org/jogl/doc/HowToBuild.html without being asked to But I felt like more detailed guides were needed for beginners (like me), so I wrote wiki pages instead.
I didn't realize that 7zip is needed by the command-line build now -- I'll add that to the wiki page.
On Tuesday, August 23, 2011 04:03:43 PM Francois [via jogamp] wrote:
> Well then from one beginner to another; the guide works. My calculated guess
> is that 7z is required for jar'ing the junit test results and not the build
yup, will work even w/o it
the 7z result is transfered to the jenkins master,
hence I wanted the archive to be as small in footprint as possible.
On Tuesday, August 23, 2011 02:31:39 PM Francois [via jogamp] wrote:
> Yay, after playing around trying to figure out what .libs and .dlls are
> required I got the gears test running. ElektronenMultiplizierer is just
> amazing (wd Demoscene Passivist).
Yes, Demo.. (aka Dominik) combined quite a few magic things there.
It should run on mobile too .. somehow very slow I guess, since it
utilizes fixed loops (loops w/ a fixed length).
We have to see how that unrolling performs on some mobile GPUs :)
The Gears ES2 will become the new default GLEventListener in all demos,
when I hook up the ARM linux/android machines to jenkins.