I'm trying to mirror a raw (without image header) BGR image, 8 bit per pixel, using the following code:
void mirrorBGR(byte* src, byte* dst, UINT width, UINT height, UINT pitch_s, UINT pitch_d)
{
IppiSize size;
size.width = width;
size.height = height;
IppStatus status = ippiMirror_8u_C3R(src, pitch_s, dst ,pitch_d, size, ippAxsVertical);
if (status != ippStsNoErr)
{
printf("Mirror RGB24 failed: %d",status);
}
}
The image size is 640x360. pitch_s = pitch_d = width = 640. What could be the problem?
Pitch is the scanline length for source & dest bitmaps.
If you use no padding, at least it should 640 (width) * 3 (bytes per pixel) = 1920