Vertical Image Flipping
The DMA engine provides the capability to flip the image vertically.
Flipped image data
The vertical image flip is controlled by the StripeArrangement feature of the data Stream module.
By default, StripeArrangement is set to 1X_1Y: the vertical image flip is disabled.
When StripeArrangement is set to 1X_1YE, the driver determines the position of the first image line in the buffer by using this formula:
BufferBase + (BufferSize + LinePitch - LineWidth) / LinePitch * LinePitch - LinePitch.
As a result:
● | if the buffer is too small, it is the bottom part of the image (as given by the camera) that will be lost; |
● | lines will start at BufferBase + n * LinePitch; |
● | only complete lines are transferred; |
● | if the buffer size is not a multiple of LinePitch bytes, some bytes at the end of the buffer will be left unchanged. |
When evaluating the above formula, if LinePitch is equal to 0, LineWidth will be used instead. Similarly, if StripeHeight is 0, 1 will be used instead.