![]() |
SCENE C++ API
2.1.2
|
Container collecting settings for the LSView3d class. More...
#include <lsview3dsettings.h>
Public Types | |
enum | PointColoring { NoColoring, CoordinateColoringDistance, CoordinateColoringX, CoordinateColoringY, CoordinateColoringZ, CoordinateColoringXYZ, NormalVectors } |
Various screen-space coloring effects. More... | |
enum | PostProcess { NoPostProcess, ClearView, GapFilling } |
Post-processing shader effects. More... | |
enum | Shading { NoShading, LightShading, StrongShading } |
Colors in the 3d view are manipulated so that areas around corners appear highlighted This achieves a clearer view of the geometry. More... | |
enum | PointSizeMode { Adaptive, Fixed } |
Manipulates the size of points shown in the 3d view. More... | |
enum | SuperSampling { NoSuperSampling, SuperSampling2x2, SuperSampling3x3, SuperSampling4x4 } |
Effect that achieves better image quality by drawing in a higher resolution than the one suggested by the the 3d view window and scaling back to the original resolution. More... | |
enum | ApplyShadingTo { Points, Meshes, Both } |
Restricts what types of objects Shading is applied to. More... | |
enum | ColorMap { Rainbow, ColdHot, Linear } |
Defines what type of colors will be used to display the PointColoring effect. More... | |
Public Member Functions | |
LSResult::Result | setSuperSampling (const SuperSampling mode) |
Sets the mode of SuperSampling to be used in the view. More... | |
SuperSampling | getSuperSampling () const |
Gets the mode of SuperSampling of the settings. More... | |
LSResult::Result | setPointSizeMode (const PointSizeMode mode) |
Sets the mode for the size of points to be rendered in the view. More... | |
PointSizeMode | getPointSizeMode () const |
Gets the mode for the size of points to be rendered in the view. More... | |
LSResult::Result | setFixedPointSize (const unsigned int pixels) |
Sets the fixed point size. More... | |
unsigned int | getFixedPointSize () const |
Gets the fixed point size. More... | |
LSResult::Result | setAdaptivePointSize (const float meters) |
Sets the adaptive point size. More... | |
float | getAdaptivePointSize () const |
Gets the adaptive point size. More... | |
LSResult::Result | setPointColoring (const PointColoring mode) |
Sets the mode of PointColoring to be used in the view. More... | |
PointColoring | getPointColoring () const |
Gets the PointColoring setting. More... | |
LSResult::Result | setColoringRangeMin (const Eigen::Vector4d &min) |
Sets the lower bound of the ranges used by the PointColoring effects. More... | |
Eigen::Vector4d | getColoringRangeMin () const |
Gets the lower bound of the ranges used by the PointColoring effects. More... | |
LSResult::Result | setColoringRangeMax (const Eigen::Vector4d &max) |
Sets the upper bound of the ranges used by the PointColoring effects. More... | |
Eigen::Vector4d | getColoringRangeMax () const |
Gets the upper bound of the ranges used by the coloring effects. More... | |
LSResult::Result | setBlendColoringWithPointColors (const bool blendColoringWithPointColorsEnabled) |
Enables coloring effects to be blended with point colors. More... | |
bool | getBlendColoringWithPointColors () const |
Gets whether the setting to blend coloring effects with point colors is enabled or not. More... | |
LSResult::Result | setReferenceOrigin (const Eigen::Vector3d &origin) |
Sets the origin used in coordinate coloring. More... | |
Eigen::Vector3d | getReferenceOrigin () const |
Sets the origin used in coordinate PointColoring. More... | |
LSResult::Result | setReferencePose (const Eigen::Matrix4f &pose) |
Sets the orientation of the colorization. More... | |
Eigen::Matrix4f | getReferencePose () const |
Gets the orientation of the colorization. More... | |
LSResult::Result | setDiscreteColors (const bool discreteColorsEnabled) |
Enables/disables the discrete option for the coordinate colorization. More... | |
bool | getDiscreteColors () const |
Gets whether the discrete option is enabled for the coordinate colorization. More... | |
LSResult::Result | setNumOfDiscreteColors (const unsigned int numOfColors) |
Sets the number of intervals used for coordinate colorization. More... | |
unsigned int | getNumOfDiscreteColors () const |
Gets the number of intervals used in PointColoring. More... | |
LSResult::Result | setColorMap (const ColorMap mode) |
Sets the type of ColorMap that will be used in colorization. More... | |
ColorMap | getColorMap () const |
Gets the type of ColorMap used in PointColoring effects. More... | |
LSResult::Result | setCalculateDistanceFromCamera (const bool distanceFromCamera) |
Sets the setting for the origin for the mode PointColoring::CoordinateColoringDistance Setting this to true will use the camera as the origin from which the distance is calculated. More... | |
bool | getCalculateDistanceFromCamera () const |
Gets the setting for the origin for the mode PointColoring::CoordinateColoringDistance If this value is true the mode PointColoring::CoordinateColoringDistance will use the camera as the origin from which the distance is calculated. More... | |
LSResult::Result | setShading (const Shading mode) |
Sets the mode of Shading to be used in the view. More... | |
Shading | getShading () const |
Gets the mode of Shading used in the view. More... | |
LSResult::Result | setApplyShadingTo (const ApplyShadingTo mode) |
If any shading effect is enabled this will set whether this is applied to meshes, points, or both Default value is ApplyShadingTo::Both. More... | |
ApplyShadingTo | getApplyShadingTo () const |
Gets what type of objects Shading effects are applied to Default value is ApplyShadingTo::Both. More... | |
LSResult::Result | setShadingStrength (const uint8_t shadingStrength) |
Sets the shading strength setting used by shading effects Pass a value from 1 (small effect) to 5 (intense effect). More... | |
uint8_t | getShadingStrength () const |
Gets the shading strength setting used by Shading effects. More... | |
LSResult::Result | setPostProcess (const PostProcess mode) |
Enables a post-process effect for the view, e.g. More... | |
PostProcess | getPostProcess () const |
Gets the PostProcess setting. More... | |
LSResult::Result | setTransparencyFactor (const float factor) |
Sets the transparency factor for clear view rendering. More... | |
float | getTransparencyFactor () const |
Gets the transparency factor for clear view rendering. More... | |
![]() | |
LSString | getTypeName () const |
Gets the type name of this instance. More... | |
LSString | getName () const |
Gets the name of the container. More... | |
LSResult::Result | setName (LSString name) |
Sets the name of the container. More... | |
LSString | getUuid () const |
Returns the unique id of the container. More... | |
LSString | assignUuid () |
Assigns a unique id to the container if the container does not not yet have a unique id. More... | |
unsigned int | getNumAttributes () const |
Get the number of attributes in the container. More... | |
LSString | getAttributeName (unsigned int index) const |
Get the name of an attribute in the container. More... | |
unsigned int | getAttributeIndex (LSString name) const |
Get the index of an attribute in the container. More... | |
LSAttribute | getAttribute (unsigned int index) const |
Get an attribute based on its index. More... | |
LSAttribute | getAttribute (LSString name) const |
Get an attribute based on its name. More... | |
LSResult::Result | setAttribute (unsigned int index, const LSAttribute &attribute) |
Set an attribute based on its index. More... | |
LSResult::Result | setAttribute (LSString name, const LSAttribute &attribute) |
Set an attribute based on its name. More... | |
LSResult::Result | addCustomAttribute (LSString name, const LSAttribute &attribute) |
Add a new custom attribute to the container. More... | |
bool | removeCustomAttribute (LSString name) |
Remove a custom attribute from the container. More... | |
unsigned int | getNumFields () const |
Returns the number of fields in the container. More... | |
ref_ptr< LSAttributeContainer > | getField (unsigned int index) const |
Returns the field at position n in the container. More... | |
ref_ptr< LSAttributeContainer > | getField (const LSString &name) const |
Returns the field with the given name. More... | |
LSResult::Result | addField (const LSString &name, const LSString &typeName, ref_ptr< LSAttributeContainer > &fieldOut) |
Add a field to the container. More... | |
bool | rmField (const LSString &name) |
Removes the field with a given name from the container. More... | |
Static Public Member Functions | |
static ref_ptr< LSView3dSettings > | create () |
Additional Inherited Members | |
![]() | |
void | ref () const |
Increments the internal reference counter. More... | |
void | unref () const |
Decrements the internal reference counter. More... | |
Container collecting settings for the LSView3d class.
|
strong |
Various screen-space coloring effects.
|
strong |
|
strong |
Colors in the 3d view are manipulated so that areas around corners appear highlighted This achieves a clearer view of the geometry.
Enumerator | |
---|---|
NoShading | The effect is disabled. |
LightShading | The |
StrongShading | The |
|
strong |
|
strong |
Effect that achieves better image quality by drawing in a higher resolution than the one suggested by the the 3d view window and scaling back to the original resolution.
|
strong |
|
strong |
|
static |
LSResult::Result setSuperSampling | ( | const SuperSampling | mode | ) |
Sets the mode of SuperSampling to be used in the view.
To turn supersampling off pass SuperSampling::NoSuperSampling here. Default value is SuperSampling::NoSuperSampling
SuperSampling getSuperSampling | ( | ) | const |
Gets the mode of SuperSampling of the settings.
Default value is SuperSampling::NoSuperSampling
LSResult::Result setPointSizeMode | ( | const PointSizeMode | mode | ) |
Sets the mode for the size of points to be rendered in the view.
Default value is PointSizeMode::Adaptive
PointSizeMode getPointSizeMode | ( | ) | const |
Gets the mode for the size of points to be rendered in the view.
Default value is PointSizeMode::Adaptive
LSResult::Result setFixedPointSize | ( | const unsigned int | pixels | ) |
Sets the fixed point size.
The value represents the pixel size, and should be between 1px and 10px. If the value is not within this range, it will be clamped. Default value is 1.
unsigned int getFixedPointSize | ( | ) | const |
Gets the fixed point size.
Default value is 1.
LSResult::Result setAdaptivePointSize | ( | const float | meters | ) |
Sets the adaptive point size.
The value represents size in meters, and should be between 0.001 m and 0.02 m. If the value is not within this range, it will be clamped. Default value is 0.003 m.
float getAdaptivePointSize | ( | ) | const |
Gets the adaptive point size.
Default value is 0.003 m.
LSResult::Result setPointColoring | ( | const PointColoring | mode | ) |
Sets the mode of PointColoring to be used in the view.
To turn this effect off simply pass PointColoring::NoColoring here. Default value is PointColoring::NoColoring
PointColoring getPointColoring | ( | ) | const |
Gets the PointColoring setting.
Default value is PointColoring::NoColoring
LSResult::Result setColoringRangeMin | ( | const Eigen::Vector4d & | min | ) |
Sets the lower bound of the ranges used by the PointColoring effects.
Any coordinate coloring effect will use this value to calculate the lower limit of its ranges. These values don't represent actual coordinates, but rather offsets from the point returned by getReferenceOrigin().
min.x corresponds to the x cartesian coordinate. This value will be added to the ReferenceOrigin.x to determine the x coordinate where the coloring will start. min.y corresponds to the y cartesian coordinate. This value will be added to the ReferenceOrigin.y to determine the y coordinate where the coloring will start. min.z corresponds to the z cartesian coordinate. This value will be added to the ReferenceOrigin.z to determine the z coordinate where the coloring will start. min.w corresponds to the minimum distance used in PointColoring::CoordinateColoringDistance.
Default value is (0,0,0,0)
Eigen::Vector4d getColoringRangeMin | ( | ) | const |
Gets the lower bound of the ranges used by the PointColoring effects.
Any coordinate coloring effect will use this value to calculate the lower limit of its ranges.
setColoringRangeMin
Default value is (0,0,0,0)
LSResult::Result setColoringRangeMax | ( | const Eigen::Vector4d & | max | ) |
Sets the upper bound of the ranges used by the PointColoring effects.
Any coordinate coloring effect will use this value to calculate the upper limit of its ranges. These values don't represent actual coordinates, but rather offsets from the point returned by getReferenceOrigin().
max.x corresponds to the x Cartesian coordinate. This value will be added to the ReferenceOrigin.x to determine the x coordinate where the coloring will end. max.y corresponds to the y Cartesian coordinate. This value will be added to the ReferenceOrigin.y to determine the y coordinate where the coloring will end. min.z corresponds to the z Cartesian coordinate. This value will be added to the ReferenceOrigin.z to determine the z coordinate where the coloring will end. This number needs to be positive. min.w corresponds to the maximum distance used in PointColoring::CoordinateColoringDistance. Default value is (0,0,0,0)
Eigen::Vector4d getColoringRangeMax | ( | ) | const |
Gets the upper bound of the ranges used by the coloring effects.
Any coordinate coloring effect will use this value to calculate the upper limit of its ranges.
setColoringRangeMax
Default value is (0,0,0,0)
LSResult::Result setBlendColoringWithPointColors | ( | const bool | blendColoringWithPointColorsEnabled | ) |
Enables coloring effects to be blended with point colors.
If this is set to false the point colors will be ignored, and only the coloring effect color will be rendered. Default value is true
bool getBlendColoringWithPointColors | ( | ) | const |
Gets whether the setting to blend coloring effects with point colors is enabled or not.
If this is set to false the point colors will be ignored, and only the coloring effect color will be rendered. Default value is true
LSResult::Result setReferenceOrigin | ( | const Eigen::Vector3d & | origin | ) |
Sets the origin used in coordinate coloring.
This setting has no visual effect if the PointColoring setting is disabled in the view. All coordinate coloring effects will calculate their distance from this point. In the case of PointColoring::CoordinateColoringDistance the function getCalculateDistanceFromCamera() should also return false for this coordinate to have any effect. The point passed as a parameter should be in the world coordinate system. Default value is (0,0,0)
Eigen::Vector3d getReferenceOrigin | ( | ) | const |
Sets the origin used in coordinate PointColoring.
This setting has no visual effect if the PointColoring setting is disabled in the view. All coordinate coloring effects will calculate their distance from this point. The point returned is in the world coordinate system.
LSResult::Result setReferencePose | ( | const Eigen::Matrix4f & | pose | ) |
Sets the orientation of the colorization.
This setting has no visual effect if the PointColoring setting is disabled in the view. The user can pass a transformation matrix to set the pose. Usage:
Default value is identity matrix, which would end up in world coordinates.
Eigen::Matrix4f getReferencePose | ( | ) | const |
Gets the orientation of the colorization.
Default value is the identity matrix.
LSResult::Result setDiscreteColors | ( | const bool | discreteColorsEnabled | ) |
Enables/disables the discrete option for the coordinate colorization.
If this setting is on, the view will display the coloring effect in discrete intervals. Set the amount of intervals with setNumOfDiscreteColors(). Default value is false
bool getDiscreteColors | ( | ) | const |
Gets whether the discrete option is enabled for the coordinate colorization.
If this setting is on the view will display the coloring effect in discrete intervals. Default value is false
LSResult::Result setNumOfDiscreteColors | ( | const unsigned int | numOfColors | ) |
Sets the number of intervals used for coordinate colorization.
This setting has no visual effect if the PointColoring setting or the discrete colors setting is disabled in the view. Pass a value in the range [2,50] here. If the value is not within the range, it will be clamped. Default value is 10
unsigned int getNumOfDiscreteColors | ( | ) | const |
Gets the number of intervals used in PointColoring.
Default value is 10
LSResult::Result setColorMap | ( | const ColorMap | mode | ) |
Sets the type of ColorMap that will be used in colorization.
This setting has no visual effect if the PointColoring setting is disabled in the view. Default value is ColorMap::Rainbow
ColorMap getColorMap | ( | ) | const |
Gets the type of ColorMap used in PointColoring effects.
Default value is ColorMap::Rainbow
LSResult::Result setCalculateDistanceFromCamera | ( | const bool | distanceFromCamera | ) |
Sets the setting for the origin for the mode PointColoring::CoordinateColoringDistance Setting this to true will use the camera as the origin from which the distance is calculated.
Otherwise the value returned by getReferenceOrigin() will be used Default value is true
bool getCalculateDistanceFromCamera | ( | ) | const |
Gets the setting for the origin for the mode PointColoring::CoordinateColoringDistance If this value is true the mode PointColoring::CoordinateColoringDistance will use the camera as the origin from which the distance is calculated.
Otherwise the value returned by getReferenceOrigin() will be used. Default value is true
LSResult::Result setShading | ( | const Shading | mode | ) |
Sets the mode of Shading to be used in the view.
To turn shading off pass Shading::NoShading here. Default value is Shading::NoShading
Shading getShading | ( | ) | const |
Gets the mode of Shading used in the view.
Default value is Shading::NoShading
LSResult::Result setApplyShadingTo | ( | const ApplyShadingTo | mode | ) |
If any shading effect is enabled this will set whether this is applied to meshes, points, or both Default value is ApplyShadingTo::Both.
ApplyShadingTo getApplyShadingTo | ( | ) | const |
Gets what type of objects Shading effects are applied to Default value is ApplyShadingTo::Both.
LSResult::Result setShadingStrength | ( | const uint8_t | shadingStrength | ) |
Sets the shading strength setting used by shading effects Pass a value from 1 (small effect) to 5 (intense effect).
In case the value passed here is not within the range [1,5] it will be clamped. Default value is 3
uint8_t getShadingStrength | ( | ) | const |
Gets the shading strength setting used by Shading
effects.
The value returned ranges from 1 (small effect) to 5 (intense effect).
LSResult::Result setPostProcess | ( | const PostProcess | mode | ) |
Enables a post-process effect for the view, e.g.
clear view, gap filling To disable such effects simply call this function with PostProcess::NoPostProcess Default value is PostProcess::NoPostProcess
PostProcess getPostProcess | ( | ) | const |
Gets the PostProcess setting.
Default value is PostProcess::NoPostProcess
LSResult::Result setTransparencyFactor | ( | const float | factor | ) |
Sets the transparency factor for clear view rendering.
Value of 1.0f means max opacity, while value of 0.0 means max transparency. The function accepts any value, but it is clamped in the range [0.0f, 1.0f]. This setting has no visual effect if PostProcess::ClearView is not set. Default value is 0.2f
float getTransparencyFactor | ( | ) | const |
Gets the transparency factor for clear view rendering.
Value of 1.0f means max opacity, while value of 0.0f means max transparency. Default value is 0.2f