Next: Regular Closed Plane Curve Intersections, Previous: Regular Closed Plane Curve Data Members, Up: Regular Closed Plane Curve Reference
const
inline virtual functions: bool is_quadratic (void)These functions all return
false
. They are intended to be overloaded by member functions of derived classes.
const
inline virtual function: real_triple get_coefficients (real Slope, real v_intercept)Returns a
real_triple
with all three values ==INVALID_REAL
. Intended to be overloaded by member functions of derived classes.
const
inline virtual function: pair<real, real> solve (char axis_unknown, real known)Returns a
pair<real, real>
withfirst
=second
=INVALID_REAL
. Intended to be overloaded by member functions of derived classes.
const
virtual function: signed short location (Point ref_pt, Point p)Returns a
signed short
indicating the location of p with respect to theReg_Cl_Plane_Curve
, which must be planar. TheReg_Cl_Plane_Curve
constructors should ensure thatReg_Cl_Plane_Curves
are, but there is no guarantee that they will not have been manipulated into a non-planar state, by shearing, for example.The argument ref_pt is used within the function for shifting a copy of the
Reg_Cl_Plane_Curve
to a convenient position. It need not be the |center| of theReg_Cl_Plane_Curve
, however, classes derived fromReg_Cl_Plane_Curve
will probably have their own versions oflocation()
, which will passcenter
as the ref_pt argument to this function.Reg_Cl_Plane_Curves
need not have a meaningful |center|.
location()
returns the following values:
- -1
- p and
*this
are coplanar, and p lies outside the perimeter of*this
.- 0
- p and
*this
are coplanar, and p lies on the perimeter of*this
.- 1
- p and
*this
are coplanar, and p lies inside the perimeter of*this
.- -2
- p and
*this
are not coplanar.- -3
- Something has gone terribly wrong.
- -4
- The normal to
*this
has 0 magnitude, i.e., the |Points| on*this
are colinear.- -5
- An error occurred in putting
*this
in one of the major planes.