|
|
| Curve (global::System.IntPtr cPtr, bool cMemoryOwn) |
| |
|
cadex.Geom.CurveType | Type () |
| |
| cadex.Geom.Continuity | Continuity () |
| | Returns a continuity type of the curve.
|
| |
| cadex.Geom.Point | Value (double theParameter) |
| | Evaluates a point on the curve.
|
| |
| cadex.Geom.Direction | Normal (double theParameter) |
| | Returns the normal direction theNormal of parameter theParam.
|
| |
| double | Curvature (double theParameter) |
| | Returns the curvature value of parameter theParam.
|
| |
| bool | IsPeriodic () |
| | Returns true if the curve is periodic.
|
| |
| double | UMin () |
| | Returns a minimum parameter of a definition domain.
|
| |
| double | UMax () |
| | Returns a maximum parameter of a definition domain.
|
| |
| void | Domain (out double theUMin, out double theUMax) |
| | Returns a definition domain.
|
| |
| bool | IsTrimmed () |
| | Returns whether curve is trimmed or not.
|
| |
| void | SetTrim (double theFirst, double theLast) |
| | Trims curve with [theFirst, theLast] section.
|
| |
| void | Transform (cadex.Geom.Transformation theTransformation) |
| | Results depends on the actual curve type.
|
| |
| cadex.Geom.Curve | Transformed (cadex.Geom.Transformation theTransformation) |
| | The contents of this object is not modified.
|
| |
| void | D0 (double theParameter, cadex.Geom.Point theValue) |
| | Throws exception only for the OffsetCurve if it is not possible to compute the current point.
|
| |
| void | D1 (double theParameter, cadex.Geom.Point theValue, cadex.Geom.Vector theD1) |
| | Returns the point theValue of parameter theParam and the first derivative theD1.
|
| |
| void | D2 (double theParameter, cadex.Geom.Point theValue, cadex.Geom.Vector theD1, cadex.Geom.Vector theD2) |
| | Returns the point theValue of parameter theParam, the first theD1 and second theD2 derivatives.
|
| |
| bool | DN (double theParameter, uint theDerivativeOrder, cadex.Geom.Point theValue, cadex.Collections.VectorList theD) |
| | Returns true if calculation completed successfully.
|
| |
|
void | Mirror (cadex.Geom.Point thePoint) |
| |
|
void | Mirror (cadex.Geom.Axis1d theAxis) |
| |
|
void | Mirror (cadex.Geom.Axis3d theAxis) |
| |
|
cadex.Geom.Curve | Mirrored (cadex.Geom.Point theRef) |
| |
|
cadex.Geom.Curve | Mirrored (cadex.Geom.Axis1d theAxis) |
| |
|
cadex.Geom.Curve | Mirrored (cadex.Geom.Axis3d theAxis) |
| |
|
void | Rotate (cadex.Geom.Axis1d theAxis, double theAngle) |
| |
|
cadex.Geom.Curve | Rotated (cadex.Geom.Axis1d theAxis, double theAngle) |
| |
|
void | Translate (cadex.Geom.Vector theVector) |
| |
|
cadex.Geom.Curve | Translated (cadex.Geom.Vector theVector) |
| |
|
void | Scale (cadex.Geom.Point thePoint, double theScale) |
| |
|
cadex.Geom.Curve | Scaled (cadex.Geom.Point thePoint, double theScale) |
| |
|
| Geometry (global::System.IntPtr cPtr, bool cMemoryOwn) |
| |
|
| BaseObject (global::System.IntPtr cPtr, bool cMemoryOwn) |
| |
|
void | Dispose () |
| |
|
bool | IsNull () |
| |
| ulong | Id () |
| | Return unique identifier of public object.
|
| |
|
bool | IsEqual (cadex.BaseObject theObj) |
| |
|
override int | GetHashCode () |
| |
|
override bool | Equals (System.Object o) |
| |
Base class for 3D curves.
3D curves are used to represent curves in 3D space. Each non-degenerated edge must refer to a 3D curve.
Types
Refer to Curve Types for the list of supported curve types. Type() returns a curve type as enumeration value which can be used to downcast to a respective subclass type, for instance:
if (aCurve.Type() == Geom::CurveType::Circle) {
const Circle& aCircle =
static_cast<const Circle&
> (aCurve);
double aRadius = aCircle.
Radius();
...
}
Defines 3D circle.
Definition Circle.cs:29
double Radius()
Returns the value specified in the constructor.
Definition Circle.cs:74
Base class for 3D curves.
Definition Curve.cs:84
Parametric Definition
Curve is defined using parametric definition as \(\mathbf{C}(t)\) where \(\mathbf{C}\) is a 3D radius-vector \((x,y,z)^\top\) and \(t\) is a parameter from a definition range \([a, b]\).
UMin() and UMax(), and Domain() return parametric definition range. Parametric range can be bounded (e.g. \([0, 2\pi]\) for a circle) or unbounded (e.g. \((-\infty, +\infty)\) for a line).
Evaluation
At any parameter \(t\) within a definition range, the curve can be evaluated as follows:
- Value() and D0() return a 3D point;
- D1(), D2() and DN() return a derivative of a respective order;
- Curvature() returns a curvature;
- Normal() returns a normal to the curve (i.e. perpendicular to its first derivative).
The following example demonstrates computation of a point on a line at parameter t=2:
Point aPoint = aLine.Value (2.);
Defines 3D line.
Definition Line.cs:28
Defines a 3D point.
Definition Point.cs:17
If the curve is periodic (IsPeriodic() returns true) then the curve can be evaluated at any parameter t, otherwise behavior is undefined (e.g. an exception can be thrown or a weird value can be returned).
Continuity
Continuity() returns continuity ( \(C^0\), \(C^1\), \(C^2\), \(C^N\)) of the curve, where \(C^0\) that only the curve itself is continuous, \(C^1\) - that the curve is continuous together with its first derivative, and so on.
Transformation
The curve can be modified using the following operations:
- translation (Translate() and Translated());
- rotation (Rotate() and Rotated());
- mirroring (Mirror() and Mirrored());
- scaling (Scale() and Scaled());
- arbitrary transformation using 3x4 matrix (Transform() and Transformed()).
- Reversed() returns a curve with opposite orientation.
- Warning
- As the curve data is shared via internal pointer modification of the curve may affect other users of the curve (e.g. an edge referring to it). So you might want to use method returning a modified copy of the curve (such as Transformed()).
- See also
- Curves, Curve2d, ModelData.Edge, Surface.
- Examples
- exploring/brep_geometry/Program.cs, exploring/brep_geometry/main.cxx, exploring/brep_topology/Program.cs, and exploring/brep_topology/main.cxx.