Interactive 3D Surface Plot macro problem

Dear all,

We had this macro that created a 3D surface plot using the 3D Surface Plot plugin following the code instructions provided here:

We cannot make it work any more, it gives us the error attached when running our macro or the macro example provided.

I will try with the simpler ImageJ and installing the plugin just in case, but it would be great to be able to use it in Fiji again.

Thanks a lot in advance!


Hi Veronica,
The following macro from the website works for me in Fiji.
Did you put the jar from the plugin in > plugins and restarted Fiji?
Also maybe put the command

run("Interactive 3D Surface Plot", "plotType=3 smooth=11 colorType=3 snapshot=1 rotationZ="+angleZ);`

on a single line like below, instead of having it span 2 lines
Otherwise try on a freshly downloaded Fiji.

run("Blobs (25K)");
img1 = getImageID;
stack = 0;
n = 10;
for (i=0; i<n; i++) {
showProgress(i, n);
angleZ = -i * 4 + 60;
run("Interactive 3D Surface Plot", "plotType=3 smooth=11 colorType=3 snapshot=1 rotationZ="+angleZ);
w = getWidth; h = getHeight;
if (stack==0) {
 newImage("Plots", "RGB", w, h, 1);
 stack = getImageID;
} else {
 run("Add Slice");
run("Select None");

I see, you are totally right! I thought the tool available in Fiji in Analyze>3D Surface Plot was the same as the plugin. Thank you for your fast reply and sorry for the silly question!

1 Like

There is no silly question, other people might come across the same situation, so thanks for making the point !

And sorry for the confusing 3D viewers situation, I like the interactive 3D plotter too, It would be great if it would be available via a dedicated Fiji update site rather than manually installing it.
Let’s see what the original author (@barthel) thinks about it :blush:


The plugin Analyze>3D Surface Plot is the same plugin and it is included in Fiji.
If you change the mocro line:
run(“Interactive 3D Surface Plot”, “plotType=3 smooth=11 colorType=3 snapshot=1 rotationZ=”+angleZ);
run(“3D Surface Plot”, “plotType=3 smooth=11 colorType=3 snapshot=1 rotationZ=”+angleZ);
it will work.

Thanks a lot for the info!