error with tab_i opcode

classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

error with tab_i opcode

Stefan Thomas-2
Dear community,
with the below quoted .csd-file a get the following error message:
PERF ERROR: tab_i off end
Early return from csoundPerform().
inactive allocs returned to freespace
When I substitute tab_i with table it works as expexted. But I would like to understand why this happens.
Here is my code:

<CsoundSynthesizer>
<CsOptions>
-odac
</CsOptions>

<CsInstruments>

sr    =    48000
ksmps     =     100
nchnls    =    1
0dbfs    =    1
giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001       
gisine            ftgen   0,0,2^10,10,1
instr 1   
iamp = 1
icps = 440
indx = p4

    iattScl tab_i        indx,giAttTimeModalAdsyn,1 ; this causes an error
asig oscil     iamp, icps, gisine
aenv linseg       0, 0.01*iattScl, iamp
aout = aenv*asig
out aout
endin

</CsInstruments>
; ==============================================
<CsScore>
;     indx
i1 0 1 1
i1 2 1 70
e

</CsScore>
</CsoundSynthesizer>



Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: error with tab_i opcode

jpff
70 is not in range 0-127

use mode 0




 Dear community,

> with the below quoted .csd-file a get the following error message:
> PERF ERROR: tab_i off end
> Early return from csoundPerform().
> inactive allocs returned to freespace
> When I substitute tab_i with table it works as expexted. But I would like
> to understand why this happens.
> Here is my code:
>
> <CsoundSynthesizer>
> <CsOptions>
> -odac
> </CsOptions>
>
> <CsInstruments>
>
> sr    =    48000
> ksmps     =     100
> nchnls    =    1
> 0dbfs    =    1
> giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001
> gisine            ftgen   0,0,2^10,10,1
> instr 1
> iamp = 1
> icps = 440
> indx = p4
>
>     iattScl tab_i        indx,giAttTimeModalAdsyn,1 ; this causes an error
> asig oscil     iamp, icps, gisine
> aenv linseg       0, 0.01*iattScl, iamp
> aout = aenv*asig
> out aout
> endin
>
> </CsInstruments>
> ; ==============================================
> <CsScore>
> ;     indx
> i1 0 1 1
> i1 2 1 70
> e
>
> </CsScore>
> </CsoundSynthesizer>
>
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email [hidden email] with body "unsubscribe
> csound"
>
>




Send bugs reports to the Sourceforge bug tracker
            https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email [hidden email] with body "unsubscribe csound"

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: error with tab_i opcode

Stefan Thomas-2
Why is 70 not in range 0-127???

Am 20. Februar 2012 21:38 schrieb <[hidden email]>:
70 is not in range 0-127

use mode 0




 Dear community,
> with the below quoted .csd-file a get the following error message:
> PERF ERROR: tab_i off end
> Early return from csoundPerform().
> inactive allocs returned to freespace
> When I substitute tab_i with table it works as expexted. But I would like
> to understand why this happens.
> Here is my code:
>
> <CsoundSynthesizer>
> <CsOptions>
> -odac
> </CsOptions>
>
> <CsInstruments>
>
> sr    =    48000
> ksmps     =     100
> nchnls    =    1
> 0dbfs    =    1
> giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001
> gisine            ftgen   0,0,2^10,10,1
> instr 1
> iamp = 1
> icps = 440
> indx = p4
>
>     iattScl tab_i        indx,giAttTimeModalAdsyn,1 ; this causes an error
> asig oscil     iamp, icps, gisine
> aenv linseg       0, 0.01*iattScl, iamp
> aout = aenv*asig
> out aout
> endin
>
> </CsInstruments>
> ; ==============================================
> <CsScore>
> ;     indx
> i1 0 1 1
> i1 2 1 70
> e
>
> </CsScore>
> </CsoundSynthesizer>
>
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email [hidden email] with body "unsubscribe
> csound"
>
>




Send bugs reports to the Sourceforge bug tracker
           https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email [hidden email] with body "unsubscribe csound"


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: error with tab_i opcode

Stefan Thomas-2
Sorry,
I've understand, mode 1 means normalization and does not a value above 1. But why does the code work, when I choose table instead of tab_i?

Am 20. Februar 2012 22:08 schrieb Stefan Thomas <[hidden email]>:
Why is 70 not in range 0-127???

Am 20. Februar 2012 21:38 schrieb <[hidden email]>:

70 is not in range 0-127

use mode 0




 Dear community,
> with the below quoted .csd-file a get the following error message:
> PERF ERROR: tab_i off end
> Early return from csoundPerform().
> inactive allocs returned to freespace
> When I substitute tab_i with table it works as expexted. But I would like
> to understand why this happens.
> Here is my code:
>
> <CsoundSynthesizer>
> <CsOptions>
> -odac
> </CsOptions>
>
> <CsInstruments>
>
> sr    =    48000
> ksmps     =     100
> nchnls    =    1
> 0dbfs    =    1
> giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001
> gisine            ftgen   0,0,2^10,10,1
> instr 1
> iamp = 1
> icps = 440
> indx = p4
>
>     iattScl tab_i        indx,giAttTimeModalAdsyn,1 ; this causes an error
> asig oscil     iamp, icps, gisine
> aenv linseg       0, 0.01*iattScl, iamp
> aout = aenv*asig
> out aout
> endin
>
> </CsInstruments>
> ; ==============================================
> <CsScore>
> ;     indx
> i1 0 1 1
> i1 2 1 70
> e
>
> </CsScore>
> </CsoundSynthesizer>
>
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email [hidden email] with body "unsubscribe
> csound"
>
>




Send bugs reports to the Sourceforge bug tracker
           https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email [hidden email] with body "unsubscribe csound"



Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: error with tab_i opcode

peiman
yes, I was just about to say that.

P


On 20 February 2012 21:10, Stefan Thomas <[hidden email]> wrote:
Sorry,
I've understand, mode 1 means normalization and does not a value above 1. But why does the code work, when I choose table instead of tab_i?

Am 20. Februar 2012 22:08 schrieb Stefan Thomas <[hidden email]>:

Why is 70 not in range 0-127???

Am 20. Februar 2012 21:38 schrieb <[hidden email]>:

70 is not in range 0-127

use mode 0




 Dear community,
> with the below quoted .csd-file a get the following error message:
> PERF ERROR: tab_i off end
> Early return from csoundPerform().
> inactive allocs returned to freespace
> When I substitute tab_i with table it works as expexted. But I would like
> to understand why this happens.
> Here is my code:
>
> <CsoundSynthesizer>
> <CsOptions>
> -odac
> </CsOptions>
>
> <CsInstruments>
>
> sr    =    48000
> ksmps     =     100
> nchnls    =    1
> 0dbfs    =    1
> giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001
> gisine            ftgen   0,0,2^10,10,1
> instr 1
> iamp = 1
> icps = 440
> indx = p4
>
>     iattScl tab_i        indx,giAttTimeModalAdsyn,1 ; this causes an error
> asig oscil     iamp, icps, gisine
> aenv linseg       0, 0.01*iattScl, iamp
> aout = aenv*asig
> out aout
> endin
>
> </CsInstruments>
> ; ==============================================
> <CsScore>
> ;     indx
> i1 0 1 1
> i1 2 1 70
> e
>
> </CsScore>
> </CsoundSynthesizer>
>
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email [hidden email] with body "unsubscribe
> csound"
>
>




Send bugs reports to the Sourceforge bug tracker
           https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email [hidden email] with body "unsubscribe csound"




Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: error with tab_i opcode

Stefan Thomas-2
I mean, I don't care if it works with table instead of tab_i, but couldn't be there a drawback? I think tab_i is much faster and this could be of advantage if I make use of midi, couldn't it?

Am 20. Februar 2012 22:13 schrieb peiman khosravi <[hidden email]>:
yes, I was just about to say that.

P



On 20 February 2012 21:10, Stefan Thomas <[hidden email]> wrote:
Sorry,
I've understand, mode 1 means normalization and does not a value above 1. But why does the code work, when I choose table instead of tab_i?

Am 20. Februar 2012 22:08 schrieb Stefan Thomas <[hidden email]>:

Why is 70 not in range 0-127???

Am 20. Februar 2012 21:38 schrieb <[hidden email]>:

70 is not in range 0-127

use mode 0




 Dear community,
> with the below quoted .csd-file a get the following error message:
> PERF ERROR: tab_i off end
> Early return from csoundPerform().
> inactive allocs returned to freespace
> When I substitute tab_i with table it works as expexted. But I would like
> to understand why this happens.
> Here is my code:
>
> <CsoundSynthesizer>
> <CsOptions>
> -odac
> </CsOptions>
>
> <CsInstruments>
>
> sr    =    48000
> ksmps     =     100
> nchnls    =    1
> 0dbfs    =    1
> giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001
> gisine            ftgen   0,0,2^10,10,1
> instr 1
> iamp = 1
> icps = 440
> indx = p4
>
>     iattScl tab_i        indx,giAttTimeModalAdsyn,1 ; this causes an error
> asig oscil     iamp, icps, gisine
> aenv linseg       0, 0.01*iattScl, iamp
> aout = aenv*asig
> out aout
> endin
>
> </CsInstruments>
> ; ==============================================
> <CsScore>
> ;     indx
> i1 0 1 1
> i1 2 1 70
> e
>
> </CsScore>
> </CsoundSynthesizer>
>
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email [hidden email] with body "unsubscribe
> csound"
>
>




Send bugs reports to the Sourceforge bug tracker
           https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email [hidden email] with body "unsubscribe csound"





Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: error with tab_i opcode

peiman


From the 'table' manual page:

iwrap (optional) -- wraparound index flag. The default value is 0.

  • 0 = nowrap (index < 0 treated as index=0; index > tablesize sticks at index=size)

P

On 20 February 2012 21:29, Stefan Thomas <[hidden email]> wrote:
I mean, I don't care if it works with table instead of tab_i, but couldn't be there a drawback? I think tab_i is much faster and this could be of advantage if I make use of midi, couldn't it?

Am 20. Februar 2012 22:13 schrieb peiman khosravi <[hidden email]>:

yes, I was just about to say that.

P



On 20 February 2012 21:10, Stefan Thomas <[hidden email]> wrote:
Sorry,
I've understand, mode 1 means normalization and does not a value above 1. But why does the code work, when I choose table instead of tab_i?

Am 20. Februar 2012 22:08 schrieb Stefan Thomas <[hidden email]>:

Why is 70 not in range 0-127???

Am 20. Februar 2012 21:38 schrieb <[hidden email]>:

70 is not in range 0-127

use mode 0




 Dear community,
> with the below quoted .csd-file a get the following error message:
> PERF ERROR: tab_i off end
> Early return from csoundPerform().
> inactive allocs returned to freespace
> When I substitute tab_i with table it works as expexted. But I would like
> to understand why this happens.
> Here is my code:
>
> <CsoundSynthesizer>
> <CsOptions>
> -odac
> </CsOptions>
>
> <CsInstruments>
>
> sr    =    48000
> ksmps     =     100
> nchnls    =    1
> 0dbfs    =    1
> giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001
> gisine            ftgen   0,0,2^10,10,1
> instr 1
> iamp = 1
> icps = 440
> indx = p4
>
>     iattScl tab_i        indx,giAttTimeModalAdsyn,1 ; this causes an error
> asig oscil     iamp, icps, gisine
> aenv linseg       0, 0.01*iattScl, iamp
> aout = aenv*asig
> out aout
> endin
>
> </CsInstruments>
> ; ==============================================
> <CsScore>
> ;     indx
> i1 0 1 1
> i1 2 1 70
> e
>
> </CsScore>
> </CsoundSynthesizer>
>
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email [hidden email] with body "unsubscribe
> csound"
>
>




Send bugs reports to the Sourceforge bug tracker
           https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email [hidden email] with body "unsubscribe csound"






Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: error with tab_i opcode

Victor Lazzarini
In reply to this post by Stefan Thomas-2
no, 70 is not in the range 0 to 1 (mode 1). use mode 0



On 20 Feb 2012, at 21:08, Stefan Thomas <[hidden email]> wrote:

Why is 70 not in range 0-127???

Am 20. Februar 2012 21:38 schrieb <[hidden email]>:
70 is not in range 0-127

use mode 0




 Dear community,
> with the below quoted .csd-file a get the following error message:
> PERF ERROR: tab_i off end
> Early return from csoundPerform().
> inactive allocs returned to freespace
> When I substitute tab_i with table it works as expexted. But I would like
> to understand why this happens.
> Here is my code:
>
> <CsoundSynthesizer>
> <CsOptions>
> -odac
> </CsOptions>
>
> <CsInstruments>
>
> sr    =    48000
> ksmps     =     100
> nchnls    =    1
> 0dbfs    =    1
> giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001
> gisine            ftgen   0,0,2^10,10,1
> instr 1
> iamp = 1
> icps = 440
> indx = p4
>
>     iattScl tab_i        indx,giAttTimeModalAdsyn,1 ; this causes an error
> asig oscil     iamp, icps, gisine
> aenv linseg       0, 0.01*iattScl, iamp
> aout = aenv*asig
> out aout
> endin
>
> </CsInstruments>
> ; ==============================================
> <CsScore>
> ;     indx
> i1 0 1 1
> i1 2 1 70
> e
>
> </CsScore>
> </CsoundSynthesizer>
>
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email [hidden email] with body "unsubscribe
> csound"
>
>




Send bugs reports to the Sourceforge bug tracker
           https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email [hidden email] with body "unsubscribe csound"


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: error with tab_i opcode

Victor Lazzarini
In reply to this post by peiman
with table, it is probably not doing what you want.



On 20 Feb 2012, at 21:34, peiman khosravi <[hidden email]> wrote:


From the 'table' manual page:

iwrap (optional) -- wraparound index flag. The default value is 0.

  • 0 = nowrap (index < 0 treated as index=0; index > tablesize sticks at index=size)

P

On 20 February 2012 21:29, Stefan Thomas <[hidden email]> wrote:
I mean, I don't care if it works with table instead of tab_i, but couldn't be there a drawback? I think tab_i is much faster and this could be of advantage if I make use of midi, couldn't it?

Am 20. Februar 2012 22:13 schrieb peiman khosravi <[hidden email]>:

yes, I was just about to say that.

P



On 20 February 2012 21:10, Stefan Thomas <[hidden email]> wrote:
Sorry,
I've understand, mode 1 means normalization and does not a value above 1. But why does the code work, when I choose table instead of tab_i?

Am 20. Februar 2012 22:08 schrieb Stefan Thomas <[hidden email]>:

Why is 70 not in range 0-127???

Am 20. Februar 2012 21:38 schrieb <[hidden email]>:

70 is not in range 0-127

use mode 0




 Dear community,
> with the below quoted .csd-file a get the following error message:
> PERF ERROR: tab_i off end
> Early return from csoundPerform().
> inactive allocs returned to freespace
> When I substitute tab_i with table it works as expexted. But I would like
> to understand why this happens.
> Here is my code:
>
> <CsoundSynthesizer>
> <CsOptions>
> -odac
> </CsOptions>
>
> <CsInstruments>
>
> sr    =    48000
> ksmps     =     100
> nchnls    =    1
> 0dbfs    =    1
> giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001
> gisine            ftgen   0,0,2^10,10,1
> instr 1
> iamp = 1
> icps = 440
> indx = p4
>
>     iattScl tab_i        indx,giAttTimeModalAdsyn,1 ; this causes an error
> asig oscil     iamp, icps, gisine
> aenv linseg       0, 0.01*iattScl, iamp
> aout = aenv*asig
> out aout
> endin
>
> </CsInstruments>
> ; ==============================================
> <CsScore>
> ;     indx
> i1 0 1 1
> i1 2 1 70
> e
>
> </CsScore>
> </CsoundSynthesizer>
>
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email [hidden email] with body "unsubscribe
> csound"
>
>




Send bugs reports to the Sourceforge bug tracker
           https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email [hidden email] with body "unsubscribe csound"






Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: error with tab_i opcode

Stefan Thomas-2
What's the difference in behaviour?

Am 20. Februar 2012 23:04 schrieb Victor <[hidden email]>:
with table, it is probably not doing what you want.



On 20 Feb 2012, at 21:34, peiman khosravi <[hidden email]> wrote:


From the 'table' manual page:

iwrap (optional) -- wraparound index flag. The default value is 0.

  • 0 = nowrap (index < 0 treated as index=0; index > tablesize sticks at index=size)

P

On 20 February 2012 21:29, Stefan Thomas <[hidden email]> wrote:
I mean, I don't care if it works with table instead of tab_i, but couldn't be there a drawback? I think tab_i is much faster and this could be of advantage if I make use of midi, couldn't it?

Am 20. Februar 2012 22:13 schrieb peiman khosravi <[hidden email]>:

yes, I was just about to say that.

P



On 20 February 2012 21:10, Stefan Thomas <[hidden email]> wrote:
Sorry,
I've understand, mode 1 means normalization and does not a value above 1. But why does the code work, when I choose table instead of tab_i?

Am 20. Februar 2012 22:08 schrieb Stefan Thomas <[hidden email]>:

Why is 70 not in range 0-127???

Am 20. Februar 2012 21:38 schrieb <[hidden email]>:

70 is not in range 0-127

use mode 0




 Dear community,
> with the below quoted .csd-file a get the following error message:
> PERF ERROR: tab_i off end
> Early return from csoundPerform().
> inactive allocs returned to freespace
> When I substitute tab_i with table it works as expexted. But I would like
> to understand why this happens.
> Here is my code:
>
> <CsoundSynthesizer>
> <CsOptions>
> -odac
> </CsOptions>
>
> <CsInstruments>
>
> sr    =    48000
> ksmps     =     100
> nchnls    =    1
> 0dbfs    =    1
> giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001
> gisine            ftgen   0,0,2^10,10,1
> instr 1
> iamp = 1
> icps = 440
> indx = p4
>
>     iattScl tab_i        indx,giAttTimeModalAdsyn,1 ; this causes an error
> asig oscil     iamp, icps, gisine
> aenv linseg       0, 0.01*iattScl, iamp
> aout = aenv*asig
> out aout
> endin
>
> </CsInstruments>
> ; ==============================================
> <CsScore>
> ;     indx
> i1 0 1 1
> i1 2 1 70
> e
>
> </CsScore>
> </CsoundSynthesizer>
>
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email [hidden email] with body "unsubscribe
> csound"
>
>




Send bugs reports to the Sourceforge bug tracker
           https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email [hidden email] with body "unsubscribe csound"







Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: error with tab_i opcode

peiman
From the 'table' manual page:

iwrap (optional) -- wraparound index flag. The default value is 0.

  • 0 = nowrap (index < 0 treated as index=0; index > tablesize sticks at index=size)


Meaning that the index remains on the maximum as opposed to going out of range. So it is just outputting the value of the last index.

Best,

P

 

On 20 February 2012 22:16, Stefan Thomas <[hidden email]> wrote:
What's the difference in behaviour?

Am 20. Februar 2012 23:04 schrieb Victor <[hidden email]>:

with table, it is probably not doing what you want.



On 20 Feb 2012, at 21:34, peiman khosravi <[hidden email]> wrote:


From the 'table' manual page:

iwrap (optional) -- wraparound index flag. The default value is 0.

  • 0 = nowrap (index < 0 treated as index=0; index > tablesize sticks at index=size)

P

On 20 February 2012 21:29, Stefan Thomas <[hidden email]> wrote:
I mean, I don't care if it works with table instead of tab_i, but couldn't be there a drawback? I think tab_i is much faster and this could be of advantage if I make use of midi, couldn't it?

Am 20. Februar 2012 22:13 schrieb peiman khosravi <[hidden email]>:

yes, I was just about to say that.

P



On 20 February 2012 21:10, Stefan Thomas <[hidden email]> wrote:
Sorry,
I've understand, mode 1 means normalization and does not a value above 1. But why does the code work, when I choose table instead of tab_i?

Am 20. Februar 2012 22:08 schrieb Stefan Thomas <[hidden email]>:

Why is 70 not in range 0-127???

Am 20. Februar 2012 21:38 schrieb <[hidden email]>:

70 is not in range 0-127

use mode 0




 Dear community,
> with the below quoted .csd-file a get the following error message:
> PERF ERROR: tab_i off end
> Early return from csoundPerform().
> inactive allocs returned to freespace
> When I substitute tab_i with table it works as expexted. But I would like
> to understand why this happens.
> Here is my code:
>
> <CsoundSynthesizer>
> <CsOptions>
> -odac
> </CsOptions>
>
> <CsInstruments>
>
> sr    =    48000
> ksmps     =     100
> nchnls    =    1
> 0dbfs    =    1
> giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001
> gisine            ftgen   0,0,2^10,10,1
> instr 1
> iamp = 1
> icps = 440
> indx = p4
>
>     iattScl tab_i        indx,giAttTimeModalAdsyn,1 ; this causes an error
> asig oscil     iamp, icps, gisine
> aenv linseg       0, 0.01*iattScl, iamp
> aout = aenv*asig
> out aout
> endin
>
> </CsInstruments>
> ; ==============================================
> <CsScore>
> ;     indx
> i1 0 1 1
> i1 2 1 70
> e
>
> </CsScore>
> </CsoundSynthesizer>
>
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email [hidden email] with body "unsubscribe
> csound"
>
>




Send bugs reports to the Sourceforge bug tracker
           https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email [hidden email] with body "unsubscribe csound"








Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: error with tab_i opcode

Stefan Thomas-2
Just to be sure, if I've understood everything right:
When I use tab_i with xmode 0 it allows only indexes between 0 and 1, right?
But it shouldn't crash wich index = 1, should it?
In the below quoted example I get a crash for partial number 30 and I wouldn't expect it:
 %%%%%%%%%%%%%%% snippet
<CsoundSynthesizer>
<CsOptions>
-odac
</CsOptions>
; ==============================================
<CsInstruments>

sr    =    48000
ksmps     =     100
nchnls    =    1
0dbfs    =    1
giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001       
gisine            ftgen   0,0,2^10,10,1
instr 1   
iamp = 1
icps = 440
indx = p4
inumparts = 30
ipartnumber = p4
ibrigthness = p5
iAmpCurveModalAdsyn    ftgen    0,0,128,-16,1,128,ibrigthness,0       
    ipartamp    tab_i    (ipartnumber-1)/(inumparts-1),iAmpCurveModalAdsyn,1
print ipartamp
endin

</CsInstruments>
; ==============================================
<CsScore>
;      partial ibrigthness
i1 0 2 30     -4

e

</CsScore>
</CsoundSynthesizer>


%% END SNIPPET %%%%%%%%%%%%%

Am 20. Februar 2012 23:18 schrieb peiman khosravi <[hidden email]>:
From the 'table' manual page:

iwrap (optional) -- wraparound index flag. The default value is 0.

  • 0 = nowrap (index < 0 treated as index=0; index > tablesize sticks at index=size)


Meaning that the index remains on the maximum as opposed to going out of range. So it is just outputting the value of the last index.

Best,

P

 

On 20 February 2012 22:16, Stefan Thomas <[hidden email]> wrote:
What's the difference in behaviour?

Am 20. Februar 2012 23:04 schrieb Victor <[hidden email]>:

with table, it is probably not doing what you want.



On 20 Feb 2012, at 21:34, peiman khosravi <[hidden email]> wrote:


From the 'table' manual page:

iwrap (optional) -- wraparound index flag. The default value is 0.

  • 0 = nowrap (index < 0 treated as index=0; index > tablesize sticks at index=size)

P

On 20 February 2012 21:29, Stefan Thomas <[hidden email]> wrote:
I mean, I don't care if it works with table instead of tab_i, but couldn't be there a drawback? I think tab_i is much faster and this could be of advantage if I make use of midi, couldn't it?

Am 20. Februar 2012 22:13 schrieb peiman khosravi <[hidden email]>:

yes, I was just about to say that.

P



On 20 February 2012 21:10, Stefan Thomas <[hidden email]> wrote:
Sorry,
I've understand, mode 1 means normalization and does not a value above 1. But why does the code work, when I choose table instead of tab_i?

Am 20. Februar 2012 22:08 schrieb Stefan Thomas <[hidden email]>:

Why is 70 not in range 0-127???

Am 20. Februar 2012 21:38 schrieb <[hidden email]>:

70 is not in range 0-127

use mode 0




 Dear community,
> with the below quoted .csd-file a get the following error message:
> PERF ERROR: tab_i off end
> Early return from csoundPerform().
> inactive allocs returned to freespace
> When I substitute tab_i with table it works as expexted. But I would like
> to understand why this happens.
> Here is my code:
>
> <CsoundSynthesizer>
> <CsOptions>
> -odac
> </CsOptions>
>
> <CsInstruments>
>
> sr    =    48000
> ksmps     =     100
> nchnls    =    1
> 0dbfs    =    1
> giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001
> gisine            ftgen   0,0,2^10,10,1
> instr 1
> iamp = 1
> icps = 440
> indx = p4
>
>     iattScl tab_i        indx,giAttTimeModalAdsyn,1 ; this causes an error
> asig oscil     iamp, icps, gisine
> aenv linseg       0, 0.01*iattScl, iamp
> aout = aenv*asig
> out aout
> endin
>
> </CsInstruments>
> ; ==============================================
> <CsScore>
> ;     indx
> i1 0 1 1
> i1 2 1 70
> e
>
> </CsScore>
> </CsoundSynthesizer>
>
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email [hidden email] with body "unsubscribe
> csound"
>
>




Send bugs reports to the Sourceforge bug tracker
           https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email [hidden email] with body "unsubscribe csound"









Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: error with tab_i opcode

peiman
I just found this thread: http://csound.1045644.n5.nabble.com/tab-opcode-td3799415.html#a3859283

"1 denotes N in a table ranging from 0 to N-1"

Maybe this should be mentioned in the manual?

P

On 21 February 2012 09:10, Stefan Thomas <[hidden email]> wrote:
Just to be sure, if I've understood everything right:
When I use tab_i with xmode 0 it allows only indexes between 0 and 1, right?
But it shouldn't crash wich index = 1, should it?
In the below quoted example I get a crash for partial number 30 and I wouldn't expect it:
 %%%%%%%%%%%%%%% snippet
<CsoundSynthesizer>
<CsOptions>
-odac
</CsOptions>
; ==============================================

<CsInstruments>

sr    =    48000
ksmps     =     100
nchnls    =    1
0dbfs    =    1
giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001       
gisine            ftgen   0,0,2^10,10,1
instr 1   
iamp = 1
icps = 440
indx = p4
inumparts = 30
ipartnumber = p4
ibrigthness = p5
iAmpCurveModalAdsyn    ftgen    0,0,128,-16,1,128,ibrigthness,0       
    ipartamp    tab_i    (ipartnumber-1)/(inumparts-1),iAmpCurveModalAdsyn,1
print ipartamp
endin

</CsInstruments>
; ==============================================
<CsScore>
;      partial ibrigthness
i1 0 2 30     -4

e

</CsScore>
</CsoundSynthesizer>


%% END SNIPPET %%%%%%%%%%%%%

Am 20. Februar 2012 23:18 schrieb peiman khosravi <[hidden email]>:

From the 'table' manual page:

iwrap (optional) -- wraparound index flag. The default value is 0.

  • 0 = nowrap (index < 0 treated as index=0; index > tablesize sticks at index=size)


Meaning that the index remains on the maximum as opposed to going out of range. So it is just outputting the value of the last index.

Best,

P

 

On 20 February 2012 22:16, Stefan Thomas <[hidden email]> wrote:
What's the difference in behaviour?

Am 20. Februar 2012 23:04 schrieb Victor <[hidden email]>:

with table, it is probably not doing what you want.



On 20 Feb 2012, at 21:34, peiman khosravi <[hidden email]> wrote:


From the 'table' manual page:

iwrap (optional) -- wraparound index flag. The default value is 0.

  • 0 = nowrap (index < 0 treated as index=0; index > tablesize sticks at index=size)

P

On 20 February 2012 21:29, Stefan Thomas <[hidden email]> wrote:
I mean, I don't care if it works with table instead of tab_i, but couldn't be there a drawback? I think tab_i is much faster and this could be of advantage if I make use of midi, couldn't it?

Am 20. Februar 2012 22:13 schrieb peiman khosravi <[hidden email]>:

yes, I was just about to say that.

P



On 20 February 2012 21:10, Stefan Thomas <[hidden email]> wrote:
Sorry,
I've understand, mode 1 means normalization and does not a value above 1. But why does the code work, when I choose table instead of tab_i?

Am 20. Februar 2012 22:08 schrieb Stefan Thomas <[hidden email]>:

Why is 70 not in range 0-127???

Am 20. Februar 2012 21:38 schrieb <[hidden email]>:

70 is not in range 0-127

use mode 0




 Dear community,
> with the below quoted .csd-file a get the following error message:
> PERF ERROR: tab_i off end
> Early return from csoundPerform().
> inactive allocs returned to freespace
> When I substitute tab_i with table it works as expexted. But I would like
> to understand why this happens.
> Here is my code:
>
> <CsoundSynthesizer>
> <CsOptions>
> -odac
> </CsOptions>
>
> <CsInstruments>
>
> sr    =    48000
> ksmps     =     100
> nchnls    =    1
> 0dbfs    =    1
> giAttTimeModalAdsyn    ftgen    0,0,128,-16,1,128,0,0.001
> gisine            ftgen   0,0,2^10,10,1
> instr 1
> iamp = 1
> icps = 440
> indx = p4
>
>     iattScl tab_i        indx,giAttTimeModalAdsyn,1 ; this causes an error
> asig oscil     iamp, icps, gisine
> aenv linseg       0, 0.01*iattScl, iamp
> aout = aenv*asig
> out aout
> endin
>
> </CsInstruments>
> ; ==============================================
> <CsScore>
> ;     indx
> i1 0 1 1
> i1 2 1 70
> e
>
> </CsScore>
> </CsoundSynthesizer>
>
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email [hidden email] with body "unsubscribe
> csound"
>
>




Send bugs reports to the Sourceforge bug tracker
           https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email [hidden email] with body "unsubscribe csound"










Loading...