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

Side by Side Diff: content/common/gpu/media/android_video_decode_accelerator.h

Issue 1828033002: media: Lazily reconfigure MediaCodecs in AVDA for JellyBean (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 (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 <stdint.h> 8 #include <stdint.h>
9 9
10 #include <list> 10 #include <list>
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
143 143
144 private: 144 private:
145 friend class AVDATimerManager; 145 friend class AVDATimerManager;
146 146
147 // TODO(timav): evaluate the need for more states in the AVDA state machine. 147 // TODO(timav): evaluate the need for more states in the AVDA state machine.
148 enum State { 148 enum State {
149 NO_ERROR, 149 NO_ERROR,
150 ERROR, 150 ERROR,
151 WAITING_FOR_KEY, 151 WAITING_FOR_KEY,
152 WAITING_FOR_EOS, 152 WAITING_FOR_EOS,
153 PENDING_CODEC_RECONFIGURE,
153 }; 154 };
154 155
155 // Configures |media_codec_| with the given codec parameters from the client. 156 // Configures |media_codec_| with the given codec parameters from the client.
156 bool ConfigureMediaCodec(); 157 bool ConfigureMediaCodec();
157 158
158 // Sends the decoded frame specified by |codec_buffer_index| to the client. 159 // Sends the decoded frame specified by |codec_buffer_index| to the client.
159 void SendDecodedFrameToClient(int32_t codec_buffer_index, 160 void SendDecodedFrameToClient(int32_t codec_buffer_index,
160 int32_t bitstream_id); 161 int32_t bitstream_id);
161 162
162 // Does pending IO tasks if any. Once this is called, it polls |media_codec_| 163 // Does pending IO tasks if any. Once this is called, it polls |media_codec_|
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
334 335
335 // WeakPtrFactory for posting tasks back to |this|. 336 // WeakPtrFactory for posting tasks back to |this|.
336 base::WeakPtrFactory<AndroidVideoDecodeAccelerator> weak_this_factory_; 337 base::WeakPtrFactory<AndroidVideoDecodeAccelerator> weak_this_factory_;
337 338
338 friend class AndroidVideoDecodeAcceleratorTest; 339 friend class AndroidVideoDecodeAcceleratorTest;
339 }; 340 };
340 341
341 } // namespace content 342 } // namespace content
342 343
343 #endif // CONTENT_COMMON_GPU_MEDIA_ANDROID_VIDEO_DECODE_ACCELERATOR_H_ 344 #endif // CONTENT_COMMON_GPU_MEDIA_ANDROID_VIDEO_DECODE_ACCELERATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698