geompy.addToStudy(w1, "w1")
geompy.addToStudy(v1, "v1")
geompy.addToStudy(prj, "projOnWire")
+
+#projection of a wire on cylinder
+pp1 = geompy.MakeVertex(100, 200, 0)
+pp2 = geompy.MakeVertex(100, 200, 80)
+pp3 = geompy.MakeVertex(100, 220, 90)
+pp4 = geompy.MakeVertex(100, 130, 80)
+pp5 = geompy.MakeVertex(100, 90, 80)
+cc1 = geompy.MakeInterpol([pp1, pp2, pp3, pp4, pp5], True, False)
+ww1 = geompy.MakeWire([cc1], 1.e-7)
+vx = geompy.MakeVectorDXDYDZ(100, 0, 0)
+pln1 = geompy.MakePlane(pp1, vx, 200)
+face1 = geompy.MakeFaceFromSurface(pln1, ww1)
+prj_cyl = geompy.MakeProjectionOnCylinder(face1, 100)
+
+geompy.addToStudy(face1, "pln_face")
+geompy.addToStudy(prj_cyl, "projOnCylinder")
\n This operation makes a projection of a <b>Source planar wire or face</b> on
a cylinder defined by its radius. The cylinder's coordinate system is
the same as the global coordinate system. The result represents a wire or
-a face or a compound of faces that represents a projection of the source
-shape onto a cylinder.
+a face that represents a projection of the source shape onto a cylinder.
To make a projection it is necessary to define:
-- \b Object to be rotated. It can be either a planar wire or a face;
+- \b Object to be projected. It can be either a planar wire or a face;
- \b Radius of the cylinder;
- <b>Starting angle</b> from the cylinder's X axis around Z axis. This is
the angle of the projection starting.
Position2 = geompy.PositionAlongPath(Box, Arc, 0.5, 1, 0) #(2 GEOM_Object, 1 Double, 2 Bool)->GEOM_Object
Offset = geompy.MakeOffset(Box, 10.) #(GEOM_Object, Double)->GEOM_Object
ProjOnWire = geompy.MakeProjectionOnWire(p0, Wire)
+ ProjOnCyl = geompy.MakeProjectionOnCylinder(Wire, 100)
Orientation = geompy.ChangeOrientation(Box)
ExtEdge = geompy.ExtendEdge(Edge1, -0.3, 1.3)
ExtFace = geompy.ExtendFace(Face5, -0.3, 1.3, -0.1, 1.1)
id_Offset = geompy.addToStudy(Offset, "Offset")
id_Orientation = geompy.addToStudy(Orientation, "Orientation")
id_ProjOnWire = geompy.addToStudy(ProjOnWire[1], "ProjOnWire")
+ id_ProjOnCyl = geompy.addToStudy(ProjOnCyl, "ProjOnCyl")
id_ExtEdge = geompy.addToStudy(ExtEdge, "ExtendedEdge")
id_ExtFace = geompy.addToStudy(ExtFace, "ExtendedFace")
id_Surface = geompy.addToStudy(Surface, "Surface From Face")
return anObj
##
- # Compute a wire or a face or a compound of faces that represents
- # a projection of the source shape onto cylinder. The cylinder's
- # coordinate system is the same as the global coordinate system.
+ # Compute a wire or a face that represents a projection of the source
+ # shape onto cylinder. The cylinder's coordinate system is the same
+ # as the global coordinate system.
#
# @param theObject The object to be projected. It can be either
# a planar wire or a face.
# publication is switched on, default value is used for result name.
#
# @return New GEOM.GEOM_Object, containing the result shape. The result
- # represents a wire or a face or a compound of faces that
- # represents a projection of the source shape onto a cylinder.
+ # represents a wire or a face that represents a projection of
+ # the source shape onto a cylinder.
#
- # @ref tui_fillet "Example 1"
- # \n @ref swig_MakeFilletAll "Example 2"
+ # @ref tui_projection "Example"
def MakeProjectionOnCylinder (self, theObject, theRadius,
theStartAngle=0.0, theAngleLength=-1.0,
theName=None):
"""
- Compute a wire or a face or a compound of faces that represents
- a projection of the source shape onto cylinder. The cylinder's
- coordinate system is the same as the global coordinate system.
+ Compute a wire or a face that represents a projection of the source
+ shape onto cylinder. The cylinder's coordinate system is the same
+ as the global coordinate system.
Parameters:
theObject The object to be projected. It can be either
Returns:
New GEOM.GEOM_Object, containing the result shape. The result
- represents a wire or a face or a compound of faces that
- represents a projection of the source shape onto a cylinder.
-
- Example of usage:
- filletall = geompy.MakeFilletAll(prism, 10.)
+ represents a wire or a face that represents a projection of
+ the source shape onto a cylinder.
"""
- # Example: see GEOM_TestOthers.py
+ # Example: see GEOM_TestAll.py
theRadius, theStartAngle, theAngleLength, Parameters = ParseParameters(
theRadius, theStartAngle, theAngleLength)
anObj = self.TrsfOp.MakeProjectionOnCylinder(theObject, theRadius,
/***************************************************************/
- setHelpFileName("project_on_cylinder_operation_page.html");
+ setHelpFileName("projection_on_cylinder_operation_page.html");
Init();
}