X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FGeomAPI%2FGeomAPI_Face.cpp;h=b569598357b982526ca0221c1332289ac200bbfb;hb=61cd0845b41710ad4e7eae07cc6106904be67b9f;hp=2055bdc6dac6951b35fb2e822c1eb46b5eee628b;hpb=38afbd899a8645c83e17f2c24a17a2b7414911b4;p=modules%2Fshaper.git diff --git a/src/GeomAPI/GeomAPI_Face.cpp b/src/GeomAPI/GeomAPI_Face.cpp index 2055bdc6d..b56959835 100644 --- a/src/GeomAPI/GeomAPI_Face.cpp +++ b/src/GeomAPI/GeomAPI_Face.cpp @@ -16,6 +16,7 @@ #include #include #include +#include GeomAPI_Face::GeomAPI_Face() : GeomAPI_Shape() @@ -64,9 +65,8 @@ bool GeomAPI_Face::isPlanar() const { const TopoDS_Shape& aShape = const_cast(this)->impl(); Handle(Geom_Surface) aSurf = BRep_Tool::Surface(TopoDS::Face(aShape)); - if (aSurf->IsKind(STANDARD_TYPE(Geom_Plane))) - return true; - return false; + GeomLib_IsPlanarSurface isPlanar(aSurf); + return isPlanar.IsPlanar() == Standard_True; } std::shared_ptr GeomAPI_Face::getPlane() const