Overview of the Geom object¶
The built-in Geom object implements a geometric core.
Core Capabilities of Geom¶
Provides functions for creating graphical primitives and operating on them.
Methods of the Geom object¶
Below is a list of the available methods provided by the Geom object. Click on a method name to see its detailed description and examples.
Creating Geometric Primitives¶
2D Points and Vectors¶
| Method | Description | 
|---|---|
| Geom.point2() | Creates a 2D point. | 
| Geom.point3() | Creates a 3D point. | 
| Geom.vector3() | Creates a 3D vector. | 
| Geom.boundingBox() | Creates an enclosing box. | 
2D Primitives (Flat)¶
| Method | Description | 
|---|---|
| Geom.arc() | Creates an arc. | 
| Geom.circle() | Creates a circle or sector of a circle. | 
| Geom.ring() | Creates a ring. | 
| Geom.ellipse() | Creates an ellipse or sector of an ellipse. | 
| Geom.square() | Creates a square. | 
| Geom.rectangle() | Creates a rectangle. | 
| Geom.ngon() | Creates a regular polygon. | 
| Geom.infplane() | Creates a plane. | 
| Geom.segment() | Creates a segment. | 
| Geom.bspline() | Creates a B-spline curve through given points. | 
| Geom.polysegment() | Creates a Bezier curve or Catmull-Rom spline. | 
| Geom.polygon() | Creates a polygon. | 
3D Primitives (Volume)¶
| Method | Description | 
|---|---|
| Geom.box() | Creates a box. | 
| Geom.collar() | Creates a collar. | 
| Geom.cone() | Creates a cone. | 
| Geom.cylinder() | Creates a cylinder. | 
| Geom.sphere() | Creates a sphere. | 
| Geom.torus() | Creates a torus. | 
Boolean Operations¶
| Method | Description | 
|---|---|
| Geom.unite() | Joins two or more solids. | 
| Geom.intersect() | Finds the intersection of two or more solids. | 
| Geom.diff() | Finds the difference between two or more solids. | 
| Geom.difference() | Finds the difference between two or more solids. | 
Geometric Properties¶
Angles¶
| Method | Description | 
|---|---|
| Geom.angle() | Gets the angle of a point. | 
| Geom.angleX() | Gets the angle of a point in YOZ plane. | 
| Geom.angleY() | Gets the angle of a point in XOZ plane. | 
| Geom.angleZ() | Gets the angle of a point in XOY plane. | 
| Geom.angleBetweenVectors() | Gets the angle between two vectors. | 
Radii¶
| Method | Description | 
|---|---|
| Geom.radius() | Gets the radius of a 2D point. | 
| Geom.radiusX() | Gets the radius of a point in YOZ plane. | 
| Geom.radiusY() | Gets the radius of a point in XOZ plane. | 
| Geom.radiusZ() | Gets the radius of a point in XOY plane. | 
Distances and Parameters¶
| Method | Description | 
|---|---|
| Geom.distance() | Calculates the distance between two points. | 
| Geom.distanceToSegment() | Calculates the distance from a point to a segment. | 
| Geom.pointAtSegmentXY() | Calculates the distance from a point to a segment on the plane XOY. | 
| Geom.pointAtSegmentXZ() | Calculates the distance from a point to a segment on the plane XOZ. | 
| Geom.pointAtSegmentYZ() | Calculates the distance from a point to a segment on the plane YOZ. | 
| Geom.pointAtPolygon() | Finds the location of a point relative to a polygon. | 
| Geom.pointAtPolygonXY() | Finds the location of a point relative to a polygon on the plane XOY. | 
| Geom.pointAtPolygonXZ() | Finds the location of a point relative to a polygon on the plane XOZ. | 
| Geom.pointAtPolygonYZ() | Finds the location of a point relative to a polygon on the plane YOZ. | 
| Geom.pointAtShape() | Finds the location of a point relative to a shape. | 
Geometric Operations¶
| Method | Description | 
|---|---|
| Geom.section() | Creates a section. | 
| Geom.unify() | Simplifies the geometric representation of an object. | 
| Geom.fillet() | Performs a fillet operation on a solid. | 
| Geom.chamfer() | Performs a chamfer operation on a solid. | 
Creating Part¶
| Method | Description | 
|---|---|
| Geom.piece() | Creates a part. | 
Mathematical Functions¶
| Method | Description | 
|---|---|
| Geom.deg() | Converts degrees to radians. | 
| Geom.rad() | Converts radians to degrees. | 
| Geom.fromPolar() | Converts polar coordinates (radius, angle)to Cartesian(x, y). | 
| Geom.normAngle() | Normalizes an angle to the range (0°, 360°). | 
| Geom.middleAngle() | Calculates the middle angle between two angles with a direction. | 
| Geom.isEpsilon() | Returns true if the absolute value of the Parameter is less than or equal to epsilon. | 
| Geom.isEqual() | Returns true if the difference between two Parameters is less than or equal to epsilon. | 
| Geom.isLessEqual() | Returns true if the first Parameter is less than or equal to the second with a tolerance of epsilon. | 
| Geom.isGreatEqual() | Returns true if the first Parameter is greater than or equal to the second with a tolerance of epsilon. | 
| Geom.round() | Rounds a number to a specified precision. |