Csound Csound-dev Csound-tekno Search About

[Csnd] Csound API, c language and csd

Date2012-07-25 18:42
Fromfrancesco
Subject[Csnd] Csound API, c language and csd
Hello All,
i'm slowing study some c language and i'm try to make some simple
experiment using the Csound API.
I use this:

char *arg[]={"csound", "-m0", "-+rtaudio=alsa", "-dodac",
                        orchestra, score};
    int result = csoundCompile(csound, narg, arg);

but i'm not able to pass a csd like argument, i.e. i need to have
orc + score. I would like to know how can i (if i can) 
call compile with a csd.

Thanks,
ciao,
francesco.




--
View this message in context: http://csound.1045644.n5.nabble.com/Csound-API-c-language-and-csd-tp5714416.html
Sent from the Csound - General mailing list archive at Nabble.com.

Date2012-07-25 19:03
Fromjpff@cs.bath.ac.uk
SubjectRe: [Csnd] Csound API, c language and csd
> Hello All,
> i'm slowing study some c language and i'm try to make some simple
> experiment using the Csound API.
> I use this:
>
> char *arg[]={"csound", "-m0", "-+rtaudio=alsa", "-dodac",
>                         orchestra, score};

If you do

char *arg[]={"csound", "-m0", "-+rtaudio=alsa", "-dodac", csdfile_;

if should work, or have I misunderstood the problem?

I do not like variables in initialisers as that in not C89

==John ff

>     int result = csoundCompile(csound, narg, arg);
>
> but i'm not able to pass a csd like argument, i.e. i need to have
> orc + score. I would like to know how can i (if i can)
> call compile with a csd.
>
> Thanks,
> ciao,
> francesco.
>
>
>
>
> --
> View this message in context:
> http://csound.1045644.n5.nabble.com/Csound-API-c-language-and-csd-tp5714416.html
> Sent from the Csound - General mailing list archive at Nabble.com.
>
>
> Send bugs reports to the Sourceforge bug tracker
>             https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe
> csound"
>
>
>
>



Date2012-07-25 19:48
Fromfrancesco
Subject[Csnd] Re: Csound API, c language and csd
Yes, i have try that but seems do not work (csound output tells
that do not recognize the first character (<) of csd.
Anyway,

I do not like variables in initialisers as that in not C89

how can i do differently? Please remember that i'm only
at first step with c ...

Thanks,
ciao,
francesco.




--
View this message in context: http://csound.1045644.n5.nabble.com/Csound-API-c-language-and-csd-tp5714416p5714419.html
Sent from the Csound - General mailing list archive at Nabble.com.

Date2012-07-26 07:17
FromTito Latini
SubjectRe: [Csnd] Re: Csound API, c language and csd
AttachmentsNone  

Date2012-07-26 09:14
Fromfrancesco
Subject[Csnd] Re: Csound API, c language and csd
Thanks Tito,
i'm going to understand what i can! Especially under the sun of Liguria.

Maybe i would ask somethings different like:

csoundCompile use argc and argv and this are meant from command line
(am i right?), but what if i want to pass command directly in the main
function?
Using Lua (or Python) i have a function setCommand(string command), is there
somethings similar in c?

thanks,
and again apologies for so newbie question.
ciao,
francesco.





--
View this message in context: http://csound.1045644.n5.nabble.com/Csound-API-c-language-and-csd-tp5714416p5714428.html
Sent from the Csound - General mailing list archive at Nabble.com.

Date2012-07-26 10:07
FromTito Latini
SubjectRe: [Csnd] Re: Csound API, c language and csd
AttachmentsNone