diff --git a/src/Core/Internal/ImportMDLImplementation.cpp b/src/Core/Internal/ImportMDLImplementation.cpp index be4b12b4..7c82c361 100644 --- a/src/Core/Internal/ImportMDLImplementation.cpp +++ b/src/Core/Internal/ImportMDLImplementation.cpp @@ -633,16 +633,16 @@ Geom::Curve* ImportMDLImplementation::getCurve(const std::string name) Geom::Vertex* vtx2 = getVertex(current_command.model1d.pt2); if(vtx1!=vtx2) { - crv = Geom::EntityFactory(m_context).newSegment(vtx1,vtx2); + crv = Geom::EntityFactory(m_context).newSegment(vtx1,vtx2); - //creation des connections topologiques - crv->add(vtx1); - crv->add(vtx2); - vtx1->add(crv); - vtx2->add(crv); + //creation des connections topologiques + crv->add(vtx1); + crv->add(vtx2); + vtx1->add(crv); + vtx2->add(crv); } else { - //std::cerr<<"IMPORT D'UN SEGMENT DE LONGUEUR NULLE NON EFFECTUEE ("< dir = "<<(dir?"true":"false")<add(vtx1); - vtx1->add(crv); - if(vtx2!=vtx1){ - crv->add(vtx2); - vtx2->add(crv); + if(vtx1!=vtx2) + { + if(current_command.u.arc.is_circle) + crv = Geom::EntityFactory(m_context).newArcCircle2D(vtxcenter,vtx1,vtx2, dir); + else + crv = Geom::EntityFactory(m_context).newArcEllipse(vtxcenter,vtx1,vtx2, dir); + + //creation des connections topologiques + crv->add(vtx1); + vtx1->add(crv); + if(vtx2!=vtx1){ + crv->add(vtx2); + vtx2->add(crv); + } } - } + else { + //std::cerr<<"IMPORT D'UNE COURBE AVEC DEUX POINTS IDENTIQUES NON EFFECTUE ("<