3d translation in Python.

Terry Reedy tjreedy at udel.edu
Fri Aug 30 19:34:23 CEST 2002

"> Is there a way to translate a point in the global to the member
> coordinate?

If x,y,z are global coordinates of Point to be translated and a,b,c
are global coordinates of member (or reference point thereof), then
x-a,y-b,z-c are translated member coodinates of Point (ie, relative to
reference point of member).  If you want to rotate and/or stretch the
coordinate system also, then you need to do matrix multiplication and
should look up basic info about 3D computer graphics that explains

(Or look at transform? module of something like pygame www.pygame.org
which has such already written.)

Terry J. Reedy

More information about the Python-list mailing list