WindowLevel example for Visual J++

This example converts a bitmap to 12-bit grayscale and then performs window leveling on the four most significant bits of the image.

LEAD1.Grayscale( (short) 12 );  // Grayscale image to 12-bit
LEAD1.setLevelLowBit( (short) 8 );  // use 4 most significant bits
LEAD1.setLevelHighBit( (short) 11 );
LEAD1.WindowLevel();