Beispiel #1
0
    void OnApplicationPause(bool pause)
    {
        Debug.Log("OnApplicationPause: " + pause);

        if (pause)
        {
            MetaioSDKUnity.pauseSensors();

            if (MetaioSDKUnity.usingCamera)
            {
                MetaioSDKUnity.stopCamera();
            }
        }
        else
        {
            MetaioSDKUnity.resumeSensors();

            if (MetaioSDKUnity.usingCamera)
            {
                // Resume same camera as previously set
                MetaioSDKUnity.startCamera(MetaioSDKUnity.requestedCamera);
            }
        }
    }