problem with pluck: error: Use of i() with expression not permitted on line 1936394873
| Date | 2015-12-22 22:50 |
| From | Richard |
| Subject | problem with pluck: error: Use of i() with expression not permitted on line 1936394873 |
I got this weird messages on an instrument:
error: Use of i() with expression not permitted on line 1936394873
error: Use of i() with expression not permitted on line 1936394874
...
Obviously my instrument is not that big...
Here is a part of it:
kenv madsr 0.001, 0, iamp, 0.2
asig1 pluck kenv, (icps), icps, 0, 3, 0, 0
asig2 pluck kenv, (icps*(1+kspread)), i(icps*(1+kspread)), 0, 3,
.01, 0
asig3 pluck kenv, (icps*(1-kspread)), i(icps*(1-kspread)), 0, 3,
.01, 0
asig4 pluck kenv, (icps*(1+kspread*2)), i(icps*(1+kspread*2)), 0,
3, .01, 0
asig5 pluck kenv, (icps*(1-kspread*2)), i(icps*(1-kspread*2)), 0,
3, .01, 0
Must have something to do with the conversion of datatypes, but what?
Richard
Csound mailing list
Csound@listserv.heanet.ie
https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
Send bugs reports to
https://github.com/csound/csound/issues
Discussions of bugs and features can be posted here |
| Date | 2015-12-22 22:54 |
| From | Kevin Welsh |
| Subject | Re: problem with pluck: error: Use of i() with expression not permitted on line 1936394873 |
Try moving the arithmetic that you have happening inside of the i() statement to outside of it, the i() should only contain a variable at a different rate. It's annoying to have to do it that way, but easy enough to workaround. On Tue, Dec 22, 2015 at 5:50 PM, Richard |
| Date | 2015-12-22 23:00 |
| From | Victor Lazzarini |
| Subject | Re: problem with pluck: error: Use of i() with expression not permitted on line 1936394873 |
As the message says, i(.) cannot take expressions, it has to be a single variable. Try ival = icps*(1+kspread) asig2 pluck kenv, (icps*(1+kspread)), i(ival), 0, 3, .01, 0 ======================== Dr Victor Lazzarini Dean of Arts, Celtic Studies and Philosophy, Maynooth University, Maynooth, Co Kildare, Ireland Tel: 00 353 7086936 Fax: 00 353 1 7086952 > On 22 Dec 2015, at 22:50, Richard |
| Date | 2015-12-22 23:05 |
| From | Kevin Welsh |
| Subject | Re: problem with pluck: error: Use of i() with expression not permitted on line 1936394873 |
I'm by no means the csound guru you are, but I think that maybe it should be: kval = icps*(1+kspread) asig2 pluck kenv, (icps*(1+kspread)), i(kval), 0, 3, .01, 0 If not, I would imagine ival only gets set once at init time, so any changes to kspread would be lost. On Tue, Dec 22, 2015 at 6:00 PM, Victor Lazzarini |
| Date | 2015-12-22 23:12 |
| From | Richard |
| Subject | Re: problem with pluck: error: Use of i() with expression not permitted on line 1936394873 |
Thanks Kevin and Victor, simplifying the i() to one variable solved the error message... Richard On 23/12/15 00:00, Victor Lazzarini wrote: > As the message says, i(.) cannot take expressions, it has to be a single variable. > > Try > > ival = icps*(1+kspread) > asig2 pluck kenv, (icps*(1+kspread)), i(ival), 0, 3, .01, 0 > > ======================== > Dr Victor Lazzarini > Dean of Arts, Celtic Studies and Philosophy, > Maynooth University, > Maynooth, Co Kildare, Ireland > Tel: 00 353 7086936 > Fax: 00 353 1 7086952 > >> On 22 Dec 2015, at 22:50, Richard |
| Date | 2015-12-23 09:37 |
| From | Richard |
| Subject | Re: problem with pluck: error: Use of i() with expression not permitted on line 1936394873 |
I'm afraid this does not work. I get: Unable to find opcode entry for '=' with matching argument types: Found: i = k Richard On 23/12/15 00:00, Victor Lazzarini wrote: > As the message says, i(.) cannot take expressions, it has to be a single variable. > > Try > > ival = icps*(1+kspread) > asig2 pluck kenv, (icps*(1+kspread)), i(ival), 0, 3, .01, 0 > > ======================== > Dr Victor Lazzarini > Dean of Arts, Celtic Studies and Philosophy, > Maynooth University, > Maynooth, Co Kildare, Ireland > Tel: 00 353 7086936 > Fax: 00 353 1 7086952 > >> On 22 Dec 2015, at 22:50, Richard |
| Date | 2015-12-23 10:04 |
| From | jpff |
| Subject | Re: problem with pluck: error: Use of i() with expression not permitted on line 1936394873 |
ival = icps*(1+i(kspread)) surely On Wed, 23 Dec 2015, Richard wrote: > I'm afraid this does not work. I get: > Unable to find opcode entry for '=' with matching argument types: > Found: i = k > > Richard > > On 23/12/15 00:00, Victor Lazzarini wrote: >> As the message says, i(.) cannot take expressions, it has to be a single >> variable. >> >> Try >> >> ival = icps*(1+kspread) >> asig2 pluck kenv, (icps*(1+kspread)), i(ival), 0, 3, .01, 0 >> >> ======================== >> Dr Victor Lazzarini >> Dean of Arts, Celtic Studies and Philosophy, >> Maynooth University, >> Maynooth, Co Kildare, Ireland >> Tel: 00 353 7086936 >> Fax: 00 353 1 7086952 >> >>> On 22 Dec 2015, at 22:50, Richard |
| Date | 2015-12-23 10:13 |
| From | Victor Lazzarini |
| Subject | Re: problem with pluck: error: Use of i() with expression not permitted on line 1936394873 |
ival = icps * (1 + i(kspread)) Sorry, it was late last night... Victor Lazzarini Dean of Arts, Celtic Studies, and Philosophy Maynooth University Ireland > On 23 Dec 2015, at 09:37, Richard |