本文整理汇总了Python中myro.osc.sendMsg函数的典型用法代码示例。如果您正苦于以下问题:Python sendMsg函数的具体用法?Python sendMsg怎么用?Python sendMsg使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了sendMsg函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Python代码示例。
示例1: strike
def strike(self, strength):
if strength >= 0 and strength <= 1:
osc.sendMsg("/inst/modalbar/strike", [strength * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
示例2: __init__
def __init__(self):
self.name = "mandolin"
osc.sendMsg("/init", [self.name])
time.sleep(0.5)
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:4,代码来源:chuck.py
示例3: setPlaybackRate
def setPlaybackRate(self, rate):
if rate > 0:
osc.sendMsg("/inst/sndbuf/rate", [rate * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
示例4: setLoopRate
def setLoopRate(self, loopsPerSecond):
if loopsPerSecond > 0:
osc.sendMsg("/inst/sndbuf/loopRate", [loopsPerSecond * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
示例5: noteOff
def noteOff(self, velocity):
if self.name == "sinosc" or self.name == "sndbuf":
osc.sendMsg("/inst/" + self.name + "/gain", [0.0])
else:
osc.sendMsg("/inst/" + self.name + "/noteOff", [velocity * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:5,代码来源:chuck.py
示例6: setFile
def setFile(self, filename):
osc.sendMsg("/inst/sndbuf/read", [filename])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:2,代码来源:chuck.py
示例7: setReedStiffness
def setReedStiffness(self, stiffness):
if stiffness >= 0 and stiffness <= 1:
osc.sendMsg("/inst/blowhole/reed", [stiffness * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
示例8: setNoiseGain
def setNoiseGain(self, gain):
if gain >= 0 and gain <= 1:
osc.sendMsg("/inst/blowhole/noiseGain", [gain * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
示例9: setVibrato
def setVibrato(self, vibratoFreq, vibratoGain, noiseGain):
if vibratoGain >= 0 and vibratoGain <= 1 and noiseGain >= 0 and noiseGain <= 1:
osc.sendMsg("/inst/blowbotl/vibrato", [vibratoFreq * 1.0,
vibratoGain * 1.0,
noiseGain * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:5,代码来源:chuck.py
示例10: setFrequency
def setFrequency(self, freq):
osc.sendMsg("/inst/" + self.name + "/freq", [freq * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:2,代码来源:chuck.py
示例11: setMode
def setMode(self, mode, ratio, radius, gain):
if mode >= 0 and mode <= 1 and radius >= 0 and radius <= 1 and gain >= 0 and gain <= 1:
osc.sendMsg("/inst/modalbar/mode", [int(mode), ratio * 1.0,
radius * 1.0, gain * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:4,代码来源:chuck.py
示例12: damp
def damp(self, amount):
if amount >= 0 and amount <= 1:
osc.sendMsg("/inst/modalbar/damp", [amount * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
示例13: setToneHoleSize
def setToneHoleSize(self, size):
if size >= 0 and size <= 1:
osc.sendMsg("/inst/blowhole/tonehole", [size * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
示例14: setVolume
def setVolume(self, volume):
if volume >= 0 and volume <= 1:
osc.sendMsg("/inst/bowed/volume", [volume * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
示例15: setVent
def setVent(self, vent):
if vent >= 0 and vent <= 1:
osc.sendMsg("/inst/blowhole/vent", [vent * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
示例16: stopBowing
def stopBowing(self, floatValue):
if floatValue >= 0 and floatValue <= 1:
osc.sendMsg("/inst/bowed/stopBowing", [floatValue * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
示例17: setPressure
def setPressure(self, pressure):
if pressure >= 0 and pressure <= 1:
osc.sendMsg("/inst/blowhole/pressure", [pressure * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
示例18: setReadPosition
def setReadPosition(self, position):
if position >= 0:
osc.sendMsg("/inst/sndbuf/position", [int(position)])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
示例19: startBlowing
def startBlowing(self, strength):
if strength >= 0 and strength <= 1:
osc.sendMsg("/inst/blowhole/startBlowing", [strength * 1.0])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
示例20: setLooping
def setLooping(self, doLoop):
if doLoop >= 0:
osc.sendMsg("/inst/sndbuf/loop", [int(doLoop)])
开发者ID:BrendanBenshoof,项目名称:myro-epuck,代码行数:3,代码来源:chuck.py
注:本文中的myro.osc.sendMsg函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论