Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(979)

Side by Side Diff: gpu/command_buffer/service/async_pixel_transfer_manager_stub.cc

Issue 1186393004: gpu: Remove async texture uploads. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "gpu/command_buffer/service/async_pixel_transfer_manager_stub.h"
6
7 #include "gpu/command_buffer/service/async_pixel_transfer_delegate.h"
8
9 namespace gpu {
10
11 class AsyncPixelTransferDelegateStub : public AsyncPixelTransferDelegate {
12 public:
13 AsyncPixelTransferDelegateStub();
14 ~AsyncPixelTransferDelegateStub() override;
15
16 // Implement AsyncPixelTransferDelegate:
17 void AsyncTexImage2D(const AsyncTexImage2DParams& tex_params,
18 const AsyncMemoryParams& mem_params,
19 const base::Closure& bind_callback) override;
20 void AsyncTexSubImage2D(const AsyncTexSubImage2DParams& tex_params,
21 const AsyncMemoryParams& mem_params) override;
22 bool TransferIsInProgress() override;
23 void WaitForTransferCompletion() override;
24
25 private:
26 DISALLOW_COPY_AND_ASSIGN(AsyncPixelTransferDelegateStub);
27 };
28
29 AsyncPixelTransferDelegateStub::AsyncPixelTransferDelegateStub() {}
30
31 AsyncPixelTransferDelegateStub::~AsyncPixelTransferDelegateStub() {}
32
33 void AsyncPixelTransferDelegateStub::AsyncTexImage2D(
34 const AsyncTexImage2DParams& tex_params,
35 const AsyncMemoryParams& mem_params,
36 const base::Closure& bind_callback) {
37 bind_callback.Run();
38 }
39
40 void AsyncPixelTransferDelegateStub::AsyncTexSubImage2D(
41 const AsyncTexSubImage2DParams& tex_params,
42 const AsyncMemoryParams& mem_params) {
43 }
44
45 bool AsyncPixelTransferDelegateStub::TransferIsInProgress() {
46 return false;
47 }
48
49 void AsyncPixelTransferDelegateStub::WaitForTransferCompletion() {}
50
51 AsyncPixelTransferManagerStub::AsyncPixelTransferManagerStub() {}
52
53 AsyncPixelTransferManagerStub::~AsyncPixelTransferManagerStub() {}
54
55 void AsyncPixelTransferManagerStub::BindCompletedAsyncTransfers() {
56 }
57
58 void AsyncPixelTransferManagerStub::AsyncNotifyCompletion(
59 const AsyncMemoryParams& mem_params,
60 AsyncPixelTransferCompletionObserver* observer) {
61 observer->DidComplete(mem_params);
62 }
63
64 uint32 AsyncPixelTransferManagerStub::GetTextureUploadCount() {
65 return 0;
66 }
67
68 base::TimeDelta AsyncPixelTransferManagerStub::GetTotalTextureUploadTime() {
69 return base::TimeDelta();
70 }
71
72 void AsyncPixelTransferManagerStub::ProcessMorePendingTransfers() {
73 }
74
75 bool AsyncPixelTransferManagerStub::NeedsProcessMorePendingTransfers() {
76 return false;
77 }
78
79 void AsyncPixelTransferManagerStub::WaitAllAsyncTexImage2D() {
80 }
81
82 AsyncPixelTransferDelegate*
83 AsyncPixelTransferManagerStub::CreatePixelTransferDelegateImpl(
84 gles2::TextureRef* ref,
85 const AsyncTexImage2DParams& define_params) {
86 return new AsyncPixelTransferDelegateStub();
87 }
88
89 } // namespace gpu
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698