@@ -18,6 +18,7 @@ package google.cloud.video.livestream.v1;
1818
1919import "google/api/field_behavior.proto" ;
2020import "google/protobuf/duration.proto" ;
21+ import "google/type/datetime.proto" ;
2122
2223option csharp_namespace = "Google.Cloud.Video.LiveStream.V1" ;
2324option go_package = "cloud.google.com/go/video/livestream/apiv1/livestreampb;livestreampb" ;
@@ -60,8 +61,9 @@ message MuxStream {
6061 // - `ts` - the corresponding file extension is `.ts`
6162 string container = 3 ;
6263
63- // List of `ElementaryStream` [key][google.cloud.video.livestream.v1.ElementaryStream.key]s multiplexed in this
64- // stream.
64+ // List of `ElementaryStream`
65+ // [key][google.cloud.video.livestream.v1.ElementaryStream.key]s multiplexed
66+ // in this stream.
6567 //
6668 // - For `fmp4` container, must contain either one video or one audio stream.
6769 // - For `ts` container, must contain exactly one audio stream and up to one
@@ -70,6 +72,10 @@ message MuxStream {
7072
7173 // Segment settings for `fmp4` and `ts`.
7274 SegmentSettings segment_settings = 5 ;
75+
76+ // Identifier of the encryption configuration to use. If omitted, output
77+ // will be unencrypted.
78+ string encryption_id = 6 ;
7379}
7480
7581// Manifest configuration.
@@ -87,15 +93,17 @@ message Manifest {
8793 }
8894
8995 // The name of the generated file. The default is `manifest` with the
90- // extension suffix corresponding to the `Manifest` [type][google.cloud.video.livestream.v1.Manifest.type]. If multiple
96+ // extension suffix corresponding to the `Manifest`
97+ // [type][google.cloud.video.livestream.v1.Manifest.type]. If multiple
9198 // manifests are added to the channel, each must have a unique file name.
9299 string file_name = 1 ;
93100
94101 // Required. Type of the manifest, can be `HLS` or `DASH`.
95102 ManifestType type = 2 [(google.api.field_behavior ) = REQUIRED ];
96103
97- // Required. List of `MuxStream` [key][google.cloud.video.livestream.v1.MuxStream.key]s that should appear in this
98- // manifest.
104+ // Required. List of `MuxStream`
105+ // [key][google.cloud.video.livestream.v1.MuxStream.key]s that should appear
106+ // in this manifest.
99107 //
100108 // - For HLS, either `fmp4` or `ts` mux streams can be specified but not
101109 // mixed.
@@ -115,6 +123,15 @@ message Manifest {
115123 // player has, but were already deleted from the output Google Cloud Storage
116124 // bucket. Default value is `60s`.
117125 google.protobuf.Duration segment_keep_duration = 5 ;
126+
127+ // Whether to use the timecode, as specified in timecode config, when setting:
128+ //
129+ // - `availabilityStartTime` attribute in DASH manifests.
130+ // - `#EXT-X-PROGRAM-DATE-TIME` tag in HLS manifests.
131+ //
132+ // If false, ignore the input timecode and use the time from system clock
133+ // when the manifest is first generated. This is the default behavior.
134+ bool use_timecode_as_timeline = 6 ;
118135}
119136
120137// Sprite sheet configuration.
@@ -161,6 +178,22 @@ message SpriteSheet {
161178
162179// Preprocessing configurations.
163180message PreprocessingConfig {
181+ // Audio preprocessing configuration.
182+ message Audio {
183+ // Specify audio loudness normalization in loudness units relative to full
184+ // scale (LUFS). Enter a value between -24 and 0 according to the following:
185+ //
186+ // - -24 is the Advanced Television Systems Committee (ATSC A/85)
187+ // - -23 is the EU R128 broadcast standard
188+ // - -19 is the prior standard for online mono audio
189+ // - -18 is the ReplayGain standard
190+ // - -16 is the prior standard for stereo audio
191+ // - -14 is the new online audio standard recommended by Spotify, as well as
192+ // Amazon Echo
193+ // - 0 disables normalization. The default is 0.
194+ double lufs = 1 ;
195+ }
196+
164197 // Video cropping configuration for the input video. The cropped input video
165198 // is scaled to match the output resolution.
166199 message Crop {
@@ -193,6 +226,9 @@ message PreprocessingConfig {
193226 int32 right_pixels = 4 ;
194227 }
195228
229+ // Audio preprocessing configuration.
230+ Audio audio = 1 ;
231+
196232 // Specify the video cropping configuration.
197233 Crop crop = 2 ;
198234
@@ -212,8 +248,8 @@ message VideoStream {
212248 // Valid range is [180, 1080].
213249 int32 height_pixels = 2 ;
214250
215- // Required. The target video frame rate in frames per second (FPS). Must be less
216- // than or equal to 60. Will default to the input frame rate if larger
251+ // Required. The target video frame rate in frames per second (FPS). Must be
252+ // less than or equal to 60. Will default to the input frame rate if larger
217253 // than the input frame rate. The API will generate an output FPS that is
218254 // divisible by the input FPS, and smaller or equal to the target FPS. See
219255 // [Calculating frame
@@ -242,16 +278,18 @@ message VideoStream {
242278
243279 // Select the GOP size based on the specified duration. The default is
244280 // `2s`. Note that `gopDuration` must be less than or equal to
245- // [segment_duration][google.cloud.video.livestream.v1.SegmentSettings.segment_duration], and
246- // [segment_duration][google.cloud.video.livestream.v1.SegmentSettings.segment_duration] must be divisible
247- // by `gopDuration`. Valid range is [2s, 20s].
281+ // [segment_duration][google.cloud.video.livestream.v1.SegmentSettings.segment_duration],
282+ // and
283+ // [segment_duration][google.cloud.video.livestream.v1.SegmentSettings.segment_duration]
284+ // must be divisible by `gopDuration`. Valid range is [2s, 20s].
248285 //
249286 // All video streams in the same channel must have the same GOP size.
250287 google.protobuf.Duration gop_duration = 8 ;
251288 }
252289
253290 // Size of the Video Buffering Verifier (VBV) buffer in bits. Must be
254- // greater than zero. The default is equal to [bitrate_bps][google.cloud.video.livestream.v1.VideoStream.H264CodecSettings.bitrate_bps].
291+ // greater than zero. The default is equal to
292+ // [bitrate_bps][google.cloud.video.livestream.v1.VideoStream.H264CodecSettings.bitrate_bps].
255293 int32 vbv_size_bits = 9 ;
256294
257295 // Initial fullness of the Video Buffering Verifier (VBV) buffer in bits.
@@ -272,8 +310,9 @@ message VideoStream {
272310 bool b_pyramid = 12 ;
273311
274312 // The number of consecutive B-frames. Must be greater than or equal to
275- // zero. Must be less than [gop_frame_count][google.cloud.video.livestream.v1.VideoStream.H264CodecSettings.gop_frame_count] if set. The default
276- // is 0.
313+ // zero. Must be less than
314+ // [gop_frame_count][google.cloud.video.livestream.v1.VideoStream.H264CodecSettings.gop_frame_count]
315+ // if set. The default is 0.
277316 int32 b_frame_count = 13 ;
278317
279318 // Specify the intensity of the adaptive quantizer (AQ). Must be between 0
@@ -291,15 +330,18 @@ message VideoStream {
291330 // The available options are [FFmpeg-compatible Profile
292331 // Options](https://trac.ffmpeg.org/wiki/Encode/H.264#Profile).
293332 // Note that certain values for this field may cause the
294- // transcoder to override other fields you set in the [H264CodecSettings][google.cloud.video.livestream.v1.VideoStream.H264CodecSettings]
333+ // transcoder to override other fields you set in the
334+ // [H264CodecSettings][google.cloud.video.livestream.v1.VideoStream.H264CodecSettings]
295335 // message.
296336 string profile = 15 ;
297337
298338 // Enforces the specified codec tune. The available options are
299339 // [FFmpeg-compatible Encode
300340 // Options](https://trac.ffmpeg.org/wiki/Encode/H.264#Tune)
301341 // Note that certain values for this field may cause the transcoder to
302- // override other fields you set in the [H264CodecSettings][google.cloud.video.livestream.v1.VideoStream.H264CodecSettings] message.
342+ // override other fields you set in the
343+ // [H264CodecSettings][google.cloud.video.livestream.v1.VideoStream.H264CodecSettings]
344+ // message.
303345 string tune = 16 ;
304346 }
305347
@@ -314,22 +356,30 @@ message VideoStream {
314356message AudioStream {
315357 // The mapping for the input streams and audio channels.
316358 message AudioMapping {
317- // Required. The `Channel` [InputAttachment.key][google.cloud.video.livestream.v1.InputAttachment.key] that identifies the input that this
318- // audio mapping applies to. If an active input doesn't have an audio
319- // mapping, the primary audio track in the input stream will be selected.
359+ // Required. The `Channel`
360+ // [InputAttachment.key][google.cloud.video.livestream.v1.InputAttachment.key]
361+ // that identifies the input that this audio mapping applies to. If an
362+ // active input doesn't have an audio mapping, the primary audio track in
363+ // the input stream will be selected.
320364 string input_key = 6 [(google.api.field_behavior ) = REQUIRED ];
321365
322366 // Required. The zero-based index of the track in the input stream.
323- // All [mapping][google.cloud.video.livestream.v1.AudioStream.mapping]s in the same [AudioStream][google.cloud.video.livestream.v1.AudioStream]
324- // must have the same input track.
367+ // All [mapping][google.cloud.video.livestream.v1.AudioStream.mapping]s in
368+ // the same [AudioStream][google.cloud.video.livestream.v1.AudioStream] must
369+ // have the same input track.
325370 int32 input_track = 2 [(google.api.field_behavior ) = REQUIRED ];
326371
327372 // Required. The zero-based index of the channel in the input stream.
328373 int32 input_channel = 3 [(google.api.field_behavior ) = REQUIRED ];
329374
330375 // Required. The zero-based index of the channel in the output audio stream.
331- // Must be consistent with the [input_channel][google.cloud.video.livestream.v1.AudioStream.AudioMapping.input_channel].
376+ // Must be consistent with the
377+ // [input_channel][google.cloud.video.livestream.v1.AudioStream.AudioMapping.input_channel].
332378 int32 output_channel = 4 [(google.api.field_behavior ) = REQUIRED ];
379+
380+ // Audio volume control in dB. Negative values decrease volume,
381+ // positive values increase. The default is 0.
382+ double gain_db = 5 ;
333383 }
334384
335385 // Specifies whether pass through (transmuxing) is enabled or not.
@@ -344,7 +394,8 @@ message AudioStream {
344394 // - `aac`
345395 string codec = 1 ;
346396
347- // Required. Audio bitrate in bits per second. Must be between 1 and 10,000,000.
397+ // Required. Audio bitrate in bits per second. Must be between 1 and
398+ // 10,000,000.
348399 int32 bitrate_bps = 2 [(google.api.field_behavior ) = REQUIRED ];
349400
350401 // Number of audio channels. Must be between 1 and 6. The default is 2.
@@ -386,12 +437,43 @@ message TextStream {
386437message SegmentSettings {
387438 // Duration of the segments in seconds. The default is `6s`. Note that
388439 // `segmentDuration` must be greater than or equal to
389- // [gop_duration][google.cloud.video.livestream.v1.VideoStream.H264CodecSettings.gop_duration], and
390- // `segmentDuration` must be divisible by
440+ // [gop_duration][google.cloud.video.livestream.v1.VideoStream.H264CodecSettings.gop_duration],
441+ // and `segmentDuration` must be divisible by
391442 // [gop_duration][google.cloud.video.livestream.v1.VideoStream.H264CodecSettings.gop_duration].
392443 // Valid range is [2s, 20s].
393444 //
394- // All [mux_streams][google.cloud.video.livestream.v1.Manifest.mux_streams] in the same manifest must have the
395- // same segment duration.
445+ // All [mux_streams][google.cloud.video.livestream.v1.Manifest.mux_streams] in
446+ // the same manifest must have the same segment duration.
396447 google.protobuf.Duration segment_duration = 1 ;
397448}
449+
450+ // Timecode configuration.
451+ message TimecodeConfig {
452+ // The source of timecode.
453+ enum TimecodeSource {
454+ // The timecode source is not specified.
455+ TIMECODE_SOURCE_UNSPECIFIED = 0 ;
456+
457+ // Use input media timestamp.
458+ MEDIA_TIMESTAMP = 1 ;
459+
460+ // Use input embedded timecode e.g. picture timing SEI message.
461+ EMBEDDED_TIMECODE = 2 ;
462+ }
463+
464+ // The source of the timecode that will later be used in outputs/manifests.
465+ // It determines the initial timecode/timestamp (first frame) of output
466+ // streams.
467+ TimecodeSource source = 1 ;
468+
469+ // For EMBEDDED_TIMECODE source only.
470+ // Used to interpret the embedded timecode (which contains only the time part
471+ // and no date). We assume all inputs are live.
472+ oneof time_offset {
473+ // UTC offset. Must be whole seconds, between -18 hours and +18 hours.
474+ google.protobuf.Duration utc_offset = 2 ;
475+
476+ // Time zone e.g. "America/Los_Angeles".
477+ google.type.TimeZone time_zone = 3 ;
478+ }
479+ }
0 commit comments