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

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

Issue 2416183002: media: Use native DemuxerStream enum types in media mojo interfaces (Closed)
Patch Set: comments addressed 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
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 "media/mojo/interfaces/media_types.mojom"; 7 import "media/mojo/interfaces/media_types.mojom";
8 8
9 // DemuxerStream is modeled after media::DemuxerStream using mojo in order to 9 // DemuxerStream is modeled after media::DemuxerStream using mojo in order to
10 // enable proxying between a media::Pipeline and media::Renderer living in two 10 // enable proxying between a media::Pipeline and media::Renderer living in two
11 // different applications. 11 // different applications.
12 interface DemuxerStream { 12 interface DemuxerStream {
13 // See media::DemuxerStream for descriptions. 13 // See media::DemuxerStream for descriptions.
14 enum Type { 14 [Native]
15 UNKNOWN, 15 enum Type;
16 AUDIO,
17 VIDEO,
18 LAST_TYPE = VIDEO,
19 };
20 16
21 // See media::DemuxerStream for descriptions. 17 // See media::DemuxerStream for descriptions.
22 enum Status { 18 [Native]
23 OK = 0, 19 enum Status;
24 ABORTED,
25 CONFIG_CHANGED,
26 };
27 20
28 // Initializes the DemuxerStream. Read() can only be called after the callback 21 // Initializes the DemuxerStream. Read() can only be called after the callback
29 // is received. The returned |pipe| will be used to fill out the data section 22 // is received. The returned |pipe| will be used to fill out the data section
30 // of the media::DecoderBuffer returned via DemuxerStream::Read(). Only the 23 // of the media::DecoderBuffer returned via DemuxerStream::Read(). Only the
31 // config for |type| should be non-null, which is the initial config of the 24 // config for |type| should be non-null, which is the initial config of the
32 // stream. 25 // stream.
33 Initialize() => (Type type, 26 Initialize() => (Type type,
34 handle<data_pipe_consumer> pipe, 27 handle<data_pipe_consumer> pipe,
35 AudioDecoderConfig? audio_config, 28 AudioDecoderConfig? audio_config,
36 VideoDecoderConfig? video_config); 29 VideoDecoderConfig? video_config);
(...skipping 14 matching lines...) Expand all
51 // in a nicer fashion. 44 // in a nicer fashion.
52 Read() => (Status status, 45 Read() => (Status status,
53 DecoderBuffer? buffer, 46 DecoderBuffer? buffer,
54 AudioDecoderConfig? audio_config, 47 AudioDecoderConfig? audio_config,
55 VideoDecoderConfig? video_config); 48 VideoDecoderConfig? video_config);
56 49
57 // Enables converting bitstream to a format that is expected by the decoder. 50 // Enables converting bitstream to a format that is expected by the decoder.
58 // For example, H.264/AAC bitstream based packets into H.264 Annex B format. 51 // For example, H.264/AAC bitstream based packets into H.264 Annex B format.
59 EnableBitstreamConverter(); 52 EnableBitstreamConverter();
60 }; 53 };
OLDNEW
« no previous file with comments | « media/mojo/common/media_type_converters.cc ('k') | media/mojo/interfaces/demuxer_stream.typemap » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698