Login  Register

Problem with seMinAndMax

Posted by Michael Doube on Feb 12, 2008; 11:39am
URL: http://imagej.273.s1.nabble.com/Problem-with-seMinAndMax-tp3697203.html

Hi all

I've been struggling with a little macro that will automatically window
some 16-bit CT images of dry bone in air.  I want air to be black and
bone to be shades of grey with nice dynamic range.

If I manually set Window and Level, macro recorder tells me the code is:

setMinAndMax(31468, 32959);

and my image looks how I want it

However, if I run this code from a macro window, my image goes black as
the window level is way too low (the ramp goes off the right of the W&L
graph).

Any ideas what might be going on?

Cheers

Mike

ij 1.39r Java 1.6.0_04 WinXP SP2

--
Dr Michael Doube  BPhil BVSc PhD MRCVS
Research Associate
Department of Bioengineering
Imperial College London
South Kensington Campus
London  SW7 2AZ
United Kingdom