Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(327)

Unified Diff: chrome/browser/android/vr_shell/vr_shell_gl.cc

Issue 2680723003: Remove ENABLE_VR_SHELL compile-time define. (Closed)
Patch Set: Fix lint warnings generated by vr_shell's new pickier checks. Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/android/vr_shell/vr_shell_gl.h ('k') | chrome/browser/browser_resources.grd » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/vr_shell/vr_shell_gl.cc
diff --git a/chrome/browser/android/vr_shell/vr_shell_gl.cc b/chrome/browser/android/vr_shell/vr_shell_gl.cc
index 0277e5bd2d4c50c63eae9f2f71326bb90b7abaf3..4564af0162f5c35aab779ce0b28045de7f093c98 100644
--- a/chrome/browser/android/vr_shell/vr_shell_gl.cc
+++ b/chrome/browser/android/vr_shell/vr_shell_gl.cc
@@ -4,6 +4,7 @@
#include "chrome/browser/android/vr_shell/vr_shell_gl.h"
+#include <limits>
#include <utility>
#include "base/android/jni_android.h"
@@ -34,7 +35,7 @@ namespace vr_shell {
namespace {
// TODO(mthiesse): If gvr::PlatformInfo().GetPosePredictionTime() is ever
// exposed, use that instead (it defaults to 50ms on most platforms).
-static constexpr long kPredictionTimeWithoutVsyncNanos = 50000000;
+static constexpr int64_t kPredictionTimeWithoutVsyncNanos = 50000000;
static constexpr float kZNear = 0.1f;
static constexpr float kZFar = 1000.0f;
@@ -308,9 +309,9 @@ bool VrShellGl::GetPixelEncodedFrameIndex(uint16_t* frame_index) {
last_frame_index_ = pixels[0];
return true;
}
- VLOG(1) << "WebVR: reject decoded pose index " << (int)pixels[0]
- << ", bad magic number " << (int)pixels[1] << ", "
- << (int)pixels[2];
+ VLOG(1) << "WebVR: reject decoded pose index " << static_cast<int>(pixels[0])
+ << ", bad magic number " << static_cast<int>(pixels[1]) << ", "
+ << static_cast<int>(pixels[2]);
return false;
}
@@ -1036,7 +1037,7 @@ void VrShellGl::GetVSync(const GetVSyncCallback& callback) {
SendVSync(pending_time_, callback);
}
-void VrShellGl::UpdateVSyncInterval(long timebase_nanos,
+void VrShellGl::UpdateVSyncInterval(int64_t timebase_nanos,
double interval_seconds) {
vsync_timebase_ = base::TimeTicks();
vsync_timebase_ += base::TimeDelta::FromMicroseconds(timebase_nanos / 1000);
« no previous file with comments | « chrome/browser/android/vr_shell/vr_shell_gl.h ('k') | chrome/browser/browser_resources.grd » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698