Discussion:
Java 3D - Netbeans Plugin not working.
v0rtexza
2011-04-17 21:02:37 UTC
Permalink
Hey all,
I have recently attempted to learn Java3D. I have tried to install the Java3D Plugin from http://services.netb...n/32144/java-3d
After I install the plugin, there is no way to activate it (I'm assuming its not activated as my sample program cant find the necessary libraries.) I decided, there must be something wrong with my current version of java, so I updated both java and my java JDK to the latest versions available, Still to no avail.

I then decided, lets just manually install the libraries from http://java3d.java.n...ary-builds.html
and Downloaded j3d-1_5_2-windows-i586.zip as I have windows 7 64 bit running on a pentium Core 2 Duo, clocked @ 3.4 Ghz.
After changing my path and classpath variable, I still cannot get netbeans to recognize the libraries or the plugin. It knows it is installed as when I try and go Tools > Plugins > Downloaded > AddPlugins... > 1300986731985_com-sun-j3d > Install. Netbeans complains that the plugin is already installed.

I proceeded to try to add the jar files manually to my netbeans project and whilst this took away the libraries do not exist error, when I ran the sample code that is listed below:

Code:

/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/

package frame;

/**
*
*
*/
import com.sun.j3d.utils.universe.SimpleUniverse;

import com.sun.j3d.utils.geometry.ColorCube;

import javax.media.j3d.BranchGroup;
//import javax.media.j3d.BranchGroup;
public class Frame {
public Frame()

{

SimpleUniverse universe = new SimpleUniverse();

BranchGroup group = new BranchGroup();

group.addChild(new ColorCube(0.3));

universe.getViewingPlatform().setNominalViewingTransform();

universe.addBranchGraph(group);

}
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
new Frame();
}

}





I got this error:

Code:

ERROR: run:
Apr 17, 2011 8:56:10 PM javax.media.j3d.NativePipeline getSupportedOglVendor
SEVERE: java.lang.UnsatisfiedLinkError: no j3dcore-ogl-chk in java.library.path
Exception in thread "main" java.lang.UnsatisfiedLinkError: no j3dcore-d3d in java.library.path
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1734)
at java.lang.Runtime.loadLibrary0(Runtime.java:823)
at java.lang.System.loadLibrary(System.java:1028)
at javax.media.j3d.NativePipeline$1.run(NativePipeline.java:231)
at java.security.AccessController.doPrivileged(Native Method)
at javax.media.j3d.NativePipeline.loadLibrary(NativePipeline.java:200)
at javax.media.j3d.NativePipeline.loadLibraries(NativePipeline.java:157)
at javax.media.j3d.MasterControl.loadLibraries(MasterControl.java:987)
at javax.media.j3d.VirtualUniverse.<clinit>(VirtualUniverse.java:299)
at frame.Frame.<init>(Frame.java:23)
at frame.Frame.main(Frame.java:38)
Java Result: 1
BUILD SUCCESSFUL (total time: 2 seconds)




Finally, I proceeded to search the forums with no results and so I am finally here asking the question below:
Does anyone know a simple way to install java3D with netbeans 6.9.1?
Attached is the sample file that I was using.
Any help is appreciated, Sorry for being such a noob haha

v0rtex.
David Grace
2011-04-18 21:20:09 UTC
Permalink
Hi,

You need to put the native files (.dll's) in the path for netbeans to
find them.

This can be done by putting them in the root folder of your project, or
by putting them into the JRE itself, or by specifying them on the
classpath when you run your program.

Hope that helps,

Dave.
Post by v0rtexza
Hey all,
I have recently attempted to learn Java3D. I have tried to install the Java3D Plugin from http://services.netb...n/32144/java-3d
After I install the plugin, there is no way to activate it (I'm assuming its not activated as my sample program cant find the necessary libraries.) I decided, there must be something wrong with my current version of java, so I updated both java and my java JDK to the latest versions available, Still to no avail.
I then decided, lets just manually install the libraries from http://java3d.java.n...ary-builds.html
After changing my path and classpath variable, I still cannot get netbeans to recognize the libraries or the plugin. It knows it is installed as when I try and go Tools> Plugins> Downloaded> AddPlugins...> 1300986731985_com-sun-j3d> Install. Netbeans complains that the plugin is already installed.
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package frame;
/**
*
*
*/
import com.sun.j3d.utils.universe.SimpleUniverse;
import com.sun.j3d.utils.geometry.ColorCube;
import javax.media.j3d.BranchGroup;
//import javax.media.j3d.BranchGroup;
public class Frame {
public Frame()
{
SimpleUniverse universe = new SimpleUniverse();
BranchGroup group = new BranchGroup();
group.addChild(new ColorCube(0.3));
universe.getViewingPlatform().setNominalViewingTransform();
universe.addBranchGraph(group);
}
/**
*/
public static void main(String[] args) {
new Frame();
}
}
Apr 17, 2011 8:56:10 PM javax.media.j3d.NativePipeline getSupportedOglVendor
SEVERE: java.lang.UnsatisfiedLinkError: no j3dcore-ogl-chk in java.library.path
Exception in thread "main" java.lang.UnsatisfiedLinkError: no j3dcore-d3d in java.library.path
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1734)
at java.lang.Runtime.loadLibrary0(Runtime.java:823)
at java.lang.System.loadLibrary(System.java:1028)
at javax.media.j3d.NativePipeline$1.run(NativePipeline.java:231)
at java.security.AccessController.doPrivileged(Native Method)
at javax.media.j3d.NativePipeline.loadLibrary(NativePipeline.java:200)
at javax.media.j3d.NativePipeline.loadLibraries(NativePipeline.java:157)
at javax.media.j3d.MasterControl.loadLibraries(MasterControl.java:987)
at javax.media.j3d.VirtualUniverse.<clinit>(VirtualUniverse.java:299)
at frame.Frame.<init>(Frame.java:23)
at frame.Frame.main(Frame.java:38)
Java Result: 1
BUILD SUCCESSFUL (total time: 2 seconds)
Does anyone know a simple way to install java3D with netbeans 6.9.1?
Attached is the sample file that I was using.
Any help is appreciated, Sorry for being such a noob haha
v0rtex.
Continue reading on narkive:
Loading...