AnyCAD Rapid SDK
2020
The Rapid CAD SDK
|
Public Member Functions | |
synchronized void | delete () |
GElips2d () | |
GElips2d (GAx2d MajorAxis, double MajorRadius, double MinorRadius, boolean Sense) | |
GElips2d (GAx2d MajorAxis, double MajorRadius, double MinorRadius) | |
GElips2d (GAx22d A, double MajorRadius, double MinorRadius) | |
void | SetLocation (GPnt2d P) |
void | SetMajorRadius (double MajorRadius) |
void | SetMinorRadius (double MinorRadius) |
void | SetAxis (GAx22d A) |
void | SetXAxis (GAx2d A) |
void | SetYAxis (GAx2d A) |
double | Area () |
void | Coefficients (double[] A, double[] B, double[] C, double[] D, double[] E, double[] F) |
GAx2d | Directrix1 () |
GAx2d | Directrix2 () |
double | Eccentricity () |
double | Focal () |
GPnt2d | Focus1 () |
GPnt2d | Focus2 () |
GPnt2d | Location () |
double | MajorRadius () |
double | MinorRadius () |
double | Parameter () |
GAx22d | Axis () |
GAx2d | XAxis () |
GAx2d | YAxis () |
void | Reverse () |
GElips2d | Reversed () |
boolean | IsDirect () |
void | Mirror (GPnt2d P) |
GElips2d | Mirrored (GPnt2d P) |
void | Mirror (GAx2d A) |
GElips2d | Mirrored (GAx2d A) |
void | Rotate (GPnt2d P, double Ang) |
GElips2d | Rotated (GPnt2d P, double Ang) |
void | Scale (GPnt2d P, double S) |
GElips2d | Scaled (GPnt2d P, double S) |
void | Transform (GTrsf2d T) |
GElips2d | Transformed (GTrsf2d T) |
void | Translate (GVec2d V) |
GElips2d | Translated (GVec2d V) |
void | Translate (GPnt2d P1, GPnt2d P2) |
GElips2d | Translated (GPnt2d P1, GPnt2d P2) |
Protected Member Functions | |
GElips2d (long cPtr, boolean cMemoryOwn) | |
void | finalize () |
Static Protected Member Functions | |
static long | getCPtr (GElips2d obj) |
Protected Attributes | |
transient boolean | swigCMemOwn |
Describes an ellipse in the plane (2D space). An ellipse is defined by its major and minor radii and positioned in the plane with a coordinate system (a gp_Ax22d object) as follows: - the origin of the coordinate system is the center of the ellipse, - its "X Direction" defines the major axis of the ellipse, and - its "Y Direction" defines the minor axis of the ellipse. This coordinate system is the "local coordinate system" of the ellipse. Its orientation (direct or indirect) gives an implicit orientation to the ellipse. In this coordinate system, the equation of the ellipse is: X*X / (MajorRadius**2) + Y*Y / (MinorRadius**2) = 1.0 See Also gce_MakeElips2d which provides functions for more complex ellipse constructions Geom2d_Ellipse which provides additional functions for constructing ellipses and works, in particular, with the parametric equations of ellipses
GElips2d.GElips2d | ( | ) |
Creates an indefinite ellipse.
GElips2d.GElips2d | ( | GAx2d | MajorAxis, |
double | MajorRadius, | ||
double | MinorRadius, | ||
boolean | Sense | ||
) |
Creates an ellipse with the major axis, the major and the minor radius. The location of the MajorAxis is the center of the ellipse. The sense of parametrization is given by Sense. Warnings : It is possible to create an ellipse with MajorRadius = MinorRadius. Raises ConstructionError if MajorRadius < MinorRadius or MinorRadius < 0.0
GElips2d.GElips2d | ( | GAx2d | MajorAxis, |
double | MajorRadius, | ||
double | MinorRadius | ||
) |
Creates an ellipse with the major axis, the major and the minor radius. The location of the MajorAxis is the center of the ellipse. The sense of parametrization is given by Sense. Warnings : It is possible to create an ellipse with MajorRadius = MinorRadius. Raises ConstructionError if MajorRadius < MinorRadius or MinorRadius < 0.0
GElips2d.GElips2d | ( | GAx22d | A, |
double | MajorRadius, | ||
double | MinorRadius | ||
) |
Creates an ellipse with radii MajorRadius and MinorRadius, positioned in the plane by coordinate system A where: - the origin of A is the center of the ellipse, - the "X Direction" of A defines the major axis of the ellipse, that is, the major radius MajorRadius is measured along this axis, and - the "Y Direction" of A defines the minor axis of the ellipse, that is, the minor radius MinorRadius is measured along this axis, and - the orientation (direct or indirect sense) of A gives the orientation of the ellipse. Warnings : It is possible to create an ellipse with MajorRadius = MinorRadius. Raises ConstructionError if MajorRadius < MinorRadius or MinorRadius < 0.0
double GElips2d.Area | ( | ) |
Computes the area of the ellipse.
GAx22d GElips2d.Axis | ( | ) |
Returns the major axis of the ellipse.
void GElips2d.Coefficients | ( | double[] | A, |
double[] | B, | ||
double[] | C, | ||
double[] | D, | ||
double[] | E, | ||
double[] | F | ||
) |
Returns the coefficients of the implicit equation of the ellipse. A * (X**2) + B * (Y**2) + 2*C*(X*Y) + 2*D*X + 2*E*Y + F = 0.
GAx2d GElips2d.Directrix1 | ( | ) |
This directrix is the line normal to the XAxis of the ellipse in the local plane (Z = 0) at a distance d = MajorRadius / e from the center of the ellipse, where e is the eccentricity of the ellipse. This line is parallel to the "YAxis". The intersection point between directrix1 and the "XAxis" is the location point of the directrix1. This point is on the positive side of the "XAxis". Raised if Eccentricity = 0.0. (The ellipse degenerates into a circle)
GAx2d GElips2d.Directrix2 | ( | ) |
This line is obtained by the symmetrical transformation of "Directrix1" with respect to the minor axis of the ellipse. Raised if Eccentricity = 0.0. (The ellipse degenerates into a circle).
double GElips2d.Eccentricity | ( | ) |
Returns the eccentricity of the ellipse between 0.0 and 1.0 If f is the distance between the center of the ellipse and the Focus1 then the eccentricity e = f / MajorRadius. Returns 0 if MajorRadius = 0.
double GElips2d.Focal | ( | ) |
Returns the distance between the center of the ellipse and focus1 or focus2.
GPnt2d GElips2d.Focus1 | ( | ) |
Returns the first focus of the ellipse. This focus is on the positive side of the major axis of the ellipse.
GPnt2d GElips2d.Focus2 | ( | ) |
Returns the second focus of the ellipse. This focus is on the negative side of the major axis of the ellipse.
boolean GElips2d.IsDirect | ( | ) |
Returns true if the local coordinate system is direct and false in the other case.
GPnt2d GElips2d.Location | ( | ) |
Returns the center of the ellipse.
double GElips2d.MajorRadius | ( | ) |
Returns the major radius of the Ellipse.
double GElips2d.MinorRadius | ( | ) |
Returns the minor radius of the Ellipse.
Performs the symmetrical transformation of a ellipse with respect to the point P which is the center of the symmetry
Performs the symmetrical transformation of a ellipse with respect to an axis placement which is the axis of the symmetry.
double GElips2d.Parameter | ( | ) |
Returns p = (1 - e * e) * MajorRadius where e is the eccentricity of the ellipse. Returns 0 if MajorRadius = 0
void GElips2d.SetAxis | ( | GAx22d | A | ) |
Modifies this ellipse, by redefining its local coordinate system so that it becomes A.
void GElips2d.SetLocation | ( | GPnt2d | P | ) |
Modifies this ellipse, by redefining its local coordinate system so that - its origin becomes P.
void GElips2d.SetMajorRadius | ( | double | MajorRadius | ) |
Changes the value of the major radius. Raises ConstructionError if MajorRadius < MinorRadius.
void GElips2d.SetMinorRadius | ( | double | MinorRadius | ) |
Changes the value of the minor radius. Raises ConstructionError if MajorRadius < MinorRadius or MinorRadius < 0.0
void GElips2d.SetXAxis | ( | GAx2d | A | ) |
Modifies this ellipse, by redefining its local coordinate system so that its origin and its "X Direction" become those of the axis A. The "Y Direction" is then recomputed. The orientation of the local coordinate system is not modified.
void GElips2d.SetYAxis | ( | GAx2d | A | ) |
Modifies this ellipse, by redefining its local coordinate system so that its origin and its "Y Direction" become those of the axis A. The "X Direction" is then recomputed. The orientation of the local coordinate system is not modified.
Transforms an ellipse with the transformation T from class Trsf2d.
Translates a ellipse in the direction of the vector V. The magnitude of the translation is the vector's magnitude.
Translates a ellipse from the point P1 to the point P2.
GAx2d GElips2d.XAxis | ( | ) |
Returns the major axis of the ellipse.
GAx2d GElips2d.YAxis | ( | ) |
Returns the minor axis of the ellipse. Reverses the direction of the circle.