MathGroup Archive 2008

[Date Index] [Thread Index] [Author Index]

Search the Archive

Dynamic Rotation: Coupling of Two or More Graphics3D objects?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg85857] Dynamic Rotation: Coupling of Two or More Graphics3D objects?
  • From: "W. Craig Carter" <ccarter at mit.edu>
  • Date: Mon, 25 Feb 2008 07:37:14 -0500 (EST)

Hello,
Can anyone suggest a path that I might explore to couple the 
on-screen of one graphical 3d object to another?

I've tried what I consider to be obvious: using Manipulate 
to dynamically control viewpoints of several objects, but 
this is too slow to be useful for my purposes.

I'd prefer to rotate on object on-screen and have another 
(in, say, the same graphics grid) transform in response.

For example:
GraphicsRow[Graphics3D /@ {Cuboid[], Sphere[]}]

For a concrete example. I'd like to rotate the cube about 
its origin, but have the sphere rotate about an arbitrary 
fixed point.

If I can't do the coupling, the below (kind of) works, but 
is cludgy:

Manipulate[
  GraphicsRow[{Graphics3D[Cuboid[],
     ViewPoint -> 10 {Cos[t] Sin[p], Sin[t] Sin[p], Cos[p]}],
    Graphics3D[Cuboid[],
     ViewPoint -> {a, b, c} +
       10 {Cos[t] Sin[p], Sin[t] Sin[p], Cos[p]}]}],
  {{a, 5}, 1, 10}, {{b, 5}, 1, 10}, {{c, 5}, 1, 10},
  {{t, Pi}, 0, 2 Pi}, {{p, Pi/2}, -Pi, Pi}]

A potential problem is that I can rotate one and then lose 
the correspondence (which I could fix with a result button, 
but...)


W. Craig Carter



  • Prev by Date: Re: NDSolve[] and Differential Equations: Problem solving two
  • Next by Date: Re: PowerExpand in version 6
  • Previous by thread: Re: Branch Cuts and NDSolve
  • Next by thread: Re: Dynamic Rotation: Coupling of Two or More Graphics3D objects?