Csound Csound-dev Csound-tekno Search About

Re: power of two (was [Csnd] ChucK?? etc)

Date2006-03-25 13:47
FromVictor Lazzarini
SubjectRe: power of two (was [Csnd] ChucK?? etc)
The 'tab' opcodes can do that.

>
> el Fri, 24 Mar 2006 22:42:40 +0000
> Richard Dobson 
escribió:
>
>
> > If you mean the original oscil etc code (and the
> > (in)famous power-of-two  restriction), it goes back all
> the way to Barry Vercoe.
>
> btw, some time ago the possibility was discussed on the
> list, that the table opcode (or some variant of it) could
> access non-power-of-two tables generated by GEN01 with
> deferred size. what's the status of that?
>
> best,
>
> lj
> --
> Send bugs reports to this list.
> To unsubscribe, send email to
> csound-unsubscribe@lists.bath.ac.uk

Date2006-03-29 01:18
Fromluis jure
Subjectmanual - suggestions (was: power of two)
el Sat, 25 Mar 2006 14:47:22 +0100
Victor Lazzarini  escribió:

> The 'tab' opcodes can do that.

thanks victor, i wasn't aware of the new tab opcodes.

BTW, the manual page for tab says:

... Support non-power of two tables (can be generated by any GEN function by
giving a negative length value). 

i wasn't aware of that either, and i couldn't find that mentioned anywhere
else in the manual. 

if i may make a suggestion, perhaps it should be mentioned in the
f-statement page.

p3 -- Size of function table (i.e. number of points) Must be a power of 2,
or a power-of-2 plus 1 (see below). 

could be something like (translated into proper english, of course):
"Ordinarily a power of 2, or a power-of-2 plus 1 (see below), it can take
any arbitrary size by setting this parameter to a negative value, but in
this case the table can only be accessed by certain special opcodes, like
loscil and tab."

also the gen01 page could be updated, mentioning that non-power-of-two can
be used not only by loscil but also by the tab opcode.

best,

lj