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.

15 lines
388 B

2 years ago
  1. newImage("Untitled", "RGB", 400, 400, 1);
  2. width = getWidth();
  3. height = getHeight();
  4. for (i=0; i<1000; i++) {
  5. if (nSlices!=1) exit;
  6. w = random()*width/2+1;
  7. h = random()*width/2+1;
  8. x = random()*width-w/2;
  9. y = random()*height-h/2;
  10. setForegroundColor(random()*255, random()*255, random()*255);
  11. makeOval(x, y, w, h);
  12. run("Fill");
  13. }