| I have a doubt on how to clean csound after rendering. I am reusing a
Csound object and CsoundPerformanceThread object
Here is how I quit the display loop (in fact end animation and change
state to editor mode)
if ( csoundPerformanceThread.GetStatus() != 0 ) { // not running
csoundInstance.Cleanup();
... other stuff not csound related
}
Is that sufficient? Do I have to use csoundPerformanceThread.Join(); ?
what is the usage of join ?
I had trap when using reset, so I have stopped to use it
Thanks,
jp
victor a écrit :
> I think the only things to watch out are events, which you should
> only send using CsoundPerformanceThread::InputMessage() or
> CsoundPerformanceThread::ScoreEvent() instead of the
> Csound methoids of the same name. There should be no problems
> with GetChannel() or SetChannel().
>
> Victor
>
>
> ----- Original Message -----
> From: "Jean-Pierre Lemoine"
> To: "Developer discussions"
> Sent: Wednesday, April 16, 2008 6:32 PM
> Subject: [Cs-dev] AVSynthesis, java, thread and Linux
>
>
>
>> Just to try to clarify
>>
>> Thread
>> The Java stuff (JOGL) has internal threads that I don't manage. My
>> OpenGL code in in one thread. This thread use the csound API to start a
>> thread that executes csound rendering
>> csoundPerformanceThread = new CsoundPerformanceThread(
>> csoundInstance );
>> csoundPerformanceThread.Play();
>>
>> During real time rendering, I access to the csound software bus for
>> reading some values, used in the OpenGL loop.
>> SoundBus w = firstSoundBus;
>> while( w != null ) {
>> w.v = (float)csoundInstance.GetChannel(w.name);
>> w = w.next;
>> }
>>
>> I presume that there is no lock on the software bus, but I only read
>> values in the non csound thread. This has working nicely with 5.07, and
>> seems ok with 5.08 (windows)
>>
>> jp
>>
>>
>>
>> -------------------------------------------------------------------------
>> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
>> Don't miss this year's exciting event. There's still time to save $100.
>> Use priority code J8TL2D2.
>> http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
> Don't miss this year's exciting event. There's still time to save $100.
> Use priority code J8TL2D2.
> http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>
>
>
>
-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net |