diff --git a/Code/Common/otbPersistentImageToOGRDataFilter.txx b/Code/Common/otbPersistentImageToOGRDataFilter.txx index 9c19d6ec65a1574404966876aaad778456a6ae34..e00b887a3879c94ecc1bc1be89edab1a58a3a806 100644 --- a/Code/Common/otbPersistentImageToOGRDataFilter.txx +++ b/Code/Common/otbPersistentImageToOGRDataFilter.txx @@ -129,7 +129,7 @@ PersistentImageToOGRDataFilter<TImage> OGRDataSourcePointerType ogrDS = this->GetOGRDataSource(); - ogrDS->CreateLayer(m_LayerName, oSRS ,m_GeometryType, otb::ogr::StringListConverter(m_OGRLayerCreationOptions).to_ogr()); + ogrDS->CreateLayer(m_LayerName, oSRS ,m_GeometryType, m_OGRLayerCreationOptions); OGRFieldDefn field(m_FieldName.c_str(),OFTInteger); //Handle the case of shapefile. A shapefile is a layer and not a datasource. diff --git a/Testing/Code/Segmentation/otbStreamingImageToOGRLayerSegmentationFilter.cxx b/Testing/Code/Segmentation/otbStreamingImageToOGRLayerSegmentationFilter.cxx index dc8f40d2c273808699c44c1d2be79b6fb34cc087..f0325bbb5c651edf007868645763b731d3716390 100644 --- a/Testing/Code/Segmentation/otbStreamingImageToOGRLayerSegmentationFilter.cxx +++ b/Testing/Code/Segmentation/otbStreamingImageToOGRLayerSegmentationFilter.cxx @@ -103,7 +103,7 @@ int otbStreamingImageToOGRLayerSegmentationFilter(int argc, char * argv[]) OGRSpatialReference oSRS(reader->GetOutput()->GetProjectionRef().c_str()); // Create the layer - otb::ogr::Layer oLayer = ogrDS->CreateLayer(layerName,&oSRS,wkbMultiPolygon,NULL); + otb::ogr::Layer oLayer = ogrDS->CreateLayer(layerName,&oSRS,wkbMultiPolygon); // Create the field OGRFieldDefn field(fieldName.c_str(),OFTInteger);