Posted by Michael Entrup on Feb 01, 2016; 10:15am URL: http://imagej.273.s1.nabble.com/Get-the-pixel-Size-tp5015501p5015507.html
Hi Ben,
each ImagePlus [1] has a method called ``getCalibration()``. It returns
the Calibration [2] instance of the ImagePlus. The Calibration Object
contains all the methods you need. ``getUnit()`` returns a String to
check if the unit is µm. ``getX(double x)`` converts a pixel value into
a physical unit.
> Hello,
>
> I have a simple problem and reading different forums didn't help me to
> resolve it.
>
> I need for my ImageJ Plugins to attribute to a variable "x" the value of the
> pixel size in "µm" used in my pre-calibrated "image1".
>
> It would really help me if someone can help me on this case.
>
> Thanks very much.
>
> Ben
>
>
>
> --
> View this message in context: http://imagej.1557.x6.nabble.com/Get-the-pixel-Size-tp5015501.html > Sent from the ImageJ mailing list archive at Nabble.com.
>
> --
> ImageJ mailing list: http://imagej.nih.gov/ij/list.html >