(::Google::Protobuf::Duration) — Duration of the segments in seconds. The default is 6s. Note that
segmentDuration must be greater than or equal to
gop_duration,
and segmentDuration must be divisible by
gop_duration.
Valid range is [2s, 20s].
All mux_streams in
the same manifest must have the same segment duration.
value (::Google::Protobuf::Duration) — Duration of the segments in seconds. The default is 6s. Note that
segmentDuration must be greater than or equal to
gop_duration,
and segmentDuration must be divisible by
gop_duration.
Valid range is [2s, 20s].
All mux_streams in
the same manifest must have the same segment duration.
Returns
(::Google::Protobuf::Duration) — Duration of the segments in seconds. The default is 6s. Note that
segmentDuration must be greater than or equal to
gop_duration,
and segmentDuration must be divisible by
gop_duration.
Valid range is [2s, 20s].
All mux_streams in
the same manifest must have the same segment duration.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[],[],null,["# Live Stream V1 API - Class Google::Cloud::Video::LiveStream::V1::SegmentSettings (v2.2.0)\n\nVersion latestkeyboard_arrow_down\n\n- [2.2.0 (latest)](/ruby/docs/reference/google-cloud-video-live_stream-v1/latest/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [2.1.0](/ruby/docs/reference/google-cloud-video-live_stream-v1/2.1.0/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [2.0.1](/ruby/docs/reference/google-cloud-video-live_stream-v1/2.0.1/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [1.3.0](/ruby/docs/reference/google-cloud-video-live_stream-v1/1.3.0/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [1.2.0](/ruby/docs/reference/google-cloud-video-live_stream-v1/1.2.0/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [1.1.1](/ruby/docs/reference/google-cloud-video-live_stream-v1/1.1.1/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [1.0.0](/ruby/docs/reference/google-cloud-video-live_stream-v1/1.0.0/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [0.9.0](/ruby/docs/reference/google-cloud-video-live_stream-v1/0.9.0/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [0.8.2](/ruby/docs/reference/google-cloud-video-live_stream-v1/0.8.2/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [0.7.0](/ruby/docs/reference/google-cloud-video-live_stream-v1/0.7.0/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [0.6.0](/ruby/docs/reference/google-cloud-video-live_stream-v1/0.6.0/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [0.5.1](/ruby/docs/reference/google-cloud-video-live_stream-v1/0.5.1/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [0.4.0](/ruby/docs/reference/google-cloud-video-live_stream-v1/0.4.0/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [0.3.0](/ruby/docs/reference/google-cloud-video-live_stream-v1/0.3.0/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [0.2.0](/ruby/docs/reference/google-cloud-video-live_stream-v1/0.2.0/Google-Cloud-Video-LiveStream-V1-SegmentSettings)\n- [0.1.0](/ruby/docs/reference/google-cloud-video-live_stream-v1/0.1.0/Google-Cloud-Video-LiveStream-V1-SegmentSettings) \nReference documentation and code samples for the Live Stream V1 API class Google::Cloud::Video::LiveStream::V1::SegmentSettings.\n\nSegment settings for `fmp4` and `ts`. \n\nInherits\n--------\n\n- Object \n\nExtended By\n-----------\n\n- Google::Protobuf::MessageExts::ClassMethods \n\nIncludes\n--------\n\n- Google::Protobuf::MessageExts\n\nMethods\n-------\n\n### #segment_duration\n\n def segment_duration() -\u003e ::Google::Protobuf::Duration\n\n**Returns**\n\n- ([::Google::Protobuf::Duration](./Google-Protobuf-Duration)) --- Duration of the segments in seconds. The default is `6s`. Note that `segmentDuration` must be greater than or equal to [gop_duration](/ruby/docs/reference/google-cloud-video-live_stream-v1/latest/Google-Cloud-Video-LiveStream-V1-VideoStream-H264CodecSettings#Google__Cloud__Video__LiveStream__V1__VideoStream__H264CodecSettings_gop_duration_instance_ \"Google::Cloud::Video::LiveStream::V1::VideoStream::H264CodecSettings#gop_duration (method)\"), and `segmentDuration` must be divisible by [gop_duration](/ruby/docs/reference/google-cloud-video-live_stream-v1/latest/Google-Cloud-Video-LiveStream-V1-VideoStream-H264CodecSettings#Google__Cloud__Video__LiveStream__V1__VideoStream__H264CodecSettings_gop_duration_instance_ \"Google::Cloud::Video::LiveStream::V1::VideoStream::H264CodecSettings#gop_duration (method)\"). Valid range is \\[2s, 20s\\].\n\n\n All [mux_streams](/ruby/docs/reference/google-cloud-video-live_stream-v1/latest/Google-Cloud-Video-LiveStream-V1-Manifest#Google__Cloud__Video__LiveStream__V1__Manifest_mux_streams_instance_ \"Google::Cloud::Video::LiveStream::V1::Manifest#mux_streams (method)\") in\n the same manifest must have the same segment duration.\n\n### #segment_duration=\n\n def segment_duration=(value) -\u003e ::Google::Protobuf::Duration\n\n**Parameter**\n\n- **value** ([::Google::Protobuf::Duration](./Google-Protobuf-Duration)) --- Duration of the segments in seconds. The default is `6s`. Note that `segmentDuration` must be greater than or equal to [gop_duration](/ruby/docs/reference/google-cloud-video-live_stream-v1/latest/Google-Cloud-Video-LiveStream-V1-VideoStream-H264CodecSettings#Google__Cloud__Video__LiveStream__V1__VideoStream__H264CodecSettings_gop_duration_instance_ \"Google::Cloud::Video::LiveStream::V1::VideoStream::H264CodecSettings#gop_duration (method)\"), and `segmentDuration` must be divisible by [gop_duration](/ruby/docs/reference/google-cloud-video-live_stream-v1/latest/Google-Cloud-Video-LiveStream-V1-VideoStream-H264CodecSettings#Google__Cloud__Video__LiveStream__V1__VideoStream__H264CodecSettings_gop_duration_instance_ \"Google::Cloud::Video::LiveStream::V1::VideoStream::H264CodecSettings#gop_duration (method)\"). Valid range is \\[2s, 20s\\].\n\n\n All [mux_streams](/ruby/docs/reference/google-cloud-video-live_stream-v1/latest/Google-Cloud-Video-LiveStream-V1-Manifest#Google__Cloud__Video__LiveStream__V1__Manifest_mux_streams_instance_ \"Google::Cloud::Video::LiveStream::V1::Manifest#mux_streams (method)\") in\nthe same manifest must have the same segment duration. \n**Returns**\n\n- ([::Google::Protobuf::Duration](./Google-Protobuf-Duration)) --- Duration of the segments in seconds. The default is `6s`. Note that `segmentDuration` must be greater than or equal to [gop_duration](/ruby/docs/reference/google-cloud-video-live_stream-v1/latest/Google-Cloud-Video-LiveStream-V1-VideoStream-H264CodecSettings#Google__Cloud__Video__LiveStream__V1__VideoStream__H264CodecSettings_gop_duration_instance_ \"Google::Cloud::Video::LiveStream::V1::VideoStream::H264CodecSettings#gop_duration (method)\"), and `segmentDuration` must be divisible by [gop_duration](/ruby/docs/reference/google-cloud-video-live_stream-v1/latest/Google-Cloud-Video-LiveStream-V1-VideoStream-H264CodecSettings#Google__Cloud__Video__LiveStream__V1__VideoStream__H264CodecSettings_gop_duration_instance_ \"Google::Cloud::Video::LiveStream::V1::VideoStream::H264CodecSettings#gop_duration (method)\"). Valid range is \\[2s, 20s\\].\n\n\n All [mux_streams](/ruby/docs/reference/google-cloud-video-live_stream-v1/latest/Google-Cloud-Video-LiveStream-V1-Manifest#Google__Cloud__Video__LiveStream__V1__Manifest_mux_streams_instance_ \"Google::Cloud::Video::LiveStream::V1::Manifest#mux_streams (method)\") in\n the same manifest must have the same segment duration."]]