Dilates an image. Dilation is a "morphological" operation, modifying the shape of objects in an image. It is commonly used in image analysis operations. With some care, it can be used for some image enhancement tasks as well. For example, it can be used to repair dot matrix characters. With color or gray input data, the dilate operation achieves a similar effect, by enlarging dark objects.
→
The uncompressed image to be processed must reside in the Get Queue prior to REQ_EXEC. Typically, the image will be fully contained in the Get Queue, but that is not a requirement. The output image will be placed into the Put Queue during REQ_EXEC.
Padding pixels present at the end of each line may be modified by this operation.
- Subcode is set to SF_SUBCODE_DILATE (7).
- u.SC7.AmountOfEffectLeft is set to the distance, in pixels, that the left edge of black objects should be extended. Valid values are from 0 to 500.
- u.SC7.AmountOfEffectRight is set to the distance, in pixels, that the right edge of black objects should be extended. Valid values are from 0 to 500.
- u.SC7.AmountOfEffectUp is set to the distance, in pixels, that the top edge of black objects should be extended. Valid values are from 0 to 500.
- u.SC7.AmountOfEffectDown is set to the distance, in pixels, that the bottom edge of black objects should be extended. Valid values are from 0 to 500.
- Stride is set to the image line width in bytes including padding at the end of the line width or to 0. If Stride is 0 and PF_NoDibPad is set in PicFlags, the operation will compute the stride using: [ (PixelWidth*BitCount)/8 ]. If Stride is 0 and PF_NoDibPad is not set in PicFlags, the operation will compute the stride using: [ (((PixelWidth*BitCount)+31)&(~31))/8 ].
In addition to placing an output image into the Put Queue, this operation stores some output information into the PIC_PARM structure in the following locations.
- OutputStride is set, during REQ_INIT and REQ_EXEC, to the image line width in bytes including padding at the end of the line.
- BiOut is set, during REQ_INIT and REQ_EXEC, to the attributes of the output image. Since this operation does not adjust the size of the image, BiOut will be set to a copy of the Head structure within PIC_PARM.