Merge "media_info.proto protobuf for MpdBuilder"
This commit is contained in:
commit
c7fb605114
|
@ -0,0 +1,71 @@
|
|||
// This file defines the protocol between Muxer and classes for generating MPD
|
||||
// files.
|
||||
|
||||
syntax = "proto2";
|
||||
|
||||
option optimize_for = LITE_RUNTIME;
|
||||
|
||||
package dash_packager;
|
||||
|
||||
message Range {
|
||||
optional uint64 begin = 1;
|
||||
optional uint64 end = 2;
|
||||
}
|
||||
|
||||
message MediaInfo {
|
||||
message VideoInfo {
|
||||
optional string codec = 1;
|
||||
optional uint32 width = 2;
|
||||
optional uint32 height = 3;
|
||||
|
||||
// Relative to |time_scale|. IOW |time_scale| / |frame_duration| is the
|
||||
// framerate.
|
||||
optional uint64 frame_duration = 4;
|
||||
|
||||
optional bytes decoder_config = 5;
|
||||
}
|
||||
|
||||
message AudioInfo {
|
||||
optional string codec = 1;
|
||||
optional uint32 sampling_frequency = 2;
|
||||
optional uint32 num_channels = 3;
|
||||
optional string language = 4;
|
||||
optional bytes decoder_config = 5;
|
||||
}
|
||||
|
||||
message TextInfo {
|
||||
optional string format = 1;
|
||||
optional string language = 2;
|
||||
}
|
||||
|
||||
message ContentProtection {
|
||||
optional bytes key_id = 1;
|
||||
optional bytes pssh = 2;
|
||||
}
|
||||
|
||||
optional uint32 bandwidth = 1;
|
||||
optional uint32 time_scale = 2;
|
||||
repeated VideoInfo video_info = 3;
|
||||
repeated AudioInfo audio_info = 4;
|
||||
repeated TextInfo text_info = 5;
|
||||
repeated ContentProtection content_protections = 6;
|
||||
|
||||
// VOD only.
|
||||
optional Range init_range = 7;
|
||||
optional Range index_range = 8;
|
||||
optional string media_file_name = 9;
|
||||
|
||||
// This value is relative to |time_scale|.
|
||||
optional uint64 media_duration = 10;
|
||||
// END VOD only.
|
||||
|
||||
// LIVE only.
|
||||
optional string init_segment_name = 11;
|
||||
optional string segment_template = 12;
|
||||
|
||||
// This value is the user input “segment duration”.
|
||||
// This value is not necessarily the same as the value passed to
|
||||
// MpdNotifier::NotifyNewSegment().
|
||||
optional uint64 segment_duration = 13;
|
||||
// END LIVE only.
|
||||
}
|
|
@ -0,0 +1,19 @@
|
|||
# GYP file for any MPD generation targets.
|
||||
|
||||
{
|
||||
'targets': [
|
||||
{
|
||||
'target_name': 'media_info_proto',
|
||||
|
||||
'type': 'static_library',
|
||||
'sources': [
|
||||
'base/media_info.proto',
|
||||
],
|
||||
'variables': {
|
||||
'proto_in_dir': 'base',
|
||||
'proto_out_dir': 'mpd/base',
|
||||
},
|
||||
'includes': ['../build/protoc.gypi'],
|
||||
},
|
||||
],
|
||||
}
|
Loading…
Reference in New Issue