Re: shape rotation

jon klein <[email protected]>
Newsgroups gmane.comp.breve
Message-ID <[email protected]>
On Tuesday, August 26, 2003, at 07:44  PM, Rick Giuly wrote:

> Suppose I want to make something like a flower with rectangular prisms 
> for
> petals.
>
> Top view of four petals:
>
>   |
> -   -
>   |
>
>
> Say I want 10 petals, and I want them arranged and 36 degree spacing 
> (rather
> that the 4 petals at 90 degree spacing shown in the figure).
>
> I suppose I could do that by making each petal a Mobile with a box 
> shape (shape
> init-with-cube...). The Mobile class would provide the rotation and 
> translation
> to arrange the petals. But say I want all the petals hinged together.
>
> I think that would mean the petals could not be Mobile's, they would 
> need to be
> Link's. Link's have no rotate/move accessor, so I don't know how I 
> would rotate
> and move them into place.

The short answer: look at the Joint class for the set-relative-rotation 
and
set-relative-rotation-matrix methods.

Explanation: As you're seeing, Link objects are not rotated using 
explicit
rotation methods the way Mobile objects are.  This is because the Link 
object
is not an independent physical object--it has to be connected to other 
Links
via joints, and ultimately associated with a MultiBody.

It is the positions and rotations of the Joint objects which control the
relationship between links, not any settings in the Link itself.

Hope this helps!

- jon

-=-=-=-
to unsubscribe: send a message with the body
"unsubscribe breve" to [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.