diff --git a/stb.c b/stb.c index 25a4a056a..5ff2cc928 100644 --- a/stb.c +++ b/stb.c @@ -1,7 +1,7 @@ #define STB_IMAGE_IMPLEMENTATION #include "stb_image.h" #define STB_IMAGE_RESIZE_IMPLEMENTATION -#include "stb_image_resize.h" +#include "stb_image_resize2.h" #define STB_IMAGE_WRITE_IMPLEMENTATION #include "stb_image_write.h" #define STB_PERLIN_IMPLEMENTATION diff --git a/stb_image_resize2.h b/stb_image_resize2.h index faf1b0899..c2cf93fdf 100644 --- a/stb_image_resize2.h +++ b/stb_image_resize2.h @@ -425,12 +425,20 @@ typedef uint64_t stbir_uint64; #define STBIRDEF static #else #ifdef __cplusplus +#ifdef _MSC_VER +#define STBIRDEF extern "C" __declspec(dllexport) +#else #define STBIRDEF extern "C" +#endif +#else +#ifdef _MSC_VER +#define STBIRDEF extern __declspec(dllexport) #else #define STBIRDEF extern #endif #endif #endif +#endif ////////////////////////////////////////////////////////////////////////////// //// start "header file" ///////////////////////////////////////////////////