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

Side by Side Diff: gpu/command_buffer/service/async_pixel_transfer_manager.h

Issue 116863003: gpu: Reuse transfer buffers more aggresively (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Unset texture and texture_ref after deleting Created 6 years, 9 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
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 #ifndef GPU_COMMAND_BUFFER_SERVICE_ASYNC_PIXEL_TRANSFER_MANAGER_H_ 5 #ifndef GPU_COMMAND_BUFFER_SERVICE_ASYNC_PIXEL_TRANSFER_MANAGER_H_
6 #define GPU_COMMAND_BUFFER_SERVICE_ASYNC_PIXEL_TRANSFER_MANAGER_H_ 6 #define GPU_COMMAND_BUFFER_SERVICE_ASYNC_PIXEL_TRANSFER_MANAGER_H_
7 7
8 #include <set> 8 #include <set>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 virtual base::TimeDelta GetTotalTextureUploadTime() = 0; 71 virtual base::TimeDelta GetTotalTextureUploadTime() = 0;
72 72
73 // ProcessMorePendingTransfers() will be called at a good time 73 // ProcessMorePendingTransfers() will be called at a good time
74 // to process a small amount of pending transfer work while 74 // to process a small amount of pending transfer work while
75 // NeedsProcessMorePendingTransfers() returns true. Implementations 75 // NeedsProcessMorePendingTransfers() returns true. Implementations
76 // that can't dispatch work to separate threads should use 76 // that can't dispatch work to separate threads should use
77 // this to avoid blocking the caller thread inappropriately. 77 // this to avoid blocking the caller thread inappropriately.
78 virtual void ProcessMorePendingTransfers() = 0; 78 virtual void ProcessMorePendingTransfers() = 0;
79 virtual bool NeedsProcessMorePendingTransfers() = 0; 79 virtual bool NeedsProcessMorePendingTransfers() = 0;
80 80
81 // Wait for all AsyncTex(Sub)Image2D uploads to finish before returning.
82 virtual void WaitAllAsyncTexImage2D() = 0;
83
81 AsyncPixelTransferDelegate* CreatePixelTransferDelegate( 84 AsyncPixelTransferDelegate* CreatePixelTransferDelegate(
82 gles2::TextureRef* ref, 85 gles2::TextureRef* ref,
83 const AsyncTexImage2DParams& define_params); 86 const AsyncTexImage2DParams& define_params);
84 87
85 AsyncPixelTransferDelegate* GetPixelTransferDelegate( 88 AsyncPixelTransferDelegate* GetPixelTransferDelegate(
86 gles2::TextureRef* ref); 89 gles2::TextureRef* ref);
87 90
88 void ClearPixelTransferDelegateForTest(gles2::TextureRef* ref); 91 void ClearPixelTransferDelegateForTest(gles2::TextureRef* ref);
89 92
90 bool AsyncTransferIsInProgress(gles2::TextureRef* ref); 93 bool AsyncTransferIsInProgress(gles2::TextureRef* ref);
(...skipping 19 matching lines...) Expand all
110 virtual AsyncPixelTransferDelegate* CreatePixelTransferDelegateImpl( 113 virtual AsyncPixelTransferDelegate* CreatePixelTransferDelegateImpl(
111 gles2::TextureRef* ref, 114 gles2::TextureRef* ref,
112 const AsyncTexImage2DParams& define_params) = 0; 115 const AsyncTexImage2DParams& define_params) = 0;
113 116
114 DISALLOW_COPY_AND_ASSIGN(AsyncPixelTransferManager); 117 DISALLOW_COPY_AND_ASSIGN(AsyncPixelTransferManager);
115 }; 118 };
116 119
117 } // namespace gpu 120 } // namespace gpu
118 121
119 #endif // GPU_COMMAND_BUFFER_SERVICE_ASYNC_PIXEL_TRANSFER_MANAGER_H_ 122 #endif // GPU_COMMAND_BUFFER_SERVICE_ASYNC_PIXEL_TRANSFER_MANAGER_H_
OLDNEW
« no previous file with comments | « gpu/command_buffer/common/gles2_cmd_ids_autogen.h ('k') | gpu/command_buffer/service/async_pixel_transfer_manager_egl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698