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

Side by Side Diff: media/mojo/interfaces/media_types.mojom

Issue 760523008: Switch from a DataPipe per DecoderBuffer to a single one. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Comments. Created 6 years 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 module mojo; 5 module mojo;
6 6
7 import "mojo/services/public/interfaces/geometry/geometry.mojom"; 7 import "mojo/services/public/interfaces/geometry/geometry.mojom";
8 8
9 // See media/base/buffering_state.h for descriptions. 9 // See media/base/buffering_state.h for descriptions.
10 // Kept in sync with media::BufferingState via COMPILE_ASSERTs. 10 // Kept in sync with media::BufferingState via COMPILE_ASSERTs.
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after
183 string iv; 183 string iv;
184 array<SubsampleEntry> subsamples; 184 array<SubsampleEntry> subsamples;
185 }; 185 };
186 186
187 // This defines a mojo transport format for media::DecoderBuffer. 187 // This defines a mojo transport format for media::DecoderBuffer.
188 struct MediaDecoderBuffer { 188 struct MediaDecoderBuffer {
189 // See media/base/buffers.h for details. 189 // See media/base/buffers.h for details.
190 int64 timestamp_usec; 190 int64 timestamp_usec;
191 int64 duration_usec; 191 int64 duration_usec;
192 192
193 // The number of bytes in |data|. 193 // The number of bytes present in this buffer. The data is not serialized
194 // along with this structure and must be read from a separate DataPipe.
194 uint32 data_size; 195 uint32 data_size;
195 196
196 // Indicates whether or not this buffer is a random access point. 197 // Indicates whether or not this buffer is a random access point.
197 bool is_key_frame; 198 bool is_key_frame;
198 199
199 // This is backed by an std::vector and results in a few copies. 200 // This is backed by an std::vector and results in a few copies.
200 // Into the vector, onto and off the MessagePipe, back into a vector. 201 // Into the vector, onto and off the MessagePipe, back into a vector.
201 array<uint8>? side_data; 202 array<uint8>? side_data;
202 uint32 side_data_size; 203 uint32 side_data_size;
203 204
204 // DecryptConfig for a encrypted buffer. NULL if the buffer is not encrypted. 205 // DecryptConfig for a encrypted buffer. NULL if the buffer is not encrypted.
205 DecryptConfig? decrypt_config; 206 DecryptConfig? decrypt_config;
206 207
207 // These fields indicate the amount of data to discard after decoding. 208 // These fields indicate the amount of data to discard after decoding.
208 int64 front_discard_usec; 209 int64 front_discard_usec;
209 int64 back_discard_usec; 210 int64 back_discard_usec;
210 211
211 // Indicates this buffer is part of a splice around |splice_timestamp_usec|. 212 // Indicates this buffer is part of a splice around |splice_timestamp_usec|.
212 int64 splice_timestamp_usec; 213 int64 splice_timestamp_usec;
213
214 // The payload. Invalid handle indicates an end-of-stream (EOS) buffer.
215 // TODO(tim): This currently results in allocating a new, largeish DataPipe
216 // for each buffer. Remove this once framed data pipes exist, but using this
217 // for now for prototyping audio.
218 handle<data_pipe_consumer>? data;
219 }; 214 };
OLDNEW
« no previous file with comments | « media/mojo/interfaces/demuxer_stream.mojom ('k') | media/mojo/services/media_type_converters.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698