fip.cpp 382 B

123456789101112131415161718192021
  1. // run './waf --fip' to build this one
  2. #include <iostream>
  3. #include "FreeImagePlus.h"
  4. int main() {
  5. #if defined(FREEIMAGE_LIB) || !defined(WIN32)
  6. FreeImage_Initialise();
  7. #endif
  8. fipImage img;
  9. img.load("img.png");
  10. std::cout << img.getWidth() << "x" << img.getHeight() << std::endl;
  11. #if defined(FREEIMAGE_LIB) || !defined(WIN32)
  12. FreeImage_DeInitialise();
  13. #endif
  14. return 0;
  15. }