PixelLightAPI
.
|
Scene container node (group node) class which is using scene nodes. More...
#include <SceneContainer.h>
Public Types | |
enum | EFlags { NoRecursion = 1<<10 } |
Scene node flags (SceneNode flags extension) More... | |
Public Member Functions | |
PLS_API void | SetFilename (const PLCore::String &sValue) |
PLS_API | SceneContainer () |
Default constructor. | |
virtual PLS_API | ~SceneContainer () |
Destructor. | |
SceneNode * | Create (const PLCore::String &sClass, const PLCore::String &sName="", const PLCore::String &sParameters="") |
Creates a new scene node. | |
PLS_API SceneNode * | CreateAtIndex (const PLCore::String &sClass, const PLCore::String &sName="", const PLCore::String &sParameters="", int nPosition=-1) |
Creates a new scene node at a certain index inside the scene node list. | |
PLS_API void | CalculateAABoundingBox () |
Calculates and sets the axis align bounding box in 'scene node space'. | |
PLS_API bool | GetTransformMatrixTo (SceneContainer &cContainer, PLMath::Matrix3x4 &mTransform) |
Calculates a transform matrix to bring a transformation from 'this scene container' into 'another scene container'. | |
PLS_API SceneHierarchy * | CreateHierarchy (const PLCore::String &sClass="PLScene::SHList") |
Creates the scene hierarchy of this scene container. | |
PLS_API SceneHierarchy * | GetHierarchyInstance () |
Returns the scene hierarchy of this scene container. | |
PLS_API SceneQuery * | CreateQuery (const PLCore::String &sClass) |
Creates a scene query. | |
PLS_API bool | DestroyQuery (SceneQuery &cQuery) |
Destroys a scene query. | |
virtual PLS_API bool | DeInit () override |
De-initializes the manager. | |
virtual PLS_API SceneNode * | GetByIndex (PLCore::uint32 nIndex=0) const override |
virtual PLS_API SceneNode * | GetByName (const PLCore::String &sName) const override |
Returns the element with the given name. | |
virtual PLS_API bool | LoadByFilename (const PLCore::String &sFilename, const PLCore::String &sParams="", const PLCore::String &sMethod="") override |
Loads the loadable from a file given by filename. | |
virtual PLS_API bool | LoadByFile (PLCore::File &cFile, const PLCore::String &sParams="", const PLCore::String &sMethod="") override |
Loads the loadable from a file given by a reference. | |
virtual PLS_API bool | Unload () override |
Unloads the loadable. | |
virtual PLS_API PLCore::String | GetLoadableTypeName () const override |
Returns the loadable type name. | |
Protected Member Functions | |
virtual PLS_API void | InitFunction () override |
This function is called when the scene node gets initialized. | |
virtual PLS_API void | DeInitFunction () override |
This function is called when the scene node gets de-initialized. | |
virtual PLS_API void | OnActivate (bool bActivate) override |
Called when the scene node has been activated or deactivated. | |
virtual PLS_API bool | CallLoadable (PLCore::File &cFile, PLCore::Loader &cLoader, const PLCore::String &sMethod, const PLCore::String &sParams) override |
Calls the loadable in order to load or save. |
Scene container node (group node) class which is using scene nodes.
Scene node flags (SceneNode flags extension)
NoRecursion |
Do NOT take the scene nodes of this container into account when for instance rendering the scene. 'SCRenderToTexture' for example sets this flag. |
Reimplemented from PLScene::SceneNode.
PLS_API PLScene::SceneContainer::SceneContainer | ( | ) |
Default constructor.
virtual PLS_API PLScene::SceneContainer::~SceneContainer | ( | ) | [virtual] |
Destructor.
PLS_API void PLScene::SceneContainer::SetFilename | ( | const PLCore::String & | sValue | ) |
SceneNode * PLScene::SceneContainer::Create | ( | const PLCore::String & | sClass, |
const PLCore::String & | sName = "" , |
||
const PLCore::String & | sParameters = "" |
||
) | [inline] |
Creates a new scene node.
[in] | sClass | Name of the scene node class to create an instance from |
[in] | sName | Scene node name |
[in] | sParameters | Optional parameter string |
PLS_API SceneNode* PLScene::SceneContainer::CreateAtIndex | ( | const PLCore::String & | sClass, |
const PLCore::String & | sName = "" , |
||
const PLCore::String & | sParameters = "" , |
||
int | nPosition = -1 |
||
) |
Creates a new scene node at a certain index inside the scene node list.
[in] | sClass | Name of the scene node class to create an instance from |
[in] | sName | Scene node name |
[in] | sParameters | Optional parameter string |
[in] | nPosition | Optional index position specifying the location within the scene node list where the scene node should be added, <0 for at the end |
PLS_API void PLScene::SceneContainer::CalculateAABoundingBox | ( | ) |
Calculates and sets the axis align bounding box in 'scene node space'.
PLS_API bool PLScene::SceneContainer::GetTransformMatrixTo | ( | SceneContainer & | cContainer, |
PLMath::Matrix3x4 & | mTransform | ||
) |
Calculates a transform matrix to bring a transformation from 'this scene container' into 'another scene container'.
[in] | cContainer | 'Target' scene container |
[out] | mTransform | Receives the transform matrix, may contain an invalid matrix on error |
PLS_API SceneHierarchy* PLScene::SceneContainer::CreateHierarchy | ( | const PLCore::String & | sClass = "PLScene::SHList" | ) |
Creates the scene hierarchy of this scene container.
[in] | sClass | Class name of the scene hierarchy to create, if empty this function will do nothing |
Returns the scene hierarchy of this scene container.
PLS_API SceneQuery* PLScene::SceneContainer::CreateQuery | ( | const PLCore::String & | sClass | ) |
Creates a scene query.
[in] | sClass | Class name of the scene query to create |
PLS_API bool PLScene::SceneContainer::DestroyQuery | ( | SceneQuery & | cQuery | ) |
Destroys a scene query.
[in] | cQuery | Scene query to destroy |
virtual PLS_API void PLScene::SceneContainer::InitFunction | ( | ) | [override, protected, virtual] |
This function is called when the scene node gets initialized.
Reimplemented from PLScene::SceneNode.
Reimplemented in PLScene::SCRenderToTexture, and PLPhysics::SCPhysicsWorld.
virtual PLS_API void PLScene::SceneContainer::DeInitFunction | ( | ) | [override, protected, virtual] |
This function is called when the scene node gets de-initialized.
Reimplemented from PLScene::SceneNode.
Reimplemented in PLPhysics::SCPhysicsWorld.
virtual PLS_API void PLScene::SceneContainer::OnActivate | ( | bool | bActivate | ) | [override, protected, virtual] |
Called when the scene node has been activated or deactivated.
[in] | bActivate | 'true' if the scene node is now active, else 'false' |
Reimplemented from PLScene::SceneNode.
Reimplemented in PLPhysics::SCPhysicsWorld.
virtual PLS_API bool PLScene::SceneContainer::DeInit | ( | ) | [override, virtual] |
De-initializes the manager.
Reimplemented from PLCore::ElementManager< AType >.
virtual PLS_API SceneNode* PLScene::SceneContainer::GetByIndex | ( | PLCore::uint32 | nIndex = 0 | ) | const [override, virtual] |
virtual PLS_API SceneNode* PLScene::SceneContainer::GetByName | ( | const PLCore::String & | sName | ) | const [override, virtual] |
Returns the element with the given name.
[in] | sName | Element name |
Reimplemented from PLCore::ElementManager< AType >.
virtual PLS_API bool PLScene::SceneContainer::LoadByFilename | ( | const PLCore::String & | sFilename, |
const PLCore::String & | sParams = "" , |
||
const PLCore::String & | sMethod = "" |
||
) | [override, virtual] |
Loads the loadable from a file given by filename.
[in] | sFilename | Loadable filename |
[in] | sParams | Optional load method parameters, can be an empty string |
[in] | sMethod | Optional name of the load method to use, can be an empty string |
Reimplemented from PLCore::Loadable.
Reimplemented in PLPhysics::SCPhysicsWorld.
virtual PLS_API bool PLScene::SceneContainer::LoadByFile | ( | PLCore::File & | cFile, |
const PLCore::String & | sParams = "" , |
||
const PLCore::String & | sMethod = "" |
||
) | [override, virtual] |
Loads the loadable from a file given by a reference.
[in] | cFile | File to load from, must be opened and readable |
[in] | sParams | Optional load method parameters, can be an empty string |
[in] | sMethod | Optional name of the load method to use, can be an empty string |
Reimplemented from PLCore::Loadable.
Reimplemented in PLPhysics::SCPhysicsWorld.
virtual PLS_API bool PLScene::SceneContainer::Unload | ( | ) | [override, virtual] |
Unloads the loadable.
Reimplemented from PLCore::Loadable.
virtual PLS_API PLCore::String PLScene::SceneContainer::GetLoadableTypeName | ( | ) | const [override, virtual] |
virtual PLS_API bool PLScene::SceneContainer::CallLoadable | ( | PLCore::File & | cFile, |
PLCore::Loader & | cLoader, | ||
const PLCore::String & | sMethod, | ||
const PLCore::String & | sParams | ||
) | [override, protected, virtual] |
Calls the loadable in order to load or save.
[in] | cFile | File to load from, MUST be opened |
[in] | cLoader | Loader to use |
[in] | sMethod | Name of the method to use |
[in] | sParams | Method parameters |
Reimplemented from PLCore::Loadable.
|