Hi Delport, I am sorry that i did not get much from your last reply asking how am i changing the texture when i switch the branches. Do i have to explicitly specify the texture? Even it is i believe that it is done as follows:
stateset->setTextureAttributeAndModes(0, bp->getOutputTexture().get(),osg::StateAttribute::ON); bp->getOutputTexture() is retrieving the correct texture based on the value of the _ActiveBranch. With key press event i have a function that flips the switch node that turns one switch's input to other switch's output. If i have to call this function again where should the call go into? It seems that the state is dynamic and do i have to implement a state change callback ? Thank you! Regards Sajjadul ------------------ Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=34786#34786 _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

