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

Unified Diff: remoting/client/ios/display/gl_demo_screen.h

Issue 2555803002: Adding the iOS app and integration example with GlRenderer. (Closed)
Patch Set: Adding todo reminder for ES3 vs ES2. Created 3 years, 11 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: remoting/client/ios/display/gl_demo_screen.h
diff --git a/remoting/client/ios/display/gl_demo_screen.h b/remoting/client/ios/display/gl_demo_screen.h
new file mode 100644
index 0000000000000000000000000000000000000000..e522bbd16dfab4a5ee1a6b77f7bb358fbdcc0c28
--- /dev/null
+++ b/remoting/client/ios/display/gl_demo_screen.h
@@ -0,0 +1,40 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef REMOTING_CLIENT_IOS_DISPLAY_GL_DEMO_SCREEN_H_
+#define REMOTING_CLIENT_IOS_DISPLAY_GL_DEMO_SCREEN_H_
+
+#include "base/macros.h"
+#include "base/threading/thread_checker.h"
+#include "remoting/client/display/drawable.h"
+#include "remoting/client/display/sys_opengl.h"
+
+namespace remoting {
+
+// This class draws the desktop on the canvas.
+class GlDemoScreen : public Drawable {
+ public:
+ GlDemoScreen();
+ ~GlDemoScreen() override;
+
+ // Drawable implementation.
+ void SetCanvas(base::WeakPtr<Canvas> canvas) override;
+ bool Draw() override;
+ base::WeakPtr<Drawable> GetWeakPtr() override;
+ int GetZIndex() override;
+
+ private:
+ base::WeakPtr<Canvas> canvas_;
+ int square_size_ = 0;
+ GLuint program_;
+
+ base::ThreadChecker thread_checker_;
+ base::WeakPtrFactory<Drawable> weak_factory_;
+
+ DISALLOW_COPY_AND_ASSIGN(GlDemoScreen);
+};
+
+} // namespace remoting
+
+#endif // REMOTING_CLIENT_IOS_DISPLAY_GL_DEMO_SCREEN_H_

Powered by Google App Engine
This is Rietveld 408576698