This commit is contained in:
artemp 2014-06-25 09:01:20 +01:00
parent 4f5d12defc
commit b197cbcdb7
2 changed files with 6 additions and 6 deletions

View file

@ -73,7 +73,7 @@ static void shape_text(text_line & line,
hb_buffer_set_script(buffer.get(), hb_icu_script_to_script(text_item.script));
face_ptr const& face = *face_itr;
hb_font_t *font(hb_ft_font_create(face->get_face(), nullptr));
hb_shape(font, buffer.get(), NULL, 0);
hb_shape(font, buffer.get(), nullptr, 0);
hb_font_destroy(font);
unsigned num_glyphs = hb_buffer_get_length(buffer.get());

View file

@ -118,13 +118,13 @@ void ogr_datasource::init(mapnik::parameters const& params)
{
#if GDAL_VERSION_MAJOR >= 2
unsigned int nOpenFlags = GDAL_OF_READONLY | GDAL_OF_VECTOR;
const char* papszAllowedDrivers[] = { driver.c_str(), NULL };
dataset_ = reinterpret_cast<gdal_dataset_type>(GDALOpenEx(dataset_name_.c_str(),nOpenFlags,papszAllowedDrivers,NULL,NULL));
const char* papszAllowedDrivers[] = { driver.c_str(), nullptr };
dataset_ = reinterpret_cast<gdal_dataset_type>(GDALOpenEx(dataset_name_.c_str(),nOpenFlags,papszAllowedDrivers, nullptr, nullptr));
#else
OGRSFDriver * ogr_driver = OGRSFDriverRegistrar::GetRegistrar()->GetDriverByName(driver.c_str());
if (ogr_driver && ogr_driver != nullptr)
{
dataset_ = ogr_driver->Open((dataset_name_).c_str(), FALSE);
dataset_ = ogr_driver->Open((dataset_name_).c_str(), false);
}
#endif
}
@ -132,9 +132,9 @@ void ogr_datasource::init(mapnik::parameters const& params)
{
// open ogr driver
#if GDAL_VERSION_MAJOR >= 2
dataset_ = reinterpret_cast<gdal_dataset_type>(OGROpen(dataset_name_.c_str(), FALSE, NULL));
dataset_ = reinterpret_cast<gdal_dataset_type>(OGROpen(dataset_name_.c_str(), false, nullptr));
#else
dataset_ = OGRSFDriverRegistrar::Open(dataset_name_.c_str(), FALSE);
dataset_ = OGRSFDriverRegistrar::Open(dataset_name_.c_str(), false);
#endif
}