OLD | NEW |
1 // Copyright (c) 2016 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2016 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 // This file contains the GLES2DecoderPassthroughImpl class. | 5 // This file contains the GLES2DecoderPassthroughImpl class. |
6 | 6 |
7 #ifndef GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_PASSTHROUGH_H_ | 7 #ifndef GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_PASSTHROUGH_H_ |
8 #define GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_PASSTHROUGH_H_ | 8 #define GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_PASSTHROUGH_H_ |
9 | 9 |
10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
11 #include "gpu/command_buffer/common/debug_marker_manager.h" | 11 #include "gpu/command_buffer/common/debug_marker_manager.h" |
12 #include "gpu/command_buffer/common/gles2_cmd_format.h" | 12 #include "gpu/command_buffer/common/gles2_cmd_format.h" |
13 #include "gpu/command_buffer/common/gles2_cmd_utils.h" | 13 #include "gpu/command_buffer/common/gles2_cmd_utils.h" |
14 #include "gpu/command_buffer/common/mailbox.h" | 14 #include "gpu/command_buffer/common/mailbox.h" |
| 15 #include "gpu/command_buffer/common/sync_token.h" |
15 #include "gpu/command_buffer/service/client_service_map.h" | 16 #include "gpu/command_buffer/service/client_service_map.h" |
16 #include "gpu/command_buffer/service/context_group.h" | 17 #include "gpu/command_buffer/service/context_group.h" |
17 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" | 18 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" |
18 #include "gpu/command_buffer/service/image_manager.h" | 19 #include "gpu/command_buffer/service/image_manager.h" |
19 #include "gpu/command_buffer/service/logger.h" | 20 #include "gpu/command_buffer/service/logger.h" |
20 #include "gpu/command_buffer/service/mailbox_manager.h" | 21 #include "gpu/command_buffer/service/mailbox_manager.h" |
21 #include "gpu/command_buffer/service/texture_manager.h" | 22 #include "gpu/command_buffer/service/texture_manager.h" |
22 #include "ui/gl/gl_bindings.h" | 23 #include "ui/gl/gl_bindings.h" |
23 #include "ui/gl/gl_context.h" | 24 #include "ui/gl/gl_context.h" |
24 #include "ui/gl/gl_image.h" | 25 #include "ui/gl/gl_image.h" |
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
127 | 128 |
128 void SetIgnoreCachedStateForTest(bool ignore) override; | 129 void SetIgnoreCachedStateForTest(bool ignore) override; |
129 void SetForceShaderNameHashingForTest(bool force) override; | 130 void SetForceShaderNameHashingForTest(bool force) override; |
130 size_t GetSavedBackTextureCountForTest() override; | 131 size_t GetSavedBackTextureCountForTest() override; |
131 size_t GetCreatedBackTextureCountForTest() override; | 132 size_t GetCreatedBackTextureCountForTest() override; |
132 | 133 |
133 // Sets the callback for fence sync release and wait calls. The wait call | 134 // Sets the callback for fence sync release and wait calls. The wait call |
134 // returns true if the channel is still scheduled. | 135 // returns true if the channel is still scheduled. |
135 void SetFenceSyncReleaseCallback( | 136 void SetFenceSyncReleaseCallback( |
136 const FenceSyncReleaseCallback& callback) override; | 137 const FenceSyncReleaseCallback& callback) override; |
137 void SetWaitFenceSyncCallback(const WaitFenceSyncCallback& callback) override; | 138 void SetWaitSyncTokenCallback(const WaitSyncTokenCallback& callback) override; |
138 void SetDescheduleUntilFinishedCallback( | 139 void SetDescheduleUntilFinishedCallback( |
139 const NoParamCallback& callback) override; | 140 const NoParamCallback& callback) override; |
140 void SetRescheduleAfterFinishedCallback( | 141 void SetRescheduleAfterFinishedCallback( |
141 const NoParamCallback& callback) override; | 142 const NoParamCallback& callback) override; |
142 | 143 |
143 // Gets the QueryManager for this context. | 144 // Gets the QueryManager for this context. |
144 QueryManager* GetQueryManager() override; | 145 QueryManager* GetQueryManager() override; |
145 | 146 |
146 // Gets the TransformFeedbackManager for this context. | 147 // Gets the TransformFeedbackManager for this context. |
147 TransformFeedbackManager* GetTransformFeedbackManager() override; | 148 TransformFeedbackManager* GetTransformFeedbackManager() override; |
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
320 | 321 |
321 // Managers | 322 // Managers |
322 std::unique_ptr<ImageManager> image_manager_; | 323 std::unique_ptr<ImageManager> image_manager_; |
323 | 324 |
324 // The ContextGroup for this decoder uses to track resources. | 325 // The ContextGroup for this decoder uses to track resources. |
325 scoped_refptr<ContextGroup> group_; | 326 scoped_refptr<ContextGroup> group_; |
326 scoped_refptr<FeatureInfo> feature_info_; | 327 scoped_refptr<FeatureInfo> feature_info_; |
327 | 328 |
328 // Callbacks | 329 // Callbacks |
329 FenceSyncReleaseCallback fence_sync_release_callback_; | 330 FenceSyncReleaseCallback fence_sync_release_callback_; |
330 WaitFenceSyncCallback wait_fence_sync_callback_; | 331 WaitSyncTokenCallback wait_sync_token_callback_; |
331 | 332 |
332 // Some objects may generate resources when they are bound even if they were | 333 // Some objects may generate resources when they are bound even if they were |
333 // not generated yet: texture, buffer, renderbuffer, framebuffer, transform | 334 // not generated yet: texture, buffer, renderbuffer, framebuffer, transform |
334 // feedback, vertex array | 335 // feedback, vertex array |
335 bool bind_generates_resource_; | 336 bool bind_generates_resource_; |
336 | 337 |
337 // Mappings from client side IDs to service side IDs for shared objects | 338 // Mappings from client side IDs to service side IDs for shared objects |
338 PassthroughResources* resources_; | 339 PassthroughResources* resources_; |
339 | 340 |
340 // Mappings from client side IDs to service side IDs for per-context objects | 341 // Mappings from client side IDs to service side IDs for per-context objects |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
382 | 383 |
383 // Include the prototypes of all the doer functions from a separate header to | 384 // Include the prototypes of all the doer functions from a separate header to |
384 // keep this file clean. | 385 // keep this file clean. |
385 #include "gpu/command_buffer/service/gles2_cmd_decoder_passthrough_doer_prototyp
es.h" | 386 #include "gpu/command_buffer/service/gles2_cmd_decoder_passthrough_doer_prototyp
es.h" |
386 }; | 387 }; |
387 | 388 |
388 } // namespace gles2 | 389 } // namespace gles2 |
389 } // namespace gpu | 390 } // namespace gpu |
390 | 391 |
391 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_PASSTHROUGH_H_ | 392 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_PASSTHROUGH_H_ |
OLD | NEW |