private void GetCubeInfoOnTouch() { if (Input.touchCount < 1 || (m_Touch = Input.GetTouch(0)).phase != TouchPhase.Began) { return; } var ray = Camera.main.ScreenPointToRay(m_Touch.position); if (Physics.Raycast(ray, out hitInfo)) { m_HittedVoxel = hitInfo.transform.gameObject; int hash = m_Reconstructor.GetSpatialHashing().GetHash(m_HittedVoxel.transform.position, m_Reconstructor.GetSpatialHashing().GetScale(), m_Reconstructor.GetSpatialHashing().GetHashTableSize()); HashEntry hashEntry = (HashEntry)m_Reconstructor.GetSpatialHashing().GetFromTable(hash); string text = m_HittedVoxel.transform.position.ToString("0.000") + " " + hashEntry.weight.ToString("0.00") + " " + hashEntry.distanceToCamera.ToString("0.00"); m_DebugText.SetVoxelInfo(text); } }