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

Side by Side Diff: media/base/android/sdk_media_codec_bridge.h

Issue 2365103002: Send the h264 SPS and PPS configuration parameters to AVDA (Closed)
Patch Set: Shot in the dark Created 4 years, 2 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
« no previous file with comments | « no previous file | media/base/android/sdk_media_codec_bridge.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 MEDIA_BASE_ANDROID_SDK_MEDIA_CODEC_BRIDGE_H_ 5 #ifndef MEDIA_BASE_ANDROID_SDK_MEDIA_CODEC_BRIDGE_H_
6 #define MEDIA_BASE_ANDROID_SDK_MEDIA_CODEC_BRIDGE_H_ 6 #define MEDIA_BASE_ANDROID_SDK_MEDIA_CODEC_BRIDGE_H_
7 7
8 #include <jni.h> 8 #include <jni.h>
9 #include <stddef.h> 9 #include <stddef.h>
10 #include <stdint.h> 10 #include <stdint.h>
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 // TODO(qinmin): implement the logic to switch between NDK and SDK 129 // TODO(qinmin): implement the logic to switch between NDK and SDK
130 // MediaCodecBridge. 130 // MediaCodecBridge.
131 class MEDIA_EXPORT VideoCodecBridge : public SdkMediaCodecBridge { 131 class MEDIA_EXPORT VideoCodecBridge : public SdkMediaCodecBridge {
132 public: 132 public:
133 // See MediaCodecUtil::IsKnownUnaccelerated(). 133 // See MediaCodecUtil::IsKnownUnaccelerated().
134 static bool IsKnownUnaccelerated(const VideoCodec& codec, 134 static bool IsKnownUnaccelerated(const VideoCodec& codec,
135 MediaCodecDirection direction); 135 MediaCodecDirection direction);
136 136
137 // Create, start, and return a VideoCodecBridge decoder or NULL on failure. 137 // Create, start, and return a VideoCodecBridge decoder or NULL on failure.
138 static VideoCodecBridge* CreateDecoder( 138 static VideoCodecBridge* CreateDecoder(
139 const VideoCodec& codec, // e.g. media::kCodecVP8 139 const VideoCodec& codec,
140 bool is_secure, // Will be used with encrypted content. 140 bool is_secure, // Will be used with encrypted content.
141 const gfx::Size& size, // Output frame size. 141 const gfx::Size& size, // Output frame size.
142 jobject surface, // Output surface, optional. 142 jobject surface, // Output surface, optional.
143 jobject media_crypto, // MediaCrypto object, optional. 143 jobject media_crypto, // MediaCrypto object, optional.
144 bool allow_adaptive_playback = 144 // Codec specific data. See MediaCodec docs.
145 true, // Should adaptive playback be allowed if supported. 145 const std::vector<uint8_t>& csd0,
146 bool require_software_codec = false); // Require software decoder? 146 const std::vector<uint8_t>& csd1,
147 // Should adaptive playback be allowed if supported.
148 bool allow_adaptive_playback = true,
149 bool require_software_codec = false);
147 150
148 // Create, start, and return a VideoCodecBridge encoder or NULL on failure. 151 // Create, start, and return a VideoCodecBridge encoder or NULL on failure.
149 static VideoCodecBridge* CreateEncoder( 152 static VideoCodecBridge* CreateEncoder(
150 const VideoCodec& codec, // e.g. media::kCodecVP8 153 const VideoCodec& codec, // e.g. media::kCodecVP8
151 const gfx::Size& size, // input frame size 154 const gfx::Size& size, // input frame size
152 int bit_rate, // bits/second 155 int bit_rate, // bits/second
153 int frame_rate, // frames/second 156 int frame_rate, // frames/second
154 int i_frame_interval, // count 157 int i_frame_interval, // count
155 int color_format); // MediaCodecInfo.CodecCapabilities. 158 int color_format); // MediaCodecInfo.CodecCapabilities.
156 159
(...skipping 19 matching lines...) Expand all
176 bool is_secure, 179 bool is_secure,
177 MediaCodecDirection direction, 180 MediaCodecDirection direction,
178 bool require_software_codec); 181 bool require_software_codec);
179 182
180 int adaptive_playback_supported_for_testing_; 183 int adaptive_playback_supported_for_testing_;
181 }; 184 };
182 185
183 } // namespace media 186 } // namespace media
184 187
185 #endif // MEDIA_BASE_ANDROID_SDK_MEDIA_CODEC_BRIDGE_H_ 188 #endif // MEDIA_BASE_ANDROID_SDK_MEDIA_CODEC_BRIDGE_H_
OLDNEW
« no previous file with comments | « no previous file | media/base/android/sdk_media_codec_bridge.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698