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

Side by Side Diff: samplecode/SampleApp.h

Issue 916733002: Support multiple null GL contexts on a thread. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Add back old GrGLCreateNullInterface until Chrome stops using it Created 5 years, 10 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/gpu/gl/SkNullGLContext.h ('k') | samplecode/SampleApp.cpp » ('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 2011 Skia 2 * Copyright 2011 Skia
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 SampleApp_DEFINED 8 #ifndef SampleApp_DEFINED
9 #define SampleApp_DEFINED 9 #define SampleApp_DEFINED
10 10
(...skipping 20 matching lines...) Expand all
31 SkTDArray<const SkViewFactory*> fSamples; 31 SkTDArray<const SkViewFactory*> fSamples;
32 public: 32 public:
33 enum DeviceType { 33 enum DeviceType {
34 kRaster_DeviceType, 34 kRaster_DeviceType,
35 kPicture_DeviceType, 35 kPicture_DeviceType,
36 #if SK_SUPPORT_GPU 36 #if SK_SUPPORT_GPU
37 kGPU_DeviceType, 37 kGPU_DeviceType,
38 #if SK_ANGLE 38 #if SK_ANGLE
39 kANGLE_DeviceType, 39 kANGLE_DeviceType,
40 #endif // SK_ANGLE 40 #endif // SK_ANGLE
41 kNullGPU_DeviceType,
42 #endif // SK_SUPPORT_GPU 41 #endif // SK_SUPPORT_GPU
43 42
44 kDeviceTypeCnt 43 kDeviceTypeCnt
45 }; 44 };
46 45
47 static bool IsGpuDeviceType(DeviceType devType) { 46 static bool IsGpuDeviceType(DeviceType devType) {
48 #if SK_SUPPORT_GPU 47 #if SK_SUPPORT_GPU
49 switch (devType) { 48 switch (devType) {
50 case kGPU_DeviceType: 49 case kGPU_DeviceType:
51 #if SK_ANGLE 50 #if SK_ANGLE
52 case kANGLE_DeviceType: 51 case kANGLE_DeviceType:
53 #endif // SK_ANGLE 52 #endif // SK_ANGLE
54 case kNullGPU_DeviceType:
55 return true; 53 return true;
56 default: 54 default:
57 return false; 55 return false;
58 } 56 }
59 #endif // SK_SUPPORT_GPU 57 #endif // SK_SUPPORT_GPU
60 return false; 58 return false;
61 } 59 }
62 60
63 /** 61 /**
64 * SampleApp ports can subclass this manager class if they want to: 62 * SampleApp ports can subclass this manager class if they want to:
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 void installDrawFilter(SkCanvas*); 233 void installDrawFilter(SkCanvas*);
236 int findByTitle(const char*); 234 int findByTitle(const char*);
237 void listTitles(); 235 void listTitles();
238 SkSize tileSize() const; 236 SkSize tileSize() const;
239 bool sendAnimatePulse(); 237 bool sendAnimatePulse();
240 238
241 typedef SkOSWindow INHERITED; 239 typedef SkOSWindow INHERITED;
242 }; 240 };
243 241
244 #endif 242 #endif
OLDNEW
« no previous file with comments | « include/gpu/gl/SkNullGLContext.h ('k') | samplecode/SampleApp.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698