示例#1
0
        void Update()
        {
            if (mapper != null && textMeshProUGUI != null)
            {
                MapperStats s = mapper.Stats();

                switch (debugMode)
                {
                case DebugMode.imageCount:
                    textMeshProUGUI.text = string.Format("{0} {1}", textAppend, s.imageCount);
                    break;

                case DebugMode.inQueue:
                    textMeshProUGUI.text = string.Format("{0} {1}", textAppend, s.queueLen);
                    break;

                case DebugMode.posesFound:
                    textMeshProUGUI.text = string.Format("{0} {1}/{2}", textAppend, s.locSucc, s.locSucc + s.locFail);
                    break;
                }
            }
        }
        void Update()
        {
            if (mapper != null && textMeshProUGUI != null && m_Sdk != null)
            {
                MapperStats    ms = mapper.stats;
                LocalizerStats ls = m_Sdk.Localizer.stats;

                switch (debugMode)
                {
                case DebugMode.imageCount:
                    textMeshProUGUI.text = string.Format("{0} {1}", textAppend, ms.imageCount);
                    break;

                case DebugMode.inQueue:
                    textMeshProUGUI.text = string.Format("{0} {1}", textAppend, ms.queueLen);
                    break;

                case DebugMode.posesFound:
                    textMeshProUGUI.text = string.Format("{0} {1}/{2}", textAppend, ls.localizationSuccessCount, ls.localizationAttemptCount);
                    break;
                }
            }
        }