适用于Android的Csound的非UI示例

时间:2015-03-19 17:50:01

标签: android csound

我已经查看了Csound for android附带的示例,但我想在不使用所有示例的UI小部件的情况下调用它。

我知道如何加载乐器,但如何让它播放指定频率的音符?

我是否使用sentcore?

干杯。

1 个答案:

答案 0 :(得分:0)

我不确定Csound的Android API,但如果有一个名为sentcore的函数,它听起来就像是正确的。您可能需要发送一个字符串,如:

i 1 0 10

(这意味着现在打开仪器1(时间= 0)10秒钟) 如果您的仪器已经设置好,您可能需要使用更多的值(使用Csound中所谓的p-fields)。

C API的功能是:

PUBLIC int  csoundScoreEvent (CSOUND *, char type, const MYFLT *pFields, long numFields)
PUBLIC int  csoundReadScore (CSOUND *csound, const char *str)

退房:

http://csound.github.io/docs/api/group__CONTROLEVENTS.html http://csound.github.io/docs/api/group__SCOREHANDLING.html