module OSC
From the Funaba osc gem:
Public Class Methods
coerce_argument(arg)
click to toggle source
# File lib/ruby-osc.rb, line 27 def self.coerce_argument(arg) case arg when OSCArgument then arg.to_osc_type when Symbol then arg.to_s when String, Float, Integer, Blob, String then arg # Osc 1.0 spec else raise(TypeError, "#{ arg.inspect } is not a valid Message argument") end end
padding_size(size)
click to toggle source
# File lib/ruby-osc.rb, line 41 def self.padding_size(size) (4 - (size) % 4) % 4 end
run() { || ... }
click to toggle source
# File lib/ruby-osc.rb, line 45 def self.run EM.run do EM.error_handler { |e| puts e } EM.set_quantum 5 yield end end