Mir
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
display_device.h
Go to the documentation of this file.
1 /*
2  * Copyright © 2013 Canonical Ltd.
3  *
4  * This program is free software: you can redistribute it and/or modify
5  * it under the terms of the GNU Lesser General Public License version 3 as
6  * published by the Free Software Foundation.
7  *
8  * This program is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  * GNU Lesser General Public License for more details.
12  *
13  * You should have received a copy of the GNU Lesser General Public License
14  * along with this program. If not, see <http://www.gnu.org/licenses/>.
15  *
16  * Authored by: Kevin DuBois <kevin.dubois@canonical.com>
17  */
18 
19 #ifndef MIR_GRAPHICS_ANDROID_DISPLAY_SUPPORT_PROVIDER_H_
20 #define MIR_GRAPHICS_ANDROID_DISPLAY_SUPPORT_PROVIDER_H_
21 
23 #include "mir_toolkit/common.h"
24 #include <EGL/egl.h>
25 
26 namespace mir
27 {
28 namespace graphics
29 {
30 class Buffer;
31 class Renderable;
32 
33 namespace android
34 {
35 class RenderableListCompositor;
36 class SwappingGLContext;
37 
39 {
40 public:
41  virtual ~DisplayDevice() = default;
42 
43  virtual void mode(MirPowerMode mode) = 0;
44  virtual void post_gl(SwappingGLContext const& context) = 0;
45  /* \returns true if the DisplayDevice can support the renderlist
46  false if the display device cannot support drawing the given renderlist.
47  */
48  virtual bool post_overlays(
49  SwappingGLContext const& context,
50  RenderableList const& list,
51  RenderableListCompositor const& list_compositor) = 0;
52  virtual bool apply_orientation(MirOrientation orientation) const = 0;
53 
54 protected:
55  DisplayDevice() = default;
56  DisplayDevice& operator=(DisplayDevice const&) = delete;
57  DisplayDevice(DisplayDevice const&) = delete;
58 };
59 
60 }
61 }
62 }
63 
64 #endif /* MIR_GRAPHICS_ANDROID_DISPLAY_SUPPORT_PROVIDER_H_ */
All things Mir.
Definition: aging_buffer.h:24
Definition: display_device.h:38
Definition: hwc_fallback_gl_renderer.h:38
Definition: swapping_gl_context.h:31
MirOrientation
Direction relative to the "natural" orientation of the display.
Definition: common.h:134
virtual void mode(MirPowerMode mode)=0
std::list< std::shared_ptr< Renderable > > RenderableList
Definition: renderable.h:88
virtual bool post_overlays(SwappingGLContext const &context, RenderableList const &list, RenderableListCompositor const &list_compositor)=0
MirPowerMode
Definition: common.h:96
DisplayDevice & operator=(DisplayDevice const &)=delete
virtual bool apply_orientation(MirOrientation orientation) const =0
Definition: android_input_receiver.h:32
virtual void post_gl(SwappingGLContext const &context)=0

Copyright © 2012,2013 Canonical Ltd.
Generated on Fri Oct 10 14:07:14 UTC 2014