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 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" | 5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" |
6 | 6 |
7 #include <stdio.h> | 7 #include <stdio.h> |
8 | 8 |
9 #include <algorithm> | 9 #include <algorithm> |
10 #include <cmath> | 10 #include <cmath> |
(...skipping 11717 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11728 pending_readpixel_fences_.front()->callbacks; | 11728 pending_readpixel_fences_.front()->callbacks; |
11729 pending_readpixel_fences_.pop(); | 11729 pending_readpixel_fences_.pop(); |
11730 for (size_t i = 0; i < callbacks.size(); i++) { | 11730 for (size_t i = 0; i < callbacks.size(); i++) { |
11731 callbacks[i].Run(); | 11731 callbacks[i].Run(); |
11732 } | 11732 } |
11733 } | 11733 } |
11734 } | 11734 } |
11735 | 11735 |
11736 bool GLES2DecoderImpl::HasMoreIdleWork() { | 11736 bool GLES2DecoderImpl::HasMoreIdleWork() { |
11737 return !pending_readpixel_fences_.empty() || | 11737 return !pending_readpixel_fences_.empty() || |
11738 async_pixel_transfer_manager_->NeedsProcessMorePendingTransfers(); | 11738 async_pixel_transfer_manager_->NeedsProcessMorePendingTransfers() || |
| 11739 gpu_tracer_->HasTracesToProcess(); |
11739 } | 11740 } |
11740 | 11741 |
11741 void GLES2DecoderImpl::PerformIdleWork() { | 11742 void GLES2DecoderImpl::PerformIdleWork() { |
| 11743 gpu_tracer_->ProcessTraces(); |
11742 ProcessPendingReadPixels(false); | 11744 ProcessPendingReadPixels(false); |
11743 if (!async_pixel_transfer_manager_->NeedsProcessMorePendingTransfers()) | 11745 if (!async_pixel_transfer_manager_->NeedsProcessMorePendingTransfers()) |
11744 return; | 11746 return; |
11745 async_pixel_transfer_manager_->ProcessMorePendingTransfers(); | 11747 async_pixel_transfer_manager_->ProcessMorePendingTransfers(); |
11746 ProcessFinishedAsyncTransfers(); | 11748 ProcessFinishedAsyncTransfers(); |
11747 } | 11749 } |
11748 | 11750 |
11749 error::Error GLES2DecoderImpl::HandleBeginQueryEXT(uint32 immediate_data_size, | 11751 error::Error GLES2DecoderImpl::HandleBeginQueryEXT(uint32 immediate_data_size, |
11750 const void* cmd_data) { | 11752 const void* cmd_data) { |
11751 const gles2::cmds::BeginQueryEXT& c = | 11753 const gles2::cmds::BeginQueryEXT& c = |
(...skipping 3031 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
14783 return error::kNoError; | 14785 return error::kNoError; |
14784 } | 14786 } |
14785 | 14787 |
14786 // Include the auto-generated part of this file. We split this because it means | 14788 // Include the auto-generated part of this file. We split this because it means |
14787 // we can easily edit the non-auto generated parts right here in this file | 14789 // we can easily edit the non-auto generated parts right here in this file |
14788 // instead of having to edit some template or the code generator. | 14790 // instead of having to edit some template or the code generator. |
14789 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" | 14791 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" |
14790 | 14792 |
14791 } // namespace gles2 | 14793 } // namespace gles2 |
14792 } // namespace gpu | 14794 } // namespace gpu |
OLD | NEW |