1 #ifndef WINDOW_SYSTEM_EGL_H
2 #define WINDOW_SYSTEM_EGL_H
7 * Copyright (C) 2005-2013 Team XBMC
10 * This Program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2, or (at your option)
15 * This Program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
20 * You should have received a copy of the GNU General Public License
21 * along with XBMC; see the file COPYING. If not, see
22 * <http://www.gnu.org/licenses/>.
25 #include "windowing/WinSystem.h"
28 #include "rendering/gles/RenderSystemGLES.h"
29 #include "utils/GlobalsHandling.h"
31 class CWinSystemX11GLES : public CWinSystemBase, public CRenderSystemGLES
35 virtual ~CWinSystemX11GLES();
37 virtual bool InitWindowSystem();
38 virtual bool DestroyWindowSystem();
39 virtual bool CreateNewWindow(const CStdString& name, bool fullScreen, RESOLUTION_INFO& res, PHANDLE_EVENT_FUNC userFunction);
40 virtual bool DestroyWindow();
41 virtual bool ResizeWindow(int newWidth, int newHeight, int newLeft, int newTop);
42 virtual bool SetFullScreen(bool fullScreen, RESOLUTION_INFO& res, bool blankOtherDisplays);
43 virtual void UpdateResolutions();
45 virtual void ShowOSMouse(bool show);
47 virtual void NotifyAppActiveChange(bool bActivated);
49 virtual bool Minimize();
50 virtual bool Restore() ;
52 virtual bool Show(bool raise = true);
54 virtual bool IsExtSupported(const char* extension);
56 virtual bool makeOMXCurrent();
58 EGLContext GetEGLContext() const;
59 EGLDisplay GetEGLDisplay() const;
61 bool RefreshEGLContext();
63 SDL_Surface* m_SDLSurface;
64 EGLDisplay m_eglDisplay;
65 EGLContext m_eglContext;
66 EGLContext m_eglOMXContext;
67 EGLSurface m_eglSurface;
72 bool m_bWasFullScreenBeforeMinimize;
74 virtual bool PresentRenderImpl(const CDirtyRegionList &dirty);
75 virtual void SetVSyncImpl(bool enable);
82 XBMC_GLOBAL_REF(CWinSystemX11GLES,g_Windowing);
83 #define g_Windowing XBMC_GLOBAL_USE(CWinSystemX11GLES)
85 #endif // WINDOW_SYSTEM_H