Jim Wilson wrote: > David Megginson wrote: > > I think what Andy's suggesting is that the panel be part of the > > model's scene graph.
Yeah. What he said. :) > So am I, but panel isn't moved to a scene graph yet. Now that I think > about it though, he is still going to need the offsets that the model > doesn't know about to implement the mouse action. Nope; just the matrices. The panel knows that if it runs an airframe coordinate through teh modelview and projection matrices, it'll get screen coordinates in the range [-1:1]. Just invert that matrix and we can go from screen coordinates to airframe, thence to panel coordinates. It's a little more complicated in practice, but that's the essence of the problem. The panel certainly doesn't need to know anything specific about the model or the viewer. It can do it all on its own, without reference to anything but the OpenGL render state. Again, that's the point behind scene graph architectures. Andy -- Andrew J. Ross NextBus Information Systems Senior Software Engineer Emeryville, CA [EMAIL PROTECTED] http://www.nextbus.com "Men go crazy in conflagrations. They only get better one by one." - Sting (misquoted) _______________________________________________ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
