Csound Csound-dev Csound-tekno Search About

Re: [Cs-dev] bug: turnoff2 and r family opcodes

Date2007-11-06 13:54
FromDavis Pyon
SubjectRe: [Cs-dev] bug: turnoff2 and r family opcodes
turnoff2 runs at k-rate which means that if the instrument you're turning
off has a release stage, turnoff2 will try to turn off a single instance
multiple times.  I'm not sure if this can be considered a bug, but there
are workarounds.  For instance, you could change your instr 1 to:

instr 1 
    kCount init 0

    if kCount == 0 then
        turnoff2    2, 0, 1
    endif

    kCount = kCount + 1
endin

so that turnoff2 only gets called once per instance of instr 1.

To be honest, I don't know if turnoff2 should be fixed/changed.  Maybe a
warning in the manual would suffice?

Davis


----- Original Message ----
From: Oeyvind Brandtsegg 
To: Developer discussions 
Sent: Tuesday, November 6, 2007 1:21:20 AM
Subject: [Cs-dev] bug: turnoff2 and r family opcodes


When using an r family opcode (e.g. linenr) in combination with
 turnoff2,
I get 100% CPU usage and csound halts.

I've tried this with linenr, envlpxr, and also using xtratim and
 release.

Attached is a simple test csd.
Using csound compiled from CVS on October30th.

best
Oeyvind




-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net