table index

View: New views
3 Messages — Rating Filter:   Alert me  

table index

by francibal :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi dear All,

i have a doubt ...

i'm using a table (gen 2), and i am reading values with table opcode.
for indexing i use a simple line opcode (but i have tried also phasor).

BUT: i need to specify index from 0 to lenght of table. Was not possible to use only index values from 0 to 1? I'm a little bit confused, because if i remember correct i always used index from 0 to 1 (normalized?), but probably i miss somethings.

Maybe it is because i'm using neg size and neg p4?
Or it is gen 2?

Thanks from a doubtman,

ciao,
fran.

Here is my trivial csd:

<CsoundSynthesizer>
<CsOptions>
-B8192 -odac
</CsOptions>
<CsInstruments>

sr = 48000
ksmps = 1
nchnls = 2
0dbfs = 1.0

instr 1
; this do not work
;kind line 0, p3, 1
; this work well
kind line 0, p3, ftlen(10)

printk 1, kind

kval table kind, 10

printk 1, kval

endin

</CsInstruments>
<CsScore>

f10 0 -12 -2  17.089088446  52.014754066  91.6284281219  15.2266483107  42.2226077421  79.7965969081  18.4488127373  59.6271700331  95.4067006878  17.3288932566  53.3301087396  92.6525014895

i1 0 12
</CsScore>
</CsoundSynthesizer>

Re: table index

by Victor Lazzarini :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Try

kndx line 0, p3, 1
ktab table kndx, 10, 1

Victor
On 7 Nov 2009, at 12:33, francibal wrote:

>
> Hi dear All,
>
> i have a doubt ...
>
> i'm using a table (gen 2), and i am reading values with table opcode.
> for indexing i use a simple line opcode (but i have tried also  
> phasor).
>
> BUT: i need to specify index from 0 to lenght of table. Was not  
> possible to
> use only index values from 0 to 1? I'm a little bit confused,  
> because if i
> remember correct i always used index from 0 to 1 (normalized?), but  
> probably
> i miss somethings.
>
> Maybe it is because i'm using neg size and neg p4?
> Or it is gen 2?
>
> Thanks from a doubtman,
>
> ciao,
> fran.
>
> Here is my trivial csd:
>
> <CsoundSynthesizer>
> <CsOptions>
> -B8192 -odac
> </CsOptions>
> <CsInstruments>
>
> sr = 48000
> ksmps = 1
> nchnls = 2
> 0dbfs = 1.0
>
> instr 1
> ; this do not work
> ;kind line 0, p3, 1
> ; this work well
> kind line 0, p3, ftlen(10)
>
> printk 1, kind
>
> kval table kind, 10
>
> printk 1, kval
>
> endin
>
> </CsInstruments>
> <CsScore>
>
> f10 0 -12 -2  17.089088446  52.014754066  91.6284281219  15.2266483107
> 42.2226077421  79.7965969081  18.4488127373  59.6271700331  
> 95.4067006878
> 17.3288932566  53.3301087396  92.6525014895
>
> i1 0 12
> </CsScore>
> </CsoundSynthesizer>
>
> --
> View this message in context: http://old.nabble.com/table-index-tp26240924p26240924.html
> Sent from the Csound - General mailing list archive at Nabble.com.
>
>
>
> Send bugs reports to this list.
> To unsubscribe, send email sympa@... with body  
> "unsubscribe csound"



Send bugs reports to this list.
To unsubscribe, send email sympa@... with body "unsubscribe csound"

Re: Re: table index

by francibal :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Yes, thanks Mr. Victor,
i see what i've missed ...

i'm not always so idiot, frequently, but not always.

Thank You,

ciao,
fran.

----- Original Message -----
From: "Victor Lazzarini" <Victor.Lazzarini@...>
To: <csound@...>
Sent: Saturday, November 07, 2009 2:15 PM
Subject: [Csnd] Re: table index


> Try
>
> kndx line 0, p3, 1
> ktab table kndx, 10, 1
>
> Victor
> On 7 Nov 2009, at 12:33, francibal wrote:
>
>>
>> Hi dear All,
>>
>> i have a doubt ...
>>
>> i'm using a table (gen 2), and i am reading values with table opcode.
>> for indexing i use a simple line opcode (but i have tried also  phasor).
>>
>> BUT: i need to specify index from 0 to lenght of table. Was not  possible
>> to
>> use only index values from 0 to 1? I'm a little bit confused,  because if
>> i
>> remember correct i always used index from 0 to 1 (normalized?), but
>> probably
>> i miss somethings.
>>
>> Maybe it is because i'm using neg size and neg p4?
>> Or it is gen 2?
>>
>> Thanks from a doubtman,
>>
>> ciao,
>> fran.
>>
>> Here is my trivial csd:
>>
>> <CsoundSynthesizer>
>> <CsOptions>
>> -B8192 -odac
>> </CsOptions>
>> <CsInstruments>
>>
>> sr = 48000
>> ksmps = 1
>> nchnls = 2
>> 0dbfs = 1.0
>>
>> instr 1
>> ; this do not work
>> ;kind line 0, p3, 1
>> ; this work well
>> kind line 0, p3, ftlen(10)
>>
>> printk 1, kind
>>
>> kval table kind, 10
>>
>> printk 1, kval
>>
>> endin
>>
>> </CsInstruments>
>> <CsScore>
>>
>> f10 0 -12 -2  17.089088446  52.014754066  91.6284281219  15.2266483107
>> 42.2226077421  79.7965969081  18.4488127373  59.6271700331
>> 95.4067006878
>> 17.3288932566  53.3301087396  92.6525014895
>>
>> i1 0 12
>> </CsScore>
>> </CsoundSynthesizer>
>>
>> --
>> View this message in context:
>> http://old.nabble.com/table-index-tp26240924p26240924.html
>> Sent from the Csound - General mailing list archive at Nabble.com.
>>
>>
>>
>> Send bugs reports to this list.
>> To unsubscribe, send email sympa@... with body  "unsubscribe
>> csound"
>
>
>
> Send bugs reports to this list.
> To unsubscribe, send email sympa@... with body "unsubscribe
> csound"



Send bugs reports to this list.
To unsubscribe, send email sympa@... with body "unsubscribe csound"