Configuration of warping parameters

The configuration information passed to the warping library is used to check constraints and as basis for computations.

Overall configuration parameter structure

The following table details the overall configuration parameter structure and their limits.

Name Range Description Example Value
NumBitsPerParam 1..16 Number of bits used for each parameter (bit length of each parameter, contains pixel fractions) 12
PixResolution 0: 1/16 px
1: 1/8 px
2: 1/4 px
3: 1/2 px
4: 1 px
5: 2 px
6: 4 px
7: 8 px
Resolution of warping parameters. 0 (1/16 px)
DisplaySizeX 0..655535 Display size in horizontal direction (in pixel). 480
DisplaySizeY 0..655535 Display size in vertical direction (in pixel). 240
BitmapAreaX 0..655535

Number of Bitmap-pixels in horizontal direction. Reference points are equally distributed over this range in x-direction.

Condition:
BitmapAreaX ≤ DisplaySizeX

480
BitmapAreaY 0..655535

Number of Bitmap-pixels in vertical direction. Reference points are equally distributed over this range in y-direction.

Condition:
BitmapAreaY ≤ DisplaySizeY

240
BitmapAreaShiftX 0..655535

Shift of the bitmap area center point in horizontal direction.

Condition:
(BitmapAreaX/2+BitmapAreaShiftX≤DisplaySizeX) AND (BitmapAreaX/2– BitmapAreaShiftX ≥0)

240
BitmapAreaShiftY 0..655535

Shift of the bitmap area center point in vertical direction.

Condition:
(BitmapAreaY/2+BitmapAreaShiftY≤DisplaySizeY) AND (BitmapAreaY/2– BitmapAreaShiftY ≥0)

120
IlluminatedDisplayAreaX 0..655535

Number of illuminated pixels in horizontal direction

Condition:
IlluminatedDisplayAreaX ≤DisplaySizeY

480
IlluminatedDisplayAreaY 0..655535

Number of illuminated pixels in vertical direction

Condition:
IlluminatedDisplayAreaY ≤DisplaySizeY

220
IlluminatedDisplayAreaShiftX 0..655535

Shift of the illuminated display area center point in horizontal direction.

Condition:
(IllDisplayAreaX/2+IllDisplayAreaShiftX≤DisplaySizeX) AND (IllDisplayAreaX/2– IllDisplayAreaShiftX ≥0)

480
IlluminatedDisplayAreaShiftY 0..655535

Shift of the illuminated display area center point in vertical direction.

Condition:
(IllDisplayAreaY/2+IllDisplayAreaShiftY≤DisplaySizeY) AND (IllDisplayAreaY/2– IllDisplayAreaShiftY ≥0)

220
WarpingAreaX 0..655535

Number of pixels used for warping in horizontal direction.

Condition:
WarpingAreaX≤IlluminatedDisplayAreaX


This parameter is present for historical reasons and is not used during computation/adjustment. Its validity is still checked, though.

470
WarpingAreaY 0..655535

Number of pixels used for warping in vertical direction.

Condition:
WarpingAreaY≤IlluminatedDisplayAreaY

This parameter is present for historical reasons and is not used during computation/adjustment. Its validity is still checked, though.

120
WarpedAreaShiftX 0..655535

Shift of the warped area center point in horizontal direction.


This parameter is present for historical reasons and is not used during computation/adjustment. Its validity is still checked, though.

220
WarpedAreaShiftY 0..655535

Shift of the warped area center point in vertical direction.

This parameter is present for historical reasons and is not used during computation/adjustment. Its validity is still checked, though.

110
RotationValue -18000 .. +18000 Rotation value in grad * 100 -150 // rotate 1.5°
ParamSet Data
Set of reference point shift vectors row-major ordered(left to right, top to bottom).
Each reference point in x/y direction is represented as a signed integer value in range –32,768 .. 32,767 (2 bytes).
(X0, Y0)
(X0, Y1)

(XM, YN)

M: #RefPointsX
N: #RefPointsY
ParamSetLength 0..655535 Length of parameter set in bytes calculated using the following formula:
2 * NumRefPointsX * NumRefPointsY * NumBitsPerParam / 8
825 // 2*25*11*12/8
RotationLimit 0..180 Maximal rotation angle in grad (+/- value) 5 // +/- 5°
TrapezoidLimitX 0..655535 Maximum value for trapezoid transformation in horizontal direction (+/- value) 50
TrapezoidLimitY 0..655535 Maximum value for trapezoid transformation in vertical direction (+/- value) 50
ParallelogramLimitX 0..655535 Maximum value for parallelogram transformation in horizontal direction (+/- value) 50
ParallelogramLimitY 0..655535 Maximum value for parallelogram transformation in vertical direction (+/- value) 50
PinbalanceLimitX 0..655535 Maximum value for pin balance transformation in horizontal direction (+/- value) 50
PinbalanceLimitY 0..655535 Maximum value for pin balance transformation in vetical direction (+/- value) 50
PincushionLimitX 0..655535 Maximum value for pincushion transformation in horizontal direction (+/- value) 50
PincushionLimitY 0..655535 Maximum value for pincushion transformation in vetical direction (+/- value) 50
WidthLimit 0..655535 Maximum value for width transformation in horizontal direction (+/- value) 50
HeightLimit 0..655535 Maximum value for height transformation in vetical direction (+/- value) 50
ScaleMode 0 or 1

0 - scale factor is 1. Scaling might occur if image does not fit inside illuminated area

1 - scale factor is calculated based on RotationLimit value, such that, when rotated at maximum, the image will fit inside illuminated area

0

Please refer to the following chapters for details on how the parameters influence the result of the warped image.




Revision #3
Created 2023-02-21 04:09:52 UTC by Kanai Tomoaki
Updated 2023-05-15 06:07:57 UTC by Tsuyoshi.Kato