David- PDL::Graphics::TriD implements 3D plotting and visualization functions in PDL. It supports different backend graphics devices: OpenGL (live and offline modes) and VRML (not working at the moment).
The "old" TriD implementation used PP to generate OpenGL bindings with the assumption that the OpenGL would be on an X11 system and using GLX + X11 calls for the GUI part. The "new" TriD implementation uses the Perl OpenGL module for the OpenGL bindings and FreeGLUT/GLUT for the GUI part interacting with the display. That allowed portability to MS Windows and to Mac OS X where the graphics is not X11 based. As for event handling, OpenGL is a graphics API and not a GUI toolkit. You use OpenGL calls to draw images to be displayed. The system events need are handled via the GUI toolkit used (from the OS, Gtk+, GLUT, ...). As I mentioned, PDL::Graphics::TriD uses FreeGLUT (GLUT on Mac OS X) for its GUI for portability and simplicity so I would start there unless you need more. It should be enough to get you started with OpenGL visualization. The OpenGL bindings used by PDL are not specific to PDL. You can just "use OpenGL qw(:all)" and start programming. The function calls are pretty much the same has what the C API calls have so any OpenGL tutorial should get you going there. Try googling "OpenGL" and "tutorial". David Mertens wrote: > Chris and all other interested folks - > > I know that you put in a lot of work recently to phase out the old 3d > stuff, but it's not clear to me what is old and what is new. Clearly > the PDL::Graphics::TriD stuff is old, but does it now use the new OpenGL > on the back end? The documentation for the new stuff is rather sparse > so it's hard to figure out. > > Also, how does event handling work in OpenGL? It's really a cinch to > write interactive stuff with SDL, but the emails with Kartik have > probably made it obvious that, at the moment, SDL is a moving target. > Are there any good OpenGL tutorials on the web that work well with the > PDL interface? As far as I know, SDL supports OpenGL as well and the SDL I know has been stable for a couple of years. I'm not sure what you mean by a moving target there. You should be able to use a less than bleeding edge SDL to do OpenGL programming. If I had a better idea of what you were looking to do, maybe I would have a more concrete suggestion. Regards, Chris _______________________________________________ Perldl mailing list [email protected] http://mailman.jach.hawaii.edu/mailman/listinfo/perldl
