MarkupModel

class cee.mrk.MarkupModel()

This class can be used to add markup items to a visualization.

Constructors

Accessors

  • ignoreViewClipping

  • name

  • partCount


Constructors

MarkupModel.constructor()

Constructor

Return type:

MarkupModel

Accessors

cee.mrk.ignoreViewClipping()

Enable or disable option to ignore view clipping in this model

Return type:

boolean

cee.mrk.ignoreViewClipping(ignore)
Arguments:
  • ignore (boolean) – None

Return type:

void

cee.mrk.name()

Name of the markup model.

Return type:

string

cee.mrk.name(name)
Arguments:
  • name (string) – None

Name of the model.

Mainly used for debugging.

Return type:

void

cee.mrk.partCount()

The number of parts in the model.

Return type:

number

Methods

addArrowsPart

MarkupModel.addArrowsPart()

Adds a part for drawing points. Use the returned PartPoints to add points to the new part.

Return type:

PartArrows

addImageLabelPart

MarkupModel.addImageLabelPart()

Add a part with an image attached to a 3d coordinate

Return type:

PartImageLabel

addIndexedTrianglesPart

MarkupModel.addIndexedTrianglesPart()

Adds a part containing indexed triangles to the markup model. Use the returned PartIndexedTriangles to set the mesh data and color of the new part.

Return type:

PartIndexedTriangles

addLabelsPart

MarkupModel.addLabelsPart()

Adds a part containing positioned text labels to the markup model. Use the returned PartLabels to add text labels to the new part.

Return type:

PartLabels

addLinesPart

MarkupModel.addLinesPart()

Adds a part for drawing lines. Use the returned PartLines to add lines to the new part.

Return type:

PartLines

addPointsPart

MarkupModel.addPointsPart()

Adds a part for drawing points. Use the returned PartPoints to add points to the new part.

Return type:

PartPoints

addTexturedIndexedTrianglesPart

MarkupModel.addTexturedIndexedTrianglesPart()

Adds a part containing textured indexed triangles to the markup model. Use the returned PartTexturedIndexedTriangles to set the mesh data and texture of the new part.

Return type:

PartTexturedIndexedTriangles

deleteAllParts

MarkupModel.deleteAllParts()

Deletes all parts in model

Return type:

void

deletePart

MarkupModel.deletePart(part)
Arguments:
  • part (Part) – None

Delete the given part if present.

Returns true if the part was found and deleted, false if not.

Return type:

boolean

deletePartAt

MarkupModel.deletePartAt(partIndex)
Arguments:
  • partIndex (number) – None

Deletes the part at the given (zero-based) index.

Return type:

void

getBoundingBox

MarkupModel.getBoundingBox([_options])
Arguments:
  • _options (ModelBoundingBoxOptions) – optional None

Returns the BoundingBox (in world coordinates) of the model.

Note that currently this method does not support any ModelBoundingBoxOptions

Return type:

BoundingBox

getDefaultCameraConfig

MarkupModel.getDefaultCameraConfig()

Returns default camera configuration, which is always null for this model.

Return type:

unknown

getPartAt

MarkupModel.getPartAt(partIndex)
Arguments:
  • partIndex (number) – None

Returns an active reference to the part at the given (zero-based) index.

Return type:

Part

rayIntersect

MarkupModel.rayIntersect(ray, ignoreLabels)
Arguments:
  • ray (Ray) – None

  • ignoreLabels (boolean) – None

Performs picking on the model.

If something was hit, returns a HitItem containing information about the part and primitive that was hit.

If nothing was hit, returns null.

Labels have a “special treatment” ray intersect where hitting the label will cause a hit on the label attachment point. This is not always what is intended, e.g. when doing zoom to cursor. Set ignoreLabels to true to skip labels when doing ray intersect.

Return type:

HitItem