SDK3DVerse_GeometryGizmos_Ext

Add a widget to display and interact with geometries.

This extension require the following extension installed:

  • SDK3DVerse_ThreeJS_Ext
  • SDK3DVerse_ViewportDomOverlay_Ext

The gizmo handles are dom elements and should be defined in your stylesheet with the following css class. You can customize it if you want.

.gizmo-handle
{
    display: inline-block;
    width: 15px;
    height: 15px;
    border-radius: 50%;

    cursor: pointer;
    pointer-events: initial;

    border-color: rgba(0,0,0,0.5);
    background: rgba(255,255,255,0.8);
    border-width: 1px;
    border-style: solid;
}

Methods

installExtension()

Properties:
Name Type Description
basicMaterialColor Color

Unselected geometry material color

selectedMaterialColor Color

Selected geometry material color

edgeMaterialColor Color

Unselected geometry edge material color

selectedEdgeMaterialColor Color

Selected geometry edge material color

basicMaterialOpacity float

Unselected geometry material opacity

selectedMaterialOpacity float

Selected geometry material opacity

disableRendering Boolean

Disable geometry rendering and keep only edition gizmos

The colors can be defined as numbers or css-style strings.

Examples :

  • 0xff0000
  • 'rgb(250, 0,0)'
  • 'rgb(100%,0%,0%)'
  • 'hsl(0, 100%, 50%)'
  • '#ff0000'
  • '#f00'
  • 'red'

isEntityVisible(entityRTID) → {Boolean}

Get entity visibility state of its geometry.

Parameters:
Name Type Description
entityRTID string

Entity unique identifier

Returns:

Visibility state

Type
Boolean

setEntityVisibility(entityRTID, isVisible)

Hide or show geometry of a given entity.

Parameters:
Name Type Description
entityRTID string

Entity unique identifier

isVisible Boolean

Visibility state

setGeometryDisplay(geometryRendering, gizmoRendering)

Enable or disable geometry rendering. Does not affect the visibility state of the entities.

Parameters:
Name Type Description
geometryRendering Boolean

Geometry rendering state

gizmoRendering Boolean

Edition gizmo rendering state