Fix issues; get IJ1 plugin working

Fixed problems found on IJ1 side fitting sample
images.