+ add missing geometry types

+ correct geometry types in wkb reader
This commit is contained in:
Artem Pavlenko 2011-02-24 15:47:36 +00:00
parent 3b295143bc
commit 93514d57a2
2 changed files with 9 additions and 6 deletions

View file

@ -38,8 +38,11 @@ namespace mapnik {
enum eGeomType {
Point = 1,
LineString = 2,
Polygon = 3
LineString,
Polygon,
MultiPoint,
MultiLineString,
MultiPolygon
};

View file

@ -224,7 +224,7 @@ private:
void read_multipoint_2(Feature & feature)
{
geometry_type * pt = new geometry_type(Point);
geometry_type * pt = new geometry_type(MultiPoint);
int num_points = read_integer();
for (int i=0;i<num_points;++i)
{
@ -263,7 +263,7 @@ private:
void read_multilinestring_2(Feature & feature)
{
geometry_type * line = new geometry_type(LineString);
geometry_type * line = new geometry_type(MultiLineString);
int num_lines=read_integer();
unsigned capacity = 0;
for (int i=0;i<num_lines;++i)
@ -313,10 +313,10 @@ private:
read_polygon(feature);
}
}
void read_multipolygon_2(Feature & feature)
{
geometry_type * poly = new geometry_type(Polygon);
geometry_type * poly = new geometry_type(MultiPolygon);
int num_polys=read_integer();
unsigned capacity = 0;
for (int i=0;i<num_polys;++i)