This topic is now archived and is closed to further replies.


how to get CSLLight* in DotXSI???HELP

Recommended Posts

i tried to get lights'' handles in DotXSI file format via SOFTIMAGE|FTK, but failed. here is my code: void recurse4Lights(CSLModel* in_child) { //1st, transform it transformXSI2GL(in_child); //2nd, Draw axis glCallList(listGLaxis); //3rd, Now recurse its children // Loop through all children CSLModel* *l_childrenList = in_child->GetChildrenList(); for (int i = 0; i < in_child->GetChildrenCount(); i++ ) { recurseXSI( l_childrenList ); } //4th, set this light switch(in_child->GetPrimitiveType()) { case CSLTemplate::SI_DIRECTIONAL_LIGHT: case CSLTemplate::SI_INFINITE_LIGHT: case CSLTemplate::SI_POINT_LIGHT: case CSLTemplate::SI_SPOT_LIGHT: { CSLLight* left_prim = (CSLLight*)in_child->Primitive(); drawLight(left_prim, lightCount); lightCount++; break; } default: break; }//end of switch //5th, restore matrix restoreXSI2GL(in_child); } i passed scene.root() as the parameter to this function in the major loop, but no template step in the switch-case block. does anything go wrong? help me, please.

Share this post

Link to post
Share on other sites