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

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

Issue 2809143004: VR: Add a native UI element scene manager (Closed)
Patch Set: Rebase. Created 3 years, 8 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') | no next file » | 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 48fe0bffa14f1a87a34254329b8ad9de193b4d4e..16a5ea25a6b4947193fd2287f54bc82c49ebcae5 100644
--- a/chrome/browser/android/vr_shell/vr_shell_gl.cc
+++ b/chrome/browser/android/vr_shell/vr_shell_gl.cc
@@ -156,8 +156,10 @@ VrShellGl::VrShellGl(
scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner,
gvr_context* gvr_api,
bool initially_web_vr,
- bool reprojected_rendering)
- : web_vr_mode_(initially_web_vr),
+ bool reprojected_rendering,
+ UiScene* scene)
+ : scene_(scene),
+ web_vr_mode_(initially_web_vr),
surfaceless_rendering_(reprojected_rendering),
task_runner_(base::ThreadTaskRunnerHandle::Get()),
binding_(this),
@@ -187,8 +189,6 @@ VrShellGl::~VrShellGl() {
}
void VrShellGl::Initialize() {
- scene_ = base::MakeUnique<UiScene>();
-
if (surfaceless_rendering_) {
// If we're rendering surfaceless, we'll never get a java surface to render
// into, so we can initialize GL right away.
@@ -1304,10 +1304,6 @@ void VrShellGl::ForceExitVr() {
FROM_HERE, base::Bind(&VrShell::ForceExitVr, weak_vr_shell_));
}
-void VrShellGl::UpdateScene(std::unique_ptr<base::ListValue> commands) {
- scene_->HandleCommands(std::move(commands), base::TimeTicks::Now());
-}
-
void VrShellGl::SendVSync(base::TimeDelta time,
const GetVSyncCallback& callback) {
uint8_t frame_index = frame_index_++;
« no previous file with comments | « chrome/browser/android/vr_shell/vr_shell_gl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698