From 98753db9fdc954f745801638496ff54cc699378e Mon Sep 17 00:00:00 2001 From: Dane Springmeyer Date: Mon, 25 Jun 2012 17:57:52 -0700 Subject: [PATCH] cleaner approach to a compile time magic alpha number for grid buffers --- include/mapnik/grid/grid.hpp | 3 ++- src/build.py | 1 - src/grid/grid.cpp | 31 ------------------------------- 3 files changed, 2 insertions(+), 33 deletions(-) delete mode 100644 src/grid/grid.cpp diff --git a/include/mapnik/grid/grid.hpp b/include/mapnik/grid/grid.hpp index 708f8bddc..1f838a2d3 100644 --- a/include/mapnik/grid/grid.hpp +++ b/include/mapnik/grid/grid.hpp @@ -45,6 +45,7 @@ #include #include #include +#include namespace mapnik { @@ -60,7 +61,7 @@ public: typedef std::map feature_key_type; typedef std::map key_type; typedef std::map feature_type; - static const value_type base_mask; + static const value_type base_mask = boost::integer_traits::const_min; private: unsigned width_; diff --git a/src/build.py b/src/build.py index f34a067d8..2e0e8183f 100644 --- a/src/build.py +++ b/src/build.py @@ -260,7 +260,6 @@ if env['RUNTIME_LINK'] == "static": # grid backend source += Split( """ - grid/grid.cpp grid/grid_renderer.cpp grid/process_building_symbolizer.cpp grid/process_line_pattern_symbolizer.cpp diff --git a/src/grid/grid.cpp b/src/grid/grid.cpp deleted file mode 100644 index ade783a7b..000000000 --- a/src/grid/grid.cpp +++ /dev/null @@ -1,31 +0,0 @@ -/***************************************************************************** - * - * This file is part of Mapnik (c++ mapping toolkit) - * - * Copyright (C) 2012 Artem Pavlenko - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - * - *****************************************************************************/ - -// mapnik -#include - -namespace mapnik -{ - -template<> const grid::value_type grid::base_mask = std::numeric_limits::min(); - -}