mode property
Gets or sets how a sequence of media segments are handled by the SourceBuffer object.
This property is read/write.
Syntax
| JavaScript |
|---|
object.mode = mode mode = object.mode |
Property values
Type: AppendMode
The method by which a sequence of media segments are handled.
AppendMode values:
| Value | Condition |
|---|---|
|
The placement of coded frames in the presentation are determined by the timestamps in the media segments. Media segments can be appended in any order. |
|
Media segments will be treated as adjacent in time independent of the timestamps in the media segment. Coded frames in a new media segment will be placed immediately after the coded frames in the previous media segment. The timestampOffset attribute will be updated if a new offset is needed to make the new media segments adjacent to the previous media segment. Setting the timestampOffset attribute in sequence mode allows a media segment to be placed at a specific position in the timeline without any knowledge of the timestamps in the media segment. |
See also