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

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

Issue 1681613002: Remove MediaCodecBridge::GetOutputBuffersCount() and GetOutputBuffersCapacity() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressing comments Created 4 years, 10 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 MEDIA_BASE_ANDROID_MEDIA_CODEC_BRIDGE_H_ 5 #ifndef MEDIA_BASE_ANDROID_MEDIA_CODEC_BRIDGE_H_
6 #define MEDIA_BASE_ANDROID_MEDIA_CODEC_BRIDGE_H_ 6 #define MEDIA_BASE_ANDROID_MEDIA_CODEC_BRIDGE_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 size_t* offset, 136 size_t* offset,
137 size_t* size, 137 size_t* size,
138 base::TimeDelta* presentation_time, 138 base::TimeDelta* presentation_time,
139 bool* end_of_stream, 139 bool* end_of_stream,
140 bool* key_frame) = 0; 140 bool* key_frame) = 0;
141 141
142 // Returns the buffer to the codec. If you previously specified a surface when 142 // Returns the buffer to the codec. If you previously specified a surface when
143 // configuring this video decoder you can optionally render the buffer. 143 // configuring this video decoder you can optionally render the buffer.
144 virtual void ReleaseOutputBuffer(int index, bool render) = 0; 144 virtual void ReleaseOutputBuffer(int index, bool render) = 0;
145 145
146 // Returns the number of output buffers used by the codec.
147 // TODO(qinmin): this call is deprecated in Lollipop.
148 virtual int GetOutputBuffersCount();
149
150 // Returns the capacity of each output buffer used by the codec.
151 // TODO(qinmin): this call is deprecated in Lollipop.
152 virtual size_t GetOutputBuffersCapacity();
153
154 // Returns an input buffer's base pointer and capacity. 146 // Returns an input buffer's base pointer and capacity.
155 virtual void GetInputBuffer(int input_buffer_index, 147 virtual void GetInputBuffer(int input_buffer_index,
156 uint8_t** data, 148 uint8_t** data,
157 size_t* capacity) = 0; 149 size_t* capacity) = 0;
158 150
159 // Copy |dst_size| bytes from output buffer |index|'s |offset| onwards into 151 // Copy |dst_size| bytes from output buffer |index|'s |offset| onwards into
160 // |*dst|. 152 // |*dst|.
161 virtual bool CopyFromOutputBuffer(int index, 153 virtual bool CopyFromOutputBuffer(int index,
162 size_t offset, 154 size_t offset,
163 void* dst, 155 void* dst,
164 int dst_size) = 0; 156 int dst_size) = 0;
165 157
166 protected: 158 protected:
167 MediaCodecBridge(); 159 MediaCodecBridge();
168 160
169 // Fills a particular input buffer; returns false if |data_size| exceeds the 161 // Fills a particular input buffer; returns false if |data_size| exceeds the
170 // input buffer's capacity (and doesn't touch the input buffer in that case). 162 // input buffer's capacity (and doesn't touch the input buffer in that case).
171 bool FillInputBuffer(int index, 163 bool FillInputBuffer(int index,
172 const uint8_t* data, 164 const uint8_t* data,
173 size_t data_size) WARN_UNUSED_RESULT; 165 size_t data_size) WARN_UNUSED_RESULT;
174 166
175 DISALLOW_COPY_AND_ASSIGN(MediaCodecBridge); 167 DISALLOW_COPY_AND_ASSIGN(MediaCodecBridge);
176 }; 168 };
177 169
178 } // namespace media 170 } // namespace media
179 171
180 #endif // MEDIA_BASE_ANDROID_MEDIA_CODEC_BRIDGE_H_ 172 #endif // MEDIA_BASE_ANDROID_MEDIA_CODEC_BRIDGE_H_
OLDNEW
« no previous file with comments | « media/base/android/java/src/org/chromium/media/MediaCodecBridge.java ('k') | media/base/android/media_codec_bridge.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698