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

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

Issue 2640153004: Add mailbox-based Mojo VideoFrame variant. (Closed)
Patch Set: Rebase. Created 3 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
« no previous file with comments | « media/mojo/interfaces/BUILD.gn ('k') | media/mojo/interfaces/video_decoder.mojom » ('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 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 media.mojom; 5 module media.mojom;
6 6
7 import "gpu/ipc/common/mailbox_holder.mojom";
8 import "mojo/common/time.mojom";
7 import "ui/gfx/geometry/mojo/geometry.mojom"; 9 import "ui/gfx/geometry/mojo/geometry.mojom";
8 import "mojo/common/time.mojom";
9 10
10 // See media/base/buffering_state.h for descriptions. 11 // See media/base/buffering_state.h for descriptions.
11 [Native] 12 [Native]
12 enum BufferingState; 13 enum BufferingState;
13 14
14 // See media/base/decode_status.h for descriptions. 15 // See media/base/decode_status.h for descriptions.
15 [Native] 16 [Native]
16 enum DecodeStatus; 17 enum DecodeStatus;
17 18
18 // See media/base/audio_codecs.h for descriptions. 19 // See media/base/audio_codecs.h for descriptions.
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 171
171 // Natural size of the frame. 172 // Natural size of the frame.
172 gfx.mojom.Size natural_size; 173 gfx.mojom.Size natural_size;
173 174
174 // True if end of stream. 175 // True if end of stream.
175 bool end_of_stream; 176 bool end_of_stream;
176 177
177 // Timestamp in microseconds of the associated frame. 178 // Timestamp in microseconds of the associated frame.
178 mojo.common.mojom.TimeDelta timestamp; 179 mojo.common.mojom.TimeDelta timestamp;
179 180
181 // Contents of the video frame.
182 VideoFrameData data;
183 };
184
185 // Possible choices for storing VideoFrame data.
186 union VideoFrameData {
187 SharedBufferVideoFrameData shared_buffer_data;
188 MailboxVideoFrameData mailbox_data;
189 };
190
191 // This defines video frame data stored in a Mojo shared buffer.
192 struct SharedBufferVideoFrameData {
180 // Reference to the shared memory containing the frame's data. 193 // Reference to the shared memory containing the frame's data.
181 handle<shared_buffer> frame_data; 194 handle<shared_buffer> frame_data;
182 uint64 frame_data_size; 195 uint64 frame_data_size;
183 196
184 // Stride and offsets for each plane. Offsets are relative to the start 197 // Stride and offsets for each plane. Offsets are relative to the start
185 // of |frame_data|. 198 // of |frame_data|.
186 int32 y_stride; 199 int32 y_stride;
187 int32 u_stride; 200 int32 u_stride;
188 int32 v_stride; 201 int32 v_stride;
189 uint64 y_offset; 202 uint64 y_offset;
190 uint64 u_offset; 203 uint64 u_offset;
191 uint64 v_offset; 204 uint64 v_offset;
192 }; 205 };
193 206
207 // This defines video frame data stored in texture mailboxes.
208 struct MailboxVideoFrameData {
209 array<gpu.mojom.MailboxHolder> mailbox_holder;
210 };
211
194 struct PipelineStatistics { 212 struct PipelineStatistics {
195 uint64 audio_bytes_decoded; 213 uint64 audio_bytes_decoded;
196 uint64 video_bytes_decoded; 214 uint64 video_bytes_decoded;
197 uint32 video_frames_decoded; 215 uint32 video_frames_decoded;
198 uint32 video_frames_dropped; 216 uint32 video_frames_dropped;
199 int64 audio_memory_usage; 217 int64 audio_memory_usage;
200 int64 video_memory_usage; 218 int64 video_memory_usage;
201 }; 219 };
OLDNEW
« no previous file with comments | « media/mojo/interfaces/BUILD.gn ('k') | media/mojo/interfaces/video_decoder.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698