MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / processNode

Method processNode

Engine/source/ts/loader/tsShapeLoader.cpp:185–225  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

183}
184
185bool TSShapeLoader::processNode(AppNode* node)
186{
187 // Detect bounds node
188 if ( node->isBounds() )
189 {
190 if ( boundsNode )
191 {
192 Con::warnf( "More than one bounds node found" );
193 return false;
194 }
195 boundsNode = node;
196
197 // Process bounds geometry
198 MatrixF boundsMat(boundsNode->getNodeTransform(DefaultTime));
199 boundsMat.inverse();
200 zapScale(boundsMat);
201 for (S32 iMesh = 0; iMesh < boundsNode->getNumMesh(); iMesh++)
202 {
203 AppMesh* mesh = boundsNode->getMesh(iMesh);
204 MatrixF transform = mesh->getMeshTransform(DefaultTime);
205 transform.mulL(boundsMat);
206 mesh->lockMesh(DefaultTime, transform);
207 }
208 return true;
209 }
210
211 // Detect sequence markers
212 if ( node->isSequence() )
213 {
214 //appSequences.push_back(new AppSequence(node));
215 return false;
216 }
217
218 // Add this node to the subshape (create one if needed)
219 if ( subshapes.size() == 0 )
220 subshapes.push_back( new TSShapeLoader::Subshape );
221
222 subshapes.last()->branches.push_back( node );
223
224 return true;
225}
226
227//-----------------------------------------------------------------------------
228// Nodes, meshes and skins

Callers

nothing calls this directly

Calls 13

isBoundsMethod · 0.80
getNumMeshMethod · 0.80
mulLMethod · 0.80
isSequenceMethod · 0.80
warnfFunction · 0.50
getNodeTransformMethod · 0.45
inverseMethod · 0.45
getMeshMethod · 0.45
getMeshTransformMethod · 0.45
lockMeshMethod · 0.45
sizeMethod · 0.45
push_backMethod · 0.45

Tested by

no test coverage detected