[PD] efficient cos calculation in externals?

Tom Schouten doelie at zzz.kotnet.org
Mon Oct 27 05:27:25 CET 2003

hi larry,

i didn't do extensive ABing, but gut feeling says that on intel you can
safely get away with using math.h functions, especially on newer machines.
i noticed this when i did a "prototype" version of the scroll grid chaotic
oscillator in creb which uses exp, sin and cos inside the dsp loop, and
is still relatively efficient. i'm not too sure about other architectures


> I think the answer is no, but is there a globaly available efficient cosine
> routine in Pd?
> I see that the 512 byte cosine table used by "cos~" is exported in m_pd.h, but
> this size is too small to use without interpolation, and the intperpolation
> method used by cos~ seems a bit tricky and isn't made globaly available.
> A quick grep through the externals shows that some people just call the
> functions in math.h, and others build their own lookup tables. Is this the
> case?

More information about the Pd-list mailing list