chrono::irrlicht::ChIrrNodeProxyToAsset Class Reference

Description

Class for proxy to ChAsset, it is a node with mesh in Irrlicht system and a shared pointer to the ChAsset to whom it corresponds.

Example: (with ascii art, with –> shared pointer, ...> raw pointer)

CHRONO side IRRLICHT side ChBody <......................._ ChIrrNodeAsset -----—> ChIrrNode ChBoxShape <-----------— ChIrrNodeProxyToAsset IMeshSceneNode ChSphereShape <---------— ChIrrNodeProxyToAsset IMeshSceneNode

#include <ChIrrNodeProxyToAsset.h>

Inherits ISceneNode.

Public Member Functions

 ChIrrNodeProxyToAsset (std::shared_ptr< ChAsset > myvisualization, irr::scene::ISceneNode *parent)
 Constructor. More...
 
 ~ChIrrNodeProxyToAsset ()
 Destructor.
 
virtual void render ()
 
virtual const irr::core::aabbox3d< irr::f32 > & getBoundingBox () const
 
ISceneNode * clone (ISceneNode *newParent, irr::scene::ISceneManager *newManager)
 
std::shared_ptr< ChAsset > & GetVisualizationAsset ()
 Returns a reference to the shared pointer which references the ChAsset to whom this is a proxy. More...
 
virtual bool IsUpdateEnabled () const
 Returns true if the node must recompute the mesh for each time that an Update is called. More...
 
virtual void SetUpdateEnabled (const bool mup)
 Set if the node must recompute the mesh for each time that an Update is called. More...
 
virtual void Update ()
 Updates the child mesh to reflect the ChAsset.
 
virtual irr::scene::ESCENE_NODE_TYPE getType () const
 

Constructor & Destructor Documentation

chrono::irrlicht::ChIrrNodeProxyToAsset::ChIrrNodeProxyToAsset ( std::shared_ptr< ChAsset myvisualization,
irr::scene::ISceneNode *  parent 
)

Constructor.

Parameters
myvisualizationpointer to the ChronoEngine visualization asset
parentthe parent node in Irrlicht hierarchy

Member Function Documentation

std::shared_ptr<ChAsset>& chrono::irrlicht::ChIrrNodeProxyToAsset::GetVisualizationAsset ( )

Returns a reference to the shared pointer which references the ChAsset to whom this is a proxy.

virtual bool chrono::irrlicht::ChIrrNodeProxyToAsset::IsUpdateEnabled ( ) const
virtual

Returns true if the node must recompute the mesh for each time that an Update is called.

virtual void chrono::irrlicht::ChIrrNodeProxyToAsset::SetUpdateEnabled ( const bool  mup)
virtual

Set if the node must recompute the mesh for each time that an Update is called.