Caption
public struct Caption : XMLRepresentable
A caption or subtitle with custom text elements.
-
The texts of the caption.
Declaration
Swift
public var texts: [Text] -
The text style definitions of the caption.
Declaration
Swift
public var textStyleDefinitions: [TextStyleDefinition] -
A note associated with the caption.
Declaration
Swift
public var note: String? -
The lane of the caption.
Declaration
Swift
public var lane: Int? -
The offset of the caption.
Declaration
Swift
public var offset: CMTime? -
The name of the caption.
Declaration
Swift
public var name: String? -
The start time of the caption.
Declaration
Swift
public var start: CMTime? -
The duration of the caption.
Declaration
Swift
public var duration: CMTime -
A Boolean value that indicates whether the caption is enabled.
Declaration
Swift
public var isEnabled: Bool { get set } -
Assigns a role to the underlying media component. The format is
role-name?captionFormat=captionFormat.subrole.Declaration
Swift
public var role: String? -
Initializes a new caption.
Declaration
Swift
public init(lane: Int? = nil, offset: CMTime = .zero, name: String? = nil, start: CMTime? = nil, duration: CMTime, role: String? = nil)Parameters
laneThe lane of the caption.
offsetThe offset of the caption.
nameThe name of the caption.
startThe start time of the caption.
durationThe duration of the caption.
roleThe role of the caption.
Caption Structure Reference