Dispatches OSC messages to the specified destination address and port.
예제 #1
0
        private void updateClient()
        {
            if (client != null) client.Close();
            client = new OSCClient(ip, port, true);

            this.viewModel.StatusMessage = string.Format("Client set to {0}:{1}\n", ip, port);
        }
예제 #2
0
    /// <summary>
    /// Creates an OSC client.
    /// </summary>
    /// <param name="server">The server to connect the client to.</param>
    /// <returns></returns>
    public OSCClient CreateClient(string server)
    {
        OscManager.DistantOsc oscDestination = this.GetOscDistantServer(server);

        IPAddress ip = IPAddress.Parse(oscDestination.ip);
        OSCClient c  = new UnityOSC.OSCClient(ip, (int)(oscDestination.port));

        this._localClients.Add(c);
        return(c);
    }
예제 #3
0
    // Use this for initialization
    public void Awake()
    {
        this.findNodes();

        this.oscManager = GameObject.Find("OscManager").GetComponent <OscManager> ();
        this.oscClient  = this.oscManager.CreateClient("drones");

        if (Application.isPlaying)
        {
            if (this._lpsNodes.Count < this.lpsNodesPositions.Length)
            {
                this.RecreateNodes();
            }
        }
    }
 void Start()
 {
     client = new UnityOSC.OSCClient(System.Net.IPAddress.Parse(targetIP), targetPort);
 }