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

Unified Diff: third_party/WebKit/Source/modules/vr/VRController.cpp

Issue 2309523003: Plumbing through more WebVR presentation code (Closed)
Patch Set: Addressed Michael's feedack Created 4 years, 3 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
Index: third_party/WebKit/Source/modules/vr/VRController.cpp
diff --git a/third_party/WebKit/Source/modules/vr/VRController.cpp b/third_party/WebKit/Source/modules/vr/VRController.cpp
index bc92c33ec8f19e1640dee2cab9506620a542cbe6..d65e078825eaaafa9acc0338243738a8db1140e2 100644
--- a/third_party/WebKit/Source/modules/vr/VRController.cpp
+++ b/third_party/WebKit/Source/modules/vr/VRController.cpp
@@ -58,6 +58,40 @@ void VRController::resetPose(unsigned index)
m_service->ResetPose(index);
}
+void VRController::requestPresent(unsigned index)
+{
+ if (!m_service)
+ return;
+
+ m_service->RequestPresent(index);
+}
+
+void VRController::exitPresent(unsigned index)
+{
+ if (!m_service)
+ return;
+
+ m_service->ExitPresent(index);
+}
+
+void VRController::submitFrame(unsigned index)
+{
+ if (!m_service)
+ return;
+
+ m_service->SubmitFrame(index);
+}
+
+void VRController::updateLayerBounds(unsigned index,
+ device::blink::VRLayerBoundsPtr leftBounds,
+ device::blink::VRLayerBoundsPtr rightBounds)
+{
+ if (!m_service)
+ return;
+
+ m_service->UpdateLayerBounds(index, std::move(leftBounds), std::move(rightBounds));
+}
+
VRDisplay* VRController::createOrUpdateDisplay(const device::blink::VRDisplayPtr& display)
{
VRDisplay* vrDisplay = getDisplayForIndex(display->index);
« no previous file with comments | « third_party/WebKit/Source/modules/vr/VRController.h ('k') | third_party/WebKit/Source/modules/vr/VRDisplay.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698