1

I want to run a HelloWorld JOGL programm on the commandline. I downloaded the .jars from jogamp.org and put the

gluegen-rt.jar , 
jogl.all.jar , 
gluegen-java-src.zip , 
jogl-java-src.zip , 
gluegen-rt-natives-macosx-universal.jar , 
jogl-all-natives-macosx-universal.jar 

in a directory "jar" in my HelloWorld folder - as described in http://jogamp.org/wiki/index.php/Downloading_and_installing_JOGL .

Now I try to compile with

javac -classpath "jar/gluegen-rt.jar:jar/jogl.all.jar" HelloWorld.java 

as described on https://jogamp.org/wiki/index.php/Setting_up_a_JogAmp_project_in_your_favorite_IDE .

Then it throws me 14 errors starting with

HelloWorld.java:7: package javax.media.opengl does not exist
import javax.media.opengl.GL;
                         ^

When I try to compile with absolute paths using

javac -classpath "/Users/jonas/Desktop/cool_jogl/helloworld/jar/gluegen-rt.jar:/Users/jonas/Desktop/cool_jogl/helloworld/jar/jogl-all.jar" HelloWorld.java 

it still throws me 12 errors starting with

HelloWorld.java:9: cannot find symbol
symbol  : class GLCanvas
location: package javax.media.opengl
import javax.media.opengl.GLCanvas;
                         ^
genpfault
  • 51,148
  • 11
  • 85
  • 139
Jonas Kemper
  • 3,745
  • 3
  • 14
  • 21

2 Answers2

2

try to replace javax.media by com.jogamp

Chi
  • 55
  • 9
1

You should use javax.media.opengl.awt.GLCanvas Some package names was changed. Use IDE autocomplete or look sources.zip to find new names.

olamedia
  • 188
  • 2
  • 6