when i tried to run a Java 3d PROGRAM , it gave me the following error .
当我尝试运行Java 3d程序时,它给了我以下错误。
Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: no J3D in java.library.path
at java.lang.ClassLoader.loadLibrary(Unknown Source)
I followed this web site to solve this error
我跟踪这个网站来解决这个错误。
http://www.filsa.net/2008/07/17/eclipse-java3d-and-javalibrarypath/
It says that , after adding the jar files Additionally, you need to put the native code, j3dcore-ogl.dll (j3dcore-ogl.so on Linux) onto the PATH.
它说,在添加了jar文件之后,您需要添加本机代码j3dcore-ogl。dll(j3dcore-ogl。所以在Linux上。
I have got these dll files under the j3d-1_5_2-windows-i586\bin\j3dcore-ogl.dll folder
我在j3d-1_5_2-windows-i586\bin\j3dcore-ogl下有这些dll文件。dll文件夹
I added this support from Eclipse this way Java Build Path --->Add Exernal Class Folder -->and upto bin path (Exactly there at which these dll files are residing )
我在Eclipse中添加了这种支持,这是Java构建路径--->添加了opernal类文件夹——>和upto bin路径(正是这些dll文件所在的位置)
After doing this step also , i am getting the same exception . This is how my Eclipse IDE build path looks now
在完成这一步之后,我也得到了相同的异常。这是我的Eclipse IDE构建路径的方式。
Thank you very much .
非常感谢。
3 个解决方案
#1
4
I solved the question, very easy:
Just copy & paste & merge the j3d library's bin/ & lib/
folders into the corresponding bin/ & lib/
folders of both the jre/ & jdk/
JVM folders that you use.
我解决了这个问题,非常简单:只需复制&粘贴并将j3d库的bin/ & lib/文件夹合并到您所使用的jre/ & jdk/ JVM文件夹的相应bin/ & lib/文件夹中。
- Download corresponding j3d Zip binaries at https://java3d.java.net/binary-builds.html. For me, a win7 64bit Java VM (aka. jdk & jre), I choose
j3d-1_5_2-windows-amd64.zip
. - 在https://java3d.java.net/binarybuilds.html中下载相应的j3d Zip二进制文件。对于我来说,一个win7 64位的Java VM (aka)。我选择j3d-1 _5_ 2-windows-amd64.zip。
- UnZip the downloaded j3d Zip binaries (
j3d-1_5_2-windows-amd64.zip
) to get thej3d-jre.zip
file inside. - 解压缩下载的j3d Zip二进制文件(j3d-1 _5_ 2-window -amd64.zip)获取j3d-jre。zip文件里面。
- UnZip the
j3d-jre.zip
to get thebin/ & lib/
folders. - 解压j3d-jre。zip以获取bin/ & lib/文件夹。
- Copy & paste & merge the obtained
bin/ & lib/
folders into the correspondingbin/ & lib/
folders of my JVM folders (aka. bothjdk/ & jre/
folders). - 复制&粘贴并将获得的bin/ & lib/文件夹合并到我的JVM文件夹的相应bin/ & lib/文件夹中。两个jdk/ & jre/文件夹)。
For other JVMs, it's the same thing - copy & paste & merge the j3d zip library's bin/ & lib/
folders into the corresponding bin/ & lib/
folders of the JVM's jre/ & jdk/
对于其他JVM,它是一样的——复制&粘贴&将j3d zip库的bin/ & lib/文件夹合并到JVM jre/ & jdk/的相应bin/ & lib/文件夹中。
#2
0
Can you try executing regsvr32 "name_of_dll-file" from the run menu? You need to reboot the machine for this to take effect.
您可以从run菜单中尝试执行regsvr32“name_of_dllfile”吗?您需要重新启动机器以使其生效。
This adds the DLL as a library that other programs can access. Adding it to the Eclipse build path is not the right thing since that will only be accessible to your JVM.
这将DLL添加到其他程序可以访问的库中。将它添加到Eclipse构建路径不是正确的事情,因为它只能访问您的JVM。
#3
-2
i solved problem by copying j3dcore-ogl.dll to windows/system32 folder
我通过复制j3dcore-ogl解决了问题。dll windows / system32系统文件夹
#1
4
I solved the question, very easy:
Just copy & paste & merge the j3d library's bin/ & lib/
folders into the corresponding bin/ & lib/
folders of both the jre/ & jdk/
JVM folders that you use.
我解决了这个问题,非常简单:只需复制&粘贴并将j3d库的bin/ & lib/文件夹合并到您所使用的jre/ & jdk/ JVM文件夹的相应bin/ & lib/文件夹中。
- Download corresponding j3d Zip binaries at https://java3d.java.net/binary-builds.html. For me, a win7 64bit Java VM (aka. jdk & jre), I choose
j3d-1_5_2-windows-amd64.zip
. - 在https://java3d.java.net/binarybuilds.html中下载相应的j3d Zip二进制文件。对于我来说,一个win7 64位的Java VM (aka)。我选择j3d-1 _5_ 2-windows-amd64.zip。
- UnZip the downloaded j3d Zip binaries (
j3d-1_5_2-windows-amd64.zip
) to get thej3d-jre.zip
file inside. - 解压缩下载的j3d Zip二进制文件(j3d-1 _5_ 2-window -amd64.zip)获取j3d-jre。zip文件里面。
- UnZip the
j3d-jre.zip
to get thebin/ & lib/
folders. - 解压j3d-jre。zip以获取bin/ & lib/文件夹。
- Copy & paste & merge the obtained
bin/ & lib/
folders into the correspondingbin/ & lib/
folders of my JVM folders (aka. bothjdk/ & jre/
folders). - 复制&粘贴并将获得的bin/ & lib/文件夹合并到我的JVM文件夹的相应bin/ & lib/文件夹中。两个jdk/ & jre/文件夹)。
For other JVMs, it's the same thing - copy & paste & merge the j3d zip library's bin/ & lib/
folders into the corresponding bin/ & lib/
folders of the JVM's jre/ & jdk/
对于其他JVM,它是一样的——复制&粘贴&将j3d zip库的bin/ & lib/文件夹合并到JVM jre/ & jdk/的相应bin/ & lib/文件夹中。
#2
0
Can you try executing regsvr32 "name_of_dll-file" from the run menu? You need to reboot the machine for this to take effect.
您可以从run菜单中尝试执行regsvr32“name_of_dllfile”吗?您需要重新启动机器以使其生效。
This adds the DLL as a library that other programs can access. Adding it to the Eclipse build path is not the right thing since that will only be accessible to your JVM.
这将DLL添加到其他程序可以访问的库中。将它添加到Eclipse构建路径不是正确的事情,因为它只能访问您的JVM。
#3
-2
i solved problem by copying j3dcore-ogl.dll to windows/system32 folder
我通过复制j3dcore-ogl解决了问题。dll windows / system32系统文件夹