OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/async_pixel_transfer_manager_idle.h" | 5 #include "gpu/command_buffer/service/async_pixel_transfer_manager_idle.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/debug/trace_event.h" | 8 #include "base/debug/trace_event.h" |
9 #include "base/debug/trace_event_synthetic_delay.h" | 9 #include "base/debug/trace_event_synthetic_delay.h" |
10 #include "base/lazy_instance.h" | 10 #include "base/lazy_instance.h" |
(...skipping 24 matching lines...) Expand all Loading... |
35 AsyncPixelTransferDelegateIdle( | 35 AsyncPixelTransferDelegateIdle( |
36 AsyncPixelTransferManagerIdle::SharedState* state, | 36 AsyncPixelTransferManagerIdle::SharedState* state, |
37 GLuint texture_id, | 37 GLuint texture_id, |
38 const AsyncTexImage2DParams& define_params); | 38 const AsyncTexImage2DParams& define_params); |
39 virtual ~AsyncPixelTransferDelegateIdle(); | 39 virtual ~AsyncPixelTransferDelegateIdle(); |
40 | 40 |
41 // Implement AsyncPixelTransferDelegate: | 41 // Implement AsyncPixelTransferDelegate: |
42 virtual void AsyncTexImage2D( | 42 virtual void AsyncTexImage2D( |
43 const AsyncTexImage2DParams& tex_params, | 43 const AsyncTexImage2DParams& tex_params, |
44 const AsyncMemoryParams& mem_params, | 44 const AsyncMemoryParams& mem_params, |
45 const base::Closure& bind_callback) OVERRIDE; | 45 const base::Closure& bind_callback) override; |
46 virtual void AsyncTexSubImage2D( | 46 virtual void AsyncTexSubImage2D( |
47 const AsyncTexSubImage2DParams& tex_params, | 47 const AsyncTexSubImage2DParams& tex_params, |
48 const AsyncMemoryParams& mem_params) OVERRIDE; | 48 const AsyncMemoryParams& mem_params) override; |
49 virtual bool TransferIsInProgress() OVERRIDE; | 49 virtual bool TransferIsInProgress() override; |
50 virtual void WaitForTransferCompletion() OVERRIDE; | 50 virtual void WaitForTransferCompletion() override; |
51 | 51 |
52 private: | 52 private: |
53 void PerformAsyncTexImage2D(AsyncTexImage2DParams tex_params, | 53 void PerformAsyncTexImage2D(AsyncTexImage2DParams tex_params, |
54 AsyncMemoryParams mem_params, | 54 AsyncMemoryParams mem_params, |
55 const base::Closure& bind_callback); | 55 const base::Closure& bind_callback); |
56 void PerformAsyncTexSubImage2D(AsyncTexSubImage2DParams tex_params, | 56 void PerformAsyncTexSubImage2D(AsyncTexSubImage2DParams tex_params, |
57 AsyncMemoryParams mem_params); | 57 AsyncMemoryParams mem_params); |
58 | 58 |
59 uint64 id_; | 59 uint64 id_; |
60 GLuint texture_id_; | 60 GLuint texture_id_; |
(...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
315 AsyncPixelTransferDelegate* | 315 AsyncPixelTransferDelegate* |
316 AsyncPixelTransferManagerIdle::CreatePixelTransferDelegateImpl( | 316 AsyncPixelTransferManagerIdle::CreatePixelTransferDelegateImpl( |
317 gles2::TextureRef* ref, | 317 gles2::TextureRef* ref, |
318 const AsyncTexImage2DParams& define_params) { | 318 const AsyncTexImage2DParams& define_params) { |
319 return new AsyncPixelTransferDelegateIdle(&shared_state_, | 319 return new AsyncPixelTransferDelegateIdle(&shared_state_, |
320 ref->service_id(), | 320 ref->service_id(), |
321 define_params); | 321 define_params); |
322 } | 322 } |
323 | 323 |
324 } // namespace gpu | 324 } // namespace gpu |
OLD | NEW |