Experimental
@aws-cdk/aws-mediapackagev2-alpha is an experimental (alpha) package: its API may change in any release, without a major version bump.
CmafInputProps Struct
Properties for CMAF input configuration.
| Stability | Experimental |
|---|---|
| Source | lib/channel.ts |
Example
ts
declare const stack: Stack;
declare const group: ChannelGroup;
const hlsChannel = new Channel(stack, 'HlsChannel', {
channelGroup: group,
input: InputConfiguration.hls(),
});
const cmafChannel = new Channel(stack, 'CmafChannel', {
channelGroup: group,
input: InputConfiguration.cmaf({
inputSwitchConfiguration: {
mqcsInputSwitching: true,
},
outputHeaders: [HeadersCMSD.MQCS],
}),
});
const simpleCmafChannel = new Channel(stack, 'SimpleCmafChannel', {
channelGroup: group,
input: InputConfiguration.cmaf({
outputHeaders: [HeadersCMSD.MQCS],
}),
});
python
from aws_cdk.aws_mediapackagev2_alpha import InputSwitchConfiguration
# stack: Stack
# group: ChannelGroup
hls_channel = Channel(stack, "HlsChannel",
channel_group=group,
input=InputConfiguration.hls()
)
cmaf_channel = Channel(stack, "CmafChannel",
channel_group=group,
input=InputConfiguration.cmaf(
input_switch_configuration=InputSwitchConfiguration(
mqcs_input_switching=True
),
output_headers=[HeadersCMSD.MQCS]
)
)
simple_cmaf_channel = Channel(stack, "SimpleCmafChannel",
channel_group=group,
input=InputConfiguration.cmaf(
output_headers=[HeadersCMSD.MQCS]
)
)
java
Stack stack;
ChannelGroup group;
Channel hlsChannel = Channel.Builder.create(stack, "HlsChannel")
.channelGroup(group)
.input(InputConfiguration.hls())
.build();
Channel cmafChannel = Channel.Builder.create(stack, "CmafChannel")
.channelGroup(group)
.input(InputConfiguration.cmaf(CmafInputProps.builder()
.inputSwitchConfiguration(InputSwitchConfiguration.builder()
.mqcsInputSwitching(true)
.build())
.outputHeaders(List.of(HeadersCMSD.MQCS))
.build()))
.build();
Channel simpleCmafChannel = Channel.Builder.create(stack, "SimpleCmafChannel")
.channelGroup(group)
.input(InputConfiguration.cmaf(CmafInputProps.builder()
.outputHeaders(List.of(HeadersCMSD.MQCS))
.build()))
.build();
csharp
// Install: dotnet add package Amazon.CDK.AWS.MediaPackageV2.Alpha
Stack stack;
ChannelGroup group;
var hlsChannel = new Channel(stack, "HlsChannel", new ChannelProps {
ChannelGroup = group,
Input = InputConfiguration.Hls()
});
var cmafChannel = new Channel(stack, "CmafChannel", new ChannelProps {
ChannelGroup = group,
Input = InputConfiguration.Cmaf(new CmafInputProps {
InputSwitchConfiguration = new InputSwitchConfiguration {
MqcsInputSwitching = true
},
OutputHeaders = new [] { HeadersCMSD.MQCS }
})
});
var simpleCmafChannel = new Channel(stack, "SimpleCmafChannel", new ChannelProps {
ChannelGroup = group,
Input = InputConfiguration.Cmaf(new CmafInputProps {
OutputHeaders = new [] { HeadersCMSD.MQCS }
})
});
go
// Install: go get github.com/aws/aws-cdk-go/awsmediapackagev2alpha/v2
var stack Stack
var group ChannelGroup
hlsChannel := awsmediapackagev2alpha.NewChannel(stack, jsii.String("HlsChannel"), &ChannelProps{
ChannelGroup: group,
Input: awsmediapackagev2alpha.InputConfiguration_Hls(),
})
cmafChannel := awsmediapackagev2alpha.NewChannel(stack, jsii.String("CmafChannel"), &ChannelProps{
ChannelGroup: group,
Input: awsmediapackagev2alpha.InputConfiguration_Cmaf(&CmafInputProps{
InputSwitchConfiguration: &InputSwitchConfiguration{
MqcsInputSwitching: jsii.Boolean(true),
},
OutputHeaders: []HeadersCMSD{
awsmediapackagev2alpha.HeadersCMSD_MQCS(),
},
}),
})
simpleCmafChannel := awsmediapackagev2alpha.NewChannel(stack, jsii.String("SimpleCmafChannel"), &ChannelProps{
ChannelGroup: group,
Input: awsmediapackagev2alpha.InputConfiguration_*Cmaf(&CmafInputProps{
OutputHeaders: []HeadersCMSD{
awsmediapackagev2alpha.HeadersCMSD_MQCS(),
},
}),
})
Properties
inputSwitchConfigurationoptionalInputSwitchConfigurationinput_switch_configurationoptionalInputSwitchConfigurationinputSwitchConfigurationoptionalInputSwitchConfigurationInputSwitchConfigurationoptionalInputSwitchConfigurationInputSwitchConfigurationoptionalInputSwitchConfiguration #The configuration for input switching based on the media quality confidence score (MQCS) as provided from AWS Elemental MediaLive.
Default: No customized input switch configuration added
outputHeadersoptionalHeadersCMSD[]output_headersoptionaltyping.List[HeadersCMSD]outputHeadersoptionalList<HeadersCMSD>OutputHeadersoptionalHeadersCMSD[]OutputHeadersoptional*[]HeadersCMSD = none #The settings for what common media server data (CMSD) headers AWS Elemental MediaPackage includes in responses to the CDN.