X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FHYDROData%2FHYDROData_ShapeFile.h;h=157ea9a438ef36159f598043b1e19ef4a654c768;hb=6125fb8b6cbed45b172a104b5ae3c0b3cd909e5c;hp=ec7b0ff3602caf610bfc6fbb30c7f696ec31e864;hpb=1eb9517598bec3064daf719c6fde7e29e6a98836;p=modules%2Fhydro.git diff --git a/src/HYDROData/HYDROData_ShapeFile.h b/src/HYDROData/HYDROData_ShapeFile.h index ec7b0ff3..157ea9a4 100644 --- a/src/HYDROData/HYDROData_ShapeFile.h +++ b/src/HYDROData/HYDROData_ShapeFile.h @@ -88,19 +88,23 @@ public: HYDRODATA_EXPORT void Export(const QString& aFileName, const Handle_HYDROData_LandCoverMap& aLCM, - QStringList& aNonExpList); + QStringList& aNonExpList, + bool bCheckLinear = true, + bool bUseDiscr = false, + double theDefl = 0.1); int WriteObjectPolyXY(SHPHandle theShpHandle, Handle_HYDROData_PolylineXY thePoly ); int WriteObjectPoly3D(SHPHandle theShpHandle, Handle_HYDROData_Polyline3D thePoly ); - int WriteObjectPolygon(SHPHandle theShpHandle, const TopoDS_Shape& theInputShape ); + int WriteObjectPolygon(SHPHandle theShpHandle, const TopoDS_Shape& theInputShape, bool bUseDiscr, double theDefl ); //Import bool Parse(SHPHandle theHandle, ShapeType theType, int& theShapeTypeOfFile); //Import Landcover - void ReadSHPPolygon(SHPObject* anObj, int i, TopoDS_Face& F); + void ReadSHPPolygon(Handle(HYDROData_Document) theDocument, SHPObject* anObj, int i, TopoDS_Face& F); - HYDRODATA_EXPORT int ImportPolygons(const QString theFileName, + HYDRODATA_EXPORT int ImportPolygons(Handle(HYDROData_Document) theDocument, + const QString theFileName, QStringList& thePolygonsList, TopTools_SequenceOfShape& theFaces, int& theShapeTypeOfFile); @@ -131,7 +135,11 @@ public: HYDRODATA_EXPORT bool DBF_WriteFieldAndValues(const QString& theFileName, const QString& theFieldName, DBF_FieldType theType, const std::vector& theAttrV, bool bUseStrValue); private: - void ProcessFace(TopoDS_Face theFace, SHPHandle theShpHandle); + + void ProcessFace(const TopoDS_Face& theFace, SHPHandle theShpHandle, + bool bUseDiscr, double theDefl); + + bool CheckLinear(const TopoDS_Shape& theInpShape); int TryOpenShapeFile(QString theFileName);