diff --git a/src/Mod/Part/App/PrimitiveFeature.cpp b/src/Mod/Part/App/PrimitiveFeature.cpp index 8c6fe8fe8..34818bc95 100644 --- a/src/Mod/Part/App/PrimitiveFeature.cpp +++ b/src/Mod/Part/App/PrimitiveFeature.cpp @@ -553,8 +553,7 @@ App::DocumentObjectExecReturn *RegularPolygon::execute(void) return new App::DocumentObjectExecReturn("Less than the minimum 3 sides is invalid"); if (Radius.getValue() < Precision::Confusion()) return new App::DocumentObjectExecReturn("Radius of prism too small"); -// if (Height.getValue() < Precision::Confusion()) -// return new App::DocumentObjectExecReturn("Height of prism too small"); + try { long nodes = NumberOfSides.getValue(); @@ -569,8 +568,6 @@ App::DocumentObjectExecReturn *RegularPolygon::execute(void) v = mat * v; } mkPoly.Add(gp_Pnt(v.x,v.y,v.z)); -// BRepBuilderAPI_MakeFace mkFace(mkPoly.Wire()); -// BRepPrimAPI_MakePrism mkPrism(mkFace.Face(), gp_Vec(0,0,Height.getValue())); this->Shape.setValue(mkPoly.Shape()); } catch (Standard_Failure) { @@ -842,12 +839,12 @@ App::DocumentObjectExecReturn *Spiral::execute(void) Handle(Geom2d_Line) line = new Geom2d_Line(aAx2d); gp_Pnt2d beg = line->Value(0); gp_Pnt2d end = line->Value(sqrt(4.0*M_PI*M_PI+myPitch*myPitch)*(myHeight/myPitch)); - - // calculate end point for conical helix - Standard_Real v = myHeight / cos(myAngle); - Standard_Real u = (myHeight/myPitch) * 2.0 * M_PI; - gp_Pnt2d cend(u, v); - end = cend; + + // calculate end point for conical helix + Standard_Real v = myHeight / cos(myAngle); + Standard_Real u = (myHeight/myPitch) * 2.0 * M_PI; + gp_Pnt2d cend(u, v); + end = cend; Handle(Geom2d_TrimmedCurve) segm = GCE2d_MakeSegment(beg , end); diff --git a/src/Mod/Part/App/PrimitiveFeature.h b/src/Mod/Part/App/PrimitiveFeature.h index 6e52a9e66..8ce7710dc 100644 --- a/src/Mod/Part/App/PrimitiveFeature.h +++ b/src/Mod/Part/App/PrimitiveFeature.h @@ -229,7 +229,6 @@ public: App::PropertyIntegerConstraint NumberOfSides; App::PropertyLength Radius; -// App::PropertyLength Height; /** @name methods override feature */ //@{