Skip to content

Instantly share code, notes, and snippets.

mutterer

Block or report user

Report or block mutterer

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@mutterer
mutterer / readCziEvents_.ijm
Last active Aug 28, 2019
An ImageJ macro to read 'timestamps' and 'events' from CZI files. Request from Julien Cau and Emmanuel Perisse.
View readCziEvents_.ijm
// ImageJ macro to read 'timestamps' and 'events' from CZI files.
path = File.openDialog("Select CZI File");
s = File.openAsRawString(path, File.length(path));
o = indexOf(s,"CZTIMS");
o=o+0xcc;
n = parseInt(read32bAt(o));
timestamps = newArray(n);
View add_mark_every_x_microns.ijm
// example C. elegans image from:
// https://www.age.mpg.de/science/research-laboratories/antebi/
interval = 50;
open("https://www.age.mpg.de/fileadmin/_processed_/d/1/csm_Bild_Website_Antebi_8220cc62b1.jpg");
makeLine(350, 92, 370, 131);
run("Set Scale...", "known=30 unit=microns");
makeLine(49,138,108,125,165,67,293,138,409,92,558,114,654,61,737,42);
run("Fit Spline");
run("Interpolate", "interval=1 smooth");
@mutterer
mutterer / white_balance_from_grey_area.ijm
Created Jun 5, 2019
white_balance_from_grey_area corrects an RGB image white balance using a reference ROI
View white_balance_from_grey_area.ijm
setBatchMode(1);
t=getTitle();
getBoundingRect(x, y, width, height);
run("Select None");
run("Duplicate..." , "title=ori duplicate");
makeRectangle(x, y, width, height);
run("RGB Stack");
run("32-bit");
id=getImageID;
run("Duplicate..." , "title=temp duplicate");
@mutterer
mutterer / overlay_crosses_eduardo.ijm
Last active May 5, 2019
An ImageJ macro for movie annotation, that overlays customisable reticles at each multipoint point, one per slice
View overlay_crosses_eduardo.ijm
Overlay.remove;
n = roiManager('count');
for (i=0; i<n; i++) {
roiManager('select', i);
getSelectionCoordinates(x,y);
addCross(9,12,1,'green');
}
Overlay.show;
@mutterer
mutterer / mini_app.ijm
Created Jan 23, 2019
Example code for an ActionBar mini app
View mini_app.ijm
// Example code for an ActionBar mini app.
// Save this in Plugins>ActionBar
// Launch it at statup using run("mini app"); in Options>Startup...
// Action Bar description file :mini_app
run("Action Bar","/plugins/ActionBar/mini_app.ijm");
exit;
<main>
@mutterer
mutterer / Magic_Montage.ijm
Last active Nov 9, 2018
Magic_Montage version 1.6
View Magic_Montage.ijm
//--version--1.6
// 1.6 adds the '?' button that points to the wiki page
// panel labels are now drawn on an overlay
// added overlay commands and copy to system clipboard to the rightclick menu
// Montage tools for easy montage manipulation
// jerome.mutterer at ibmp.fr
var v=versionCheck();
function versionCheck() {
requires("1.41f");
@mutterer
mutterer / zColored_dzSized_Dots.ijm
Last active Oct 13, 2018
An ImageJ macroset with a tool that places dots with colors reflecting their z position and slice navigation that adjusts dot size to according to distance to the current slice.
View zColored_dzSized_Dots.ijm
var sizes = newArray("Extra Large","Large","Medium","Small","Tiny");
macro "Z-Colored_Dots Tool - Cc0co1166C00co5366C0c0o5866Cc00o8a66" {
roiManager("Associate", false);
r=newArray(256);
for (i=0;i<r.length;i++) {
r[i] = floor(127*(1+sin(2*PI*i/256)));
}
g=Array.copy(r);
b=Array.copy(r);
@mutterer
mutterer / Pie_Cut_Toolset.ijm
Last active Jun 25, 2018
An ImageJ Toolset to interactively create image parts
View Pie_Cut_Toolset.ijm
// Pie Cut Toolset modified from the star_tool.ijm sample macro
//
var minSize = 12;
var nPoints = 6;
var ratio = 0;
var lineWidth = 2;
var fillStar = false;
macro "Pie Tool - B17C039T0f28*" {
@mutterer
mutterer / Frame_Face Tools.ijm
Last active Jan 17, 2018
Crops the clicked face in a image
View Frame_Face Tools.ijm
// presiquites: A fresh Fiji installation
// subscribe to the IJ OpenCV plugins update site
macro "Frame Face Tool - C000T0f16F" {
getCursorLoc(x,y,z,flags);
if (isOpen("ROI Manager")) {
selectWindow("ROI Manager");
run("Close");
}
run("FaceDetectionJ ");
@mutterer
mutterer / 10PRINT 'rosette'.pde
Last active Oct 2, 2017
// 10PRINT rosette Processing 3 code, thanks to @shiffman !
View 10PRINT 'rosette'.pde
// 10PRINT rosette Processing 3 code
// thanks to @shiffman !
float r=20;
float s=10;
void setup() {
size(300, 300);
frameRate(1);
}
You can’t perform that action at this time.