Re: quaternion and slerp interpolator, and all that
Robert Kern <robert.kern <at> gmail.com>
2009-06-03 21:56:40 GMT
On Wed, Jun 3, 2009 at 16:39, killian koepsell <koepsell <at> gmail.com> wrote:
> I have a related question. I have programmed a couple of
> quaternion-valued functions and used arrays with a customized numpy
> dtype for it. Something like
> dtype = [('r',np.double),('i',np.double),('j',np.double),('k',np.double)]
> Now, I am wondering if there is an easy way (e.g. using cython) to
> define a custom quaternion scalar type and make numpy aware of it. I
> found some information in the numpy book about this topic but couldn't
> find any example code.
> If anyone has working example code, that would be great -- as I said,
> ideally using cython, but c code would be fine too.
Look at the docs/newdtype_example/ directory.
"I have come to believe that the whole world is an enigma, a harmless
enigma that is made terrible by our own mad attempt to interpret it as
though it had an underlying truth."
-- Umberto Eco
SciPy-user mailing list
SciPy-user <at> scipy.org