3D Display Control Reference 15.0
Methods

Functions

void AddCoordinateAxes (LONG id, DOUBLE vx, DOUBLE vy, DOUBLE vz, DOUBLE theta, DOUBLE tx, DOUBLE ty, DOUBLE tz, DOUBLE size)
 Display a 3D coordinate indicator with specified orientation and position in the 3D viewer. More...
 
void AddLabel (BSTR text, LONG color, LONG size, DOUBLE opacity, enum Core3DViewerHorizontalTextAlignment horAlignment, enum Core3DViewerVerticalTextAlignment vertAlignment, LONG id, DOUBLE x, DOUBLE y)
 Add a new label to the 3D display. More...
 
VARIANT_BOOL AddPointCloudSolid (LONGLONG pointCloudHandle, OLE_COLOR color, DOUBLE opacity, DOUBLE pointSize, DOUBLE lineWidth, LONG id)
 Add a new point cloud to the 3D display with uniformly colored points. More...
 
VARIANT_BOOL AddPointCloudVariable (LONGLONG pointCloudHandle, DOUBLE hueMin, DOUBLE hueMax, DOUBLE saturationMin, DOUBLE saturationMax, DOUBLE valueMin, DOUBLE valueMax, DOUBLE opacity, DOUBLE pointSize, DOUBLE lineWidth, LONG id)
 Add a new point cloud to the 3D display with point colors corresponding to the points' z value. More...
 
void AddPointMarker (BSTR text, OLE_COLOR color, DOUBLE size, DOUBLE opacity, LONG id, DOUBLE x, DOUBLE y, DOUBLE z, VARIANT_BOOL reverse)
 Add a new point marker to the 3D display. More...
 
LONG GetCoordinateAxesId (LONG coordinateAxesNumber)
 Retrieve the id of the n-th coordinate indicator. More...
 
LONG GetLabelId (LONG labelNumber)
 Retrieve the id of the n-th label overlay. More...
 
LONGLONG GetPointCloud (LONG id)
 Retrieve the handle of a point cloud that is currently being displayed. More...
 
OLE_COLOR GetPointCloudColor (LONG id)
 Retrieves the currently used rendering color for a point cloud. More...
 
LONG GetPointCloudId (LONG pointCloudNumber)
 Retrieve the id of the n-th point cloud. More...
 
DOUBLE GetPointCloudLineWidth (LONG id)
 Retrieves the currently used line width for a point cloud. More...
 
VARIANT_BOOL GetPointCloudLutRanges (LONG id, DOUBLE *hueMin, DOUBLE *hueMax, DOUBLE *saturationMin, DOUBLE *saturationMax, DOUBLE *valueMin, DOUBLE *valueMax)
 Query the current LUT parameters for point cloud visualization. More...
 
DOUBLE GetPointCloudOpacity (LONG id)
 Retrieves the currently used opacity for a point cloud. More...
 
DOUBLE GetPointCloudPointSize (LONG id)
 Retrieves the currently used point size for a point cloud. More...
 
enum Core3DViewerVisualizationMode GetPointCloudVisualizationMode (LONG id)
 Queries the current visualization mode of the referenced point cloud. More...
 
LONG GetPointMarkerId (LONG pointMarkerNumber)
 Retrieve the id of the n-th point marker. More...
 
VARIANT_BOOL GetSelectedVolume (DOUBLE *xmin, DOUBLE *xmax, DOUBLE *ymin, DOUBLE *ymax, DOUBLE *zmin, DOUBLE *zmax)
 Retrieve the current extent in x, y and z direction of the volume of interest selector. More...
 
VARIANT_BOOL HasLabel (LONG id)
 Check if a label with the given id exists. More...
 
VARIANT_BOOL HasPointCloud (LONG id)
 Check if a point cloud with the given id exists. More...
 
VARIANT_BOOL HasPointMarker (LONG id)
 Check if a point marker with the given id exists. More...
 
void RemoveAllCoordinateAxes ()
 Remove all coordinate indicators from the 3D display. More...
 
void RemoveAllLabels ()
 Remove all currently visible label overlays from the 3D display. More...
 
void RemoveAllObjects ()
 Remove all currently visible objects from the 3D display. More...
 
void RemoveAllPointClouds ()
 Remove all currently visible point clouds from the 3D display. More...
 
void RemoveAllPointMarkers ()
 Remove all currently visible point markers from the 3D display. More...
 
void RemoveCoordinateAxes (LONG id)
 Remove a coordinate indicator from the 3D display. More...
 
void RemoveLabel (LONG id)
 Remove a label overlay from the 3D display. More...
 
void RemovePointCloud (LONG id)
 Remove a point cloud from the 3D display. More...
 
void RemovePointMarker (LONG id)
 Remove a point marker from the 3D display. More...
 
LONGLONG RenderWindowToImage ()
 Take a snapshot of the current 3D display render window. More...
 
void ResetCamera ()
 Auto-align the camera parameters taking account the currently visible objects. More...
 
void SetBackground (OLE_COLOR color)
 Set the background color of the 3D viewer to a solid color. More...
 
void SetBackgroundGradient (OLE_COLOR color1, OLE_COLOR color2)
 Set the background of the 3D viewer to a gradient color scheme. More...
 
void SetCameraAzimuth (DOUBLE angle)
 Rotate the camera horizontally. More...
 
void SetCameraElevation (DOUBLE angle)
 Rotate the camera in the up/down direction. More...
 
void SetCameraRoll (DOUBLE angle)
 Rotate the camera around the viewing direction. More...
 
void SetCameraZoom (DOUBLE factor)
 Modify the viewing angle. More...
 
void SetPointCloudColor (LONG id, OLE_COLOR color)
 Sets a rendering color for a point cloud and change the visualization mode to solid coloring. More...
 
void SetPointCloudLineWidth (LONG id, DOUBLE lineWidth)
 Sets the line width for rendering a point cloud. More...
 
VARIANT_BOOL SetPointCloudLutRanges (LONG id, DOUBLE hueMin, DOUBLE hueMax, DOUBLE saturationMin, DOUBLE saturationMax, DOUBLE valueMin, DOUBLE valueMax)
 Change the point cloud visualization mode to color range and/or redefine the lookup-tables. More...
 
void SetPointCloudOpacity (LONG id, DOUBLE opacity)
 Sets the opacity for rendering a point cloud. More...
 
void SetPointCloudPointSize (LONG id, DOUBLE pointSize)
 Sets the point size for rendering a point cloud. More...
 

Detailed Description

Function Documentation

◆ AddCoordinateAxes()

void AddCoordinateAxes ( LONG  id,
DOUBLE  vx,
DOUBLE  vy,
DOUBLE  vz,
DOUBLE  theta,
DOUBLE  tx,
DOUBLE  ty,
DOUBLE  tz,
DOUBLE  size 
)

Display a 3D coordinate indicator with specified orientation and position in the 3D viewer.

The coordinate indicator will be displayed at the specified position, in specified orientation and size. The orientation is given in axis/angle format, i.e. a direction vector (the eigen vector of the rotation) and the amount of rotation around this vector. There can be an unlimited number of coordinate indicators in the 3D viewer, each one identified by a unique ID. If a coordinate indicator with an equal ID already exists, orientation and position of this indicator will be updated. To remove the coordinate indicator, see RemoveCoordinateAxes.

Example: AddCoordinateAxes(101, 0, 0, 1, 90, 10, 3, 0, 5) will display a coordinate indicator

  • with an ID of 101 and the axis length of 5
  • at position x=10, y=3, z=0 in the current scene
  • rotated 90 degrees around the z-axis
Parameters
[in]Uniqueidentifier ID of the coordinate indicator. If a coordinator indicator with an equal ID exists, it will be updated correspondingly.
[in]vxX-component of the rotation direction vector.
[in]vyY-component of the rotation direction vector.
[in]vzZ-component of the rotation direction vector.
[in]thetaRotation angle in degrees.
[in]txX-Coordinate of indicator's position.
[in]tyY-Coordinate of indicator's position.
[in]tzZ-Coordinate of indicator's position.
[in]sizeLenght of indicator's coordinate axes.

◆ AddLabel()

void AddLabel ( BSTR  text,
LONG  color,
LONG  size,
DOUBLE  opacity,
enum Core3DViewerHorizontalTextAlignment  horAlignment,
enum Core3DViewerVerticalTextAlignment  vertAlignment,
LONG  id,
DOUBLE  x,
DOUBLE  y 
)

Add a new label to the 3D display.

A 'label' in the context of the 3D display control is a (usually short) piece of text to be displayed as an overlay over the scene. Labels will not scale with the scene's content, nor will they move when modifying the virtual camera's parameters.

The way AddLabel acts depends on the id parameter:

  • when specifying a new (i.e. previously unused) identifier, a new label will be added
  • when specifying an id of a label that is already in use (i.e. AddLabel has already been called to generate a label with that particular id) then the existing label will be modified using the parameters provided in the AddLabel call.

Note that ids are handled separately for different types of display objects: A 3D display may simultaneously contain a label with id 0 (see AddLabel), a point cloud with id 0 (see AddPointCloudSolid) and a point marker with id 0 (see AddPointMarker).

Attention
Ids have to be positive numbers. When specifying a value below zero this function will not do anything.
Parameters
[in]textText to be displayed as a label overlay.
[in]colorColor to be used for displaying the label overlay. Color is specified using OLE_COLOR convention, meaning that it should be provided as an integer value where the lowest 8 bits represent the red channel's intensity, bits 8 to 15 represent the green channel's intensity and bits 16 to 23 represent the blue channel's intensity. The uppermost 8 bits are not evaluated and should be set to zero (in MFC applications the easiest way to build such a color value is to use the RGB(r, g, b) macro).
[in]sizeSize (in pixels) of the text to be shown.
[in]opacityOpacity of the text overlay when rendering. Specifying a value of 1.0 will make the overlay completely opaque, a value of 0.0 will make the overlay completely transparent.
[in]horAlignmentHorizontal text alignment. Text alignment is measured relative to the values specified in the parameters x and y.
[in]vertAlignmentVertical text alignment. Text alignment is measured relative to the values specified in the parameters x and y.
[in]idNumerical identified by which the text overlay can later on be accessed (e.g. in RemoveLabel or in another AddLabel call).
[in]xHorizontal position of the label. Note that for the text overlays the 3D display uses homogeneous coordinates, i.e. a value of 0.0 represents the left edge of the display and a value of 1.0 represents the right edge of the display regardless of the actual size in pixels.
[in]yVertical position of the label. Note that for the text overlays the 3D display uses homogeneous coordinates, i.e. a value of 0.0 represents the top edge of the display and a value of 1.0 represents the bottom edge of the display regardless of the actual size in pixels.

◆ AddPointCloudSolid()

VARIANT_BOOL AddPointCloudSolid ( LONGLONG  pointCloudHandle,
OLE_COLOR  color,
DOUBLE  opacity,
DOUBLE  pointSize,
DOUBLE  lineWidth,
LONG  id 
)

Add a new point cloud to the 3D display with uniformly colored points.

A 'point cloud' in the context of the 3D display control is an object of type CVCOMPOSITE that contains 3D point data. The 3D display always uses dense point clouds with floating-point-valued XYZ-data for display purposes. I a point cloud that does not meet these requirements is passed to AddPointCloudSolid it will automatically be converted internally to a point cloud of the appropriate type.

While a point cloud is on display in a 3D display control, the control will increment its reference count by means of calling ShareObject on its handle in order to keep it alive as long as it is required (if, however, the point cloud is converted internally to meet the display's format requirements the original point cloud's reference count will not be changed).

The way AddPointCloudSolid acts depends on the id parameter:

  • when specifying a new (i.e. previously unused) identifier, a new point cloud will be added
  • when specifying an id of a point cloud that is already in use (i.e. AddPointCloudSolid has already been called to generate a point cloud with that particular id) then the existing point cloud will be modified using the parameters provided in the AddPointCloudSolid call.

Note that ids are handled separately for different types of display objects: A 3D display may simultaneously contain a label with id 0 (see AddLabel), a point cloud with id 0 (see AddPointCloudSolid) and a point marker with id 0 (see AddPointMarker).

Note that it is also possible to use a color gradient rather than solid colored point clouds - this option often makes it easier to interpret the point cloud display. See AddPointCloudVariable

Attention
Ids have to be positive numbers. When specifying a value below zero this function will not do anything.
Parameters
[in]pointCloudHandleHandle to the CVCOMPOSITE holding the point cloud data to be displayed.
[in]colorColor to be used for displaying the label overlay. Color is specified using OLE_COLOR convention, meaning that it should be provided as an integer value where the lowest 8 bits represent the red channel's intensity, bits 8 to 15 represent the green channel's intensity and bits 16 to 23 represent the blue channel's intensity. The uppermost 8 bits are not evaluated and should be set to zero (in MFC applications the easiest way to build such a color value is to use the RGB(r, g, b) macro).
[in]opacityOpacity of the point cloud when rendering. Specifying a value of 1.0 will make the overlay completely opaque, a value of 0.0 will make the overlay completely transparent.
[in]pointSizeSize of the points on display (in 3D units).
[in]lineWidthIn case a wireframe is being displayed, the lineWidth parameter specifies the line width to be used for rendering (in 3D units).
[in]idNumerical identified by which the point cloud can later on be accessed (e.g. in RemoveLabel or in another AddLabel call).
Returns
TRUE if a point cloud has been added, FALSE otherwise (e.g. if pointCloudHandle did not refer to a valid CVCOMPOSITE object).

◆ AddPointCloudVariable()

VARIANT_BOOL AddPointCloudVariable ( LONGLONG  pointCloudHandle,
DOUBLE  hueMin,
DOUBLE  hueMax,
DOUBLE  saturationMin,
DOUBLE  saturationMax,
DOUBLE  valueMin,
DOUBLE  valueMax,
DOUBLE  opacity,
DOUBLE  pointSize,
DOUBLE  lineWidth,
LONG  id 
)

Add a new point cloud to the 3D display with point colors corresponding to the points' z value.

A 'point cloud' in the context of the 3D display control is an object of type CVCOMPOSITE that contains 3D point data. The 3D display always uses dense point clouds with floating-point-valued XYZ-data for display purposes. I a point cloud that does not meet these requirements is passed to AddPointCloudSolid it will automatically be converted internally to a point cloud of the appropriate type.

While a point cloud is on display in a 3D display control, the control will increment its reference count by means of calling ShareObject on its handle in order to keep it alive as long as it is required (if, however, the point cloud is converted internally to meet the display's format requirements the original point cloud's reference count will not be changed).

The way AddPointCloudVariable acts depends on the id parameter:

  • when specifying a new (i.e. previously unused) identifier, a new point cloud will be added
  • when specifying an id of a point cloud that is already in use (i.e. AddPointCloudVariable has already been called to generate a point cloud with that particular id) then the existing point cloud will be modified using the parameters provided in the AddPointCloudVariable call.

Note that ids are handled separately for different types of display objects: A 3D display may simultaneously contain a label with id 0 (see AddLabel), a point cloud with id 0 (see AddPointCloudVariable) and a point marker with id 0 (see AddPointMarker).

Note that it is also possible to use solid color rather than a color gradient to color point clouds - this option often makes it easier to interpret the point cloud display when comparing two point clouds. See AddPointCloudSolid

Attention
Ids have to be positive numbers. When specifying a value below zero this function will not do anything.
Parameters
[in]pointCloudHandleHandle to the CVCOMPOSITE holding the point cloud data to be displayed.
[in]hueMinHue value to be assigned to the lowest z value. Value hue values are in the range [0...1] and are organized in a circle that starts (0.0) and ends (1.0) at the color red and cycles through yellow, green, cyan, blue and magenta in order of incrementing values.
[in]hueMaxHue value to be assigned to the highest z value. Value hue values are in the range [0...1] and are organized in a circle that starts (0.0) and ends (1.0) at the color red and cycles through yellow, green, cyan, blue and magenta in order of incrementing values.
[in]saturationMinSaturation value to be assigned to the lowest z value. Saturation Values are in the range [0...1] with 0.0 indicating completely unsaturated colors (i.e. gray scale) and 1.0 indicating fully saturated colors.
[in]saturationMaxSaturation value to be assigned to the highest z value. Saturation Values are in the range [0...1] with 0.0 indicating completely unsaturated colors (i.e. gray scale) and 1.0 indicating fully saturated colors.
[in]valueMinIntensity value to be assigned to the lowest z value. Intensity values are in the range [0...1].
[in]valueMaxIntensity value to be assigned to the highest z value. Intensity values are in the range [0...1].
[in]opacityOpacity of the point cloud when rendering. Specifying a value of 1.0 will make the overlay completely opaque, a value of 0.0 will make the overlay completely transparent.
[in]pointSizeSize of the points on display (in 3D units).
[in]lineWidthIn case a wireframe is being displayed, the lineWidth parameter specifies the line width to be used for rendering (in 3D units).
[in]idNumerical identified by which the point cloud can later on be accessed (e.g. in RemoveLabel or in another AddLabel call).
Returns
TRUE if a point cloud has been added, FALSE otherwise (e.g. if pointCloudHandle did not refer to a valid CVCOMPOSITE object).
Example
The hue, saturation and value range parameters may be used for building a variety of pseudo color visualizations of the z values of a point cloud:
// assumptions:
// - pch holds a valid point cloud handle
// - m_cvDisp3D holds the 3D Display control
// produce a rainbow-colored point cloud ranging from blue
// for the lowest z values to red for the highest
m_cvDisp3D.AddPointCloudVariable(reinterpret_cast<intptr_t>(pch),
0.666, 0.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 0);
// produce a monochrome point cloud ranging from black for the
// lowest z values to white for the highest
m_cvDisp3D.AddPointCloudVariable(reinterpret_cast<intptr_t>(pch),
0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 1.0, 1.0, 1.0, 1);

◆ AddPointMarker()

void AddPointMarker ( BSTR  text,
OLE_COLOR  color,
DOUBLE  size,
DOUBLE  opacity,
LONG  id,
DOUBLE  x,
DOUBLE  y,
DOUBLE  z,
VARIANT_BOOL  reverse 
)

Add a new point marker to the 3D display.

A 'point marker' in the context of the 3D display control is an indicator that is hooked to a specific 3D position and accompanied by (usually short) piece of text to be displayed nearby. Unlike labels (see AddLabel), the display of point markers will be subject to changes in the parameters of the virtual camera, i. e. the text and the indicator will zoom (however, the text will always be upright and facing the camera).

The way AddPointMarker acts depends on the id parameter:

  • when specifying a new (i.e. previously unused) identifier, a new point marker will be added
  • when specifying an id of a point marker that is already in use (i.e. AddPointMarker has already been called to generate a point marker with that particular id) then the existing point marker will be modified using the parameters provided in the AddPointMarker call.

Note that ids are handled separately for different types of display objects: A 3D display may simultaneously contain a label with id 0 (see AddLabel), a point cloud with id 0 (see AddPointCloudSolid) and a point marker with id 0 (see AddPointMarker).

Attention
Ids have to be positive numbers. When specifying a value below zero this function will not do anything.
Parameters
[in]textText to be displayed with the marker.
[in]colorColor to be used for displaying the label overlay. Color is specified using OLE_COLOR convention, meaning that it should be provided as an integer value where the lowest 8 bits represent the red channel's intensity, bits 8 to 15 represent the green channel's intensity and bits 16 to 23 represent the blue channel's intensity. The uppermost 8 bits are not evaluated and should be set to zero (in MFC applications the easiest way to build such a color value is to use the RGB(r, g, b) macro).
[in]sizeSize (in 3D units) of the text to be shown.
[in]opacityOpacity of the text overlay when rendering. Specifying a value of 1.0 will make the overlay completely opaque, a value of 0.0 will make the overlay completely transparent.
[in]idNumerical identified by which the text overlay can later on be accessed (e.g. in RemoveLabel or in another AddLabel call).
[in]x3D position of the marker.
[in]y3D position of the marker.
[in]z3D position of the marker.
[in]reverseWhen set to FALSE, the line connecting the indicator's hook point with the indicator's text will bend in the direction of the positive z axis, when set to TRUE the line will bend in the direction of the negative z axis instead.

◆ GetCoordinateAxesId()

LONG GetCoordinateAxesId ( LONG  coordinateAxesNumber)

Retrieve the id of the n-th coordinate indicator.

Object ids for coordinate indicators may be arbitrary and non-continuous integer numbers. In cases where it is necessary to iterate over all coordinate indicators (or a subset thereof) GetCoordinateAxesId together with NumCoordinateAxes allows this to happen as it converts cardinal numbers into object ids.

For details about coordinate indicators please refer to AddCoordinateAxes.

Parameters
[in]coordinateAxesNumberCardinal number of the coordinate indicator to be accessed.
Returns
Id of coordinate indicator (or -‭1 if coordinateAxesNumber was less than 0 or greater than NumCoordinateAxes.

◆ GetLabelId()

LONG GetLabelId ( LONG  labelNumber)

Retrieve the id of the n-th label overlay.

Object ids for labels may be arbitrary and non-continuous integer numbers. In cases where it is necessary to iterate over all label overlays (or a subset thereof) GetLabelId together with NumLabels allows this to happen as it converts cardinal numbers into object ids.

For details on label overlays please refer to AddLabel.

Parameters
[in]labelNumberCardinal number of the label to be accessed.
Returns
Label id (or -‭1 if labelNumber was less than 0 or greater than NumLabels.

◆ GetPointCloud()

LONGLONG GetPointCloud ( LONG  id)

Retrieve the handle of a point cloud that is currently being displayed.

Note that it is advisable to use ShareObject and ReleaseObject to manage the lifetime of the object referred to by the retrieved handle if the handle is being relied on for an extended period of time.

Parameters
[in]idId of the point cloud object that is currently being displayed.
Returns
CVCOMPOSITE handle of the point cloud object or nullptr if the specified id was invalid.

◆ GetPointCloudColor()

OLE_COLOR GetPointCloudColor ( LONG  id)

Retrieves the currently used rendering color for a point cloud.

If the point cloud is not in solid coloring mode (see GetPointCloudVisualizationMode) then -1 will be returned.

Parameters
[in]idId of the point cloud for which to retrieve the color. If no valid id is given here, the function will return -1.
Returns
Currently used color or -1 if no color could be retrieved. Color is specified using OLE_COLOR convention, meaning that it should be provided as an integer value where the lowest 8 bits represent the red channel's intensity, bits 8 to 15 represent the green channel's intensity and bits 16 to 23 represent the blue channel's intensity.

◆ GetPointCloudId()

LONG GetPointCloudId ( LONG  pointCloudNumber)

Retrieve the id of the n-th point cloud.

Object ids for point clouds may be arbitrary and non-continuous integer numbers. In cases where it is necessary to iterate over all point clouds (or a subset thereof) GetPointCloudId together with NumPointClouds allows this to happen as it converts cardinal numbers into object ids.

For details on point clouds please refer to AddPointCloudSolid.

Parameters
[in]pointCloudNumberCardinal number of the point marker to be accessed.
Returns
Point cloud id (or -‭1 if pointCloudNumber was less than 0 or greater than NumPointClouds.

◆ GetPointCloudLineWidth()

DOUBLE GetPointCloudLineWidth ( LONG  id)

Retrieves the currently used line width for a point cloud.

Parameters
[in]idId of the point cloud for which to retrieve the value. If no valid id is given here, the function will return -1.
Returns
Currently used value or -1 if no value could be retrieved.

◆ GetPointCloudLutRanges()

VARIANT_BOOL GetPointCloudLutRanges ( LONG  id,
DOUBLE *  hueMin,
DOUBLE *  hueMax,
DOUBLE *  saturationMin,
DOUBLE *  saturationMax,
DOUBLE *  valueMin,
DOUBLE *  valueMax 
)

Query the current LUT parameters for point cloud visualization.

For a description of color range visualization see AddPointCloudVariable. If the point cloud is not in color range mode (see GetPointCloudVisualizationMode) the returned values will all be 0.0.

Parameters
[in]idId of the point cloud to be queried.
[in]hueMinCurrent hue value assigned to the lowest z value. Value hue values are in the range [0...1] and are organized in a circle that starts (0.0) and ends (1.0) at the color red and cycles through yellow, green, cyan, blue and magenta in order of incrementing values.
[in]hueMaxCurrent hue value assigned to the highest z value. Value hue values are in the range [0...1] and are organized in a circle that starts (0.0) and ends (1.0) at the color red and cycles through yellow, green, cyan, blue and magenta in order of incrementing values.
[in]saturationMinCurrent saturation value assigned to the lowest z value. Saturation Values are in the range [0...1] with 0.0 indicating completely unsaturated colors (i.e. gray scale) and 1.0 indicating fully saturated colors.
[in]saturationMaxCurrent saturation value assigned to the highest z value. Saturation Values are in the range [0...1] with 0.0 indicating completely unsaturated colors (i.e. gray scale) and 1.0 indicating fully saturated colors.
[in]valueMinCurrent intensity value assigned to the lowest z value. Intensity values are in the range [0...1].
[in]valueMaxCurrent intensity value assigned to the highest z value. Intensity values are in the range [0...1].
Returns
TRUE if the LUT parameters were queried successfully FALSE otherwise (most likely because of an invalid id parameter).

◆ GetPointCloudOpacity()

DOUBLE GetPointCloudOpacity ( LONG  id)

Retrieves the currently used opacity for a point cloud.

Parameters
[in]idId of the point cloud for which to retrieve the value. If no valid id is given here, the function will return -1.
Returns
Currently used value or -1 if no value could be retrieved.

◆ GetPointCloudPointSize()

DOUBLE GetPointCloudPointSize ( LONG  id)

Retrieves the currently used point size for a point cloud.

Parameters
[in]idId of the point cloud for which to retrieve the value. If no valid id is given here, the function will return -1.
Returns
Currently used value or -1 if no value could be retrieved.

◆ GetPointCloudVisualizationMode()

enum Core3DViewerVisualizationMode GetPointCloudVisualizationMode ( LONG  id)

Queries the current visualization mode of the referenced point cloud.

Depending on how a point cloud was created (AddPointCloudSolid or AddPointCloudVariable) or the function SetPointCloudColor or SetPointCloudLutRanges was the most recently called function the point cloud may currently either use solid coloring or a color range.

Parameters
[in]idId of the point cloud for which to query the current state.
Returns
Current visualization state. VisualizationUndefined if the input id does not refer to a currently visible point cloud.

◆ GetPointMarkerId()

LONG GetPointMarkerId ( LONG  pointMarkerNumber)

Retrieve the id of the n-th point marker.

Object ids for point markers may be arbitrary and non-continuous integer numbers. In cases where it is necessary to iterate over all point markers (or a subset thereof) GetPointMarkerId together with NumPointMarkers allows this to happen as it converts cardinal numbers into object ids.

For details on point markers please refer to AddPointMarker.

Parameters
[in]pointMarkerNumberCardinal number of the point marker to be accessed.
Returns
Point marker id (or -‭1 if pointMarkerNumber was less than 0 or greater than NumPointMarkers.

◆ GetSelectedVolume()

VARIANT_BOOL GetSelectedVolume ( DOUBLE *  xmin,
DOUBLE *  xmax,
DOUBLE *  ymin,
DOUBLE *  ymax,
DOUBLE *  zmin,
DOUBLE *  zmax 
)

Retrieve the current extent in x, y and z direction of the volume of interest selector.

Note that if the selector is currently not being displayed (i.e. if ShowSelectorBox is set to FALSE) the function will return FALSE and not modify the content of the call parameters.

Parameters
[out]xminExtent in x direction.
[out]xmaxExtent in x direction.
[out]yminExtent in y direction.
[out]ymaxExtent in y direction.
[out]zminExtent in z direction.
[out]zmaxExtent in z direction.
Returns
TRUE when values were successfully retrieved, FALSE otherwise (in this case the parameter values will not have been modified).

◆ HasLabel()

VARIANT_BOOL HasLabel ( LONG  id)

Check if a label with the given id exists.

For details about label overlays please refer to AddLabel.

Parameters
[in]idId to be checked for.
Returns
TRUE if a label has already been added under the specified id, FALSE otherwise.

◆ HasPointCloud()

VARIANT_BOOL HasPointCloud ( LONG  id)

Check if a point cloud with the given id exists.

For details about point clouds please refer to AddPointCloudSolid.

Parameters
[in]idId to be checked for.
Returns
TRUE if a point cloud has already been added under the specified id, FALSE otherwise.

◆ HasPointMarker()

VARIANT_BOOL HasPointMarker ( LONG  id)

Check if a point marker with the given id exists.

For details about point markers please refer to AddPointMarker.

Parameters
[in]idId to be checked for.
Returns
TRUE if a point marker has already been added under the specified id, FALSE otherwise.

◆ RemoveAllCoordinateAxes()

void RemoveAllCoordinateAxes ( )

Remove all coordinate indicators from the 3D display.

For details about coordinate indicators please refer to AddCoordinateAxes.

◆ RemoveAllLabels()

void RemoveAllLabels ( )

Remove all currently visible label overlays from the 3D display.

For details about label overlays please refer to AddLabel.

◆ RemoveAllObjects()

void RemoveAllObjects ( )

Remove all currently visible objects from the 3D display.

Calling this function has the same effect as calling RemoveAllLabels, RemoveAllPointClouds and RemoveAllPointMarkers in any order.

◆ RemoveAllPointClouds()

void RemoveAllPointClouds ( )

Remove all currently visible point clouds from the 3D display.

For details about label overlays please refer to AddPointCloudSolid.

◆ RemoveAllPointMarkers()

void RemoveAllPointMarkers ( )

Remove all currently visible point markers from the 3D display.

For details about label overlays please refer to AddPointMarker.

◆ RemoveCoordinateAxes()

void RemoveCoordinateAxes ( LONG  id)

Remove a coordinate indicator from the 3D display.

For details about coordinate indicators please refer to AddCoordinateAxes.

Parameters
[in]idId of the coordinate indicator to be removed. When specifying an invalid id here nothing will happen.

◆ RemoveLabel()

void RemoveLabel ( LONG  id)

Remove a label overlay from the 3D display.

For details about label overlays please refer to AddLabel.

Parameters
[in]idId of the label to be removed. When specifying an invalid id here nothing will happen.

◆ RemovePointCloud()

void RemovePointCloud ( LONG  id)

Remove a point cloud from the 3D display.

For details about point clouds please refer to AddPointCloudSolid.

Parameters
[in]idId of the point cloud to be removed. When specifying an invalid id here nothing will happen.

◆ RemovePointMarker()

void RemovePointMarker ( LONG  id)

Remove a point marker from the 3D display.

For details about point markers please refer to AddPointMarker.

Parameters
[in]idId of the point marker to be removed. When specifying an invalid id here nothing will happen.

◆ RenderWindowToImage()

LONGLONG RenderWindowToImage ( )

Take a snapshot of the current 3D display render window.

Takes a snapshot of the current 3D display and stores it in a CVB image object.

Returns
Handle to the CVB image object holding the snapshot of the 3D render window. Once this image is no longer needed it must be released by means of a call to ReleaseObject.

◆ ResetCamera()

void ResetCamera ( )

Auto-align the camera parameters taking account the currently visible objects.

This call will cause the virtual camera to be repositioned to view the center of the actors and move the camera along its resulting viewing direction so that all the currently added objects can be seen.

◆ SetBackground()

void SetBackground ( OLE_COLOR  color)

Set the background color of the 3D viewer to a solid color.

The viewer's background can be set to either a solid color or a gradient color scheme, i.e. the background color varies smoothly from bottom to top of the 3D viewer. This command sets the background to the specified solid color.

Parameters
[in]colorColor to be used for background coloring. Color is specified using OLE_COLOR convention.

◆ SetBackgroundGradient()

void SetBackgroundGradient ( OLE_COLOR  color1,
OLE_COLOR  color2 
)

Set the background of the 3D viewer to a gradient color scheme.

The viewer's background can be set to either a solid color or a gradient color scheme, i.e. the background color varies smoothly from bottom to top of the 3D viewer. This command sets the viewer's background to a gradient coloring scheme.

Parameters
[in]color1to be used as the color at the bottom part of the 3D viewer. Color is specified using OLE_COLOR convention.
[in]color2to be used as the color at the top part of the 3D viewer. Color is specified using OLE_COLOR convention.

◆ SetCameraAzimuth()

void SetCameraAzimuth ( DOUBLE  angle)

Rotate the camera horizontally.

The center or rotation is the focal point and the rotation is carried out around the view "up" vector's direction.

Parameters
[in]angleAngle (in degrees) by which to rotate.

◆ SetCameraElevation()

void SetCameraElevation ( DOUBLE  angle)

Rotate the camera in the up/down direction.

Technically speaking, the camera is rotated around the cross product of the negative viewing direction vector and the view's "up" vector. The center of rotation is the focal point of the camera.

Parameters
[in]angleAngle (in degrees) by which to rotate.

◆ SetCameraRoll()

void SetCameraRoll ( DOUBLE  angle)

Rotate the camera around the viewing direction.

Parameters
[in]angleAngle (in degrees) by which to rotate.

◆ SetCameraZoom()

void SetCameraZoom ( DOUBLE  factor)

Modify the viewing angle.

Modifies the virtual camera's current viewing angle by multiplying it with the specified factor. Increasing the viewing angle (by specifying zoom factors greater than one) will give the impression of zooming out of the scene while decreasing the viewing angle (by specifying zoom factors smaller than one) will give the impression of zooming into the scene.

Parameters
[in]factorFactor with which to multiply the currently set viewing angle.

◆ SetPointCloudColor()

void SetPointCloudColor ( LONG  id,
OLE_COLOR  color 
)

Sets a rendering color for a point cloud and change the visualization mode to solid coloring.

See also AddPointCloudSolid for a description.

Parameters
[in]idId of the point cloud for which to set the color. If no valid id is given here, the call will have no effect.
[in]colorColor to be used for displaying the label overlay. Color is specified using OLE_COLOR convention, meaning that it should be provided as an integer value where the lowest 8 bits represent the red channel's intensity, bits 8 to 15 represent the green channel's intensity and bits 16 to 23 represent the blue channel's intensity. The uppermost 8 bits are not evaluated and should be set to zero (in MFC applications the easiest way to build such a color value is to use the RGB(r, g, b) macro).

◆ SetPointCloudLineWidth()

void SetPointCloudLineWidth ( LONG  id,
DOUBLE  lineWidth 
)

Sets the line width for rendering a point cloud.

Parameters
[in]idId of the point cloud for which to set the value. If no valid id is given here, the call will have no effect.
[in]lineWidthLine width to be used when rending the specified point cloud in wireframe mode (in 3D units).

◆ SetPointCloudLutRanges()

VARIANT_BOOL SetPointCloudLutRanges ( LONG  id,
DOUBLE  hueMin,
DOUBLE  hueMax,
DOUBLE  saturationMin,
DOUBLE  saturationMax,
DOUBLE  valueMin,
DOUBLE  valueMax 
)

Change the point cloud visualization mode to color range and/or redefine the lookup-tables.

For a description of color range visualization see AddPointCloudVariable.

Parameters
[in]idId of the point cloud to be modified.
[in]hueMinHue value to be assigned to the lowest z value. Value hue values are in the range [0...1] and are organized in a circle that starts (0.0) and ends (1.0) at the color red and cycles through yellow, green, cyan, blue and magenta in order of incrementing values.
[in]hueMaxHue value to be assigned to the highest z value. Value hue values are in the range [0...1] and are organized in a circle that starts (0.0) and ends (1.0) at the color red and cycles through yellow, green, cyan, blue and magenta in order of incrementing values.
[in]saturationMinSaturation value to be assigned to the lowest z value. Saturation Values are in the range [0...1] with 0.0 indicating completely unsaturated colors (i.e. gray scale) and 1.0 indicating fully saturated colors.
[in]saturationMaxSaturation value to be assigned to the highest z value. Saturation Values are in the range [0...1] with 0.0 indicating completely unsaturated colors (i.e. gray scale) and 1.0 indicating fully saturated colors.
[in]valueMinIntensity value to be assigned to the lowest z value. Intensity values are in the range [0...1].
[in]valueMaxIntensity value to be assigned to the highest z value. Intensity values are in the range [0...1].
Returns
TRUE if the point cloud visualization was changed, FALSE otherwise.

◆ SetPointCloudOpacity()

void SetPointCloudOpacity ( LONG  id,
DOUBLE  opacity 
)

Sets the opacity for rendering a point cloud.

Parameters
[in]idId of the point cloud for which to set the value. If no valid id is given here, the call will have no effect.
[in]opacityOpacity of the point cloud when rendering. Specifying a value of 1.0 will make the overlay completely opaque, a value of 0.0 will make the overlay completely transparent.

◆ SetPointCloudPointSize()

void SetPointCloudPointSize ( LONG  id,
DOUBLE  pointSize 
)

Sets the point size for rendering a point cloud.

Parameters
[in]idId of the point cloud for which to set the value. If no valid id is given here, the call will have no effect.
[in]pointSizePoint size to be used when rending the specified point cloud (in 3D units).