Assimp  v4.1. (December 2018)
Assimp::OptimizeGraphProcess Class Reference

Postprocessing step to optimize the scenegraph. More...

Inherits Assimp::BaseProcess.

Public Member Functions

void AddLockedNode (std::string &name)
 Add another node to be locked and not modified. More...
 
void AddLockedNodeList (std::string &in)
 Add a list of node names to be locked and not modified. More...
 
void Execute (aiScene *pScene)
 Executes the post processing step on the given imported data. More...
 
bool IsActive (unsigned int pFlags) const
 Returns whether the processing step is present in the given flag. More...
 
 OptimizeGraphProcess ()
 
void RemoveLockedNode (std::string &name)
 Remove a node from the list of locked nodes. More...
 
void SetupProperties (const Importer *pImp)
 Called prior to ExecuteOnScene(). More...
 
 ~OptimizeGraphProcess ()
 
- Public Member Functions inherited from Assimp::BaseProcess
 BaseProcess () AI_NO_EXCEPT
 Constructor to be privately used by Importer. More...
 
void ExecuteOnScene (Importer *pImp)
 Executes the post processing step on the given imported data. More...
 
SharedPostProcessInfoGetSharedData ()
 Get the shared data that is assigned to the step. More...
 
virtual bool RequireVerboseFormat () const
 Check whether this step expects its input vertex data to be in verbose format. More...
 
void SetSharedData (SharedPostProcessInfo *sh)
 Assign a new SharedPostProcessInfo to the step. More...
 
virtual ~BaseProcess ()
 Destructor, private as well. More...
 

Protected Member Functions

void CollectNewChildren (aiNode *nd, std::list< aiNode * > &nodes)
 
void FindInstancedMeshes (aiNode *pNode)
 

Additional Inherited Members

- Protected Attributes inherited from Assimp::BaseProcess
ProgressHandlerprogress
 Currently active progress handler. More...
 
SharedPostProcessInfoshared
 See the doc of #SharedPostProcessInfo for more details. More...
 

Detailed Description

Postprocessing step to optimize the scenegraph.

The implementation tries to merge nodes, even if they use different transformations. Animations are preserved.

See also
aiProcess_OptimizeGraph for a detailed description of the algorithm being applied.

Constructor & Destructor Documentation

◆ OptimizeGraphProcess()

OptimizeGraphProcess::OptimizeGraphProcess ( )

◆ ~OptimizeGraphProcess()

OptimizeGraphProcess::~OptimizeGraphProcess ( )

Member Function Documentation

◆ AddLockedNode()

void Assimp::OptimizeGraphProcess::AddLockedNode ( std::string &  name)
inline

Add another node to be locked and not modified.

Parameters
nameName to be locked

◆ AddLockedNodeList()

void Assimp::OptimizeGraphProcess::AddLockedNodeList ( std::string &  in)
inline

Add a list of node names to be locked and not modified.

Parameters
inList of nodes. See AI_CONFIG_PP_OG_EXCLUDE_LIST for format explanations.

◆ CollectNewChildren()

void OptimizeGraphProcess::CollectNewChildren ( aiNode nd,
std::list< aiNode * > &  nodes 
)
protected

◆ Execute()

void OptimizeGraphProcess::Execute ( aiScene pScene)
virtual

Executes the post processing step on the given imported data.

A process should throw an ImportErrorException* if it fails. This method must be implemented by deriving classes.

Parameters
pSceneThe imported data to work at.

Implements Assimp::BaseProcess.

◆ FindInstancedMeshes()

void OptimizeGraphProcess::FindInstancedMeshes ( aiNode pNode)
protected

◆ IsActive()

bool OptimizeGraphProcess::IsActive ( unsigned int  pFlags) const
virtual

Returns whether the processing step is present in the given flag.

Parameters
pFlagsThe processing flags the importer was called with. A bitwise combination of aiPostProcessSteps.
Returns
true if the process is present in this flag fields, false if not.

Implements Assimp::BaseProcess.

◆ RemoveLockedNode()

void Assimp::OptimizeGraphProcess::RemoveLockedNode ( std::string &  name)
inline

Remove a node from the list of locked nodes.

Parameters
nameName to be unlocked

◆ SetupProperties()

void OptimizeGraphProcess::SetupProperties ( const Importer pImp)
virtual

Called prior to ExecuteOnScene().

The function is a request to the process to update its configuration basing on the Importer's configuration property list.

Reimplemented from Assimp::BaseProcess.


The documentation for this class was generated from the following files: