Csound Csound-dev Csound-tekno Search About

how do I post an i statement to the score(csd.) using Python code?

Date2016-04-27 00:48
FromCacophony7
Subjecthow do I post an i statement to the score(csd.) using Python code?
how do I post an i statement to the score(csd.) using Python code?

how do I generate multiple f statments with Python?



--
View this message in context: http://csound.1045644.n5.nabble.com/how-do-I-post-an-i-statement-to-the-score-csd-using-Python-code-tp5749295.html
Sent from the Csound - General mailing list archive at Nabble.com.

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

Date2016-04-27 09:47
FromRory Walsh
SubjectRe: how do I post an i statement to the score(csd.) using Python code?
The C way of doing this is using csoundInputMessage(), I don't know the Python API well at all, but perhaps you can find a similarly named method there?

On 27 April 2016 at 00:48, Cacophony7 <michaelsparks37@gmail.com> wrote:
how do I post an i statement to the score(csd.) using Python code?

how do I generate multiple f statments with Python?



--
View this message in context: http://csound.1045644.n5.nabble.com/how-do-I-post-an-i-statement-to-the-score-csd-using-Python-code-tp5749295.html
Sent from the Csound - General mailing list archive at Nabble.com.

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

Date2016-04-27 10:26
FromVictor Lazzarini
SubjectRe: how do I post an i statement to the score(csd.) using Python code?
Methods of the Csound class:

Csound.InputMessage(score-string)

or

Csound.ReadScore(score-string)

(the second allows you to use some score processing features)

You can send in your f-statements as score lines with the above.
========================
Dr Victor Lazzarini
Dean of Arts, Celtic Studies and Philosophy,
Maynooth University,
Maynooth, Co Kildare, Ireland
Tel: 00 353 7086936
Fax: 00 353 1 7086952 

> On 27 Apr 2016, at 00:48, Cacophony7  wrote:
> 
> how do I post an i statement to the score(csd.) using Python code?
> 
> how do I generate multiple f statments with Python?
> 
> 
> 
> --
> View this message in context: http://csound.1045644.n5.nabble.com/how-do-I-post-an-i-statement-to-the-score-csd-using-Python-code-tp5749295.html
> Sent from the Csound - General mailing list archive at Nabble.com.
> 
> 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

Date2016-04-27 21:16
FromCacophony7
SubjectRe: how do I post an i statement to the score(csd.) using Python code?
does anybody have the name of that method? the library is the only internet
access that I have right now. I got 18 minutes left.



--
View this message in context: http://csound.1045644.n5.nabble.com/how-do-I-post-an-i-statement-to-the-score-csd-using-Python-code-tp5749295p5749303.html
Sent from the Csound - General mailing list archive at Nabble.com.

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

Date2016-04-27 21:36
FromRory Walsh
SubjectRe: how do I post an i statement to the score(csd.) using Python code?

I think Victor already provided the name of the library function?

On 27 Apr 2016 9:17 pm, "Cacophony7" <michaelsparks37@gmail.com> wrote:
does anybody have the name of that method? the library is the only internet
access that I have right now. I got 18 minutes left.



--
View this message in context: http://csound.1045644.n5.nabble.com/how-do-I-post-an-i-statement-to-the-score-csd-using-Python-code-tp5749295p5749303.html
Sent from the Csound - General mailing list archive at Nabble.com.

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

Date2016-04-27 22:49
FromCacophony7
SubjectRe: how do I post an i statement to the score(csd.) using Python code?
...Python code "embedded" in Csound

OR, the other way around,

using Python to access Csound?



--
View this message in context: http://csound.1045644.n5.nabble.com/how-do-I-post-an-i-statement-to-the-score-csd-using-Python-code-tp5749295p5749305.html
Sent from the Csound - General mailing list archive at Nabble.com.

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

Date2016-04-27 22:52
FromMichael Gogins
SubjectRe: how do I post an i statement to the score(csd.) using Python code?
The Python functions mostly have the same names and analogous types to
the C++ functions.

In Python you can do this to see exactly what they are. First import
csnd6, then type help(csnd6). You will see every detail of the Python
API.

restore@sorabji MINGW64
~/csound/mingw64/packages/portaudio_asio/src/portaudio-svn/bin
$ d:/python27/python -i
Python 2.7.11 (v2.7.11:6d1b6a68f775, Dec  5 2015, 20:40:30) [MSC
v.1500 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import csnd6
>>> help(csnd6)

This is just a sample, there is much much more:

    class CppSound(Csound, CsoundFile)
     |  Proxy of C++ CppSound class
     |
     |  Method resolution order:
     |      CppSound
     |      Csound
     |      CsoundFile
     |      __builtin__.object
     |
     |  Methods defined here:
     |
     |  __del__ lambda self
     |
     |  __getattr__ lambda self, name
     |
     |  __init__(self)
     |      __init__(CppSound self) -> CppSound
     |
     |  __repr__ = _swig_repr(self)
     |
     |  __setattr__ lambda self, name, value
     |
     |  cleanup(self)
     |      cleanup(CppSound self)
     |
     |  compile(self, *args)
     |      compile(CppSound self, int argc, char ** argv) -> int
     |      compile(CppSound self) -> int
     |
     |  getCsound(self)
     |      getCsound(CppSound self) -> CSOUND *
     |
     |  getCsoundFile(self)
     |      getCsoundFile(CppSound self) -> CsoundFile
     |
     |  getIsCompiled(self)
     |      getIsCompiled(CppSound self) -> bool
     |
     |  getIsGo(self)
     |      getIsGo(CppSound self) -> bool
     |
     |  getIsPerforming(self)
     |      getIsPerforming(CppSound self) -> bool
     |
     |  getOutputSoundfileName(self)
     |      getOutputSoundfileName(CppSound self) -> std::string
     |
     |  getSpoutSize(self)
     |      getSpoutSize(CppSound self) -> size_t
     |
     |  getThis(self)
     |      getThis(CppSound self) -> intptr_t
     |
     |  inputMessage(self, istatement)
     |      inputMessage(CppSound self, char const * istatement)
     |
     |  perform(self, *args)
     |      perform(CppSound self, int argc, char ** argv) -> int
     |      perform(CppSound self) -> int
     |
     |  performKsmps(self)
     |      performKsmps(CppSound self) -> int
     |
     |  setIsPerforming(self, isPerforming)
     |      setIsPerforming(CppSound self, bool isPerforming)
     |
     |  setPythonMessageCallback(self)
     |      setPythonMessageCallback(CppSound self)
     |
     |  stop(self)
     |      stop(CppSound self)
     |
     |  write(self, text)
     |      write(CppSound self, char const * text)
     |
     |  ----------------------------------------------------------------------
     |  Data and other attributes defined here:
     |
     |  __swig_destroy__ = 
     |      delete_CppSound(CppSound self)
     |
     |  __swig_getmethods__ = {'arrangement':  int
     |
     |  Cleanup(self)
     |      Cleanup(Csound self) -> int
     |
     |  Compile(self, *args)
     |      Compile(Csound self, int argc, char ** argv) -> int
     |      Compile(Csound self, char * csdName) -> int
     |      Compile(Csound self, char * orcName, char * scoName) -> int
     |      Compile(Csound self, char * arg1, char * arg2, char * arg3) -> int
     |      Compile(Csound self, char * arg1, char * arg2, char *
arg3, char * arg4) -> int
     |      Compile(Csound self, char * arg1, char * arg2, char *
arg3, char * arg4, char * arg5) -> int
     |
     |  CompileArgs(self, argc, argv)
     |      CompileArgs(Csound self, int argc, char ** argv) -> int
     |
     |  CompileCsd(self, csd)
     |      CompileCsd(Csound self, char * csd) -> int
     |
     |  CompileCsdText(self, csd_text)
     |      CompileCsdText(Csound self, char * csd_text) -> int
     |
     |  CompileOrc(self, str)
     |      CompileOrc(Csound self, char const * str) -> int
     |
     |  CompileTree(self, root)
     |      CompileTree(Csound self, TREE root) -> int
     |
     |  CreateGlobalVariable(self, name, nbytes)
     |      CreateGlobalVariable(Csound self, char const * name,
size_t nbytes) -> int
     |
     |  CreateMessageBuffer(self, toStdOut)
     |      CreateMessageBuffer(Csound self, int toStdOut)
     |
     |  DeleteChannelList(self, lst)
     |      DeleteChannelList(Csound self, controlChannelInfo_t lst)
     |
     |  DeleteTree(self, root)
     |      DeleteTree(Csound self, TREE root)
     |
     |  DeleteUtilityList(self, lst)
     |      DeleteUtilityList(Csound self, char ** lst)
     |
     |  DestroyGlobalVariable(self, name)
     |      DestroyGlobalVariable(Csound self, char const * name) -> int
     |
     |  DestroyMessageBuffer(self)
     |      DestroyMessageBuffer(Csound self)
     |
     |  DisposeOpcodeList(self, opcodelist)
     |      DisposeOpcodeList(Csound self, opcodeListEntry opcodelist)
     |
     |  EvalCode(self, str)
     |      EvalCode(Csound self, char const * str) -> double
     |
     |  Get0dBFS(self)
     |      Get0dBFS(Csound self) -> double
     |
     |  GetAPIVersion(self)
     |      GetAPIVersion(Csound self) -> int
     |
     |  GetAudioChannel(self, name, samples)
     |      GetAudioChannel(Csound self, char const * name, double * samples)
     |
     |  GetChannel(self, name, err=None)
     |      GetChannel(Csound self, char const * name, int * err=None) -> double
     |      GetChannel(Csound self, char const * name) -> double
     |


-----------------------------------------------------
Michael Gogins
Irreducible Productions
http://michaelgogins.tumblr.com
Michael dot Gogins at gmail dot com


On Wed, Apr 27, 2016 at 4:36 PM, Rory Walsh  wrote:
> I think Victor already provided the name of the library function?
>
> On 27 Apr 2016 9:17 pm, "Cacophony7"  wrote:
>>
>> does anybody have the name of that method? the library is the only
>> internet
>> access that I have right now. I got 18 minutes left.
>>
>>
>>
>> --
>> View this message in context:
>> http://csound.1045644.n5.nabble.com/how-do-I-post-an-i-statement-to-the-score-csd-using-Python-code-tp5749295p5749303.html
>> Sent from the Csound - General mailing list archive at Nabble.com.
>>
>> 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