Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

17 lines (14 sloc) 0.415 kb
#include "imageutils.h"
#include <string.h>
void flip_image(const unsigned char *src, unsigned char *dst, size_t pixelsize, size_t width, size_t height)
{
size_t rowBytes = pixelsize * width;
for (size_t i = 0 ; i < height ; i++) {
memmove(dst + (height - i - 1) * rowBytes, src + i * rowBytes, rowBytes);
}
}
#ifdef __APPLE__
#include "imageutils-macosx.cc"
#else
#include "imageutils-lodepng.cc"
#endif
Jump to Line
Something went wrong with that request. Please try again.