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

Unified Diff: chrome/browser/android/vr_shell/vr_shell.h

Issue 2552443002: WebVR: Add sanity checks for decoded pose index values (Closed)
Patch Set: Created 4 years 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 | « no previous file | chrome/browser/android/vr_shell/vr_shell.cc » ('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.h
diff --git a/chrome/browser/android/vr_shell/vr_shell.h b/chrome/browser/android/vr_shell/vr_shell.h
index 819208f3a6a69719ffa68de93d0b3ab7ba85c498..12e78413faffb7c24037a2a3016bcb4c9b287fb0 100644
--- a/chrome/browser/android/vr_shell/vr_shell.h
+++ b/chrome/browser/android/vr_shell/vr_shell.h
@@ -133,6 +133,7 @@ class VrShell : public device::GvrDelegate, content::WebContentsObserver {
const std::vector<const ContentRectangle*>& elements);
void DrawCursor(const gvr::Mat4f& render_matrix);
void DrawWebVr();
+ bool WebVrPoseByteIsValid(int pose_index_byte);
void UpdateController(const gvr::Vec3f& forward_vector);
void SendEventsToTarget(VrInputManager* input_target,
@@ -205,6 +206,7 @@ class VrShell : public device::GvrDelegate, content::WebContentsObserver {
// current backlog of poses which is 2-3 frames.
static constexpr int kPoseRingBufferSize = 8;
std::vector<gvr::Mat4f> webvr_head_pose_;
+ std::vector<bool> webvr_head_pose_valid_;
jint webvr_texture_id_ = 0;
std::unique_ptr<VrController> controller_;
« no previous file with comments | « no previous file | chrome/browser/android/vr_shell/vr_shell.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698