2
0
mirror of https://gitlab.com/ita1024/waf.git synced 2024-11-22 01:46:15 +01:00
waf/playground/freeimage/fi.cpp
2011-09-10 11:13:51 +02:00

20 lines
414 B
C++

#include <stdio.h>
#include "FreeImage.h"
int main() {
#if defined(FREEIMAGE_LIB) || !defined(WIN32)
FreeImage_Initialise(FALSE);
#endif
FIBITMAP* dib = FreeImage_Load(FIF_PNG, "img.png", PNG_DEFAULT);
printf("%dx%d", FreeImage_GetWidth(dib), FreeImage_GetHeight(dib));
FreeImage_Unload(dib);
#if defined(FREEIMAGE_LIB) || !defined(WIN32)
FreeImage_DeInitialise();
#endif
return 0;
}