OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef GPU_COMMAND_BUFFER_COMMON_COMMAND_BUFFER_H_ | 5 #ifndef GPU_COMMAND_BUFFER_COMMON_COMMAND_BUFFER_H_ |
6 #define GPU_COMMAND_BUFFER_COMMON_COMMAND_BUFFER_H_ | 6 #define GPU_COMMAND_BUFFER_COMMON_COMMAND_BUFFER_H_ |
7 | 7 |
8 #include "../../gpu_export.h" | 8 #include "../../gpu_export.h" |
9 #include "../common/buffer.h" | 9 #include "../common/buffer.h" |
10 #include "../common/constants.h" | 10 #include "../common/constants.h" |
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
134 // GetLastError declared would mean we'd have to also define it, and pull more | 134 // GetLastError declared would mean we'd have to also define it, and pull more |
135 // of gpu in to the NaCl Win64 build. | 135 // of gpu in to the NaCl Win64 build. |
136 #if !defined(NACL_WIN64) | 136 #if !defined(NACL_WIN64) |
137 // TODO(apatrick): this is a temporary optimization while skia is calling | 137 // TODO(apatrick): this is a temporary optimization while skia is calling |
138 // RendererGLContext::MakeCurrent prior to every GL call. It saves returning 6 | 138 // RendererGLContext::MakeCurrent prior to every GL call. It saves returning 6 |
139 // ints redundantly when only the error is needed for the CommandBufferProxy | 139 // ints redundantly when only the error is needed for the CommandBufferProxy |
140 // implementation. | 140 // implementation. |
141 virtual error::Error GetLastError(); | 141 virtual error::Error GetLastError(); |
142 #endif | 142 #endif |
143 | 143 |
| 144 // Inserts a sync point, returning its ID. Sync point IDs are global and can |
| 145 // be used for cross-context synchronization. |
| 146 virtual uint32 InsertSyncPoint() = 0; |
| 147 |
144 private: | 148 private: |
145 DISALLOW_COPY_AND_ASSIGN(CommandBuffer); | 149 DISALLOW_COPY_AND_ASSIGN(CommandBuffer); |
146 }; | 150 }; |
147 | 151 |
148 } // namespace gpu | 152 } // namespace gpu |
149 | 153 |
150 #endif // GPU_COMMAND_BUFFER_COMMON_COMMAND_BUFFER_H_ | 154 #endif // GPU_COMMAND_BUFFER_COMMON_COMMAND_BUFFER_H_ |
OLD | NEW |