fixes proj_transform_cache incomplete type for gcc

This commit is contained in:
Mathis Logemann 2021-04-01 17:57:20 +02:00
parent 53669bc42e
commit ee90425de1
2 changed files with 7 additions and 4 deletions

View file

@ -103,7 +103,7 @@ private:
boost::optional<std::string> font_directory_;
freetype_engine::font_file_mapping_type font_file_mapping_;
freetype_engine::font_memory_cache_type font_memory_cache_;
std::unique_ptr<proj_transform_cache> proj_cache_ = {};
std::unique_ptr<proj_transform_cache> proj_cache_;
public:
using const_style_iterator = std::map<std::string,feature_type_style>::const_iterator;
using style_iterator = std::map<std::string,feature_type_style>::iterator;

View file

@ -76,7 +76,8 @@ Map::Map()
extra_params_(),
font_directory_(),
font_file_mapping_(),
font_memory_cache_() {}
font_memory_cache_(),
proj_cache_(std::make_unique<proj_transform_cache>()) {}
Map::Map(int width,int height, std::string const& srs)
: width_(width),
@ -90,7 +91,8 @@ Map::Map(int width,int height, std::string const& srs)
extra_params_(),
font_directory_(),
font_file_mapping_(),
font_memory_cache_() {}
font_memory_cache_(),
proj_cache_(std::make_unique<proj_transform_cache>()) {}
Map::Map(Map const& rhs)
: width_(rhs.width_),
@ -112,7 +114,8 @@ Map::Map(Map const& rhs)
font_directory_(rhs.font_directory_),
font_file_mapping_(rhs.font_file_mapping_),
// on copy discard memory caches
font_memory_cache_()
font_memory_cache_(),
proj_cache_(std::make_unique<proj_transform_cache>())
{
init_proj_transforms();
}