OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 CONTENT_COMMON_GPU_MEDIA_ANDROID_VIDEO_DECODE_ACCELERATOR_H_ | 5 #ifndef CONTENT_COMMON_GPU_MEDIA_ANDROID_VIDEO_DECODE_ACCELERATOR_H_ |
6 #define CONTENT_COMMON_GPU_MEDIA_ANDROID_VIDEO_DECODE_ACCELERATOR_H_ | 6 #define CONTENT_COMMON_GPU_MEDIA_ANDROID_VIDEO_DECODE_ACCELERATOR_H_ |
7 | 7 |
8 #include <list> | 8 #include <list> |
9 #include <map> | 9 #include <map> |
10 #include <queue> | 10 #include <queue> |
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
154 | 154 |
155 // Notifies the client that the decoder was flushed. | 155 // Notifies the client that the decoder was flushed. |
156 void NotifyFlushDone(); | 156 void NotifyFlushDone(); |
157 | 157 |
158 // Notifies the client that the decoder was reset. | 158 // Notifies the client that the decoder was reset. |
159 void NotifyResetDone(); | 159 void NotifyResetDone(); |
160 | 160 |
161 // Notifies about decoding errors. | 161 // Notifies about decoding errors. |
162 void NotifyError(media::VideoDecodeAccelerator::Error error); | 162 void NotifyError(media::VideoDecodeAccelerator::Error error); |
163 | 163 |
| 164 // Return true if and only if we should use deferred rendering. |
| 165 static bool UseDeferredRenderingStrategy(); |
| 166 |
164 // Used to DCHECK that we are called on the correct thread. | 167 // Used to DCHECK that we are called on the correct thread. |
165 base::ThreadChecker thread_checker_; | 168 base::ThreadChecker thread_checker_; |
166 | 169 |
167 // To expose client callbacks from VideoDecodeAccelerator. | 170 // To expose client callbacks from VideoDecodeAccelerator. |
168 Client* client_; | 171 Client* client_; |
169 | 172 |
170 // Callback to set the correct gl context. | 173 // Callback to set the correct gl context. |
171 base::Callback<bool(void)> make_context_current_; | 174 base::Callback<bool(void)> make_context_current_; |
172 | 175 |
173 // Codec type. Used when we configure media codec. | 176 // Codec type. Used when we configure media codec. |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
233 | 236 |
234 // WeakPtrFactory for posting tasks back to |this|. | 237 // WeakPtrFactory for posting tasks back to |this|. |
235 base::WeakPtrFactory<AndroidVideoDecodeAccelerator> weak_this_factory_; | 238 base::WeakPtrFactory<AndroidVideoDecodeAccelerator> weak_this_factory_; |
236 | 239 |
237 friend class AndroidVideoDecodeAcceleratorTest; | 240 friend class AndroidVideoDecodeAcceleratorTest; |
238 }; | 241 }; |
239 | 242 |
240 } // namespace content | 243 } // namespace content |
241 | 244 |
242 #endif // CONTENT_COMMON_GPU_MEDIA_ANDROID_VIDEO_DECODE_ACCELERATOR_H_ | 245 #endif // CONTENT_COMMON_GPU_MEDIA_ANDROID_VIDEO_DECODE_ACCELERATOR_H_ |
OLD | NEW |