media/libraries
ibaker 33bbb9511a Fix TextRenderer exception when a subtitle file contains no cues
Discovered while investigating Issue: google/ExoPlayer#10823

Example stack trace with the previous code (I added the index value for
debugging):

```
playerFailed [eventTime=44.07, mediaPos=44.01, window=0, period=0, errorCode=ERROR_CODE_FAILED_RUNTIME_CHECK
  androidx.media3.exoplayer.ExoPlaybackException: Unexpected runtime error
      at androidx.media3.exoplayer.ExoPlayerImplInternal.handleMessage(ExoPlayerImplInternal.java:635)
      at android.os.Handler.dispatchMessage(Handler.java:102)
      at android.os.Looper.loopOnce(Looper.java:202)
      at android.os.Looper.loop(Looper.java:291)
      at android.os.HandlerThread.run(HandlerThread.java:67)
  Caused by: java.lang.IllegalArgumentException: index=-1
      at androidx.media3.common.util.Assertions.checkArgument(Assertions.java:55)
      at androidx.media3.extractor.text.webvtt.WebvttSubtitle.getEventTime(WebvttSubtitle.java:62)
      at androidx.media3.extractor.text.SubtitleOutputBuffer.getEventTime(SubtitleOutputBuffer.java:56)
      at androidx.media3.exoplayer.text.TextRenderer.getCurrentEventTimeUs(TextRenderer.java:435)
      at androidx.media3.exoplayer.text.TextRenderer.render(TextRenderer.java:268)
      at androidx.media3.exoplayer.ExoPlayerImplInternal.doSomeWork(ExoPlayerImplInternal.java:1008)
      at androidx.media3.exoplayer.ExoPlayerImplInternal.handleMessage(ExoPlayerImplInternal.java:509)
      at android.os.Handler.dispatchMessage(Handler.java:102)
      at android.os.Looper.loopOnce(Looper.java:202)
      at android.os.Looper.loop(Looper.java:291)
      at android.os.HandlerThread.run(HandlerThread.java:67)
]
```

#minor-release

PiperOrigin-RevId: 492464180
2022-12-12 11:05:49 +00:00
..
cast Bump cast sdk version and remove workaround for live duration 2022-11-29 18:45:46 +00:00
common Removed ExoPlayer specific states from SimpleBasePlayer 2022-12-12 11:04:44 +00:00
database Mark all non-public IntDefs as only TYPE_USE 2022-02-21 16:56:36 +00:00
datasource Fix instrumentation tests not working via Gradle 2022-09-30 18:03:11 +00:00
datasource_cronet Handle buffers in DefaultAudioSink with AudioProcessingPipeline. 2022-11-16 12:07:58 +00:00
datasource_okhttp Annotate methods that always return this with @CanIgnoreReturnValue 2022-08-08 07:55:25 +00:00
datasource_rtmp Annotate methods that always return this with @CanIgnoreReturnValue 2022-08-08 07:55:25 +00:00
decoder Expect PresentationTime Discontinuity During Stream Transitions 2022-04-26 14:21:36 +01:00
decoder_av1 Fix Dackka parameter name error in Gav1Decoder and VpxDecoder 2022-11-10 14:48:37 +00:00
decoder_ffmpeg Fix compilation error in ffmpeg JNI layer 2022-11-22 17:46:02 +00:00
decoder_flac Fix Dackka/Metalava errors in av1, flac, ffmpeg, midi, and opus modules 2022-11-10 14:44:16 +00:00
decoder_opus Add set -eu to all shell scripts 2022-11-22 10:11:32 +00:00
decoder_vp9 Add set -eu to all shell scripts 2022-11-22 10:11:32 +00:00
effect Add the processor, GLEffect, texture and bitmap overlays 2022-12-12 10:38:59 +00:00
exoplayer Fix TextRenderer exception when a subtitle file contains no cues 2022-12-12 11:05:49 +00:00
exoplayer_dash Add missing IntDef on MediaSource.Factory.getSupportedTypes overrides 2022-11-10 14:56:54 +00:00
exoplayer_hls Refactor transformation completion 2022-11-22 09:44:47 +00:00
exoplayer_ima Merge pull request #10799 from OxygenCobalt:id3v2-multi-value 2022-11-29 18:35:59 +00:00
exoplayer_rtsp Add missing IntDef on MediaSource.Factory.getSupportedTypes overrides 2022-11-10 14:56:54 +00:00
exoplayer_smoothstreaming Add missing IntDef on MediaSource.Factory.getSupportedTypes overrides 2022-11-10 14:56:54 +00:00
exoplayer_workmanager Reformat some javadoc 2022-02-18 14:54:02 +00:00
extractor Split SubripDecoder and ParsableByteArray tests 2022-12-12 10:57:18 +00:00
session Write media type with a custom key to legacy components. 2022-12-12 11:02:38 +00:00
test_data Make sure that the sample pipeline data is processed regularly. 2022-12-12 11:01:36 +00:00
test_exoplayer_playback Fix instrumentation tests not working via Gradle 2022-09-30 18:03:11 +00:00
test_session_common Migrate BROWSER_ROOT_HINTS_KEY_ROOT_CHILDREN_SUPPORTED_FLAGS to Media3 2022-11-24 14:38:41 +00:00
test_session_current Write media type with a custom key to legacy components. 2022-12-12 11:02:38 +00:00
test_utils Ensure messages sent on a dead thread don't block FakeClock execution 2022-11-29 18:34:44 +00:00
test_utils_robolectric Remove flakiness from DefaultAnalyticsCollectorTest 2022-11-29 18:31:15 +00:00
transformer Make sure that the sample pipeline data is processed regularly. 2022-12-12 11:01:36 +00:00
ui Fix gradle build 2022-12-12 10:51:03 +00:00
ui_leanback Refactor transformation completion 2022-11-22 09:44:47 +00:00