| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2011 Google Inc. | 3 * Copyright 2011 Google Inc. |
| 4 * | 4 * |
| 5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
| 6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
| 7 */ | 7 */ |
| 8 | 8 |
| 9 #include "SkRefCnt.h" | 9 #include "SkRefCnt.h" |
| 10 | 10 |
| 11 #ifndef SkWGL_DEFINED | 11 #ifndef SkWGL_DEFINED |
| 12 #define SkWGL_DEFINED | 12 #define SkWGL_DEFINED |
| 13 | 13 |
| 14 /** | 14 /** |
| 15 * Working with WGL extensions can be a pain. Among the reasons is that You must | 15 * Working with WGL extensions can be a pain. Among the reasons is that You must |
| 16 * have a GL context to get the proc addresses, but you want to use the procs to | 16 * have a GL context to get the proc addresses, but you want to use the procs to |
| 17 * create a context in the first place. So you have to create a dummy GL ctx to | 17 * create a context in the first place. So you have to create a dummy GL ctx to |
| 18 * get the proc addresses. | 18 * get the proc addresses. |
| 19 * | 19 * |
| 20 * This file helps by providing SkCreateWGLInterface(). It returns a struct of | 20 * This file helps by providing SkCreateWGLInterface(). It returns a struct of |
| 21 * function pointers that it initializes. It also has a helper function to query | 21 * function pointers that it initializes. It also has a helper function to query |
| 22 * for WGL extensions. It handles the fact that wglGetExtensionsString is itself | 22 * for WGL extensions. It handles the fact that wglGetExtensionsString is itself |
| 23 * an extension. | 23 * an extension. |
| 24 */ | 24 */ |
| 25 | 25 |
| 26 #if !defined(WIN32_LEAN_AND_MEAN) | 26 #if !defined(WIN32_LEAN_AND_MEAN) |
| 27 #define WIN32_LEAN_AND_MEAN | 27 #define WIN32_LEAN_AND_MEAN |
| 28 #define SK_LOCAL_LEAN_AND_MEAN | 28 #define SK_LOCAL_LEAN_AND_MEAN |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 159 private: | 159 private: |
| 160 SkWGLPbufferContext(HPBUFFER pbuffer, HDC dc, HGLRC glrc); | 160 SkWGLPbufferContext(HPBUFFER pbuffer, HDC dc, HGLRC glrc); |
| 161 | 161 |
| 162 HPBUFFER fPbuffer; | 162 HPBUFFER fPbuffer; |
| 163 HDC fDC; | 163 HDC fDC; |
| 164 HGLRC fGLRC; | 164 HGLRC fGLRC; |
| 165 SkWGLExtensions fExtensions; | 165 SkWGLExtensions fExtensions; |
| 166 }; | 166 }; |
| 167 | 167 |
| 168 #endif | 168 #endif |
| OLD | NEW |