Sfoglia il codice sorgente

MSVC compile fix (example); win32 screenshot added

r-lyeh 12 anni fa
parent
commit
0da08eec2e
2 ha cambiato i file con 6 aggiunte e 1 eliminazioni
  1. 6 1
      example/example.c
  2. BIN
      example/screenshot-02.png

+ 6 - 1
example/example.c

@@ -18,7 +18,6 @@
 
 #include <stdio.h>
 #include <string.h>
-#include <iconv.h>
 #include <math.h>
 #ifdef NANOVG_GLEW
 #  include <GL/glew.h>
@@ -28,6 +27,12 @@
 #define GLNANOVG_IMPLEMENTATION
 #include "glnanovg.h"
 
+#ifdef _MSC_VER
+#define snprintf _snprintf
+#else
+#include <iconv.h>
+#endif
+
 #define ICON_SEARCH 0x1F50D
 #define ICON_CIRCLED_CROSS 0x2716
 #define ICON_CHEVRON_RIGHT 0xE75E

BIN
example/screenshot-02.png