]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - image_png.c
changed collision brush loader to not discard planes that don't produce a polygon...
[xonotic/darkplaces.git] / image_png.c
index 94a2bd819c1a7c9d2077f79403866e5b12cbd6ad..2f8e76a7cfb3273c6cd931d5ff41097dd442b11d 100644 (file)
@@ -111,6 +111,7 @@ qboolean PNG_OpenLibrary (void)
                "libpng12.0.dylib",
 #else
                "libpng12.so.0",
+               "libpng.so", // FreeBSD
 #endif
                NULL
        };
@@ -212,7 +213,7 @@ void PNG_fReadData(void *png, unsigned char *data, size_t length)
        }
        memcpy(data, my_png.tmpBuf + my_png.tmpi, length);
        my_png.tmpi += (int)length;
-       Com_HexDumpToConsole(data, (int)length);
+       //Com_HexDumpToConsole(data, (int)length);
 }
 
 void PNG_error_fn(void *png, const char *message)
@@ -250,7 +251,11 @@ unsigned char *PNG_LoadImage (const unsigned char *raw, int filesize, int matchw
        // NOTE: this relies on jmp_buf being the first thing in the png structure
        // created by libpng! (this is correct for libpng 1.2.x)
 #ifdef __cplusplus
+#ifdef MACOSX
+       if (setjmp((int *)png))
+#else
        if (setjmp((__jmp_buf_tag *)png))
+#endif
 #else
        if (setjmp(png))
 #endif