Types of plugins

Before developing a plug-in for ImageJ / Fijian must think that kind is going to be, and this depends on the input data:

  • If you do not require an image as input: PlugIn
  • If requires that an open image: PlugInFilter
  • And if the plugin runs in its own window: PlugInFrame


Its interfaces are:


void run (java.lang.String arg) //this method runs the plugin. "arg" is an argument to the plugin, which can be empty string.



void run (ImageProcessor ip) //this method runs the plugin. It takes the image processor and it works on as an argument.


int setup (java.lang.String arg, ImagePlus imp) //this method sets up the plugin filter use. The "arg" string has the same function as in the run method of the PlugIn interface.



       //this is a subclass of an AWT frame that implementes the PlugIn

PlugInFrame(java.lang.String title) 

void run (java.lang.String arg) //declared in the PlugIn interface is implemented and can be overwritten by your plugin's run method.


Source: here.

Escribir comentario

Comentarios: 0