Home
last modified time | relevance | path

Searched refs:subtitle (Results 1 – 25 of 89) sorted by relevance

1234

/external/exoplayer/tree/library/core/src/test/java/com/google/android/exoplayer2/text/webvtt/
DWebvttDecoderTest.java73 WebvttSubtitle subtitle = getSubtitleForTestAsset(TYPICAL_FILE); in decodeTypical() local
75 assertThat(subtitle.getEventTimeCount()).isEqualTo(4); in decodeTypical()
77 assertThat(subtitle.getEventTime(0)).isEqualTo(0L); in decodeTypical()
78 assertThat(subtitle.getEventTime(1)).isEqualTo(1_234_000L); in decodeTypical()
79 Cue firstCue = Iterables.getOnlyElement(subtitle.getCues(subtitle.getEventTime(0))); in decodeTypical()
82 assertThat(subtitle.getEventTime(2)).isEqualTo(2_345_000L); in decodeTypical()
83 assertThat(subtitle.getEventTime(3)).isEqualTo(3_456_000L); in decodeTypical()
84 Cue secondCue = Iterables.getOnlyElement(subtitle.getCues(subtitle.getEventTime(2))); in decodeTypical()
90 WebvttSubtitle subtitle = getSubtitleForTestAsset(WITH_BOM); in decodeWithBom() local
92 assertThat(subtitle.getEventTimeCount()).isEqualTo(4); in decodeWithBom()
[all …]
DWebvttSubtitleTest.java202 private void testSubtitleEventTimesHelper(WebvttSubtitle subtitle) { in testSubtitleEventTimesHelper() argument
203 assertThat(subtitle.getEventTime(0)).isEqualTo(1_000_000); in testSubtitleEventTimesHelper()
204 assertThat(subtitle.getEventTime(1)).isEqualTo(2_000_000); in testSubtitleEventTimesHelper()
205 assertThat(subtitle.getEventTime(2)).isEqualTo(3_000_000); in testSubtitleEventTimesHelper()
206 assertThat(subtitle.getEventTime(3)).isEqualTo(4_000_000); in testSubtitleEventTimesHelper()
209 private void testSubtitleEventIndicesHelper(WebvttSubtitle subtitle) { in testSubtitleEventIndicesHelper() argument
211 assertThat(subtitle.getNextEventTimeIndex(0)).isEqualTo(0); in testSubtitleEventIndicesHelper()
212 assertThat(subtitle.getNextEventTimeIndex(500_000)).isEqualTo(0); in testSubtitleEventIndicesHelper()
213 assertThat(subtitle.getNextEventTimeIndex(999_999)).isEqualTo(0); in testSubtitleEventIndicesHelper()
216 assertThat(subtitle.getNextEventTimeIndex(1_000_000)).isEqualTo(1); in testSubtitleEventIndicesHelper()
[all …]
/external/exoplayer/tree/library/core/src/test/java/com/google/android/exoplayer2/text/subrip/
DSubripDecoderTest.java48 Subtitle subtitle = decoder.decode(bytes, bytes.length, false); in decodeEmpty() local
50 assertThat(subtitle.getEventTimeCount()).isEqualTo(0); in decodeEmpty()
51 assertThat(subtitle.getCues(0).isEmpty()).isTrue(); in decodeEmpty()
58 Subtitle subtitle = decoder.decode(bytes, bytes.length, false); in decodeTypical() local
60 assertThat(subtitle.getEventTimeCount()).isEqualTo(6); in decodeTypical()
61 assertTypicalCue1(subtitle, 0); in decodeTypical()
62 assertTypicalCue2(subtitle, 2); in decodeTypical()
63 assertTypicalCue3(subtitle, 4); in decodeTypical()
72 Subtitle subtitle = decoder.decode(bytes, bytes.length, false); in decodeTypicalWithByteOrderMark() local
74 assertThat(subtitle.getEventTimeCount()).isEqualTo(6); in decodeTypicalWithByteOrderMark()
[all …]
/external/exoplayer/tree/library/core/src/test/java/com/google/android/exoplayer2/text/ssa/
DSsaDecoderTest.java52 Subtitle subtitle = decoder.decode(bytes, bytes.length, false); in decodeEmpty() local
54 assertThat(subtitle.getEventTimeCount()).isEqualTo(0); in decodeEmpty()
55 assertThat(subtitle.getCues(0).isEmpty()).isTrue(); in decodeEmpty()
62 Subtitle subtitle = decoder.decode(bytes, bytes.length, false); in decodeTypical() local
64 assertThat(subtitle.getEventTimeCount()).isEqualTo(6); in decodeTypical()
66 Cue firstCue = subtitle.getCues(subtitle.getEventTime(0)).get(0); in decodeTypical()
78 assertTypicalCue1(subtitle, 0); in decodeTypical()
79 assertTypicalCue2(subtitle, 2); in decodeTypical()
80 assertTypicalCue3(subtitle, 4); in decodeTypical()
95 Subtitle subtitle = decoder.decode(bytes, bytes.length, false); in decodeTypicalWithInitializationData() local
[all …]
/external/exoplayer/tree/library/core/src/test/java/com/google/android/exoplayer2/text/ttml/
DTtmlDecoderTest.java69 TtmlSubtitle subtitle = getSubtitle(INLINE_ATTRIBUTES_TTML_FILE); in inlineAttributes() local
71 assertThat(subtitle.getEventTimeCount()).isEqualTo(4); in inlineAttributes()
73 Spanned spanned = getOnlyCueTextAtTimeUs(subtitle, 10_000_000); in inlineAttributes()
88 TtmlSubtitle subtitle = getSubtitle(INLINE_ATTRIBUTES_TTML_FILE); in inheritInlineAttributes() local
90 assertThat(subtitle.getEventTimeCount()).isEqualTo(4); in inheritInlineAttributes()
92 Spanned spanned = getOnlyCueTextAtTimeUs(subtitle, 20_000_000); in inheritInlineAttributes()
117 TtmlSubtitle subtitle = getSubtitle(INLINE_ATTRIBUTES_TTML_FILE); in lime() local
119 assertThat(subtitle.getEventTimeCount()).isEqualTo(4); in lime()
121 Spanned spanned = getOnlyCueTextAtTimeUs(subtitle, 20_000_000); in lime()
132 TtmlSubtitle subtitle = getSubtitle(INHERIT_STYLE_TTML_FILE); in inheritGlobalStyle() local
[all …]
/external/exoplayer/tree/library/core/src/test/java/com/google/android/exoplayer2/text/tx3g/
DTx3gDecoderTest.java60 Subtitle subtitle = decoder.decode(bytes, bytes.length, false); in decodeNoSubtitle() local
61 assertThat(subtitle.getCues(0)).isEmpty(); in decodeNoSubtitle()
69 Subtitle subtitle = decoder.decode(bytes, bytes.length, false); in decodeJustText() local
70 SpannedString text = new SpannedString(subtitle.getCues(0).get(0).text); in decodeJustText()
73 assertFractionalLinePosition(subtitle.getCues(0).get(0), 0.85f); in decodeJustText()
81 Subtitle subtitle = decoder.decode(bytes, bytes.length, false); in decodeWithStyl() local
82 SpannedString text = new SpannedString(subtitle.getCues(0).get(0).text); in decodeWithStyl()
90 assertFractionalLinePosition(subtitle.getCues(0).get(0), 0.85f); in decodeWithStyl()
99 Subtitle subtitle = decoder.decode(bytes, bytes.length, false); in decodeWithStylAllDefaults() local
100 SpannedString text = new SpannedString(subtitle.getCues(0).get(0).text); in decodeWithStylAllDefaults()
[all …]
/external/exoplayer/tree/library/core/src/main/java/com/google/android/exoplayer2/text/
DSubtitleOutputBuffer.java29 @Nullable private Subtitle subtitle; field in SubtitleOutputBuffer
41 public void setContent(long timeUs, Subtitle subtitle, long subsampleOffsetUs) { in setContent() argument
43 this.subtitle = subtitle; in setContent()
50 return Assertions.checkNotNull(subtitle).getEventTimeCount(); in getEventTimeCount()
55 return Assertions.checkNotNull(subtitle).getEventTime(index) + subsampleOffsetUs; in getEventTime()
60 return Assertions.checkNotNull(subtitle).getNextEventTimeIndex(timeUs - subsampleOffsetUs); in getNextEventTimeIndex()
65 return Assertions.checkNotNull(subtitle).getCues(timeUs - subsampleOffsetUs); in getCues()
71 subtitle = null; in clear()
DTextRenderer.java89 @Nullable private SubtitleOutputBuffer subtitle; field in TextRenderer
180 if (subtitle != null) { in render()
203 if (subtitle != null) { in render()
204 subtitle.release(); in render()
206 subtitle = nextSubtitle; in render()
208 nextSubtitleEventIndex = subtitle.getNextEventTimeIndex(positionUs); in render()
215 updateOutput(subtitle.getCues(positionUs)); in render()
280 if (subtitle != null) { in releaseBuffers()
281 subtitle.release(); in releaseBuffers()
282 subtitle = null; in releaseBuffers()
[all …]
/external/exoplayer/tree/testdata/src/test/assets/ssa/
Doverlapping_timecodes6 Dialogue: 0:00:01.00,0:00:04.23,First subtitle - end overlaps second
7 Dialogue: 0:00:02.00,0:00:05.23,Second subtitle - beginning overlaps first
8 Dialogue: 0:00:08.44,0:00:09.44,Fourth subtitle - same timings as fifth
9 Dialogue: 0:00:06.00,0:00:08.44,Third subtitle - out of order
10 Dialogue: 0:00:08.44,0:00:09.44,Fifth subtitle - same timings as fourth
11 Dialogue: 0:00:10.72,0:00:15.65,Sixth subtitle - fully encompasses seventh
12 Dialogue: 0:00:13.22,0:00:14.22,Seventh subtitle - nested fully inside sixth
Dpositioning13 Dialogue: 0,0:00:00.00,0:00:01.23,Default,Olly,{\pos(150,50.5)}First subtitle.
14 Dialogue: 0,0:00:02.34,0:00:03.45,Default,Olly,Second subtitle{\pos(75,50.5)}.
15 Dialogue: 0,0:00:04:56,0:00:08:90,Default,Olly,{\pos(150,100)}Third subtitle{\pos(75,101)}, (only l…
16 Dialogue: 0,0:00:09:56,0:00:12:90,Default,Olly,{\move(150,100,150,50.5)}Fourth subtitle.
17 Dialogue: 0,0:00:13:56,0:00:15:90,Default,Olly,{ \pos( 150, 101 ) }Fifth subtitle {\an2}(alignment …
18 Dialogue: 0,0:00:16:56,0:00:19:90,Default,Olly,{\pos(150,101)\an9}Sixth subtitle (multiple override…
Dinvalid_timecodes10 Dialogue: 0,Invalid,0:00:01.23,Default,Olly,This is the first subtitle{ignored}.
11 Dialogue: 0,0:00:02.34,Invalid,Default,Olly,This is the second subtitle \nwith a newline \Nand anot…
12 Dialogue: 0,0:00:04:56,0:00:08:90,Default,Olly,This is the third subtitle, with a comma.
13 Dialogue: 0, ,0:00:10:90,Default,Olly,This is the fourth subtitle.
14 Dialogue: 0,0:00:12:90, ,Default,Olly,This is the fifth subtitle.
Dinvalid_positioning13 Dialogue: 0,0:00:00.00,0:00:01.23,Default,Olly,{\pos(-5,50)}First subtitle (negative \pos()).
14 Dialogue: 0,0:00:02.34,0:00:03.45,Default,Olly,{\move(-5,50,-5,50)}Second subtitle (negative \move(…
15 Dialogue: 0,0:00:04:56,0:00:08:90,Default,Olly,{\an11}Third subtitle (invalid alignment).
16 Dialogue: 0,0:00:09:56,0:00:12:90,Default,Olly,\pos(150,100) Fourth subtitle (no braces).
/external/exoplayer/tree/testdata/src/test/assets/subrip/
Dtypical_missing_timecode3 This is the first subtitle.
6 This is the second subtitle.
7 Second subtitle with second line.
11 This is the third subtitle.
15 This is the fourth subtitle.
19 This is the fifth subtitle.
Dtypical_extra_blank_line3 This is the first subtitle.
8 This is the second subtitle.
9 Second subtitle with second line.
13 This is the third subtitle.
Dtypical_missing_sequence3 This is the first subtitle.
6 This is the second subtitle.
7 Second subtitle with second line.
11 This is the third subtitle.
Dtypical3 This is the first subtitle.
7 This is the second subtitle.
8 Second subtitle with second line.
12 This is the third subtitle.
Dtypical_negative_timestamps3 This is the first subtitle.
7 This is the second subtitle.
8 Second subtitle with second line.
12 This is the third subtitle.
Dtypical_no_hours_and_millis3 This is the first subtitle.
7 This is the second subtitle.
8 Second subtitle with second line.
12 This is the third subtitle.
Dtypical_with_byte_order_mark3 This is the first subtitle.
7 This is the second subtitle.
8 Second subtitle with second line.
12 This is the third subtitle.
Dtypical_with_tags3 This is {\an1} the first subtitle.
7 This is the second subtitle.
8 Second {\ an 2} subtitle with second line.
12 This {\an2} is the third {\ tag} subtitle.
20 This {\an2} is the fifth subtitle with multiple {\xyz} valid {\qwe} tags.
Dtypical_unexpected_end3 This is the first subtitle.
7 This is the second subtitle.
8 Second subtitle with second line.
/external/exoplayer/tree/testdata/src/test/assets/webvtt/
Dwith_positioning6 This is the first subtitle.
12 This is the second subtitle.
17 This is the third subtitle.
22 This is the fourth subtitle.
27 This is the fifth subtitle.
32 This is the sixth subtitle.
37 This is the seventh subtitle.
42 This is the eighth subtitle.
Dwith_tags4 This is the <i>first</i> subtitle.
7 This is the <b><i>second</b></i> subtitle.
10 This is the <c.red.caps>third</c> subtitle.
13 This is the &lt;fourth&gt; &amp;subtitle.
Dwith_bad_cue_header4 This is the first subtitle.
7 This is the second subtitle.
10 This is the third subtitle.
/external/subsampling-scale-image-view/sample/src/main/java/com/davemorrissey/labs/subscaleview/test/
DPage.java7 private final int subtitle; field in Page
9 public Page(int subtitle, int text) { in Page() argument
10 this.subtitle = subtitle; in Page()
19 return subtitle; in getSubtitle()

1234