blob: f338891cb3035f01f600b096f765d519240b5b44 [file] [log] [blame]
David Ghandeharib1536522017-05-24 00:01:15 -07001//
Kaido Kert612c0202020-01-22 10:28:42 -08002// Copyright 2015 The ANGLE Project Authors. All rights reserved.
David Ghandeharib1536522017-05-24 00:01:15 -07003// Use of this source code is governed by a BSD-style license that can be
4// found in the LICENSE file.
5//
6
7// X11Pixmap.h: Definition of the implementation of OSPixmap for X11
8
9#ifndef UTIL_X11_PIXMAP_H_
10#define UTIL_X11_PIXMAP_H_
11
12#include <X11/Xlib.h>
13#include <X11/Xutil.h>
14
Kaido Kert612c0202020-01-22 10:28:42 -080015#include "util/OSPixmap.h"
David Ghandeharib1536522017-05-24 00:01:15 -070016
17class X11Pixmap : public OSPixmap
18{
19 public:
20 X11Pixmap();
21 ~X11Pixmap() override;
22
23 bool initialize(EGLNativeDisplayType display, size_t width, size_t height, int depth) override;
24
25 EGLNativePixmapType getNativePixmap() const override;
26
27 private:
28 Pixmap mPixmap;
29 Display *mDisplay;
30};
31
Kaido Kert612c0202020-01-22 10:28:42 -080032#endif // UTIL_X11_PIXMAP_H_