ImageJ base code to get access to all the classes and their methods to test new Plugins. https://imagejdocu.tudor.lu/howto/plugins/the_imagej_eclipse_howto
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 

18 lines
656 B

var floodType = call("ij.Prefs.get", "tool.flood", "8-connected");
var alt = 8;
macro "Flood Fill Tool -C037B21P085373b75d0L4d1aL3135L4050L6166D57D77D68D09D94Da7C123Da5La9abLb6bc" {
setupUndo();
getCursorLoc(x, y, z, flags);
if (flags&alt!=0)
setColor(getValue("color.background"));
floodFill(x, y, floodType);
}
macro 'Flood Fill Tool Options...' {
Dialog.create("Flood Fill Tool");
Dialog.addChoice("Flood Type:", newArray("4-connected", "8-connected"), floodType);
Dialog.show();
floodType = Dialog.getChoice();
call("ij.Prefs.set", "tool.flood", floodType);
}