Experimental
@aws-cdk/aws-medialive-alpha is an experimental (alpha) package: its API may change in any release, without a major version bump.
ColorSpace Class
A color space supported for 3D-LUT color conversion in a color-correction rule.
Example
ts
declare const stack: Stack;
declare const bucket: s3.IBucket;
declare const input: medialive.IInput;
declare const video: medialive.EncodeConfiguration;
declare const destination: medialive.OutputDestination;
new medialive.Channel(stack, 'Channel', {
inputs: [{ input }],
colorCorrections: [{
inputColorSpace: medialive.ColorSpace.REC_601,
outputColorSpace: medialive.ColorSpace.REC_709,
lut: medialive.Lut.fromBucket(bucket, 'luts/rec601-to-rec709.cube'),
}],
outputGroups: [
medialive.OutputGroupConfiguration.hls({
name: 'hls',
destinations: [destination],
outputs: [{ encodes: [video], outputName: 'video' }],
}),
],
});
python
# stack: Stack
# bucket: s3.IBucket
# input: medialive.IInput
# video: medialive.EncodeConfiguration
# destination: medialive.OutputDestination
medialive.Channel(stack, "Channel",
inputs=[medialive.InputAttachment(input=input)],
color_corrections=[medialive.ColorCorrection(
input_color_space=medialive.ColorSpace.REC_601,
output_color_space=medialive.ColorSpace.REC_709,
lut=medialive.Lut.from_bucket(bucket, "luts/rec601-to-rec709.cube")
)],
output_groups=[
medialive.OutputGroupConfiguration.hls(
name="hls",
destinations=[destination],
outputs=[medialive.HlsOutputDefinition(encodes=[video], output_name="video")]
)
]
)
java
Stack stack;
IBucket bucket;
IInput input;
EncodeConfiguration video;
OutputDestination destination;
Channel.Builder.create(stack, "Channel")
.inputs(List.of(InputAttachment.builder().input(input).build()))
.colorCorrections(List.of(ColorCorrection.builder()
.inputColorSpace(ColorSpace.REC_601)
.outputColorSpace(ColorSpace.REC_709)
.lut(Lut.fromBucket(bucket, "luts/rec601-to-rec709.cube"))
.build()))
.outputGroups(List.of(OutputGroupConfiguration.hls(HlsOutputGroupProps.builder()
.name("hls")
.destinations(List.of(destination))
.outputs(List.of(HlsOutputDefinition.builder().encodes(List.of(video)).outputName("video").build()))
.build())))
.build();
csharp
// Install: dotnet add package Amazon.CDK.AWS.MediaLive.Alpha
Stack stack;
IBucket bucket;
IInput input;
EncodeConfiguration video;
OutputDestination destination;
new Channel(stack, "Channel", new ChannelProps {
Inputs = new [] { new InputAttachment { Input = input } },
ColorCorrections = new [] { new ColorCorrection {
InputColorSpace = ColorSpace.REC_601,
OutputColorSpace = ColorSpace.REC_709,
Lut = Lut.FromBucket(bucket, "luts/rec601-to-rec709.cube")
} },
OutputGroups = new [] { OutputGroupConfiguration.Hls(new HlsOutputGroupProps {
Name = "hls",
Destinations = new [] { destination },
Outputs = new [] { new HlsOutputDefinition { Encodes = new [] { video }, OutputName = "video" } }
}) }
});
go
// Install: go get github.com/aws/aws-cdk-go/awsmedialivealpha/v2
var stack Stack
var bucket IBucket
var input IInput
var video EncodeConfiguration
var destination OutputDestination
medialive.NewChannel(stack, jsii.String("Channel"), &ChannelProps{
Inputs: []InputAttachment{
&InputAttachment{
Input: *Input,
},
},
ColorCorrections: []ColorCorrection{
&ColorCorrection{
InputColorSpace: medialive.ColorSpace_REC_601(),
OutputColorSpace: medialive.ColorSpace_REC_709(),
Lut: medialive.Lut_FromBucket(bucket, jsii.String("luts/rec601-to-rec709.cube")),
},
},
OutputGroups: []OutputGroupConfiguration{
medialive.OutputGroupConfiguration_Hls(&HlsOutputGroupProps{
Name: jsii.String("hls"),
Destinations: []OutputDestination{
destination,
},
Outputs: []HlsOutputDefinition{
&HlsOutputDefinition{
Encodes: []EncodeConfiguration{
video,
},
OutputName: jsii.String("video"),
},
},
}),
},
})
Properties
HDR10.
HLG (Rec.
2020).
Rec.
601 (SD).
Rec.
709 (HD).
The underlying string value passed to CloudFormation.
Methods
of(value: string): ColorSpace // chainable@staticmethod def of(value: str) -> ColorSpacepublic static ColorSpace of(String value)public static ColorSpace Of(string value)func Of(Value *string) ColorSpacestatic#A value not yet modelled by AWS CDK.