AnnotationBase

AnnotationBase

Provides a common base class to all annotation geometry. This class refers to the geometric element that is independent from the document.

Extends

Members

hasBrepForm :bool

Inherited From:
Returns true if the Brep.TryConvertBrep function will be successful for this object
Type:
  • bool

isDeformable :bool

Inherited From:
true if object can be accurately modified with "squishy" transformations like projections, shears, and non-uniform scaling.
Type:
  • bool

isValid :bool

Inherited From:
Tests an object to see if it is valid.
Type:
  • bool

objectType :ObjectType

Inherited From:
Useful for switch statements that need to differentiate between basic object types like points, curves, surfaces, and so on.
Type:
  • ObjectType

plainText :string

Text stripped of RTF formatting information
Type:
  • string

richText :string

Text including additional RTF formatting information
Type:
  • string

userStringCount

Inherited From:

Methods

duplicate() → {GeometryBase}

Inherited From:
Constructs a deep (full) copy of this object.
Returns:
An object of the same type as this, with the same properties and behavior.
Type
GeometryBase

encode()

Inherited From:
...

getBoundingBox(plane) → {Array}

Inherited From:
Aligned Bounding box solver. Gets the plane aligned bounding box.
Parameters:
Name Type Description
plane Plane Orientation plane for BoundingBox.
Returns:
[BoundingBox, Box]
  • (BoundingBox) A BoundingBox in plane coordinates.
  • (Box) Aligned box in World coordinates.
Type
Array

getUserString()

Inherited From:
...

getUserStrings()

Inherited From:
...

makeDeformable() → {bool}

Inherited From:
If possible, converts the object into a form that can be accurately modified with "squishy" transformations like projections, shears, an non-uniform scaling.
Returns:
false if object cannot be converted to a deformable object. true if object was already deformable or was converted into a deformable object.
Type
bool

rdkXml()

Inherited From:
...

rotate(angleRadians, rotationAxis, rotationCenter) → {bool}

Inherited From:
Rotates the object about the specified axis. A positive rotation angle results in a counter-clockwise rotation about the axis (right hand rule).
Parameters:
Name Type Description
angleRadians double Angle of rotation in radians.
rotationAxis Array.<x, y, z> Direction of the axis of rotation.
rotationCenter Array.<x, y, z> Point on the axis of rotation.
Returns:
true if geometry successfully rotated.
Type
bool

scale(scaleFactor) → {bool}

Inherited From:
Scales the object by the specified factor. The scale is centered at the origin.
Parameters:
Name Type Description
scaleFactor double The uniform scaling factor.
Returns:
true if geometry successfully scaled.
Type
bool

setUserString()

Inherited From:
...

toJSON()

Inherited From:
Create a JSON string representation of this object

transform(xform) → {bool}

Inherited From:
Transforms the geometry. If the input Transform has a SimilarityType of OrientationReversing, you may want to consider flipping the transformed geometry after calling this function when it makes sense. For example, you may want to call Flip() on a Brep after transforming it.
Parameters:
Name Type Description
xform Transform Transformation to apply to geometry.
Returns:
true if geometry successfully transformed.
Type
bool

translate(translationVector) → {bool}

Inherited From:
Translates the object along the specified vector.
Parameters:
Name Type Description
translationVector Array.<x, y, z> A moving vector.
Returns:
true if geometry successfully translated.
Type
bool