POV-Ray : Newsgroups : povray.advanced-users : matrix help.... : Re: matrix help.... Server Time
29 Jul 2024 22:27:07 EDT (-0400)
  Re: matrix help....  
From: David Fontaine
Date: 14 Sep 2000 00:26:07
Message: <39C05238.D50B204E@faricy.net>
J Charter wrote:

> Yikes! This is great!  So I put together concepts from Margus and David and come up
> with the following.  And it seems to solve a problem I've been chasing for some
> time,...how to orient an arbitrary set of points from a shape ( the processes of a
> vertabrae ) along a spline ( forming the axial structure of an animal's turning neck
)
> and know what the new point locations are ( in order to attach muscles at their
> insertion points ).  Mild testing seems to indicate this works!  Can anyone who
knows
> vet this?  Is this really a solution?  Is there a cleaner way?

Oh, you wanted to apply it to an input vector? Well I wrote something for that too!
:))

Looks right. The last two lines that modify pt can be comnbined: vrotate ( pt,
<-RotX,RotY,0> )

Basically the more control and more errorproofing you want the more sloppy code you'll
have to write. Basically my macro finds the rotation values (spherical vector) of the
vectors and undoes the first one and applies the second.

--
David Fontaine   <dav### [at] faricynet>   ICQ 55354965
Please visit my website:  http://davidf.faricy.net/


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.