zoom problem
Posted by Nicola B. on Feb 09, 2009; 3:03pm
URL: http://imagej.273.s1.nabble.com/Tudor-DICOM-compressed-images-tp3693776p3693785.html
Hi all,
I've a little problem with zoom..
When I create a little image (e.g. 30x30), what should I do to display
it bigger on screen? (e.g 1/5 of total screen height)
I try with:
-----------
ImagePlus imp = new ImagePlus("testZoom", new
ColorProcessor(30,30));
imp.show();
double _newImpHeight =
Toolkit.getDefaultToolkit().getScreenSize().getHeight() / 5;
double _displayMagn = _newImpHeight/imp.getHeight();
imp.getCanvas().setMagnification(_displayMagn);
imp.updateAndDraw();
imp.updateAndRepaintWindow();
-----------
but it doesn't work..
Best regards,
-nicola