http://imagej.273.s1.nabble.com/Problem-using-ROIs-tp3701857p3701858.html
> I'm using ImageJ for a project at university and came across
> a problem when using ROIs. I've created a (quick & dirty)
> sample plugin to demonstrate my problem:
>
http://www.cip.ifi.lmu.de/~graff/uni/ROI_Marker.java>
> The paintRoi() method creates an OvalRoi and colors the
> masked pixels (within the oval) red. At least it's supposed
> to do that.
>
> It's no problem when it's called from the run() method. But
> when it's called from the JFrame (which is opened by the
> plugin) the OvalRoi is shown, but all pixels in the bounding
> rectangle are colored red.
>
> Why is it like that? Can I only create and apply ROIs within
> the run() method or what's the correct way to achieve the
> correct masking?
Use the ImageProcessor.reset(mask) method to do the masking. I updated