White Shading

Supported by ...

COLOR cameras only.  

Description

The White Shading feature provides control over the individual red, green and blue channel gains so that non-standard color balance can be achieved.  One-push Auto will attempt to white balance the gains (match the histogram peaks of the brightest area in each color channel) based on the image data in the current ROI. 

 

Note

The auto white shading algorithm is based on a brightfield microscopy where the background is bright and white.  The algorithm balances the brightest areas of the image to white.  When used in reflected light microscopy or in colored environments, the brightest areas in the image must be neutral in color.  If not, it is best to perform the auto white shading using a grey card.

White shading is performed prior to other image processing steps and is independent of the white balance (color correction) settings.

Setting a gain parameter to zero will effectively turn off that color channel – it will output a zero value.

 

Note

Setting a color channel gain to zero and also setting the saturation feature to zero will result in values on that color channel.  The color channel gains affect the raw sensor data and any image processing performed on-board the camera, like the saturation adjustment, may modify the values on the color channels.

API Control

PxLGetFeature, PxLSetFeature

Feature

Number of Parms

Parameters

Units

Restrictions

FEATURE_WHITE_SHADING

Camera color channel gains

3

fRedGain

Decibels (dB)

N/A

fGreenGain

Decibels (dB)

N/A

fBlueGain

Decibels (dB)

N/A

 

Feature Flags

Camera

Presence

Read Only

Auto

Manual

One-time Auto

Off

CiD

All Cameras

Yes

No

No

Yes

Yes

No

Yes

 

Parameters

Camera

Parameter

Unit

Type

Min

Max

Default

Step Size

Comments

742, 681C

Gain Red

None

Absolute

0

4

1.06

0.0156

 

Gain Green

None

Absolute

0

4

1.0

0.0156

 

Gain Blue

None

Absolute

0

4

1.57

0.0156

 

762

Gain Red

None

Absolute

0

4

1.0

0.01

 

Gain Green

None

Absolute

0

4

1.0

0.01

 

Gain Blue

None

Absolute

0

4

2.0

0.01

 

774, 776, 778,

 622C, 623C, 625C

Gain Red

None

Absolute

0

4

1.0

0.0156

 

Gain Green

None

Absolute

0

4

1.0

0.0156

 

Gain Blue

None

Absolute

0

4

1.73

0.0156

 

782, 686C

Gain Red

None

Absolute

0

4

1.42

0.0156

 

Gain Green

None

Absolute

0

4

1.0

0.0156

 

Gain Blue

None

Absolute

0

4

1.08

0.0156

 

870C, 950

Gain Red

None

Absolute

0

8

1.0

0.0312

 

Gain Green

None

Absolute

0

8

1.0

0.0312

 

Gain Blue

None

Absolute

0

8

2.0

0.0312

 

IIDC Control

The white shading control, as described in the IIDC 1.31 specification, only provides for 8 bits of shading data per channel. Additional CSRs are provided to allow 32-bit resolution in color channels.  The White Shading can also be set by the Auto mode of the White Balance feature.

Cameras

Feature

Feature Control Register Values

Corresponding Absolute Values

Min

Max

Min

Max

600 & 700

White Shading

0

255

0.0

4.0

800 & 900

0

255

0.0

8.0

 

White Shading Absolute Value Registers

The IIDC 1.31 specification defines White Shading as controlling three values, the red, green and blue channel compensations, but only one absolute value register is defined for White Shading.  This does not allow for control of the separate channel compensations with standard engineering units. So extra absolute value registers are defined as follows.

The offsets for the White_Shading absolute value CSRs are defined in the ABS_CSR_HI_INQ_14 register (offset 738h). This will define the offsets for the red channel compensation CSRs. The absolute value CSR offsets for the green and blue channels can be calculated as follows : quadlet offset of green or blue CSRs = ABS_CSR_HI_INQ_14 + 3 * X (where X = 1 for green and X = 2 for blue).