point of view in 3d graphics

40 views
Skip to first unread message

MathLynx

unread,
Sep 18, 2011, 6:42:28 PM9/18/11
to sage-support
In Maple there is the option orientation=[#1,#2,#3] to tell the
display mechanism what the viewer's position is vis-a-vis the viewed
object. I don't know how to do something like this in Sage. Tried
rotateX, etc., but this rotates the object in a standard euclidean
coordinate system, thus altering its relationship with the axes. I
want to fix axes and change point-of-view. Is this possible?

And, as a side note, is it possible to stick math symbols (like
generated by a call to LaTex) in to either 2d or 3d graphics? Maybe
this needs to be a separate post...

slabbe

unread,
Sep 20, 2011, 11:30:47 AM9/20/11
to sage-support
> I want to fix axes and change point-of-view.  Is this possible?

Recently, I managed to find the camera position from the moveto
command [1]. One way to do what you want would be to do the converse :
find the moveto command from the desired camera position. This would
give a solution once Jmol is open. Because you could use the script
window to rotate the object with the axes using the moveto command. I
do not have the time right now to write a post about how to find the
arguments to give to the moveto command.

A better solution would be to give the point of view from sage like :

sage: something.show3d(camera=[10,20,30])

I talked with Jonathan Gutow (a Jmol developper) last June in a Sage
Days and he told me the way the information is passed from Sage to
Jmol could be improved a lot. So I believe this is something doable in
a near future...

Sébastien

[1] http://groups.google.com/group/sage-devel/browse_thread/thread/16167d7babe07ab7/809b5d4742546f40
Reply all
Reply to author
Forward
0 new messages