On 10/22/2010 10:32 AM, Matt Caron wrote: > Are there standard ways to configure sound placement from outside the source > code? Looking through the 1 page of documentation that comes with the source > code as well as the examples, I see that I can place a sound object at an > (x,y) position - so I can manually place it somewhere in my model. However, > what I'd really like to do is configure Sound1 to position itself at Node1, > so that when I make changes to my coordinate system, model, etc. I won't have > to recalculate and re-code position information. I see that sound nodes are > extensions of OSG's Node so I can manipulate them in the same way, but I > would still need to change the source code if I ever moved or manipulated my > 3D model. > For example, I have a large model of a school and I'd like to attach a bell > ring to the bell tower, cheers to the stadium, etc. It would be great if I > could just write a config file or smarter source code that would always pair > each sound with its part of the model in the scene. Has anyone solved this > task before?
I guess I'd probably make a visitor that goes out and located the nodes you want by name, and attaches similarly-named sounds to them? That way wherever those nodes are in the model, they get their appropriate sounds. > Also, is there any detailed documentation for this system? The only > documentation I found on the google project site was for building the system > - and then I only saw 1 page of documentation in the source. Every significant class has Doxygen-type comment documentation embedded in the source. That, coupled with the examples, is all there is. Similar to OSG itself. ;) > Thanks. > Matt -- Chris 'Xenon' Hanson, omo sanza lettere. [email protected] http://www.alphapixel.com/ Digital Imaging. OpenGL. Scene Graphs. GIS. GPS. Training. Consulting. Contracting. "There is no Truth. There is only Perception. To Perceive is to Exist." - Xen _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

