From 4c4ce5a04cf88d708354ce12b4ccf2b82f022581 Mon Sep 17 00:00:00 2001 From: Dane Springmeyer Date: Wed, 18 Jun 2014 17:53:33 -0700 Subject: [PATCH] windows build fixes in palette and miniz_png headers --- include/mapnik/miniz_png.hpp | 13 +++++++++++++ include/mapnik/palette.hpp | 6 +++--- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/include/mapnik/miniz_png.hpp b/include/mapnik/miniz_png.hpp index 7ff902e2b..1956e5183 100644 --- a/include/mapnik/miniz_png.hpp +++ b/include/mapnik/miniz_png.hpp @@ -32,6 +32,10 @@ #include #include +#ifdef _MSC_VER +#include +#endif + /* miniz.c porting issues: - duplicate symbols in python bindings require moving miniz.c include to just cpp file - due to http://code.google.com/p/miniz/issues/detail?id=7 @@ -80,6 +84,15 @@ private: static const unsigned char IEND_tpl[]; }; +#ifdef _MSC_VER +template MAPNIK_DECL void PNGWriter::writeIDAT(image_data_8 const& image); +template MAPNIK_DECL void PNGWriter::writeIDAT >(image_view const& image); +template MAPNIK_DECL void PNGWriter::writeIDAT(image_data_32 const& image); +template MAPNIK_DECL void PNGWriter::writeIDAT >(image_view const& image); +template MAPNIK_DECL void PNGWriter::writeIDATStripAlpha(image_data_32 const& image); +template MAPNIK_DECL void PNGWriter::writeIDATStripAlpha >(image_view const& image); +#endif + }} #endif // MAPNIK_MINIZ_PNG_HPP diff --git a/include/mapnik/palette.hpp b/include/mapnik/palette.hpp index e301e0e59..edf47513d 100644 --- a/include/mapnik/palette.hpp +++ b/include/mapnik/palette.hpp @@ -58,7 +58,7 @@ namespace mapnik { struct rgba; -struct rgb { +struct MAPNIK_DECL rgb { byte r; byte g; byte b; @@ -72,7 +72,7 @@ struct rgb { } }; -struct rgba +struct MAPNIK_DECL rgba { byte r; byte g; @@ -103,7 +103,7 @@ struct rgba } // ordering by mean(a,r,g,b), a, r, g, b - struct mean_sort_cmp + struct MAPNIK_DECL mean_sort_cmp { bool operator() (const rgba& x, const rgba& y) const; };