Last active
October 21, 2020 01:07
-
-
Save miura/5ad58a8b7538aa4a3c2653d933d1cd65 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ImageJ macro | |
//*** change the window title here, depending on your input image. | |
OriginalTitle = "BloodVessels_small.tif"; | |
// following window titles are always same. | |
LabelMask = "FastFiltered_Tubeness_LabelMask.tif"; | |
tagged = "FastFiltered_Tubeness_LabelMask_Skeleton_tagged_skeleton.tif"; | |
VisualisationDilation = 2; | |
Nthreads = 4; | |
selectWindow( tagged ); | |
run("Macro...", "code=v=(v==127)*127+(v==30)*192+(v==70)*255 stack"); | |
run("3D Fast Filters","filter=Maximum radius_x_pix="+d2s(VisualisationDilation,0)+" radius_y_pix="+d2s(VisualisationDilation,0)+" radius_z_pix="+d2s(VisualisationDilation,0)+" Nb_cpus="+d2s(Nthreads,0)); | |
run("Fire"); | |
rename("ThickSkeleton.tif"); | |
run("3D Viewer"); | |
call("ij3d.ImageJ3DViewer.setCoordinateSystem", "false"); | |
call("ij3d.ImageJ3DViewer.add", OriginalTitle, "None", OriginalTitle, "0", "true", "true", "true", "2", "0"); | |
call("ij3d.ImageJ3DViewer.add", LabelMask, "None", LabelMask, "0", "true", "true", "true", "2", "0"); | |
call("ij3d.ImageJ3DViewer.add", "ThickSkeleton.tif", "None", "ThickSkeleton.tif", "0", "true", "true", "true", "2", "0"); | |
call("ij3d.ImageJ3DViewer.startAnimate"); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment