Example #1
0
 private void OscListener_PacketReceived(Network.Osc.OscPacketEventArgs e)
 {
     if (HostAddresses.Any(a => a.Equals(e.SourceAddress)))
     {
         OscMessage?.Invoke(this, e);
         var message   = e.Packet as Svt.Network.Osc.OscMessage;
         var recorders = Recorders;
         if (message != null)
         {
             OscMessageReceived(message);
         }
         else
         {
             var bundle = e.Packet as Svt.Network.Osc.OscBundle;
             if (bundle != null)
             {
                 foreach (var m in bundle.Messages)
                 {
                     OscMessageReceived(m);
                 }
             }
         }
     }
 }