Csound Csound-dev Csound-tekno Search About

[Csnd] A rate functional style envelopes are affected by control rate.

Date2020-07-09 14:56
FromPeter Burgess
Subject[Csnd] A rate functional style envelopes are affected by control rate.
Sorry to keep posting bugs today...

But I've realised that the ksmps affects how my expsegr:a and linsegr:a envelopes sound, with many sensible ksmps values actually causing them to produce silence...

with sr==48000, I get sound if ksmps is set to 1, 12, 24, 48 or 96 (and I'm yet to find any other value that doesn't silence my instruments). When I use ksmps==96, the envelopes act audibly different to when I use ksmps==1.

I'm using functional style syntax. I haven't got a single k rate opcode or variable anywhere, absolutely all my opcode are suffixed with `:i` or `:a`, so it seems odd that the sound would be affected by the control rate at all, even ignoring the weird silence issue.

Pete
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

Date2020-07-09 15:00
FromVictor Lazzarini
SubjectRe: [Csnd] [EXTERNAL] [Csnd] A rate functional style envelopes are affected by control rate.
Try making sure you are actually using arate versions by annotating the opcodes 

opcode:a(…)

========================
Prof. Victor Lazzarini
Maynooth University
Ireland

> On 9 Jul 2020, at 14:56, Peter Burgess  wrote:
> 
> WARNINGThis email originated from outside of Maynooth University's Mail System. Do not reply, click links or open attachments unless you recognise the sender and know the content is safe.
> Sorry to keep posting bugs today...
> 
> But I've realised that the ksmps affects how my expsegr:a and linsegr:a envelopes sound, with many sensible ksmps values actually causing them to produce silence...
> 
> with sr==48000, I get sound if ksmps is set to 1, 12, 24, 48 or 96 (and I'm yet to find any other value that doesn't silence my instruments). When I use ksmps==96, the envelopes act audibly different to when I use ksmps==1.
> 
> I'm using functional style syntax. I haven't got a single k rate opcode or variable anywhere, absolutely all my opcode are suffixed with `:i` or `:a`, so it seems odd that the sound would be affected by the control rate at all, even ignoring the weird silence issue.
> 
> Pete
> 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


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

Date2020-07-09 15:04
FromPeter Burgess
SubjectRe: [Csnd] [EXTERNAL] [Csnd] A rate functional style envelopes are affected by control rate.
That's what I'm saying, I have every opcode annotated with either :a or :i, and not a :k in sight. Every last opcode is definitely annotate, and not a single variable is declared krate.

If I change one of the expsegr:a opcodes to the original non-functional style, it is unaffected by the control rate

On Thu, Jul 9, 2020 at 3:00 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
Try making sure you are actually using arate versions by annotating the opcodes

opcode:a(…)

========================
Prof. Victor Lazzarini
Maynooth University
Ireland

> On 9 Jul 2020, at 14:56, Peter Burgess <pete.soundtechnician@GMAIL.COM> wrote:
>
> WARNINGThis email originated from outside of Maynooth University's Mail System. Do not reply, click links or open attachments unless you recognise the sender and know the content is safe.
> Sorry to keep posting bugs today...
>
> But I've realised that the ksmps affects how my expsegr:a and linsegr:a envelopes sound, with many sensible ksmps values actually causing them to produce silence...
>
> with sr==48000, I get sound if ksmps is set to 1, 12, 24, 48 or 96 (and I'm yet to find any other value that doesn't silence my instruments). When I use ksmps==96, the envelopes act audibly different to when I use ksmps==1.
>
> I'm using functional style syntax. I haven't got a single k rate opcode or variable anywhere, absolutely all my opcode are suffixed with `:i` or `:a`, so it seems odd that the sound would be affected by the control rate at all, even ignoring the weird silence issue.
>
> Pete
> 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


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


--
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

Date2020-07-09 15:16
FromVictor Lazzarini
SubjectRe: [Csnd] [EXTERNAL] [Csnd] A rate functional style envelopes are affected by control rate.
Can you show us a minimal example of your code where this happens?
========================
Prof. Victor Lazzarini
Maynooth University
Ireland

> On 9 Jul 2020, at 15:04, Peter Burgess  wrote:
> 
> That's what I'm saying, I have every opcode annotated with either :a or :i, and not a :k in sight. Every last opcode is definitely annotate, and not a single variable is declared krate.
> 
> If I change one of the expsegr:a opcodes to the original non-functional style, it is unaffected by the control rate
> 
> On Thu, Jul 9, 2020 at 3:00 PM Victor Lazzarini  wrote:
> Try making sure you are actually using arate versions by annotating the opcodes 
> 
> opcode:a(…)
> 
> ========================
> Prof. Victor Lazzarini
> Maynooth University
> Ireland
> 
> > On 9 Jul 2020, at 14:56, Peter Burgess  wrote:
> > 
> > WARNINGThis email originated from outside of Maynooth University's Mail System. Do not reply, click links or open attachments unless you recognise the sender and know the content is safe.
> > Sorry to keep posting bugs today...
> > 
> > But I've realised that the ksmps affects how my expsegr:a and linsegr:a envelopes sound, with many sensible ksmps values actually causing them to produce silence...
> > 
> > with sr==48000, I get sound if ksmps is set to 1, 12, 24, 48 or 96 (and I'm yet to find any other value that doesn't silence my instruments). When I use ksmps==96, the envelopes act audibly different to when I use ksmps==1.
> > 
> > I'm using functional style syntax. I haven't got a single k rate opcode or variable anywhere, absolutely all my opcode are suffixed with `:i` or `:a`, so it seems odd that the sound would be affected by the control rate at all, even ignoring the weird silence issue.
> > 
> > Pete
> > 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
> 
> 
> 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
> 
> 
> -- 
> http://algorythmradio.com
> https://soundcloud.com/algorythmradio
> 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


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

Date2020-07-09 15:52
FromPeter Burgess
SubjectRe: [Csnd] [EXTERNAL] [Csnd] A rate functional style envelopes are affected by control rate.
AttachmentsMINIMUM_BUG_EXAMPLE.csd  
I've just been wittling it down to produce a minimum example, and discovered that removing the `rand:a()` call allows me to push ksmps up further without losing audio altogether, but I still eventually hit silence if I push it further. With the rand:a opcode, I have found that ksmps values between 1 and 96 all work, but I get silence if I use 97 or higher. Attached is the minimal example I could come up with...

On Thu, Jul 9, 2020 at 3:16 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
Can you show us a minimal example of your code where this happens?
========================
Prof. Victor Lazzarini
Maynooth University
Ireland

> On 9 Jul 2020, at 15:04, Peter Burgess <pete.soundtechnician@gmail.com> wrote:
>
> That's what I'm saying, I have every opcode annotated with either :a or :i, and not a :k in sight. Every last opcode is definitely annotate, and not a single variable is declared krate.
>
> If I change one of the expsegr:a opcodes to the original non-functional style, it is unaffected by the control rate
>
> On Thu, Jul 9, 2020 at 3:00 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
> Try making sure you are actually using arate versions by annotating the opcodes
>
> opcode:a(…)
>
> ========================
> Prof. Victor Lazzarini
> Maynooth University
> Ireland
>
> > On 9 Jul 2020, at 14:56, Peter Burgess <pete.soundtechnician@GMAIL.COM> wrote:
> >
> > WARNINGThis email originated from outside of Maynooth University's Mail System. Do not reply, click links or open attachments unless you recognise the sender and know the content is safe.
> > Sorry to keep posting bugs today...
> >
> > But I've realised that the ksmps affects how my expsegr:a and linsegr:a envelopes sound, with many sensible ksmps values actually causing them to produce silence...
> >
> > with sr==48000, I get sound if ksmps is set to 1, 12, 24, 48 or 96 (and I'm yet to find any other value that doesn't silence my instruments). When I use ksmps==96, the envelopes act audibly different to when I use ksmps==1.
> >
> > I'm using functional style syntax. I haven't got a single k rate opcode or variable anywhere, absolutely all my opcode are suffixed with `:i` or `:a`, so it seems odd that the sound would be affected by the control rate at all, even ignoring the weird silence issue.
> >
> > Pete
> > 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
>
>
> 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
>
>
> --
> http://algorythmradio.com
> https://soundcloud.com/algorythmradio
> 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


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


--
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

Date2020-07-09 16:24
FromEduardo Moguillansky
SubjectRe: [Csnd] [EXTERNAL] [Csnd] A rate functional style envelopes are affected by control rate.

Didn't test, but the thing that is most probably wrong is that you use time deltas for the expsegr which are shorter than one cycle (1/ksmps) when ksmps grows, which probably results in nans somewhere along the line. Increase those time deltas to at least 1/ksmps and you will probably get sound again. It would be nice if expsegr et al. would check that the time deltas are not smaller than a cycle, but nevertheless this is not a bug and just user error.

For the future, before hitting send I would suggest making a habit of doing a search and replace, substituting "bug" for "something I don't understand". Of course it might be a bug, but the predisposition to help is higher in the second case.

On 09.07.20 16:52, Peter Burgess wrote:
I've just been wittling it down to produce a minimum example, and discovered that removing the `rand:a()` call allows me to push ksmps up further without losing audio altogether, but I still eventually hit silence if I push it further. With the rand:a opcode, I have found that ksmps values between 1 and 96 all work, but I get silence if I use 97 or higher. Attached is the minimal example I could come up with...

On Thu, Jul 9, 2020 at 3:16 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
Can you show us a minimal example of your code where this happens?
========================
Prof. Victor Lazzarini
Maynooth University
Ireland

> On 9 Jul 2020, at 15:04, Peter Burgess <pete.soundtechnician@gmail.com> wrote:
>
> That's what I'm saying, I have every opcode annotated with either :a or :i, and not a :k in sight. Every last opcode is definitely annotate, and not a single variable is declared krate.
>
> If I change one of the expsegr:a opcodes to the original non-functional style, it is unaffected by the control rate
>
> On Thu, Jul 9, 2020 at 3:00 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
> Try making sure you are actually using arate versions by annotating the opcodes
>
> opcode:a(…)
>
> ========================
> Prof. Victor Lazzarini
> Maynooth University
> Ireland
>
> > On 9 Jul 2020, at 14:56, Peter Burgess <pete.soundtechnician@GMAIL.COM> wrote:
> >
> > WARNINGThis email originated from outside of Maynooth University's Mail System. Do not reply, click links or open attachments unless you recognise the sender and know the content is safe.
> > Sorry to keep posting bugs today...
> >
> > But I've realised that the ksmps affects how my expsegr:a and linsegr:a envelopes sound, with many sensible ksmps values actually causing them to produce silence...
> >
> > with sr==48000, I get sound if ksmps is set to 1, 12, 24, 48 or 96 (and I'm yet to find any other value that doesn't silence my instruments). When I use ksmps==96, the envelopes act audibly different to when I use ksmps==1.
> >
> > I'm using functional style syntax. I haven't got a single k rate opcode or variable anywhere, absolutely all my opcode are suffixed with `:i` or `:a`, so it seems odd that the sound would be affected by the control rate at all, even ignoring the weird silence issue.
> >
> > Pete
> > 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
>
>
> 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
>
>
> --
> http://algorythmradio.com
> https://soundcloud.com/algorythmradio
> 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


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


--
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

Date2020-07-09 16:38
FromPeter Burgess
SubjectRe: [Csnd] [EXTERNAL] [Csnd] A rate functional style envelopes are affected by control rate.
If I swap out the functional opcode style for the traditional csound opcode style it works fine. None of my opcodes are k-rate so they should be affected by sr not kr.

On Thu, Jul 9, 2020 at 4:26 PM Eduardo Moguillansky <eduardo.moguillansky@gmail.com> wrote:

Didn't test, but the thing that is most probably wrong is that you use time deltas for the expsegr which are shorter than one cycle (1/ksmps) when ksmps grows, which probably results in nans somewhere along the line. Increase those time deltas to at least 1/ksmps and you will probably get sound again. It would be nice if expsegr et al. would check that the time deltas are not smaller than a cycle, but nevertheless this is not a bug and just user error.

For the future, before hitting send I would suggest making a habit of doing a search and replace, substituting "bug" for "something I don't understand". Of course it might be a bug, but the predisposition to help is higher in the second case.

On 09.07.20 16:52, Peter Burgess wrote:
I've just been wittling it down to produce a minimum example, and discovered that removing the `rand:a()` call allows me to push ksmps up further without losing audio altogether, but I still eventually hit silence if I push it further. With the rand:a opcode, I have found that ksmps values between 1 and 96 all work, but I get silence if I use 97 or higher. Attached is the minimal example I could come up with...

On Thu, Jul 9, 2020 at 3:16 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
Can you show us a minimal example of your code where this happens?
========================
Prof. Victor Lazzarini
Maynooth University
Ireland

> On 9 Jul 2020, at 15:04, Peter Burgess <pete.soundtechnician@gmail.com> wrote:
>
> That's what I'm saying, I have every opcode annotated with either :a or :i, and not a :k in sight. Every last opcode is definitely annotate, and not a single variable is declared krate.
>
> If I change one of the expsegr:a opcodes to the original non-functional style, it is unaffected by the control rate
>
> On Thu, Jul 9, 2020 at 3:00 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
> Try making sure you are actually using arate versions by annotating the opcodes
>
> opcode:a(…)
>
> ========================
> Prof. Victor Lazzarini
> Maynooth University
> Ireland
>
> > On 9 Jul 2020, at 14:56, Peter Burgess <pete.soundtechnician@GMAIL.COM> wrote:
> >
> > WARNINGThis email originated from outside of Maynooth University's Mail System. Do not reply, click links or open attachments unless you recognise the sender and know the content is safe.
> > Sorry to keep posting bugs today...
> >
> > But I've realised that the ksmps affects how my expsegr:a and linsegr:a envelopes sound, with many sensible ksmps values actually causing them to produce silence...
> >
> > with sr==48000, I get sound if ksmps is set to 1, 12, 24, 48 or 96 (and I'm yet to find any other value that doesn't silence my instruments). When I use ksmps==96, the envelopes act audibly different to when I use ksmps==1.
> >
> > I'm using functional style syntax. I haven't got a single k rate opcode or variable anywhere, absolutely all my opcode are suffixed with `:i` or `:a`, so it seems odd that the sound would be affected by the control rate at all, even ignoring the weird silence issue.
> >
> > Pete
> > 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
>
>
> 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
>
>
> --
> http://algorythmradio.com
> https://soundcloud.com/algorythmradio
> 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


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


--
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
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


--
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

Date2020-07-09 17:44
FromPeter Burgess
SubjectRe: [Csnd] [EXTERNAL] [Csnd] A rate functional style envelopes are affected by control rate.
AttachmentsMINIMUM_BUG_EXAMPLE.csd  
Victor - The functional style thing was a wild goose chase, apologies. I've narrowed it down properly to expsegr causing the issue. The attached .csd should demonstrate that by switching between the version of the kick instrument, expseg:a behaves as expected, expsegr:a misbehaves.

I wonder too if this has anything to do with the extreme amplitude explosions I was reporting in my use of Csound API on the dev thread? That also seemed to start when I switched from expseg to expsegr.

On Thu, Jul 9, 2020 at 4:38 PM Peter Burgess <pete.soundtechnician@gmail.com> wrote:
If I swap out the functional opcode style for the traditional csound opcode style it works fine. None of my opcodes are k-rate so they should be affected by sr not kr.

On Thu, Jul 9, 2020 at 4:26 PM Eduardo Moguillansky <eduardo.moguillansky@gmail.com> wrote:

Didn't test, but the thing that is most probably wrong is that you use time deltas for the expsegr which are shorter than one cycle (1/ksmps) when ksmps grows, which probably results in nans somewhere along the line. Increase those time deltas to at least 1/ksmps and you will probably get sound again. It would be nice if expsegr et al. would check that the time deltas are not smaller than a cycle, but nevertheless this is not a bug and just user error.

For the future, before hitting send I would suggest making a habit of doing a search and replace, substituting "bug" for "something I don't understand". Of course it might be a bug, but the predisposition to help is higher in the second case.

On 09.07.20 16:52, Peter Burgess wrote:
I've just been wittling it down to produce a minimum example, and discovered that removing the `rand:a()` call allows me to push ksmps up further without losing audio altogether, but I still eventually hit silence if I push it further. With the rand:a opcode, I have found that ksmps values between 1 and 96 all work, but I get silence if I use 97 or higher. Attached is the minimal example I could come up with...

On Thu, Jul 9, 2020 at 3:16 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
Can you show us a minimal example of your code where this happens?
========================
Prof. Victor Lazzarini
Maynooth University
Ireland

> On 9 Jul 2020, at 15:04, Peter Burgess <pete.soundtechnician@gmail.com> wrote:
>
> That's what I'm saying, I have every opcode annotated with either :a or :i, and not a :k in sight. Every last opcode is definitely annotate, and not a single variable is declared krate.
>
> If I change one of the expsegr:a opcodes to the original non-functional style, it is unaffected by the control rate
>
> On Thu, Jul 9, 2020 at 3:00 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
> Try making sure you are actually using arate versions by annotating the opcodes
>
> opcode:a(…)
>
> ========================
> Prof. Victor Lazzarini
> Maynooth University
> Ireland
>
> > On 9 Jul 2020, at 14:56, Peter Burgess <pete.soundtechnician@GMAIL.COM> wrote:
> >
> > WARNINGThis email originated from outside of Maynooth University's Mail System. Do not reply, click links or open attachments unless you recognise the sender and know the content is safe.
> > Sorry to keep posting bugs today...
> >
> > But I've realised that the ksmps affects how my expsegr:a and linsegr:a envelopes sound, with many sensible ksmps values actually causing them to produce silence...
> >
> > with sr==48000, I get sound if ksmps is set to 1, 12, 24, 48 or 96 (and I'm yet to find any other value that doesn't silence my instruments). When I use ksmps==96, the envelopes act audibly different to when I use ksmps==1.
> >
> > I'm using functional style syntax. I haven't got a single k rate opcode or variable anywhere, absolutely all my opcode are suffixed with `:i` or `:a`, so it seems odd that the sound would be affected by the control rate at all, even ignoring the weird silence issue.
> >
> > Pete
> > 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
>
>
> 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
>
>
> --
> http://algorythmradio.com
> https://soundcloud.com/algorythmradio
> 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


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


--
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
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


--


--
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

Date2020-07-09 19:35
FromVictor Lazzarini
SubjectRe: [Csnd] [EXTERNAL] [Csnd] A rate functional style envelopes are affected by control rate.
Could well be. Can you file a ticket please and we'll have a look.

Prof. Victor Lazzarini
Maynooth University
Ireland

On 9 Jul 2020, at 17:45, Peter Burgess <pete.soundtechnician@gmail.com> wrote:


Victor - The functional style thing was a wild goose chase, apologies. I've narrowed it down properly to expsegr causing the issue. The attached .csd should demonstrate that by switching between the version of the kick instrument, expseg:a behaves as expected, expsegr:a misbehaves.

I wonder too if this has anything to do with the extreme amplitude explosions I was reporting in my use of Csound API on the dev thread? That also seemed to start when I switched from expseg to expsegr.

On Thu, Jul 9, 2020 at 4:38 PM Peter Burgess <pete.soundtechnician@gmail.com> wrote:
If I swap out the functional opcode style for the traditional csound opcode style it works fine. None of my opcodes are k-rate so they should be affected by sr not kr.

On Thu, Jul 9, 2020 at 4:26 PM Eduardo Moguillansky <eduardo.moguillansky@gmail.com> wrote:

Didn't test, but the thing that is most probably wrong is that you use time deltas for the expsegr which are shorter than one cycle (1/ksmps) when ksmps grows, which probably results in nans somewhere along the line. Increase those time deltas to at least 1/ksmps and you will probably get sound again. It would be nice if expsegr et al. would check that the time deltas are not smaller than a cycle, but nevertheless this is not a bug and just user error.

For the future, before hitting send I would suggest making a habit of doing a search and replace, substituting "bug" for "something I don't understand". Of course it might be a bug, but the predisposition to help is higher in the second case.

On 09.07.20 16:52, Peter Burgess wrote:
I've just been wittling it down to produce a minimum example, and discovered that removing the `rand:a()` call allows me to push ksmps up further without losing audio altogether, but I still eventually hit silence if I push it further. With the rand:a opcode, I have found that ksmps values between 1 and 96 all work, but I get silence if I use 97 or higher. Attached is the minimal example I could come up with...

On Thu, Jul 9, 2020 at 3:16 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
Can you show us a minimal example of your code where this happens?
========================
Prof. Victor Lazzarini
Maynooth University
Ireland

> On 9 Jul 2020, at 15:04, Peter Burgess <pete.soundtechnician@gmail.com> wrote:
>
> That's what I'm saying, I have every opcode annotated with either :a or :i, and not a :k in sight. Every last opcode is definitely annotate, and not a single variable is declared krate.
>
> If I change one of the expsegr:a opcodes to the original non-functional style, it is unaffected by the control rate
>
> On Thu, Jul 9, 2020 at 3:00 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
> Try making sure you are actually using arate versions by annotating the opcodes
>
> opcode:a(…)
>
> ========================
> Prof. Victor Lazzarini
> Maynooth University
> Ireland
>
> > On 9 Jul 2020, at 14:56, Peter Burgess <pete.soundtechnician@GMAIL.COM> wrote:
> >
> > WARNINGThis email originated from outside of Maynooth University's Mail System. Do not reply, click links or open attachments unless you recognise the sender and know the content is safe.
> > Sorry to keep posting bugs today...
> >
> > But I've realised that the ksmps affects how my expsegr:a and linsegr:a envelopes sound, with many sensible ksmps values actually causing them to produce silence...
> >
> > with sr==48000, I get sound if ksmps is set to 1, 12, 24, 48 or 96 (and I'm yet to find any other value that doesn't silence my instruments). When I use ksmps==96, the envelopes act audibly different to when I use ksmps==1.
> >
> > I'm using functional style syntax. I haven't got a single k rate opcode or variable anywhere, absolutely all my opcode are suffixed with `:i` or `:a`, so it seems odd that the sound would be affected by the control rate at all, even ignoring the weird silence issue.
> >
> > Pete
> > 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
>
>
> 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
>
>
> --
> http://algorythmradio.com
> https://soundcloud.com/algorythmradio
> 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


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


--
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
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


--


--
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
<MINIMUM_BUG_EXAMPLE.csd>

Date2020-07-09 20:30
FromPeter Burgess
SubjectRe: [Csnd] [EXTERNAL] [Csnd] A rate functional style envelopes are affected by control rate.
As requested, I filed a bug report:


Cheers Victor

On Thu, 9 Jul 2020, 19:35 Victor Lazzarini, <Victor.Lazzarini@mu.ie> wrote:
Could well be. Can you file a ticket please and we'll have a look.

Prof. Victor Lazzarini
Maynooth University
Ireland

On 9 Jul 2020, at 17:45, Peter Burgess <pete.soundtechnician@gmail.com> wrote:


Victor - The functional style thing was a wild goose chase, apologies. I've narrowed it down properly to expsegr causing the issue. The attached .csd should demonstrate that by switching between the version of the kick instrument, expseg:a behaves as expected, expsegr:a misbehaves.

I wonder too if this has anything to do with the extreme amplitude explosions I was reporting in my use of Csound API on the dev thread? That also seemed to start when I switched from expseg to expsegr.

On Thu, Jul 9, 2020 at 4:38 PM Peter Burgess <pete.soundtechnician@gmail.com> wrote:
If I swap out the functional opcode style for the traditional csound opcode style it works fine. None of my opcodes are k-rate so they should be affected by sr not kr.

On Thu, Jul 9, 2020 at 4:26 PM Eduardo Moguillansky <eduardo.moguillansky@gmail.com> wrote:

Didn't test, but the thing that is most probably wrong is that you use time deltas for the expsegr which are shorter than one cycle (1/ksmps) when ksmps grows, which probably results in nans somewhere along the line. Increase those time deltas to at least 1/ksmps and you will probably get sound again. It would be nice if expsegr et al. would check that the time deltas are not smaller than a cycle, but nevertheless this is not a bug and just user error.

For the future, before hitting send I would suggest making a habit of doing a search and replace, substituting "bug" for "something I don't understand". Of course it might be a bug, but the predisposition to help is higher in the second case.

On 09.07.20 16:52, Peter Burgess wrote:
I've just been wittling it down to produce a minimum example, and discovered that removing the `rand:a()` call allows me to push ksmps up further without losing audio altogether, but I still eventually hit silence if I push it further. With the rand:a opcode, I have found that ksmps values between 1 and 96 all work, but I get silence if I use 97 or higher. Attached is the minimal example I could come up with...

On Thu, Jul 9, 2020 at 3:16 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
Can you show us a minimal example of your code where this happens?
========================
Prof. Victor Lazzarini
Maynooth University
Ireland

> On 9 Jul 2020, at 15:04, Peter Burgess <pete.soundtechnician@gmail.com> wrote:
>
> That's what I'm saying, I have every opcode annotated with either :a or :i, and not a :k in sight. Every last opcode is definitely annotate, and not a single variable is declared krate.
>
> If I change one of the expsegr:a opcodes to the original non-functional style, it is unaffected by the control rate
>
> On Thu, Jul 9, 2020 at 3:00 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
> Try making sure you are actually using arate versions by annotating the opcodes
>
> opcode:a(…)
>
> ========================
> Prof. Victor Lazzarini
> Maynooth University
> Ireland
>
> > On 9 Jul 2020, at 14:56, Peter Burgess <pete.soundtechnician@GMAIL.COM> wrote:
> >
> > WARNINGThis email originated from outside of Maynooth University's Mail System. Do not reply, click links or open attachments unless you recognise the sender and know the content is safe.
> > Sorry to keep posting bugs today...
> >
> > But I've realised that the ksmps affects how my expsegr:a and linsegr:a envelopes sound, with many sensible ksmps values actually causing them to produce silence...
> >
> > with sr==48000, I get sound if ksmps is set to 1, 12, 24, 48 or 96 (and I'm yet to find any other value that doesn't silence my instruments). When I use ksmps==96, the envelopes act audibly different to when I use ksmps==1.
> >
> > I'm using functional style syntax. I haven't got a single k rate opcode or variable anywhere, absolutely all my opcode are suffixed with `:i` or `:a`, so it seems odd that the sound would be affected by the control rate at all, even ignoring the weird silence issue.
> >
> > Pete
> > 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
>
>
> 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
>
>
> --
> http://algorythmradio.com
> https://soundcloud.com/algorythmradio
> 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


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


--
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
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


--


--
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
<MINIMUM_BUG_EXAMPLE.csd>
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
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

Date2020-07-09 22:35
FromVictor Lazzarini
SubjectRe: [Csnd] [EXTERNAL] [Csnd] A rate functional style envelopes are affected by control rate.
Thanks, we'll investigate.

Prof. Victor Lazzarini
Maynooth University
Ireland

On 9 Jul 2020, at 20:31, Peter Burgess <pete.soundtechnician@gmail.com> wrote:


As requested, I filed a bug report:


Cheers Victor

On Thu, 9 Jul 2020, 19:35 Victor Lazzarini, <Victor.Lazzarini@mu.ie> wrote:
Could well be. Can you file a ticket please and we'll have a look.

Prof. Victor Lazzarini
Maynooth University
Ireland

On 9 Jul 2020, at 17:45, Peter Burgess <pete.soundtechnician@gmail.com> wrote:


Victor - The functional style thing was a wild goose chase, apologies. I've narrowed it down properly to expsegr causing the issue. The attached .csd should demonstrate that by switching between the version of the kick instrument, expseg:a behaves as expected, expsegr:a misbehaves.

I wonder too if this has anything to do with the extreme amplitude explosions I was reporting in my use of Csound API on the dev thread? That also seemed to start when I switched from expseg to expsegr.

On Thu, Jul 9, 2020 at 4:38 PM Peter Burgess <pete.soundtechnician@gmail.com> wrote:
If I swap out the functional opcode style for the traditional csound opcode style it works fine. None of my opcodes are k-rate so they should be affected by sr not kr.

On Thu, Jul 9, 2020 at 4:26 PM Eduardo Moguillansky <eduardo.moguillansky@gmail.com> wrote:

Didn't test, but the thing that is most probably wrong is that you use time deltas for the expsegr which are shorter than one cycle (1/ksmps) when ksmps grows, which probably results in nans somewhere along the line. Increase those time deltas to at least 1/ksmps and you will probably get sound again. It would be nice if expsegr et al. would check that the time deltas are not smaller than a cycle, but nevertheless this is not a bug and just user error.

For the future, before hitting send I would suggest making a habit of doing a search and replace, substituting "bug" for "something I don't understand". Of course it might be a bug, but the predisposition to help is higher in the second case.

On 09.07.20 16:52, Peter Burgess wrote:
I've just been wittling it down to produce a minimum example, and discovered that removing the `rand:a()` call allows me to push ksmps up further without losing audio altogether, but I still eventually hit silence if I push it further. With the rand:a opcode, I have found that ksmps values between 1 and 96 all work, but I get silence if I use 97 or higher. Attached is the minimal example I could come up with...

On Thu, Jul 9, 2020 at 3:16 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
Can you show us a minimal example of your code where this happens?
========================
Prof. Victor Lazzarini
Maynooth University
Ireland

> On 9 Jul 2020, at 15:04, Peter Burgess <pete.soundtechnician@gmail.com> wrote:
>
> That's what I'm saying, I have every opcode annotated with either :a or :i, and not a :k in sight. Every last opcode is definitely annotate, and not a single variable is declared krate.
>
> If I change one of the expsegr:a opcodes to the original non-functional style, it is unaffected by the control rate
>
> On Thu, Jul 9, 2020 at 3:00 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
> Try making sure you are actually using arate versions by annotating the opcodes
>
> opcode:a(…)
>
> ========================
> Prof. Victor Lazzarini
> Maynooth University
> Ireland
>
> > On 9 Jul 2020, at 14:56, Peter Burgess <pete.soundtechnician@GMAIL.COM> wrote:
> >
> > WARNINGThis email originated from outside of Maynooth University's Mail System. Do not reply, click links or open attachments unless you recognise the sender and know the content is safe.
> > Sorry to keep posting bugs today...
> >
> > But I've realised that the ksmps affects how my expsegr:a and linsegr:a envelopes sound, with many sensible ksmps values actually causing them to produce silence...
> >
> > with sr==48000, I get sound if ksmps is set to 1, 12, 24, 48 or 96 (and I'm yet to find any other value that doesn't silence my instruments). When I use ksmps==96, the envelopes act audibly different to when I use ksmps==1.
> >
> > I'm using functional style syntax. I haven't got a single k rate opcode or variable anywhere, absolutely all my opcode are suffixed with `:i` or `:a`, so it seems odd that the sound would be affected by the control rate at all, even ignoring the weird silence issue.
> >
> > Pete
> > 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
>
>
> 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
>
>
> --
> http://algorythmradio.com
> https://soundcloud.com/algorythmradio
> 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


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


--
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
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


--


--
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
<MINIMUM_BUG_EXAMPLE.csd>
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
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