VisioMove SDK (iOS)  2.1.22
VgEngine::VgSpatial Class Reference
Inheritance diagram for VgEngine::VgSpatial:
Inheritance graph

Public Member Functions

void setAnimation (const std::string &pAnimationName, VgEngine::VgRefPtr< VgEngine::VgAnimation > &pAnimation)
 
void setAnimation (VgEngine::VgRefPtr< VgEngine::VgAnimation > pAnimation)
 
void setLocalAnimation (VgEngine::VgRefPtr< VgEngine::VgAnimation > pAnimation)
 
VgConstRefPtr< VgAnimationgetAnimation (const std::string &pName) const
 
VgRefPtr< VgAnimationeditAnimation (const std::string &pName)
 
void getAnimationNames (std::list< std::string > &pNameList) const
 
VgValue getAnimationChannelValue (const std::string &pChannelName) const
 
VgEngine::VgPosition getPosition () const
 
virtual void setPosition (const VgEngine::VgPosition &pPosition, bool pHaveGeographicCoherence=true)
 
VgEngine::VgOrientation getOrientation () const
 
void setOrientation (const VgEngine::VgOrientation &pOrientation)
 
float getScale () const
 
void setScale (float pScale)
 
int getZIndex () const
 
void setZIndex (int pZIndex)
 
bool isDrawnOnTop () const
 
void setDrawOnTop (bool pEnable)
 
virtual void setVisible (bool pIsVisible)
 
virtual bool isVisible () const
 
virtual Vg3DModule::VgIGeometryasGeometry ()
 
virtual Vg3DModule::VgPointasPoint ()
 
virtual Vg3DModule::VgLineasLine ()
 
- Public Member Functions inherited from VgEngine::VgReferenced
 VgReferenced ()
 
 VgReferenced (const VgReferenced &pThis)
 
virtual ~VgReferenced ()
 
VgReferencedoperator= (const VgReferenced &pThis)
 
void ref () const
 
int unref () const
 
int getNbReferences () const
 

Protected Member Functions

 VgSpatial ()
 
virtual ~VgSpatial ()
 

Protected Attributes

Private * mPrivate
 
- Protected Attributes inherited from VgEngine::VgReferenced
int mNbReferences
 

Friends

class VgObjectBridge
 
class VgLayer
 

Detailed Description

This class gives access to the spatial aspect of an object (layer, point, etc). The spatial aspect controls the object's position in scene space. It also enables animation features on spatial objects.

Version
2.0

Constructor & Destructor Documentation

VgEngine::VgSpatial::VgSpatial ( )
protected

Default constructor. This is protected since it is not possible to create a spatial directly. Instead, instantiate a spatial object (like point for example) and access it's spatial aspect.

virtual VgEngine::VgSpatial::~VgSpatial ( )
protectedvirtual

Destructor.

Member Function Documentation

virtual Vg3DModule::VgIGeometry* VgEngine::VgSpatial::asGeometry ( )
virtual

Casts this instance into a VgIGeometry.

Returns
A valid pointer if this instance as the correct type, NULL otherwise.
Version
2.0.9590

Reimplemented in Vg3DModule::VgIGeometry.

virtual Vg3DModule::VgLine* VgEngine::VgSpatial::asLine ( )
virtual

Casts this instance into a VgLine.

Returns
A valid pointer if this instance as the correct type, NULL otherwise.
Version
2.0.9590

Reimplemented in Vg3DModule::VgPoint, Vg3DModule::VgLine, and Vg3DModule::VgIGeometry.

virtual Vg3DModule::VgPoint* VgEngine::VgSpatial::asPoint ( )
virtual

Casts this instance into a VgPoint.

Returns
A valid pointer if this instance as the correct type, NULL otherwise.
Version
2.0.9590

Reimplemented in Vg3DModule::VgPoint, Vg3DModule::VgLine, and Vg3DModule::VgIGeometry.

VgRefPtr< VgAnimation > VgEngine::VgSpatial::editAnimation ( const std::string &  pName)

Edits an animation from the spatial's animation map.

Parameters
pNameThe name of the animation to fetch.
Returns
A reference pointer that is valid if an animation exists by that name in this spatial.
Version
2.0.8744
VgConstRefPtr< VgAnimation > VgEngine::VgSpatial::getAnimation ( const std::string &  pName) const

Gets an animation from the spatial's animation map.

Parameters
pNameThe name of the animation to fetch.
Returns
A const reference pointer that is valid if an animation exists by that name in this spatial.
Version
2.0.8744
VgValue VgEngine::VgSpatial::getAnimationChannelValue ( const std::string &  pChannelName) const

Get the current value of a given animation channel.

Parameters
pChannelNameThe name of the channel.
Returns
The value stored in a VgValue object.
Version
2.1.19
void VgEngine::VgSpatial::getAnimationNames ( std::list< std::string > &  pNameList) const

Gets the list of the stored animation names.

Parameters
pNameListThe list of strings to feed with the names.
Version
2.0.8744
VgEngine::VgOrientation VgEngine::VgSpatial::getOrientation ( ) const

Gets spatial's orientation.

Returns
The spatial's orientation.
Version
2.0.8744
VgEngine::VgPosition VgEngine::VgSpatial::getPosition ( ) const

Gets spatial's position.

Returns
The spatial's position.
Version
2.0.7445
float VgEngine::VgSpatial::getScale ( ) const
Returns
the spatial's scale.
Version
2.0.9263
int VgEngine::VgSpatial::getZIndex ( ) const
Returns
Z index. default value is 0.
Version
2.0.9263
2.1.0 Updated documentation with default value
bool VgEngine::VgSpatial::isDrawnOnTop ( ) const
Returns
True if the current spatial is drawn on top. Default value is false.
Version
2.0.9263
2.1.0 Updated documentation with default value
virtual bool VgEngine::VgSpatial::isVisible ( ) const
virtual
Returns
True if visible. By default, a VgSpatial is visible.
Version
2.0.9334

Reimplemented in VgEngine::VgLayer.

void VgEngine::VgSpatial::setAnimation ( const std::string &  pAnimationName,
VgEngine::VgRefPtr< VgEngine::VgAnimation > &  pAnimation 
)

Sets an animation on this spatial. As of version 2.0.8744, multiple animations can be set (and played) on a spatial at the same time. This is the reason why a name has to be provided along with the animation. If an animation already exists in the spatial with that name, the new one will replace the old one (and the previous one will one less reference to it).

Parameters
pAnimationNameThe name to associate the animation with in this spatial
pAnimationAn animation to animate the spatial with.
Version
2.0.8744
void VgEngine::VgSpatial::setAnimation ( VgEngine::VgRefPtr< VgEngine::VgAnimation pAnimation)

Sets an animation with an empty name on this spatial.

Parameters
pAnimationAn animation to animate the spatial with.
Deprecated:
Version
2.0.7445
void VgEngine::VgSpatial::setDrawOnTop ( bool  pEnable)

Sets the drawOnTop flag. The VgSpatial will be visible even if there are objects in front.

Version
2.0.9263
void VgEngine::VgSpatial::setLocalAnimation ( VgEngine::VgRefPtr< VgEngine::VgAnimation pAnimation)

Sets an animation on this spatial.

Parameters
pAnimationAn animation to animate the spatial with.
Deprecated:
Warning
This method is kept for compatibility concerns. It will set all of the animation's channels to address the local animation node. The animation will be named "local". YOUR ANIMATION MAY BE MODIFIED BY THIS CALL.
void VgEngine::VgSpatial::setOrientation ( const VgEngine::VgOrientation pOrientation)

Sets the spatial orientation.

Parameters
pOrientationThe orientation to set on the spatial.
Version
2.0.8744
virtual void VgEngine::VgSpatial::setPosition ( const VgEngine::VgPosition pPosition,
bool  pHaveGeographicCoherence = true 
)
virtual

Sets the spatial position.

Parameters
pPositionThe position to put the spatial at.
pHaveGeographicCoherenceAn optional parameter who by default is true. Is used to determine the geographic coherence of the spatial. If set to false, then the spatial will be coherent with the scene.
Version
2.0.7445
void VgEngine::VgSpatial::setScale ( float  pScale)

Sets the spatial's scale.

Parameters
pScaleThe scale to set on the spatial.
Version
2.0.8744
virtual void VgEngine::VgSpatial::setVisible ( bool  pIsVisible)
virtual

Sets the visibility. By default, a VgSpatial is visible.

Version
2.0.9334

Reimplemented in VgEngine::VgLayer.

void VgEngine::VgSpatial::setZIndex ( int  pZIndex)

Sets the Z Index, an object with a smaller ZIndex will be drawn in front of another with a larger one.

Version
2.0.9263
2.1.2 Updated documentation

Friends And Related Function Documentation

friend class VgLayer
friend
friend class VgObjectBridge
friend

Member Data Documentation

Private* VgEngine::VgSpatial::mPrivate
protected

Private.


The documentation for this class was generated from the following file:
VisioMove 2.1.22, Visioglobe® 2016