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

Side by Side Diff: include/views/SkOSWindow_SDL.h

Issue 2061233002: Remove command buffer sample app support. (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: Created 4 years, 6 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 unified diff | Download patch
« no previous file with comments | « include/views/SkOSWindow_Mac.h ('k') | include/views/SkOSWindow_Unix.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2006 The Android Open Source Project 2 * Copyright 2006 The Android Open Source Project
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef SkOSWindow_SDL_DEFINED 8 #ifndef SkOSWindow_SDL_DEFINED
9 #define SkOSWindow_SDL_DEFINED 9 #define SkOSWindow_SDL_DEFINED
10 10
11 #include "SDL.h" 11 #include "SDL.h"
12 #include "SDL_opengl.h" 12 #include "SDL_opengl.h"
13 #include "SkWindow.h" 13 #include "SkWindow.h"
14 14
15 class SkOSWindow : public SkWindow { 15 class SkOSWindow : public SkWindow {
16 public: 16 public:
17 SkOSWindow(void*); 17 SkOSWindow(void*);
18 virtual ~SkOSWindow(); 18 virtual ~SkOSWindow();
19 19
20 enum SkBackEndTypes { 20 enum SkBackEndTypes {
21 kNone_BackEndType, // TODO: remove this, it's not a real option. 21 kNone_BackEndType, // TODO: remove this, it's not a real option.
22 kNativeGL_BackEndType, 22 kNativeGL_BackEndType,
23 #if SK_ANGLE 23 #if SK_ANGLE
24 kANGLE_BackEndType, 24 kANGLE_BackEndType,
25 #endif // SK_ANGLE 25 #endif // SK_ANGLE
26 #if SK_COMMAND_BUFFER
27 kCommandBuffer_BackEndType,
28 #endif // SK_COMMAND_BUFFER
29 }; 26 };
30 27
31 void release(); 28 void release();
32 bool attach(SkBackEndTypes attachType, int msaaSampleCount, bool deepColor, AttachmentInfo*); 29 bool attach(SkBackEndTypes attachType, int msaaSampleCount, bool deepColor, AttachmentInfo*);
33 void present(); 30 void present();
34 bool makeFullscreen(); 31 bool makeFullscreen();
35 void setVsync(bool); 32 void setVsync(bool);
36 void closeWindow(); 33 void closeWindow();
37 static void RunEventLoop(); 34 static void RunEventLoop();
38 35
39 protected: 36 protected:
40 void onSetTitle(const char title[]) override; 37 void onSetTitle(const char title[]) override;
41 38
42 private: 39 private:
43 void createWindow(int msaaSampleCount); 40 void createWindow(int msaaSampleCount);
44 void destroyWindow(); 41 void destroyWindow();
45 void updateWindowTitle(); 42 void updateWindowTitle();
46 static SkOSWindow* GetInstanceForWindowID(Uint32 windowID); 43 static SkOSWindow* GetInstanceForWindowID(Uint32 windowID);
47 static bool HasDirtyWindows(); 44 static bool HasDirtyWindows();
48 static void UpdateDirtyWindows(); 45 static void UpdateDirtyWindows();
49 static void HandleEvent(const SDL_Event&); 46 static void HandleEvent(const SDL_Event&);
50 47
51 SDL_Window* fWindow; 48 SDL_Window* fWindow;
52 SDL_GLContext fGLContext; 49 SDL_GLContext fGLContext;
53 int fWindowMSAASampleCount; 50 int fWindowMSAASampleCount;
54 typedef SkWindow INHERITED; 51 typedef SkWindow INHERITED;
55 }; 52 };
56 53
57 #endif 54 #endif
OLDNEW
« no previous file with comments | « include/views/SkOSWindow_Mac.h ('k') | include/views/SkOSWindow_Unix.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698