scenepic 1.1.0
3D Visualization Made Easy
Public Member Functions | Static Public Attributes | List of all members
scenepic::LayerSettings Class Reference

Settings used for customizing canvas drawing by layer. More...

#include <layer_settings.h>

Public Member Functions

 LayerSettings (bool filled=true, bool wireframe=false, double opacity=1.0, int render_order=LayerSettings::NO_RENDER_ORDER)
 Constructor. More...
 
bool filled () const
 Specifies whether to draw the layer with filled triangles. More...
 
LayerSettingsfilled (bool value)
 Specifies whether to draw the layer with filled triangles. More...
 
bool wireframe () const
 Specifies whether to draw the layer with a wireframe outline. More...
 
LayerSettingswireframe (bool value)
 Specifies whether to draw the layer with a wireframe outline. More...
 
double opacity () const
 In [0,1] specifies the opacity with which to draw the layer. More...
 
LayerSettingsopacity (double value)
 In [0,1] specifies the opacity with which to draw the layer. More...
 
int render_order () const
 Specifies a fixed order to draw transparency. More...
 
LayerSettingsrender_order (int value)
 Specifies a fixed order to draw transparency. More...
 
std::string to_string () const
 Return a JSON string representing the object. More...
 
JsonValue to_json () const
 Convert this object into ScenePic json. More...
 

Static Public Attributes

static const int NO_RENDER_ORDER
 Special value indicating that this layer has no specific rendering order. More...
 

Detailed Description

Settings used for customizing canvas drawing by layer.

Constructor & Destructor Documentation

◆ LayerSettings()

scenepic::LayerSettings::LayerSettings ( bool  filled = true,
bool  wireframe = false,
double  opacity = 1.0,
int  render_order = LayerSettings::NO_RENDER_ORDER 
)

Constructor.

Parameters
render_orderWhere in the transparency order to draw this layer
filledwhether to draw the layer with filled polygons
wireframewhether to draw the layer with a frame outline
opacitythe opacity with which to draw the layer

Member Function Documentation

◆ filled() [1/2]

bool scenepic::LayerSettings::filled ( ) const

Specifies whether to draw the layer with filled triangles.

◆ filled() [2/2]

LayerSettings & scenepic::LayerSettings::filled ( bool  value)

Specifies whether to draw the layer with filled triangles.

◆ opacity() [1/2]

double scenepic::LayerSettings::opacity ( ) const

In [0,1] specifies the opacity with which to draw the layer.

◆ opacity() [2/2]

LayerSettings & scenepic::LayerSettings::opacity ( double  value)

In [0,1] specifies the opacity with which to draw the layer.

◆ render_order() [1/2]

int scenepic::LayerSettings::render_order ( ) const

Specifies a fixed order to draw transparency.

◆ render_order() [2/2]

LayerSettings & scenepic::LayerSettings::render_order ( int  value)

Specifies a fixed order to draw transparency.

◆ to_json()

JsonValue scenepic::LayerSettings::to_json ( ) const

Convert this object into ScenePic json.

Returns
a json value

◆ to_string()

std::string scenepic::LayerSettings::to_string ( ) const

Return a JSON string representing the object.

◆ wireframe() [1/2]

bool scenepic::LayerSettings::wireframe ( ) const

Specifies whether to draw the layer with a wireframe outline.

◆ wireframe() [2/2]

LayerSettings & scenepic::LayerSettings::wireframe ( bool  value)

Specifies whether to draw the layer with a wireframe outline.

Member Data Documentation

◆ NO_RENDER_ORDER

const int scenepic::LayerSettings::NO_RENDER_ORDER
static

Special value indicating that this layer has no specific rendering order.


The documentation for this class was generated from the following file: