[Gridflow-cvs] [svn] commit: r4977 - /trunk/src/jpeg.cxx

gridflow-cvs at artengine.ca gridflow-cvs at artengine.ca
Sun Feb 7 12:32:55 EST 2010


Author: matju
Date: Sun Feb  7 12:32:55 2010
New Revision: 4977

Log:
[#in jpeg] [#out jpeg] win32

Modified:
    trunk/src/jpeg.cxx

Modified: trunk/src/jpeg.cxx
==============================================================================
--- trunk/src/jpeg.cxx (original)
+++ trunk/src/jpeg.cxx Sun Feb  7 12:32:55 2010
@@ -24,14 +24,15 @@
 //!@#$ not handling abort on compress
 //!@#$ not handling abort on decompress
 
+#include <stdio.h> /* must come first since when jpeglib.h became loaded before gridflow.hxx.fcs */
+extern "C" {
+#include <jpeglib.h> /* load this before the gridflow header, because of name conflict of convert() with <winsock2.h> on win32 */
+#undef EXTERN /* redefined by gridflow header */
+};
 #include "gridflow.hxx.fcs"
 /* removing macros (removing warnings) */
 #undef HAVE_PROTOTYPES
 #undef HAVE_STDLIB_H
-#undef EXTERN
-extern "C" {
-#include <jpeglib.h>
-};
 
 \class FormatJPEG : Format {
 	P<BitPacking> bit_packing;



More information about the Gridflow-cvs mailing list