Class SBDVisualPreset#
The SBDVisualPreset class is a base class for visual preset.More...
#include <SBDVisualPreset.hpp>
Public Functions#
Type | Name |
---|---|
SBDVisualPreset (const std::string & name, const std::vector< SBDVisualPresetStep * > & visualPresetSteps=std::vector< SBDVisualPresetStep * >()) Constructor that does a deep copy of the vector of visual preset steps, i.e. it clones visual preset steps. |
|
SBDVisualPreset (const std::string & name, std::vector< SBDVisualPresetStep * > && visualPresetSteps) noexcept Constructor taking the vector of visual preset steps by move. |
|
SBDVisualPreset (const SBDVisualPreset & other) Copy constructor. |
|
SBDVisualPreset (SBDVisualPreset && other) noexcept Move constructor. |
|
SB_DECLARE_DATA (SBDVisualPreset) |
|
void | addVisualPresetStep (const SBDVisualPresetStep & visualPresetStep) Adds the cloned visual preset step visualPresetStep to this visual preset. |
void | apply (SBNodeIndexer & nodeIndexer, SBFolder * preferredFolder=nullptr) Applies the visual preset to nodes in nodeIndexer and adds the node groups and visual models (if any) topreferredFolder . |
virtual SBDVisualPreset * | clone () const Clones the visual preset. |
void | deleteVisualPresetStep (int index) Deletes the visual preset step with index index from the visual preset. |
void | deleteVisualPresetStep (SBDVisualPresetStep * visualPresetStep) Removes the visual preset step visualPresetStep from the visual preset if it has any, and, if found, deletes the visual preset stepvisualPresetStep . |
const std::string & | getName () const Returns the name of the visual preset. |
int | getNumberOfVisualPresetSteps () const Returns the number of visual preset steps. |
const std::vector< SBDVisualPresetStep * > & | getVisualPresetSteps () const Returns the vector of visual preset steps. |
bool | operator!= (const SBDVisualPreset & other) const |
SBDVisualPreset & | operator= (const SBDVisualPreset & other) Copy assignment operator. |
SBDVisualPreset & | operator= (SBDVisualPreset && other) noexcept Move assignment operator. |
bool | operator== (const SBDVisualPreset & other) const |
void | setName (const std::string & name) Sets the name of the visual preset to name . |
void | swap (int i, int j) Swaps visual preset steps i andj . |
virtual std::string | toPythonCode () const Returns the string representation of the object that can be used to reconstruct it in Python. |
virtual | ~SBDVisualPreset () |
Public Static Functions#
Type | Name |
---|---|
const std::vector< const SBDVisualPreset * > * | getDefaultVisualPresets () Returns a vector of the default visual presets. |
Protected Attributes#
Type | Name |
---|---|
SBDVisualPresetData * | dataPointer |
Detailed Description#
Short name: SBVisualPreset
Public Functions Documentation#
function SBDVisualPreset [1/4]#
Constructor that does a deep copy of the vector of visual preset steps, i.e. it clones visual preset steps.
SBDVisualPreset::SBDVisualPreset (
const std::string & name,
const std::vector< SBDVisualPresetStep * > & visualPresetSteps=std::vector< SBDVisualPresetStep * >()
)
function SBDVisualPreset [2/4]#
Constructor taking the vector of visual preset steps by move.
SBDVisualPreset::SBDVisualPreset (
const std::string & name,
std::vector< SBDVisualPresetStep * > && visualPresetSteps
) noexcept
function SBDVisualPreset [3/4]#
Copy constructor.
function SBDVisualPreset [4/4]#
Move constructor.
function SB_DECLARE_DATA#
function addVisualPresetStep#
Adds the cloned visual preset step visualPresetStep
to this visual preset.
function apply#
Applies the visual preset to nodes in nodeIndexer
and adds the node groups and visual models (if any) topreferredFolder
.
function clone#
Clones the visual preset.
function deleteVisualPresetStep [1/2]#
Deletes the visual preset step with index index
from the visual preset.
function deleteVisualPresetStep [2/2]#
Removes the visual preset step visualPresetStep
from the visual preset if it has any, and, if found, deletes the visual preset stepvisualPresetStep
.
function getName#
Returns the name of the visual preset.
function getNumberOfVisualPresetSteps#
Returns the number of visual preset steps.
function getVisualPresetSteps#
Returns the vector of visual preset steps.
function operator!=#
function operator=#
Copy assignment operator.
function operator=#
Move assignment operator.
function operator==#
function setName#
Sets the name of the visual preset to name
.
function swap#
Swaps visual preset steps i
andj
.
function toPythonCode#
Returns the string representation of the object that can be used to reconstruct it in Python.
function ~SBDVisualPreset#
Public Static Functions Documentation#
function getDefaultVisualPresets#
Returns a vector of the default visual presets.