class CaptionAlignment
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.MediaLive.Alpha.CaptionAlignment |
Go | github.com/aws/aws-cdk-go/awsmedialivealpha/v2#CaptionAlignment |
Java | software.amazon.awscdk.services.medialive.alpha.CaptionAlignment |
Python | aws_cdk.aws_medialive_alpha.CaptionAlignment |
TypeScript (source) | @aws-cdk/aws-medialive-alpha ยป CaptionAlignment |
Caption alignment for burn-in and DVB-Sub outputs.
Example
// Define a caption selector on the input attachment (see Input Attachment Settings below)
const captionSelector = medialive.CaptionSelector.embedded('captions');
// WebVTT captions โ packaged alongside the video encode in the same output
const webvtt = medialive.EncodeConfiguration.caption({
name: 'eng_webvtt',
captionSelectorName: captionSelector.name,
languageCode: 'eng',
languageDescription: 'English',
destination: medialive.CaptionDestination.webvtt(),
});
// Burned-in captions โ rendered into the video, styled via the burn-in options
const burnIn = medialive.EncodeConfiguration.caption({
name: 'eng_burnin',
captionSelectorName: captionSelector.name,
destination: medialive.CaptionDestination.burnIn({
alignment: medialive.CaptionAlignment.CENTERED,
fontColor: medialive.CaptionFontColor.WHITE,
outlineColor: medialive.CaptionOutlineColor.BLACK,
fontSize: medialive.CaptionFontSize.AUTO,
}),
});
Properties
| Name | Type | Description |
|---|---|---|
| value | string | The underlying string value passed to CloudFormation. |
| static CENTERED | Caption | Center the captions. |
| static LEFT | Caption | Left-align the captions. |
| static SMART | Caption | Smart: left-justify live subtitles, center-justify pre-recorded subtitles. |
value
Type:
string
The underlying string value passed to CloudFormation.
static CENTERED
Type:
Caption
Center the captions.
static LEFT
Type:
Caption
Left-align the captions.
static SMART
Type:
Caption
Smart: left-justify live subtitles, center-justify pre-recorded subtitles.
Methods
| Name | Description |
|---|---|
| static of(value) | A value not yet modelled by AWS CDK. |
static of(value)
public static of(value: string): CaptionAlignment
Parameters
- value
string
Returns
A value not yet modelled by AWS CDK.

.NET
Go
Java
Python
TypeScript (