Csound Csound-dev Csound-tekno Search About

[Csnd] opcode active by fractional number

Date2020-02-10 21:13
FromTarmo Johannes
Subject[Csnd] opcode active by fractional number
Hi,

I think it has been asked but I cannot find:

If I start and instrument with fractional number, say:

schedule 1.1, 0,  -1
schedule 1.2, 0,  -1

then
active(1.2) returns 2
but I would like to get to get 1 as the correct answer?

How can I test achieve it?

tarmo
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-02-10 21:21
FromDave Seidel
SubjectRe: [Csnd] opcode active by fractional number
Maybe you could use nstance instead of schedule, store the instance handles in an array, and then test them to see if their still active? But I'm not sure how to use the handles returned by nstance, so not sure if there's a suitable opcode to test them for activity or validity.

On Mon, Feb 10, 2020 at 4:13 PM Tarmo Johannes <trmjhnns@gmail.com> wrote:
Hi,

I think it has been asked but I cannot find:

If I start and instrument with fractional number, say:

schedule 1.1, 0,  -1
schedule 1.2, 0,  -1

then
active(1.2) returns 2
but I would like to get to get 1 as the correct answer?

How can I test achieve it?

tarmo
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-02-10 21:34
Fromthorin kerr
SubjectRe: [Csnd] opcode active by fractional number

On Tue, Feb 11, 2020 at 7:13 AM Tarmo Johannes <trmjhnns@gmail.com> wrote:
Hi,

I think it has been asked but I cannot find:

If I start and instrument with fractional number, say:

schedule 1.1, 0,  -1
schedule 1.2, 0,  -1

then
active(1.2) returns 2
but I would like to get to get 1 as the correct answer?

How can I test achieve it?

tarmo
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-02-10 21:51
FromTarmo Johannes
SubjectRe: [Csnd] opcode active by fractional number
Thanks!

That was nice solution! I had realized something similar with arrays but this is neater.

tarmo

Kontakt thorin kerr (<thorin.kerr@gmail.com>) kirjutas kuupäeval E, 10. veebruar 2020 kell 23:34:

On Tue, Feb 11, 2020 at 7:13 AM Tarmo Johannes <trmjhnns@gmail.com> wrote:
Hi,

I think it has been asked but I cannot find:

If I start and instrument with fractional number, say:

schedule 1.1, 0,  -1
schedule 1.2, 0,  -1

then
active(1.2) returns 2
but I would like to get to get 1 as the correct answer?

How can I test achieve it?

tarmo
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