Csound Csound-dev Csound-tekno Search About

Audiorate comparator

Date2016-11-20 07:43
FromEduardo Moguillansky
SubjectAudiorate comparator
I need to do audiorate comparisons between signals, like

a3 = a1 >= a2

where a3 would be 1 for all samples where a1 >= to a2, 0 otherwise

But comparators seem to be only implemented for k-rate vars. Am I missing some evident opcode that does this?

thanks,
eduardo
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

Date2016-11-20 09:40
FromVictor Lazzarini
SubjectRe: Audiorate comparator
The way to do this is to use one of the vector
reading opcodes in a loop.


and compare each value.

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 07:44, Eduardo Moguillansky <eduardo.moguillansky@GMAIL.COM> wrote:

I need to do audiorate comparisons between signals, like

a3 = a1 >= a2

where a3 would be 1 for all samples where a1 >= to a2, 0 otherwise

But comparators seem to be only implemented for k-rate vars. Am I missing some evident opcode that does this?

thanks,
eduardo
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

Date2016-11-20 09:47
FromVictor Lazzarini
SubjectRe: Audiorate comparator
but maybe we could consider overloading
the logic ops to work on vectors as well.

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 09:40, Victor Lazzarini <Victor.Lazzarini@NUIM.IE> wrote:

The way to do this is to use one of the vector
reading opcodes in a loop.


and compare each value.

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 07:44, Eduardo Moguillansky <eduardo.moguillansky@GMAIL.COM> wrote:

I need to do audiorate comparisons between signals, like

a3 = a1 >= a2

where a3 would be 1 for all samples where a1 >= to a2, 0 otherwise

But comparators seem to be only implemented for k-rate vars. Am I missing some evident opcode that does this?

thanks,
eduardo
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

Date2016-11-20 10:11
FromEduardo Moguillansky
SubjectRe: Audiorate comparator
that would be great.

maybe while at it, it would be possible to fix the need for ternary operator when using comparators, to avoid repeating kx > ky ? 1 : 0

On Sun, Nov 20, 2016 at 10:47 AM, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote:
but maybe we could consider overloading
the logic ops to work on vectors as well.

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 09:40, Victor Lazzarini <Victor.Lazzarini@NUIM.IE> wrote:

The way to do this is to use one of the vector
reading opcodes in a loop.


and compare each value.

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 07:44, Eduardo Moguillansky <eduardo.moguillansky@GMAIL.COM> wrote:

I need to do audiorate comparisons between signals, like

a3 = a1 >= a2

where a3 would be 1 for all samples where a1 >= to a2, 0 otherwise

But comparators seem to be only implemented for k-rate vars. Am I missing some evident opcode that does this?

thanks,
eduardo
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

Date2016-11-20 10:16
FromVictor Lazzarini
SubjectRe: Audiorate comparator
Can you elaborate on this, I am not quite sure what needs to be fixed?

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 10:12, Eduardo Moguillansky <eduardo.moguillansky@GMAIL.COM> wrote:

that would be great.

maybe while at it, it would be possible to fix the need for ternary operator when using comparators, to avoid repeating kx > ky ? 1 : 0

On Sun, Nov 20, 2016 at 10:47 AM, Victor Lazzarini <Victor.Lazzarini@nuim.ie> wrote:
but maybe we could consider overloading
the logic ops to work on vectors as well.

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 09:40, Victor Lazzarini <Victor.Lazzarini@NUIM.IE> wrote:

The way to do this is to use one of the vector
reading opcodes in a loop.


and compare each value.

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 07:44, Eduardo Moguillansky <eduardo.moguillansky@GMAIL.COM> wrote:

I need to do audiorate comparisons between signals, like

a3 = a1 >= a2

where a3 would be 1 for all samples where a1 >= to a2, 0 otherwise

But comparators seem to be only implemented for k-rate vars. Am I missing some evident opcode that does this?

thanks,
eduardo
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

Date2016-11-20 10:40
Frommoguillansky
SubjectRe: Audiorate comparator
I normally would expect that kx > ky would be 1 if the condition is true, as in most programming languages true equals to 1.

On Sun, Nov 20, 2016 at 11:16 AM, Victor Lazzarini [via Csound] <[hidden email]> wrote:
Can you elaborate on this, I am not quite sure what needs to be fixed?

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 10:12, Eduardo Moguillansky <[hidden email]> wrote:

that would be great.

maybe while at it, it would be possible to fix the need for ternary operator when using comparators, to avoid repeating kx > ky ? 1 : 0

On Sun, Nov 20, 2016 at 10:47 AM, Victor Lazzarini <[hidden email]> wrote:
but maybe we could consider overloading
the logic ops to work on vectors as well.

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 09:40, Victor Lazzarini <[hidden email]> wrote:

The way to do this is to use one of the vector
reading opcodes in a loop.


and compare each value.

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 07:44, Eduardo Moguillansky <[hidden email]> wrote:

I need to do audiorate comparisons between signals, like

a3 = a1 >= a2

where a3 would be 1 for all samples where a1 >= to a2, 0 otherwise

But comparators seem to be only implemented for k-rate vars. Am I missing some evident opcode that does this?

thanks,
eduardo
Csound mailing list [hidden email] 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 [hidden email] 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 [hidden email] 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 [hidden email] 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 [hidden email] 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


If you reply to this email, your message will be added to the discussion below:
http://csound.1045644.n5.nabble.com/Csnd-Audiorate-comparator-tp5752690p5752696.html
To start a new topic under Csound - General, email [hidden email]
To unsubscribe from Csound, click here.
NAML



View this message in context: Re: [Csnd] Audiorate comparator
Sent from the Csound - General mailing list archive at Nabble.com.
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

Date2016-11-20 10:51
FromVictor Lazzarini
SubjectRe: Audiorate comparator
I guess Csound does not parse that. It could perhaps, expanding to a triple expression

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 10:41, moguillansky <eduardo.moguillansky@GMAIL.COM> wrote:

I normally would expect that kx > ky would be 1 if the condition is true, as in most programming languages true equals to 1.

On Sun, Nov 20, 2016 at 11:16 AM, Victor Lazzarini [via Csound] <[hidden email]> wrote:
Can you elaborate on this, I am not quite sure what needs to be fixed?

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 10:12, Eduardo Moguillansky <[hidden email]> wrote:

that would be great.

maybe while at it, it would be possible to fix the need for ternary operator when using comparators, to avoid repeating kx > ky ? 1 : 0

On Sun, Nov 20, 2016 at 10:47 AM, Victor Lazzarini <[hidden email]> wrote:
but maybe we could consider overloading
the logic ops to work on vectors as well.

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 09:40, Victor Lazzarini <[hidden email]> wrote:

The way to do this is to use one of the vector
reading opcodes in a loop.


and compare each value.

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 20 Nov 2016, at 07:44, Eduardo Moguillansky <[hidden email]> wrote:

I need to do audiorate comparisons between signals, like

a3 = a1 >= a2

where a3 would be 1 for all samples where a1 >= to a2, 0 otherwise

But comparators seem to be only implemented for k-rate vars. Am I missing some evident opcode that does this?

thanks,
eduardo
Csound mailing list [hidden email] 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 [hidden email] 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 [hidden email] 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 [hidden email] 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 [hidden email] 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


If you reply to this email, your message will be added to the discussion below:
http://csound.1045644.n5.nabble.com/Csnd-Audiorate-comparator-tp5752690p5752696.html
To start a new topic under Csound - General, email [hidden email]
To unsubscribe from Csound, click here.
NAML



View this message in context: Re: [Csnd] Audiorate comparator
Sent from the Csound - General mailing list archive at Nabble.com.
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

Date2016-11-20 13:13
FromJohn ff
SubjectRe: Audiorate comparator
This would be easier in C taking a few minutes to write without introducing major changes.

Sent from TypeApp
On 20 Nov 2016, at 07:44, Eduardo Moguillansky <eduardo.moguillansky@GMAIL.COM> wrote:
I need to do audiorate comparisons between signals, like

a3 = a1 >= a2

where a3 would be 1 for all samples where a1 >= to a2, 0 otherwise

But comparators seem to be only implemented for k-rate vars. Am I missing some evident opcode that does this?

thanks,
eduardo
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

Date2016-11-20 14:18
FromSteven Yi
SubjectRe: Audiorate comparator
I don't think it is true that most languages permit 1 and true to be
the same, nor do I think it would be good to have in Csound.  It opens
up ways to make mistakes, but doesn't provide enough benefit, IMO.

Also you may want to use a UDO that does what you want:

opcode gte, a, aa
a1, a2 xin
aout init 0
kindx = 0
while (kindx < ksmps) do
  aout[kindx] = (a1[kindx] >= a2[kindx]) ? 1 : 0
od
xout aout
endop

aval = gte(asig, asig2)



On Sun, Nov 20, 2016 at 5:40 AM, moguillansky
 wrote:
> I normally would expect that kx > ky would be 1 if the condition is true, as
> in most programming languages true equals to 1.
>
> On Sun, Nov 20, 2016 at 11:16 AM, Victor Lazzarini [via Csound] <[hidden
> email]> wrote:
>>
>> Can you elaborate on this, I am not quite sure what needs to be fixed?
>>
>> Victor Lazzarini
>> Dean of Arts, Celtic Studies, and Philosophy
>> Maynooth University
>> Ireland
>>
>> On 20 Nov 2016, at 10:12, Eduardo Moguillansky <[hidden email]> wrote:
>>
>> that would be great.
>>
>> maybe while at it, it would be possible to fix the need for ternary
>> operator when using comparators, to avoid repeating kx > ky ? 1 : 0
>>
>> On Sun, Nov 20, 2016 at 10:47 AM, Victor Lazzarini <[hidden email]> wrote:
>>>
>>> but maybe we could consider overloading
>>> the logic ops to work on vectors as well.
>>>
>>> Victor Lazzarini
>>> Dean of Arts, Celtic Studies, and Philosophy
>>> Maynooth University
>>> Ireland
>>>
>>> On 20 Nov 2016, at 09:40, Victor Lazzarini <[hidden email]> wrote:
>>>
>>> The way to do this is to use one of the vector
>>> reading opcodes in a loop.
>>>
>>> http://csound.github.io/docs/manual/vaget.html
>>>
>>> and compare each value.
>>>
>>> Victor Lazzarini
>>> Dean of Arts, Celtic Studies, and Philosophy
>>> Maynooth University
>>> Ireland
>>>
>>> On 20 Nov 2016, at 07:44, Eduardo Moguillansky <[hidden email]> wrote:
>>>
>>> I need to do audiorate comparisons between signals, like
>>>
>>> a3 = a1 >= a2
>>>
>>> where a3 would be 1 for all samples where a1 >= to a2, 0 otherwise
>>>
>>> But comparators seem to be only implemented for k-rate vars. Am I missing
>>> some evident opcode that does this?
>>>
>>> thanks,
>>> eduardo
>>> Csound mailing list [hidden email]
>>> 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 [hidden email]
>>> 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 [hidden email]
>>> 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 [hidden email]
>> 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 [hidden email]
>> 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
>>
>> ________________________________
>> If you reply to this email, your message will be added to the discussion
>> below:
>>
>> http://csound.1045644.n5.nabble.com/Csnd-Audiorate-comparator-tp5752690p5752696.html
>> To start a new topic under Csound - General, email [hidden email]
>> To unsubscribe from Csound, click here.
>> NAML
>
>
>
> ________________________________
> View this message in context: Re: [Csnd] Audiorate comparator
> Sent from the Csound - General mailing list archive at Nabble.com.
>
> 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

Date2016-11-26 15:53
Frommskala@ANSUZ.SOOKE.BC.CA
SubjectRe: Audiorate comparator
On Sun, 20 Nov 2016, moguillansky wrote:
> I normally would expect that kx > ky would be 1 if the condition is true, as
> in most programming languages true equals to 1.

I think in most programming languages, booleans are a different type from
integers and not equal to them at all.  C is a notable exception.

Date2016-11-26 16:00
Frommskala@ANSUZ.SOOKE.BC.CA
SubjectRe: Audiorate comparator
On Sun, 20 Nov 2016, Eduardo Moguillansky wrote:
> a3 = a1 >= a2
>
> where a3 would be 1 for all samples where a1 >= to a2, 0 otherwise
>
> But comparators seem to be only implemented for k-rate vars. Am I missing
> some evident opcode that does this?

One possibility would be to compute a1-a2 and look up the result in a
small table.  I don't know how that compares for speed with other ways of
doing it that people have suggested, but I expect it wouldn't be bad.

Date2016-11-26 16:09
Fromjpff
SubjectRe: Audiorate comparator
How about an opcode
aout select a1, a2, aless, aequal, amore
which for each sample sets
aout[i] = (a1[i] On Sun, 20 Nov 2016, Eduardo Moguillansky wrote:
>> a3 = a1 >= a2
>>
>> where a3 would be 1 for all samples where a1 >= to a2, 0 otherwise
>>
>> But comparators seem to be only implemented for k-rate vars. Am I missing
>> some evident opcode that does this?
>
> One possibility would be to compute a1-a2 and look up the result in a
> small table.  I don't know how that compares for speed with other ways of
> doing it that people have suggested, but I expect it wouldn't be bad.
>
> -- 
> Matthew Skala
> mskala@ansuz.sooke.bc.ca                 People before principles.
> http://ansuz.sooke.bc.ca/
>
> 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

Date2016-11-29 20:52
Fromjpff
SubjectRe: Audiorate comparator
Well I have the code but not in git yet as not sure it is useful/necessary

On Sat, 26 Nov 2016, jpff wrote:

> How about an opcode
> aout select a1, a2, aless, aequal, amore
> which for each sample sets
> aout[i] = (a1[i]
> That is almost the code
>
>
>
> On Sat, 26 Nov 2016, mskala@ANSUZ.SOOKE.BC.CA wrote:
>
>> On Sun, 20 Nov 2016, Eduardo Moguillansky wrote:
>>> a3 = a1 >= a2
>>> 
>>> where a3 would be 1 for all samples where a1 >= to a2, 0 otherwise
>>> 
>>> But comparators seem to be only implemented for k-rate vars. Am I missing
>>> some evident opcode that does this?
>> 
>> One possibility would be to compute a1-a2 and look up the result in a
>> small table.  I don't know how that compares for speed with other ways of
>> doing it that people have suggested, but I expect it wouldn't be bad.
>> 
>> -- 
>> Matthew Skala
>> mskala@ansuz.sooke.bc.ca                 People before principles.
>> http://ansuz.sooke.bc.ca/
>> 
>> 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

Date2016-11-29 21:05
FromVictor Lazzarini
SubjectRe: Audiorate comparator
I think it could be useful.

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

> On 29 Nov 2016, at 20:53, jpff  wrote:
> 
> Well I have the code but not in git yet as not sure it is useful/necessary
> 
>> On Sat, 26 Nov 2016, jpff wrote:
>> 
>> How about an opcode
>> aout select a1, a2, aless, aequal, amore
>> which for each sample sets
>> aout[i] = (a1[i]> 
>> That is almost the code
>> 
>> 
>> 
>>> On Sat, 26 Nov 2016, mskala@ANSUZ.SOOKE.BC.CA wrote:
>>> 
>>>> On Sun, 20 Nov 2016, Eduardo Moguillansky wrote:
>>>> a3 = a1 >= a2
>>>> where a3 would be 1 for all samples where a1 >= to a2, 0 otherwise
>>>> But comparators seem to be only implemented for k-rate vars. Am I missing
>>>> some evident opcode that does this?
>>> One possibility would be to compute a1-a2 and look up the result in a
>>> small table.  I don't know how that compares for speed with other ways of
>>> doing it that people have suggested, but I expect it wouldn't be bad.
>>> -- 
>>> Matthew Skala
>>> mskala@ansuz.sooke.bc.ca                 People before principles.
>>> http://ansuz.sooke.bc.ca/
>>> 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