OLD | NEW |
(Empty) | |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CHROME_BROWSER_ANDROID_VR_SHELL_VR_METRICS_UTIL_H_ |
| 6 #define CHROME_BROWSER_ANDROID_VR_SHELL_VR_METRICS_UTIL_H_ |
| 7 |
| 8 #include "base/macros.h" |
| 9 |
| 10 #include "chrome/browser/android/vr_shell/vr_core_info.h" |
| 11 #include "third_party/gvr-android-sdk/src/libraries/headers/vr/gvr/capi/include/
gvr.h" |
| 12 #include "third_party/gvr-android-sdk/src/libraries/headers/vr/gvr/capi/include/
gvr_types.h" |
| 13 |
| 14 namespace vr_shell { |
| 15 |
| 16 enum class ViewerType { |
| 17 UNKNOWN_TYPE = 0, |
| 18 CARDBOARD = 1, |
| 19 DAYDREAM = 2, |
| 20 VIEWER_TYPE_MAX, |
| 21 }; |
| 22 |
| 23 class VrMetricsUtil { |
| 24 public: |
| 25 static void LogGvrVersionForVrViewerType(gvr_context* context, |
| 26 const VrCoreInfo& vr_core_info); |
| 27 static void LogVrViewerType(gvr_context* context); |
| 28 |
| 29 private: |
| 30 static ViewerType GetVrViewerType(gvr_context* context); |
| 31 |
| 32 static bool has_logged_gvr_version_; |
| 33 |
| 34 DISALLOW_IMPLICIT_CONSTRUCTORS(VrMetricsUtil); |
| 35 }; |
| 36 |
| 37 } // namespace vr_shell |
| 38 |
| 39 #endif // CHROME_BROWSER_ANDROID_VR_SHELL_VR_METRICS_UTIL_H_ |
OLD | NEW |