| 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 #ifndef CC_RESOURCES_VIDEO_RESOURCE_UPDATER_H_ | 5 #ifndef CC_RESOURCES_VIDEO_RESOURCE_UPDATER_H_ |
| 6 #define CC_RESOURCES_VIDEO_RESOURCE_UPDATER_H_ | 6 #define CC_RESOURCES_VIDEO_RESOURCE_UPDATER_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 124 BlockingTaskRunner* main_thread_task_runner); | 124 BlockingTaskRunner* main_thread_task_runner); |
| 125 static void ReturnTexture(base::WeakPtr<VideoResourceUpdater> updater, | 125 static void ReturnTexture(base::WeakPtr<VideoResourceUpdater> updater, |
| 126 const scoped_refptr<media::VideoFrame>& video_frame, | 126 const scoped_refptr<media::VideoFrame>& video_frame, |
| 127 uint32 sync_point, | 127 uint32 sync_point, |
| 128 bool lost_resource, | 128 bool lost_resource, |
| 129 BlockingTaskRunner* main_thread_task_runner); | 129 BlockingTaskRunner* main_thread_task_runner); |
| 130 | 130 |
| 131 ContextProvider* context_provider_; | 131 ContextProvider* context_provider_; |
| 132 ResourceProvider* resource_provider_; | 132 ResourceProvider* resource_provider_; |
| 133 scoped_ptr<media::SkCanvasVideoRenderer> video_renderer_; | 133 scoped_ptr<media::SkCanvasVideoRenderer> video_renderer_; |
| 134 std::vector<uint8_t> upload_pixels_; | |
| 135 | 134 |
| 136 // Recycle resources so that we can reduce the number of allocations and | 135 // Recycle resources so that we can reduce the number of allocations and |
| 137 // data transfers. | 136 // data transfers. |
| 138 ResourceList all_resources_; | 137 ResourceList all_resources_; |
| 139 | 138 |
| 140 DISALLOW_COPY_AND_ASSIGN(VideoResourceUpdater); | 139 DISALLOW_COPY_AND_ASSIGN(VideoResourceUpdater); |
| 141 }; | 140 }; |
| 142 | 141 |
| 143 } // namespace cc | 142 } // namespace cc |
| 144 | 143 |
| 145 #endif // CC_RESOURCES_VIDEO_RESOURCE_UPDATER_H_ | 144 #endif // CC_RESOURCES_VIDEO_RESOURCE_UPDATER_H_ |
| OLD | NEW |