Java3D Issue: BoneJ with latest Fiji version - Problem solved

Tags: #<Tag:0x00007fb87d863ac0>


@Vasily The code you invoked has been updated to use the SciJava version of Java 3D 1.6. So you need to update your Fiji to the latest version. You are still running the old Java 6 version.

Unfortunately, the ImageJ Updater cannot currently do this update for you. The easiest way forward is to download a new copy of Fiji from the web site. See also this page for details on the transition.

If you have a heavily customized Fiji installation and would rather not reinstall, you can: 1) update to Java-8 by renaming the\java folder to\java6; 2) Launch Fiji and make sure the status bar says “Java 1.8.0…” and not “Java 1.6.0_24”; and then 3) Enable the Java-8 update site and install all the updates.

If you want to play it safe, unpack a newly downloaded Fiji into a new directory, and leave your old installation alone. It is certainly OK to have multiple copies of Fiji on your system.


A post was split to a new topic: Image disappearing rapidly


Hello, I tried to install the latest fiji and bonej and I have issues. I am using mac sierra (10.12.6). Fiji works fine. I installed bonej, but when I use any of the functions it says “java 3d libraries are not installed. please install and run the imagej 3d viewer, which will automatically install java’s 3d libraries.”

I checked and it appears that the 3d viewers are working correctly in fiji.

Any suggestions?

Thank you.


@rhk12 It is recommended that you use the Java 6 version of Fiji with BoneJ. It is not fully compatible with the current Java 8 version.

  • Go here:
  • Download the “2017 May 30” version of Fiji, i.e. the final version of Fiji using Java 6.
  • Unpack it somewhere beneath your home folder.
  • Download and install BoneJ into that installation.
  • Launch Fiji and run Plugins :arrow_forward: 3D Viewer to trigger installation of the 3D Viewer.
  • Restart Fiji.

After that, all BoneJ functionality should work; please follow up here if not.

Edit: I added these instructions to the BoneJ wiki page.

Edit 2:

Note that I am not 100% certain that Java 6 + Java 3D 1.5 actually works on macOS Sierra. At least, it doesn’t work on my system (Java dumps core on startup), although my system may have unique quirks. But it is also possible that Apple changed something in Sierra that renders this combination infeasible now.

It would be helpful if someone else on macOS Sierra could test this and report back.

3D fractal analysis
BoneJ issue- volume fraction or 3D viewer problem?

Hello there!

We are beating our heads against the wall with the same error(s). I have tried several different install combinations and we are not able to get Fiji, BoneJ, and Java 3d working at the some time.

We are using MacOS Sierra 10.12.6

When launching one of the BoneJ functions we get the message about “java 3d libraries are not installed…” or if I test the 3d Viewer I get the following dump in the console:

version = 1.5
Exception in thread “J3D-Renderer-1” java.lang.UnsatisfiedLinkError: /Applications/ Library not loaded: /System/Library/Frameworks/JavaVM.framework/Libraries/libjawt.dylib Referenced from: /Applications/ Reason: image not found
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(
at java.lang.ClassLoader.loadLibrary(
at java.lang.Runtime.loadLibrary0(
at java.lang.System.loadLibrary(
at com.sun.opengl.impl.NativeLibLoader.loadLibraryInternal(
at com.sun.opengl.impl.NativeLibLoader.access$000(
at com.sun.opengl.impl.NativeLibLoader$DefaultAction.loadLibrary(
at com.sun.opengl.impl.NativeLibLoader.loadLibrary(
at com.sun.opengl.impl.NativeLibLoader.access$200(
at com.sun.opengl.impl.NativeLibLoader$
at Method)
at com.sun.opengl.impl.NativeLibLoader.loadAWTImpl(
at com.sun.opengl.impl.JAWT.getJAWT(
at com.sun.opengl.impl.macosx.MacOSXOnscreenGLDrawable.lockSurface(
at com.sun.opengl.impl.macosx.MacOSXOnscreenGLContext.makeCurrentImpl(
at com.sun.opengl.impl.GLContextImpl.makeCurrent(

I have been trying to get this to work for weeks now. Please advise before I start drinking again. :weary:



Sorry to hear of your troubles, @D_Maag.

Your error message of “image not found” for file /System/Library/Frameworks/JavaVM.framework/Libraries/libjawt.dylib suggests that Java 6 may not be installed. Are you confident your Fiji is running with Java 6? Here’s how to check. Note that running Java 6 on macOS is increasingly painful, but it can still be done; see here for instructions.

That said, I checked on my High Sierra system, and indeed the file /System/Library/Frameworks/JavaVM.framework/Libraries/libjawt.dylib is not present anymore, even though I have Java 6 installed. Instead, I found that file here: /Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Libraries. I will do some testing now, see if I can reproduce, and fix the issue locally. Edit: I have the same issue. And it cannot be fixed easily with a symlink because macOS disallows edits to /System due to the System Integrity Protection feature of El Capitan and later. I tried to develop a shell script to work around the problem, but the library linkages are really broken now.

If your choices are really to either make this work, or start drinking again, then next thing to try would be to disable System Integrity Protection and start symlinking Library directories and/or dylib and jnilib files, hoping to make something work. But I would urge you to consider sticking with an older version of macOS instead, since this seems like a crumbling path.

Perhaps @rimadoma or @mdoube could comment on the timeline for BoneJ to work with Java 8 + Java 3D 1.6 and/or SciView.

3D Viewer doesn't work with Java8

Hi @D_Maag,

Sorry to hear about your troubles. Depending on which BoneJ tools you need, you could try the experimental version of BoneJ2. Implemented so far are:

  • Analyze skeleton
  • Connectivity
  • Fractal dimension
  • Intertrabecular angles
  • Isosurface
  • Local thickness
  • Skeletonize
  • Support for additional file formats
  • Volume fraction

Here are instructions how to install it on either Fiji or ImageJ:

Best regards,


Please stick with us & have a go with BoneJ2 experimental as @rimadoma suggests, and let us know how you get on.

I personally need something strong before doing anything with Apple products; happy to give you my Martini recipe off-forum.


LOL, if only I drank martinis (don’t hate me).

We are using the Volume Fraction component.

The truly frustrating thing about this is that I had it BoneJ and the 3D libraries working two weeks ago. Then the iMac crashed (new BTW) and got wiped by the Apple Store folks.

Thank you for the instructions. I will try this soonest and get back.




Thank you for the detailed reply. Unfortunately, I only understood about half of what you said. My forté is Windows.

As far as “sticking with an older version of macOS”, that may not be an option. This is a brand new iMac. I will give it some thought.

Do you think a Linux VM would be easier than getting this to work on Sierra?


It would be worth a try. The performance of Java 3D in a VM may suffer (or may not—try and see). But hopefully it will at least still function.

Alternately, you could Boot Camp to Windows or Linux, which should retain good 3D performance.




In an attempt to get this working anywhere, I have now downloaded Fiji w/Java 6 and Fiji w/Java 8 onto my Win10 PC.

Our best case scenario right now (on both Mac and PC) goes like this…

  1. File -> Import -> Image Sequence -> select folder containing images -> wait while images are imported
  2. Plugins -> 3D Viewer (3D viewer launches fine with no errors) -> we can see and manipulate the compiled image in the 3D Viewer.
  3. Plugins -> BoneJ -> Volume Fraction -> Immediately get message: “Java 3D libraries are not installed. Please install and run the ImageJ 3D Viewer…etc…”

Does this help?

Thank you again for your time and attention.




It’s possible that even if the 3D viewer works for viewing, the libraries it uses under the hood have changed, so BoneJ doesn’t recognise them. @rimadoma suggested making BoneJ’s environment check more specific so that it only complains about missing 3D libraries at the point in the code when they’re really needed. I’m a bit short on bandwidth right now to do this for BoneJ1; the alternative is to have a go with BoneJ2.


Sounds great. Which version did you use for testing in your following report? Java 6? Or Java 8?


Maybe it’d be best to only complain about missing 3D libs where possible, i.e. “You wanted me to display surfaces, but I can’t. Here’s your other results though.” instead of “I won’t run because there are no 3D libs”. With Volume Fraction having the libs for creating a mesh is essential, and the surface based version cannot run without them. But the voxel based can.


I used both.

I will try BoneJ2. Thank you.


OK, good news. I was able to get this working by using BoneJ2. Thank you for the suggestion @mdoube

Next, I will go try this on the iMac.

Once more unto the breach, dear friends, once more…


@mdoube Just a side note: at the moment BoneJ2 can create meshes with marching cubes and calculate their properties in Volume fraction and Isosurface, but it doesn’t know how to visualize them yet.


Hi @Dave_Maag,

@ctrueden (big thanks!) and I have been trying to reproduce your problem on Windows 10, but in our environments BoneJ works fine. Here are the steps we took to get BoneJ up and running:

  1. Download and install Java 6 lifeline version of Fiji
  2. Download BoneJ and drop it to the folder as per normal.
  3. Launch Fiji and start using the plugins.

We’ve tested that these steps work on both Win 8.1 64-bit and Win 10 64-bit.

Best regards,

BoneJ Isosurface- cannot measure surface area BS(um^2)

Thanks for this. Running Fiji under Ubuntu 16.04 with Java 8 update site, the 3D ImageJ suite was complaining that Java3D was not working, and this manual install fixed it.