本文属于机器翻译版本。若本译文内容与英语原文存在差异,则一律以英文原文为准。
输入开关动作-有效载荷
以下各节显示了输入切换操作的有效载荷。
在此有效载荷中,仅ScheduleActionStartSettings
包含FixedModeScheduleActionStartSettings
ImmediateModeScheduleActionStartSettings
、或中的一个FollowModeScheduleActionStartSettings
。
有关每个标签的示例,请参阅以下示例。
有关以下 JSON 中字段的含义和值的信息,请参阅输入开关的字段。
{ "ChannelId": "string", "Creates": { "ScheduleActions": [ { "ScheduleActionStartSettings": { "FixedModeScheduleActionStartSettings": { "Time": "string" }, "FollowModeScheduleActionStartSettings": { "FollowPoint": "enum", "ReferenceActionName": "string" }, "ImmediateModeScheduleActionStartSettings": { } }, "ActionName": "string", "ScheduleActionSettings": { "InputSwitchSettings": { "InputAttachmentNameReference": "string", "InputClippingSettings": { "InputTimecodeSource": "enum", "StartTimecode": { "Timecode": "string" }, "StopTimecode": { "LastFrameClippingBehavior": "enum", "Timecode": "string" } }, "UrlPath": ["string", ...] } } ] } }
切换到具有固定开始时间的实时输入的示例
这个请求示例是在固定的开始时间切换到实时输入。开关动作被调用studio-feed
,它会切换到连接到名为的输入附件的输入live-studio-feed
。它会在指定的 UTC 时间切换到此输入。
{ "ChannelId": "999999", "Creates": { "ScheduleActions": [ { "ScheduleActionStartSettings": { "FixedModeScheduleActionStartSettings": { "Time": "2018-05-21T20:42:19.000Z" } }, "ActionName": "studio-feed", "ScheduleActionSettings": { "InputSwitchSettings": { "InputAttachmentNameReference": "live-studio-feed" } } } ] } }
静态文件切换示例如下
这个请求示例是切换到静态文件输入以跟随前一个输入的结尾。开关动作被调用action-ad-003
,它会切换到连接到名为的输入附件的输入zel-cafe
。当被调用的动作action-ad-002
结束时,它会切换到此输入。此操作的文件会被剪掉,使其在 30 秒零 11 帧后结束:
{ "ChannelId": "999999", "Creates": { "ScheduleActions": [ { "ScheduleActionStartSettings": { "FollowModeScheduleActionStartSettings": { "FollowPoint": "END", "ReferenceActionName": "action-ad-002" } }, "ActionName": "action-ad-003", "ScheduleActionSettings": { "InputSwitchSettings": { "InputAttachmentNameReference": "zel-cafe", "InputClippingSettings": { "InputTimecodeSource": "ZEROBASED", "StopTimecode":{ "Timecode": "00:00:30:11", "LastFrameClippingBehavior": "INCLUDE_LAST_FRAME" } } } } } ] } }
切换到具有即时启动时间的动态输入的示例
此请求示例是立即切换到动态文件输入。开关动作被调用action-unscheduled-standby
,它会切换到连接到名为的输入附件的输入dynamic-unscheduled-standby
。对于动态输入的这种用法,要使用的文件是oceanwaves.mp4
。
{ "ChannelId": "999999", "Creates": { "ScheduleActions": [ { "ScheduleActionStartSettings": { "ImmediateModeScheduleActionStartSettings": { } }, "ActionName": "action-unscheduled-slate", "ScheduleActionSettings": { "InputSwitchSettings": { "InputAttachmentNameReference": "slate", "UrlPath":[ "main/oceanwaves.mp4", "redundant/oceanwaves.mp4"] } } } ] } }