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

Unified Diff: examples/spinning_cube/spinning_cube_app.cc

Issue 1168993002: Update the native_viewport interface to allow specification of the surface configuration, currently… (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Final cleanups Created 5 years, 6 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 | « apps/moterm/gl_helper_test_app.cc ('k') | examples/surfaces_app/surfaces_app.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: examples/spinning_cube/spinning_cube_app.cc
diff --git a/examples/spinning_cube/spinning_cube_app.cc b/examples/spinning_cube/spinning_cube_app.cc
index 42e64b0b04c449da97fcb437d07489dfac6c2b4c..9ff7b4c6c75bf41e97ffb2d1bd89dd345d760cd2 100644
--- a/examples/spinning_cube/spinning_cube_app.cc
+++ b/examples/spinning_cube/spinning_cube_app.cc
@@ -41,8 +41,13 @@ class SpinningCubeApp : public mojo::ApplicationDelegate,
mojo::SizePtr size(mojo::Size::New());
size->width = 800;
size->height = 600;
+
+ auto requested_configuration = mojo::SurfaceConfiguration::New();
+ requested_configuration->depth_bits = 16;
+
viewport_->Create(
size.Clone(),
+ requested_configuration.Pass(),
base::Bind(&SpinningCubeApp::OnMetricsChanged, base::Unretained(this)));
viewport_->Show();
mojo::ContextProviderPtr onscreen_context_provider;
« no previous file with comments | « apps/moterm/gl_helper_test_app.cc ('k') | examples/surfaces_app/surfaces_app.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698