Unigine::FieldSpacer Class
Interface for field spacer handling.
To use this class, include the UnigineFieldSpacer.h file.
Unigine::FieldSpacer Class
Members
static int type ()
FieldSpacer type.Return value
FieldSpacer type identifier.static Ptr< FieldSpacer > create (const NodePtr & node)
FieldSpacer constructor.Arguments
- const NodePtr & node - Node smart pointer.
static Ptr< FieldSpacer > create (const FieldPtr & field)
FieldSpacer constructor.Arguments
- const FieldPtr & field - Field smart pointer.
static Ptr< FieldSpacer > create (const vec3 & size)
FieldSpacer constructor.Arguments
- const vec3 & size - A size of the Field Spacer along the X, Y and Z axes in units.
virtual void setEllipse (int ellipse) const =0
Transforms a cubical Field Spacer into an ellipse-shaped one.Arguments
- int ellipse - 1 for the ellipse-shaped Field Spacer, 0 for the cubical one.
virtual int isEllipse () const =0
Returns the size of the Field Spacer.Return value
1 if the Field Spacer is of an ellipse shape; otherwise, 0.virtual void setSize (const vec3 & size) const =0
Sets a size for the Field Spacer.Arguments
- const vec3 & size - A size of the Field Spacer along the X, Y and Z axes in units. If a negative value is provided, 0 will be used instead.
virtual vec3 getSize () const =0
Returns the size of the Field Spacer.Return value
The size of the Field Spacer in units.virtual void setAttenuation (float attenuation) const =0
Sets an attenuation factor value for the Field Spacer.Arguments
- float attenuation - A new attenuation factor value. If a too small value is provided, 1E-6 will be used instead.
virtual float getAttenuation () const =0
Returns the current attenuation factor for the Field Spacer.Return value
The attenuation factor value.Last update: 2017-07-03
Help improve this article
Was this article helpful?
(or select a word/phrase and press Ctrl+Enter)