Jim Morcombe wrote:
I want to write a program that helps teach students how to draw ray
diagrams for lenses and mirrors. Vpython seems to be used for a number
of physics simulations, but may be overkill for my application.
Although there are a few 3D things I would like to do, most just
involves drawing curves and simple objects, and allowing the User to do
the same.
So the question - What is the best thing to use to draw and manipulate
simple 2D objects in an application like this?
I'd stick to a simple 2D Gui toolkit that has a canvas. Tkinter comes by
default and is usually more than sufficient for simple applications.
Simple physics like the thin lens equation etc. can probably be done by
hand for your application. I don't think you need to really use a *real*
physics engine.
For heavy duty physics simulation (the kind you see in modern games),
you can take a look at the Open Dynamics Engine (http://www.ode.org/).
There are Python bindings. I managed to get some of the demos to work fine.
--
~noufal
http://nibrahim.net.in/
_______________________________________________
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor