Ticket #2772: os_curvedpolygon.diff

File os_curvedpolygon.diff, 3.0 KB (added by nd, 15 years ago)
  • maporaclespatial.c

     
    177177static void osClosedPolygon(msOracleSpatialHandler *hand, shapeObj *shape, SDOGeometryObj *obj, int start, int end, lineObj points, int elem_type, int data3d);
    178178static void osRectangle(msOracleSpatialHandler *hand, shapeObj *shape, SDOGeometryObj *obj, int start, int end, lineObj points, pointObj *pnt, int data3d);
    179179static void osCircle(msOracleSpatialHandler *hand, shapeObj *shape, SDOGeometryObj *obj, int start, int end, lineObj points, pointObj *pnt, int data3d);
    180 static void osArcPolygon(msOracleSpatialHandler *hand, shapeObj *shape, SDOGeometryObj *obj, int start, int end, lineObj arcpoints, int data3d);
     180static void osArcPolygon(msOracleSpatialHandler *hand, shapeObj *shape, SDOGeometryObj *obj, int start, int end, lineObj arcpoints,int elem_type,int data3d);
    181181static int osGetOrdinates(msOracleSpatialDataHandler *dthand, msOracleSpatialHandler *hand, shapeObj *shape, SDOGeometryObj *obj, SDOGeometryInd *ind);
    182182static int osCheck2DGtype(int pIntGtype);
    183183static int osCheck3DGtype(int pIntGtype);
     
    12831283    }
    12841284}
    12851285
    1286 static void osArcPolygon(msOracleSpatialHandler *hand, shapeObj *shape, SDOGeometryObj *obj, int start, int end, lineObj arcpoints, int data3d)
     1286static void osArcPolygon(msOracleSpatialHandler *hand, shapeObj *shape, SDOGeometryObj *obj, int start, int end, lineObj arcpoints, int elem_type, int data3d)
    12871287{
    12881288    int n, i;
    12891289    lineObj points = {0, NULL};
     
    12981298
    12991299    if (n > 2)
    13001300    {
    1301         shape->type = MS_SHAPE_LINE;
     1301        shape->type = (elem_type==32) ? MS_SHAPE_POLYGON : MS_SHAPE_LINE;
    13021302        points.numpoints = n;
    13031303
    13041304        for (i = 0; i < n-2; i = i+2)
     
    14691469                      break;
    14701470                  case 22: /* compound type */
    14711471                      if (compound_type)
    1472                           osArcPolygon(hand, &newshape, obj, ord_start, (compound_count<compound_lenght)?ord_end+2:ord_end , points, data3d);
     1472                          osArcPolygon(hand, &newshape, obj, ord_start, (compound_count<compound_lenght)?ord_end+2:ord_end , points, elem_type, data3d);
    14731473                      else
    1474                           osArcPolygon(hand, shape, obj, ord_start, ord_end, points, data3d);
     1474                          osArcPolygon(hand, shape, obj, ord_start, ord_end, points, elem_type, data3d);
    14751475                      break;
    14761476                  case 31: /* simple polygon with n points, last point equals the first one */
    14771477                      osClosedPolygon(hand, shape, obj, ord_start, ord_end, points, elem_type, data3d);
    14781478                      break;
     1479                  case 32: /* Polygon with arcs */
     1480                      osArcPolygon(hand, shape, obj, ord_start, ord_end, points, elem_type, data3d);
     1481                      break;
    14791482                  case 33: /* rectangle defined by 2 points */
    14801483                      osRectangle(hand, shape, obj, ord_start, ord_end, points, point5, data3d);
    14811484                      break;