Ask Your Question

Revision history [back]

Few years ago, I was also surprised by the behavior of Graphics3d objects with respect to the coordinate system used in the tachyon output. I wanted to move the camera on a circle around a 3d object. It was just impossible. I found another way (rotating the object): the video I made is available at https://en.wikipedia.org/wiki/Dancing_Links on which you can see the wiggle in the camera because of the way Graphics3d object are turned into Tachyon string and how the camera is placed.

This is because of the _prepare_for_tachyon method of a Graphics3D (https://git.sagemath.org/sage.git/tree/src/sage/plot/plot3d/base.pyx#n1467) object which basically change the coordinate system to make sure the camera is placed and zoom in a way that we always see the object. I never like that choice because the coordinate system in the tachyon string is not the same as the one defining the Graphics3d. Also, there is no way to place camera else where, and adding an argument to the user to place the camera is just impossible since we don't know the new coordinate system.

If you want to improve this code in sage, I will be willing to review your changes.