Csound Csound-dev Csound-tekno Search About

[Csnd] Running CsoundAC on a CSD

Date2013-03-04 14:35
FromMark Brophy
Subject[Csnd] Running CsoundAC on a CSD
I want to run CsoundAC on a CSD rather than an ORC and SCO. Is there a function analogous to setCsoundOrchestra and setCsoundScoreHeader that accepts a CSD as input?


Date2013-03-04 14:53
FromMichael Gogins
SubjectRe: [Csnd] Running CsoundAC on a CSD
You can call getCppSound from MusicModel, and from CppSound you can call setCSD and getCSD.

Hope this helps,
Mike


On Mon, Mar 4, 2013 at 9:35 AM, Mark Brophy <mark@brophyworld.com> wrote:
I want to run CsoundAC on a CSD rather than an ORC and SCO. Is there a function analogous to setCsoundOrchestra and setCsoundScoreHeader that accepts a CSD as input?




--
Michael Gogins
Irreducible Productions
http://www.michael-gogins.com
Michael dot Gogins at gmail dot com

Date2013-03-04 18:42
FromMark Brophy
SubjectRe: [Csnd] Running CsoundAC on a CSD
I don't understand this. I use the code below, producing no sound:

def RenderCSD():

model = CsoundAC.MusicModel()

CppSound = model.getCppSound()

f = open('/songs/csound/exp.csd', 'r')

csd = f.read()

f.close()

CppSound.setCSD(csd)

command = 'csound -odac /songs/csound/exp.csd'

model.setCsoundCommand(command)

model.render()


What's wrong with this code?


On Mon, Mar 4, 2013 at 8:53 AM, Michael Gogins <michael.gogins@gmail.com> wrote:
You can call getCppSound from MusicModel, and from CppSound you can call setCSD and getCSD.

Hope this helps,
Mike


On Mon, Mar 4, 2013 at 9:35 AM, Mark Brophy <mark@brophyworld.com> wrote:
I want to run CsoundAC on a CSD rather than an ORC and SCO. Is there a function analogous to setCsoundOrchestra and setCsoundScoreHeader that accepts a CSD as input?




--
Michael Gogins
Irreducible Productions
http://www.michael-gogins.com
Michael dot Gogins at gmail dot com


Date2013-03-04 18:53
FromMichael Gogins
SubjectRe: [Csnd] Running CsoundAC on a CSD
After you load the file, you have to save it for performance with the CppSound exportForPerformance function. Look at the examples/python/Lindenmayer.py file. Sorry I forgot to mention this. 

In Csound 6, this extraneous saving step will no longer be necessary.

Hope this helps,
Mike


On Mon, Mar 4, 2013 at 1:42 PM, Mark Brophy <mark@brophyworld.com> wrote:
I don't understand this. I use the code below, producing no sound:

def RenderCSD():

model = CsoundAC.MusicModel()

CppSound = model.getCppSound()

f = open('/songs/csound/exp.csd', 'r')

csd = f.read()

f.close()

CppSound.setCSD(csd)

command = 'csound -odac /songs/csound/exp.csd'

model.setCsoundCommand(command)

model.render()


What's wrong with this code?


On Mon, Mar 4, 2013 at 8:53 AM, Michael Gogins <michael.gogins@gmail.com> wrote:
You can call getCppSound from MusicModel, and from CppSound you can call setCSD and getCSD.

Hope this helps,
Mike


On Mon, Mar 4, 2013 at 9:35 AM, Mark Brophy <mark@brophyworld.com> wrote:
I want to run CsoundAC on a CSD rather than an ORC and SCO. Is there a function analogous to setCsoundOrchestra and setCsoundScoreHeader that accepts a CSD as input?




--
Michael Gogins
Irreducible Productions
http://www.michael-gogins.com
Michael dot Gogins at gmail dot com




--
Michael Gogins
Irreducible Productions
http://www.michael-gogins.com
Michael dot Gogins at gmail dot com

Date2013-03-05 04:05
FromMark Brophy
SubjectRe: [Csnd] Running CsoundAC on a CSD
The Lindenmayer.py file does not use exportForPerformance; it uses model.performAll() without the export. What is the purpose of csound.setFilename(filename)?

I haven't been able to run a CSD with CsoundAC, but I am able to run a CSD by importing csnd using code from the "Controlling Csound using Python" section of the Creating Rhythmic Noise article of the "Python for Friends" blog.


On Mon, Mar 4, 2013 at 12:53 PM, Michael Gogins <michael.gogins@gmail.com> wrote:
After you load the file, you have to save it for performance with the CppSound exportForPerformance function. Look at the examples/python/Lindenmayer.py file. Sorry I forgot to mention this. 

In Csound 6, this extraneous saving step will no longer be necessary.

Hope this helps,
Mike


On Mon, Mar 4, 2013 at 1:42 PM, Mark Brophy <mark@brophyworld.com> wrote:
I don't understand this. I use the code below, producing no sound:

def RenderCSD():

model = CsoundAC.MusicModel()

CppSound = model.getCppSound()

f = open('/songs/csound/exp.csd', 'r')

csd = f.read()

f.close()

CppSound.setCSD(csd)

command = 'csound -odac /songs/csound/exp.csd'

model.setCsoundCommand(command)

model.render()


What's wrong with this code?


On Mon, Mar 4, 2013 at 8:53 AM, Michael Gogins <michael.gogins@gmail.com> wrote:
You can call getCppSound from MusicModel, and from CppSound you can call setCSD and getCSD.

Hope this helps,
Mike


On Mon, Mar 4, 2013 at 9:35 AM, Mark Brophy <mark@brophyworld.com> wrote:
I want to run CsoundAC on a CSD rather than an ORC and SCO. Is there a function analogous to setCsoundOrchestra and setCsoundScoreHeader that accepts a CSD as input?




--
Michael Gogins
Irreducible Productions
http://www.michael-gogins.com
Michael dot Gogins at gmail dot com




--
Michael Gogins
Irreducible Productions
http://www.michael-gogins.com
Michael dot Gogins at gmail dot com