| hi lorangeverte -
sure you can. below you find an example. in this case, sending and
receiving is done in csound both, but of course you can send from any
other application.
the printout shows that triggering is done immediately.
ciao -
joachim
-m128
sr = 44100
ksmps = 32
nchnls = 2
0dbfs = 1
seed 0
giPort OSCinit 7777
instr Send
kFreq init 1
kKlick metro kFreq
if kKlick == 1 then
kDur random 1, 3
kPitch random 8, 11
OSCsend kDur, "localhost", 7777, "/startinstr", "ff", kDur, kPitch
kFreq random 1/4, 4
printks "Sent at k-cycle %d\n", 0, timek:k()
endif
endin
schedule("Send",0,99999)
instr Receive
kDur, kOct init 0
kGotIt OSClisten giPort, "/startinstr", "ff", kDur, kOct
if kGotIt == 1 then
event "i", "Triggered", 0, kDur, kOct
printks " Received at k-cycle %d\n", 0, timek:k()
endif
endin
schedule("Receive",0,99999)
instr Triggered
aTone poscil ampdb(random:i(-30,-10)), cpsoct(p4)
aL, aR pan2 transeg:a(1, p3, -3, 0) * aTone, random:i(0,1)
out aL, aR
iTime timek
prints " Triggered at k-cycle %d\n", iTime
endin
On 16/07/17 18:34, lorangeverte wrote:
> Hello Csound community,
>
> I'm a user of csound~ and antescofo~ on Max... It's possible to communicate
> to Csound with antescofo~ and Osc messages (so communicate to Csound without
> csound~), but in the Csd it's meens that instruments are immedialtly turnon.
> So, do you know if it's possible to send via an Osc message a score
> information directly, and active via Osc an instrument? For exemple the Osc
> message could be: "i1 0 -3 P4 P5".
>
> Thanks for your responses,
>
> See you later!
>
> Lorangeverte
>
>
>
> --
> View this message in context: http://csound.1045644.n5.nabble.com/Osc-messages-to-Csound-score-tp5757243.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 |