| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2009, Google Inc. | 2 * Copyright 2009, Google Inc. |
| 3 * All rights reserved. | 3 * All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 112 // and context here. | 112 // and context here. |
| 113 HINSTANCE module_handle; | 113 HINSTANCE module_handle; |
| 114 if (!::GetModuleHandleEx(GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT | | 114 if (!::GetModuleHandleEx(GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT | |
| 115 GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS, | 115 GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS, |
| 116 reinterpret_cast<wchar_t*>(IntermediateWindowProc), | 116 reinterpret_cast<wchar_t*>(IntermediateWindowProc), |
| 117 &module_handle)) { | 117 &module_handle)) { |
| 118 return false; | 118 return false; |
| 119 } | 119 } |
| 120 | 120 |
| 121 WNDCLASS intermediate_class; | 121 WNDCLASS intermediate_class; |
| 122 intermediate_class.style = CS_HREDRAW | CS_VREDRAW; | 122 intermediate_class.style = CS_HREDRAW | CS_VREDRAW | CS_OWNDC; |
| 123 intermediate_class.lpfnWndProc = IntermediateWindowProc; | 123 intermediate_class.lpfnWndProc = IntermediateWindowProc; |
| 124 intermediate_class.cbClsExtra = 0; | 124 intermediate_class.cbClsExtra = 0; |
| 125 intermediate_class.cbWndExtra = 0; | 125 intermediate_class.cbWndExtra = 0; |
| 126 intermediate_class.hInstance = module_handle; | 126 intermediate_class.hInstance = module_handle; |
| 127 intermediate_class.hIcon = LoadIcon(NULL, IDI_APPLICATION); | 127 intermediate_class.hIcon = LoadIcon(NULL, IDI_APPLICATION); |
| 128 intermediate_class.hCursor = LoadCursor(NULL, IDC_ARROW); | 128 intermediate_class.hCursor = LoadCursor(NULL, IDC_ARROW); |
| 129 intermediate_class.hbrBackground = NULL; | 129 intermediate_class.hbrBackground = NULL; |
| 130 intermediate_class.lpszMenuName = NULL; | 130 intermediate_class.lpszMenuName = NULL; |
| 131 intermediate_class.lpszClassName = L"Intermediate GL Window"; | 131 intermediate_class.lpszClassName = L"Intermediate GL Window"; |
| 132 | 132 |
| (...skipping 277 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 410 glClearStencil(stencil); | 410 glClearStencil(stencil); |
| 411 glClear((buffers & kColor ? GL_COLOR_BUFFER_BIT : 0) | | 411 glClear((buffers & kColor ? GL_COLOR_BUFFER_BIT : 0) | |
| 412 (buffers & kDepth ? GL_DEPTH_BUFFER_BIT : 0) | | 412 (buffers & kDepth ? GL_DEPTH_BUFFER_BIT : 0) | |
| 413 (buffers & kStencil ? GL_STENCIL_BUFFER_BIT : 0)); | 413 (buffers & kStencil ? GL_STENCIL_BUFFER_BIT : 0)); |
| 414 CHECK_GL_ERROR(); | 414 CHECK_GL_ERROR(); |
| 415 } | 415 } |
| 416 | 416 |
| 417 } // namespace o3d | 417 } // namespace o3d |
| 418 } // namespace command_buffer | 418 } // namespace command_buffer |
| 419 } // namespace o3d | 419 } // namespace o3d |
| OLD | NEW |