Core 1.0
|
The twist deformation. More...
#include <twist.h>
Public Member Functions | |
Twist (const double &, const double &) | |
Creates a twisting operator. More... | |
Twist (const Vector &, const Vector &, const double &) | |
Creates a twisting operator. More... | |
~Twist () | |
Empty. | |
Cylinder | GetCylinder (const Box &) const |
Compute the bounding cylinder of a box that would be deformed by the twist. More... | |
Box | GetBox (const Box &) const |
Compute the bounding box of a box that would be deformed by the twist. More... | |
Vector | Transform (const Vector &) const |
Transforms a point. More... | |
Vector | InverseTransform (const Vector &) const |
Transforms a point. More... | |
Matrix | Jacobian (const Vector &) const |
Compute the Jacobian of the transformation. More... | |
double | K (const double &) const |
Compute the Lipschitz constant using the maximum distance to the axis. | |
Public Member Functions inherited from Axis | |
Axis () | |
Empty. | |
Axis (const Vector &, const Vector &) | |
Creates an axis given end vertices. More... | |
~Axis () | |
Empty. | |
void | Rotate (const Matrix &) |
Rotates an axis. More... | |
void | Translate (const Vector &) |
Translates an axis. More... | |
void | Scale (const double &) |
Uniformly scales an axis. More... | |
void | Scale (const Vector &) |
Scales an axis. More... | |
Quadric | Equation (const Ray &) const |
Compute the polynomial equation of the Euclidean distance between a ray and the axis. More... | |
Vector | Vertex (int) const |
Return one of the end vertexes of the axis. | |
Vector | Point (const double &) const |
Compute a point on the axis. | |
Vector | GetAxis () const |
Returns the normalized axis vector. | |
double | Length () const |
Return the axis length. | |
Vector | Symmetric (const Vector &) const |
Symmetric point. More... | |
Sphere | Symmetric (const Sphere &) const |
Symmetric sphere. More... | |
Vector | Normal (const Vector &) const |
Compute the normal vector between a point and its projection onto the edge. More... | |
double | R (const Vector &) const |
Compute the squared distance to the segment. More... | |
double | R (const Axis &) const |
Compute the squared distance between two axes. More... | |
double | R (const Vector &, double &) const |
Compute the squared distance to the axis. More... | |
Matrix | GetFrame () const |
Compute an orthonormal frame attached to the axis. More... | |
Protected Member Functions | |
Circle | GetCircle (const Vector &) const |
Compute the circle obtained by rotating the point around the axis. More... | |
Protected Member Functions inherited from Axis | |
double | Radial (const Vector &, Vector &, Vector &) const |
Compute the radial coordinates of a point. More... | |
Vector2 | Radial (const Vector &) const |
Compute the radial coordinates of a point. More... | |
Protected Attributes | |
double | omega |
Angular velocity. | |
double | angle |
Twisting angle between end vertices. | |
Vector | y |
Orthonormal vectors. | |
Protected Attributes inherited from Axis | |
Vector | b = Vector::Z |
End vertices of the axis. | |
Vector | axis = Vector::Z |
Normalized axis vector. | |
double | length = 1.0 |
Length of the axis. | |
Friends | |
std::ostream & | operator<< (std::ostream &, const Twist &) |
Overloaded. | |
Additional Inherited Members | |
Static Public Member Functions inherited from Axis | |
static Matrix | GetFrame (const Vector &) |
Compute an orthonormal frame attached to the axis. More... | |
static Vector | BoxVector (const Vector &) |
Compute the box vector extent of a unit circle with a given axis. More... | |
The twist deformation.
Example of how to code a twist:
|
explicit |
Creates a twisting operator.
length | Length of the vertial twisting axis. |
angle | The twisting angle. |
Creates a twisting operator.
a,b | End vertices of the twisting axis. |
angle | The twisting angle between end vertices. |
Compute the bounding box of a box that would be deformed by the twist.
This function is slightly more accurate than computing the bounding cylinder, and then taking its bouding box.
box | The box. |
Compute the circle obtained by rotating the point around the axis.
p | Point. |
Compute the bounding cylinder of a box that would be deformed by the twist.
box | The box. |
Transforms a point.
p | Argument point. |
Compute the Jacobian of the transformation.
This function is needed to implement the computation of the gradient of the field function. The argument point is assumed to be in the frame of the twist.
p | Point (in the twisting coordinate system). |