• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Java + JOGL / Java3D

 
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey all!

For I live, I won't understand Java imports I swear to you guys... I did a full Java reinstall yesterday. After that, my C:/Program Files/Java directory has the following directories in it:
jdk1.6.0_16
jre6
Java3D

My classpath is set to the following at Control Panel / System: .;C:\Program Files\Java\jdk1.6.0_16;C:\Program Files\Java\jre6;

Basic java applications work fine, so no problem with the install there.

Now I tried to load an OBJ file in Java3D. I got all imports, but the on the following one: import javax.vecmath.Point3D;

eclipse says cannot be resolved,although vechmath.jar is in the JRE system library.
I checked the Point3D class in the javax.vecmath package, and upon double clicking on it, Eclipse says "source not found, the source attachment does not contain the source for the file Point3d.class. "

I asked this particular question in another topic already, but since the next problem (described below) is in connection with this one, I thought I'd write it here too.

Now I tried to fire up JOGL and try to load the OBJ file under that. To be on the safe side, I copied the jogl's DLLs ( to almost everywhere, like:
jdk1.6.0_16/bin
jdk1.6.0_16/jre/bin
jre6/bin

... and also copied the JARs to everywhere, like:
jdk1.6.0_16/lib
jdk1.6.0_16/jre/lib
jre6/lib

dlls and jars mentioned here are gluegen-rt.dll, jogl.dll, jogl_awt.dll, jogl_cg.dll, gluegen-rt.jar, jogl.jar .

Now I fire up Eclipse, set everything ship-shape, and the problem is still on.. won't recognize the jogl imports.... Jesus, this drives me crazy.

I attack a screenie of this, maybe it helps:


I hope that someone can help me out on this one.
Thanks for reading.
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
A few observations

My classpath is set to the following at Control Panel / System: .;C:\Program Files\Java\jdk1.6.0_16;C:\Program Files\Java\jre6;


There's an extra semicolon at the end. If you want the classpath to include jar files, then you add their specific file names to the classpath, not the directory they're in. I never rely on the CLASSPATh setting, instead preferring to use the "-classpath" switch (or using an Ant build file for anything that has multiple dependencies).

Also note that DLLs are not picked up from the CLASSPATH, but from the PATH.

Furthermore, Eclipse may not use the CLASSPATH at all - try adding the relevant jar files to your Eclipse project.

Lastly, be aware that changes to environment variables may not be picked up until you log out and log back in.
 
Java Cowboy
Posts: 16084
88
Android Scala IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please post your question in the right forum; this question does not have anything to do with EJBs or Java EE. I'll move it to a more appropriate forum for you.
 
Dávid Kéri
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Ulf Dittmer wrote:A few observations

My classpath is set to the following at Control Panel / System: .;C:\Program Files\Java\jdk1.6.0_16;C:\Program Files\Java\jre6;


There's an extra semicolon at the end. If you want the classpath to include jar files, then you add their specific file names to the classpath, not the directory they're in. I never rely on the CLASSPATh setting, instead preferring to use the "-classpath" switch (or using an Ant build file for anything that has multiple dependencies).

Also note that DLLs are not picked up from the CLASSPATH, but from the PATH.

Furthermore, Eclipse may not use the CLASSPATH at all - try adding the relevant jar files to your Eclipse project.

Lastly, be aware that changes to environment variables may not be picked up until you log out and log back in.



Thanks for the observations, I corrected the extra semicolon, rebooted the machine, still no change. I haven't modified the CLASSPATH, because as you can see on the attached screenshot, Eclipse HAS those jars included in the System Library. From here on I absolutely don't get how could it NOT see the imports... Any idea on that?
 
What are your superhero powers? Go ahead and try them on this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic