CImage:SubBiasVal
The SubBiasVal method subtracts a specified bias value image from the current image. The result replaces the current image.
bSuccess = CImage:SubBiasVal( value ) bSuccess = CImage:SubBiasVal( value, datatype ) where |
value is the bias correction value and may be passed as a number or string.
datatype specifies the output data type as a number or string.
bSuccess is the returned success code. On success it is true, otherwise false.
This method applies a bias value correction to the image and updates the image header with the appropriate history and other keywords. The same bias value is applied to all pixels of the image. The data type of the image may also be changed as part of the correction, for example, to increase the precision of the bias removal procedure.
The following script loads an image and subtracts a bias value of 490.56. The output data type is changed to "float" to maintain precision of the correction process:
|
-- create a new CImage |
|
-- load the image from file sPath |
|
-- perform the operation on image I |
|
|