public ThumbnailsCanvas(ImagePlus imp) { if (!imp.isComposite()) { return; } cImp = (CompositeImage) imp; addMouseListener(this); addMouseMotionListener(this); currentChannel = cImp.getChannel(); currentSlice = cImp.getSlice(); currentFrame = cImp.getFrame(); channelUnderCursor = currentChannel; int ww = cImp.getWidth(); int hh = cImp.getHeight(); if (ww > hh) { iconHeight = iconWidth * hh / ww; dy = (iconWidth - iconHeight) / 2; } if (ww < hh) { iconWidth = iconHeight * ww / hh; dx = (iconHeight - iconWidth) / 2; } nChannels = cImp.getNChannels(); seq = seq.substring(0, nChannels); setSize((nChannels + 1) * iconSize, 2 * iconSize + 30); }
public ThumbnailsCanvas(ImagePlus imp) { if (!imp.isComposite()) { return; } cImp = (CompositeImage) imp; addMouseListener(this); addMouseMotionListener(this); currentChannel = cImp.getChannel(); currentSlice = cImp.getSlice(); currentFrame = cImp.getFrame(); channelUnderCursor = currentChannel; int ww = cImp.getWidth(); int hh = cImp.getHeight(); if (ww > hh) { iconHeight = iconWidth * hh / ww; dy = (iconWidth - iconHeight) / 2; } if (ww < hh) { iconWidth = iconHeight * ww / hh; dx = (iconHeight - iconWidth) / 2; } nChannels = cImp.getNChannels(); seq = seq.substring(0, nChannels); setSize((nChannels + 1) * iconSize, 2 * iconSize + 30); }
final ImageStack stack = new ImageStack( timepoint0.getWidth(), timepoint0.getHeight() );
height = imp.getHeight(); imageSize = width*height*4.0/(1024.0*1024.0); channels1 = imp.getNChannels();
height = imp.getHeight(); imageSize = width*height*4.0/(1024.0*1024.0); channels1 = imp.getNChannels();
return; ImageStack stack = new ImageStack(imp.getWidth(), imp.getHeight()); int c = imp.getChannel(); int n = imp.getNChannels();
return; ImageStack stack = new ImageStack(imp.getWidth(), imp.getHeight()); int c = imp.getChannel(); int n = imp.getNChannels();