// Update is called once per frame void Update() { if (m_SendPos == SendState.World) { m_OSCHandler.SendOSCMessage(m_OSCName + "/pos", m_Tform.position); // hacks until multi value osc can be sorted m_OSCHandler.SendOSCMessage(m_OSCName + "/pos/x", m_Tform.position.x); m_OSCHandler.SendOSCMessage(m_OSCName + "/pos/y", m_Tform.position.y); m_OSCHandler.SendOSCMessage(m_OSCName + "/pos/z", m_Tform.position.z); } else if (m_SendPos == SendState.Local) { m_OSCHandler.SendOSCMessage(m_OSCName + "/pos", m_Tform.localPosition); } if (m_SendRot == SendState.World) { m_OSCHandler.SendOSCMessage(m_OSCName + "/rot", m_Tform.rotation.eulerAngles); } else if (m_SendRot == SendState.Local) { m_OSCHandler.SendOSCMessage(m_OSCName + "/rot", m_Tform.localRotation.eulerAngles); } }
void OutputOSC() { m_OSCHandler.SendOSCMessage(m_OSCPrefix + "/boundsVel", m_BoundsVel); m_OSCHandler.SendOSCMessage(m_OSCPrefix + "/transformAvVel", m_TransformAvVel); m_OSCHandler.SendOSCMessage(m_OSCPrefix + "/boundsCOM", m_Bounds_All.Center); m_OSCHandler.SendOSCMessage(m_OSCPrefix + "/transformCOM", m_TransformCOM); m_OSCHandler.SendOSCMessage(m_OSCPrefix + "/spaceIntensity", m_SpaceIntensity.m_NormalizedValue); m_OSCHandler.SendOSCMessage(m_OSCPrefix + "/speed", m_Speed.m_NormalizedValue); m_OSCHandler.SendOSCMessage(m_OSCPrefix + "/smoothness", m_Smoothness.m_NormalizedValue); m_OSCHandler.SendOSCMessage(m_OSCPrefix + "/reach", m_Reach.m_NormalizedValue); m_OSCHandler.SendOSCMessage(m_OSCPrefix + "/density", m_Density.m_NormalizedValue); m_OSCHandler.SendOSCMessage(m_OSCPrefix + "/coherence", m_Coherence.m_NormalizedValue); m_OSCHandler.SendOSCMessage(m_OSCPrefix + "/travelIntensity", m_TravelIntensity.m_NormalizedValue); m_OSCHandler.SendOSCMessage(m_OSCPrefix + "/energy", m_Energy.m_NormalizedValue); }