Corentin Wallez | 5244528 | 2015-06-09 09:15:54 +0200 | [diff] [blame] | 1 | // |
| 2 | // Copyright (c) 2015 The ANGLE Project Authors. All rights reserved. |
| 3 | // Use of this source code is governed by a BSD-style license that can be |
| 4 | // found in the LICENSE file. |
| 5 | // |
| 6 | |
| 7 | // OSPixmap.h: Definition of an abstract pixmap class |
| 8 | |
| 9 | #ifndef SAMPLE_UTIL_PIXMAP_H_ |
| 10 | #define SAMPLE_UTIL_PIXMAP_H_ |
| 11 | |
Corentin Wallez | 27593e0 | 2015-09-15 08:19:09 -0700 | [diff] [blame] | 12 | #include <stdlib.h> |
| 13 | |
Corentin Wallez | 5244528 | 2015-06-09 09:15:54 +0200 | [diff] [blame] | 14 | #include <EGL/egl.h> |
| 15 | #include <EGL/eglext.h> |
| 16 | |
Jamie Madill | ba319ba | 2018-12-29 10:29:33 -0500 | [diff] [blame] | 17 | #include "util/Event.h" |
| 18 | #include "util/util_export.h" |
Corentin Wallez | 5244528 | 2015-06-09 09:15:54 +0200 | [diff] [blame] | 19 | |
Jamie Madill | ba319ba | 2018-12-29 10:29:33 -0500 | [diff] [blame] | 20 | class ANGLE_UTIL_EXPORT OSPixmap |
Corentin Wallez | 5244528 | 2015-06-09 09:15:54 +0200 | [diff] [blame] | 21 | { |
| 22 | public: |
| 23 | OSPixmap() {} |
| 24 | virtual ~OSPixmap() {} |
| 25 | |
Jamie Madill | ba319ba | 2018-12-29 10:29:33 -0500 | [diff] [blame] | 26 | virtual bool initialize(EGLNativeDisplayType display, |
| 27 | size_t width, |
| 28 | size_t height, |
| 29 | int depth) = 0; |
Corentin Wallez | 5244528 | 2015-06-09 09:15:54 +0200 | [diff] [blame] | 30 | |
| 31 | virtual EGLNativePixmapType getNativePixmap() const = 0; |
| 32 | }; |
| 33 | |
Jamie Madill | ba319ba | 2018-12-29 10:29:33 -0500 | [diff] [blame] | 34 | ANGLE_UTIL_EXPORT OSPixmap *CreateOSPixmap(); |
Corentin Wallez | 5244528 | 2015-06-09 09:15:54 +0200 | [diff] [blame] | 35 | |
Jamie Madill | ba319ba | 2018-12-29 10:29:33 -0500 | [diff] [blame] | 36 | #endif // SAMPLE_UTIL_PIXMAP_H_ |