Constructor and Description |
---|
TtmlSubtitle(com.google.android.exoplayer.text.ttml.TtmlNode root,
Map<String,com.google.android.exoplayer.text.ttml.TtmlStyle> globalStyles,
Map<String,com.google.android.exoplayer.text.ttml.TtmlRegion> regionMap) |
Modifier and Type | Method and Description |
---|---|
List<Cue> |
getCues(long timeUs)
Retrieve the subtitle cues that should be displayed at a given time.
|
long |
getEventTime(int index)
Gets the event time at a specified index.
|
int |
getEventTimeCount()
Gets the number of event times, where events are defined as points in time at which the cues
returned by
Subtitle.getCues(long) changes. |
long |
getLastEventTime()
Convenience method for obtaining the last event time.
|
int |
getNextEventTimeIndex(long timeUs)
Gets the index of the first event that occurs after a given time (exclusive).
|
public int getNextEventTimeIndex(long timeUs)
Subtitle
getNextEventTimeIndex
in interface Subtitle
timeUs
- The time in microseconds.public int getEventTimeCount()
Subtitle
Subtitle.getCues(long)
changes.getEventTimeCount
in interface Subtitle
public long getEventTime(int index)
Subtitle
getEventTime
in interface Subtitle
index
- The index of the event time to obtain.public long getLastEventTime()
Subtitle
getLastEventTime
in interface Subtitle
getEventTimeCount() == 0
.