macros.SprayCanTool.txt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of ij Show documentation
Show all versions of ij Show documentation
ImageJ is an open source Java image processing program inspired by NIH Image for the Macintosh.
// Spray Can Tool
var width=100, dotSize=1, rate=6;
macro 'Spray Can Tool - C123D20D22D24D41D43D62D82Da2C037L93b3D84Dc4L75d5L757f Ld5dfLa7d7LabdbLa9d9LacdcLa7ac' {
setLineWidth(dotSize);
radius=width/2; radius2=radius*radius;
start = getTime();
autoUpdate(false);
n = 25*exp(0.9*(10-rate));
if (n<=5) n = 0;
while (true) {
getCursorLoc(x, y, z, flags);
if (flags&16==0) exit();
x2 = (random()-0.5)*width;
y2 = (random()-0.5)*width;
if (x2*x2+y2*y2start+50) {
updateDisplay();
start = getTime();
}
}
for (i=0; i10) rate = 10;
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy