Issue description
When trying to play the .ts file sent via email, the player goes to prepared state but doesn't start playing anything. If we stream the .ts file by tsplay as a UDP multicast, the player won't throw any error. If we try playing the .ts file directly from the device, we get OutOfMemoryError after a few seconds. We've tried setting the FLAG_ALLOW_NON_IDR_KEYFRAMES and FLAG_DETECT_ACCESS_UNITS flags but it didn't have any effect.
12-31 05:27:09.890 5731 5731 E EventLogger: internalError [11.40, 0.00, window=0, period=0, loadError]
12-31 05:27:09.890 5731 5731 E EventLogger: com.google.android.exoplayer2.upstream.Loader$UnexpectedLoaderException: Unexpected OutOfMemoryError: Failed to allocate a 65548 byte allocation with 1904 free bytes and 1904B until OOM
12-31 05:27:09.890 5731 5731 E EventLogger: at com.google.android.exoplayer2.upstream.Loader$LoadTask.run(Loader.java:409)
12-31 05:27:09.890 5731 5731 E EventLogger: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1113)
12-31 05:27:09.890 5731 5731 E EventLogger: at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:588)
12-31 05:27:09.890 5731 5731 E EventLogger: at java.lang.Thread.run(Thread.java:818)
12-31 05:27:09.890 5731 5731 E EventLogger: Caused by: java.lang.OutOfMemoryError: Failed to allocate a 65548 byte allocation with 1904 free bytes and 1904B until OOM
12-31 05:27:09.890 5731 5731 E EventLogger: at com.google.android.exoplayer2.upstream.DefaultAllocator.allocate(DefaultAllocator.java:102)
12-31 05:27:09.890 5731 5731 E EventLogger: at com.google.android.exoplayer2.source.SampleQueue.preAppend(SampleQueue.java:626)
12-31 05:27:09.890 5731 5731 E EventLogger: at com.google.android.exoplayer2.source.SampleQueue.sampleData(SampleQueue.java:562)
12-31 05:27:09.890 5731 5731 E EventLogger: at com.google.android.exoplayer2.extractor.ts.MpegAudioReader.readHeaderRemainder(MpegAudioReader.java:192)
12-31 05:27:09.890 5731 5731 E EventLogger: at com.google.android.exoplayer2.extractor.ts.MpegAudioReader.consume(MpegAudioReader.java:98)
12-31 05:27:09.890 5731 5731 E EventLogger: at com.google.android.exoplayer2.extractor.ts.PesReader.consume(PesReader.java:136)
12-31 05:27:09.890 5731 5731 E EventLogger: at com.google.android.exoplayer2.extractor.ts.TsExtractor.read(TsExtractor.java:325)
12-31 05:27:09.890 5731 5731 E EventLogger: at com.google.android.exoplayer2.source.ExtractorMediaPeriod$ExtractingLoadable.load(ExtractorMediaPeriod.java:898)
12-31 05:27:09.890 5731 5731 E EventLogger: at com.google.android.exoplayer2.upstream.Loader$LoadTask.run(Loader.java:379)
12-31 05:27:09.890 5731 5731 E EventLogger: ... 3 more
Also, regarding MPEG-TS content in general, we've been having issues with playing some content. From our experience, ExoPlayer is usually able to play about 90% of streams we encounter but we're often not sure why the problematic streams are problematic. Do you have any advice on what to pay attention to when debugging this or on what is ExoPlayer sensitive to?
Thank you.
Reproduction steps
Either play the .ts file directly using FileDataSource and ExtractorMediaSource or stream the .ts file using tsplay and play the stream using UdpDataSource and ExtractorMediaSource.
Link to test content
Sent via email
Version of ExoPlayer being used
ExoPlayer 2.9.0
Device(s) and version(s) of Android being used
Amlogic S905X, 1GB RAM, Android 6.0.1
HiSillicon Hi3798M V200, 2GB RAM, Android 8.0
A full bug report captured from the device
Sent via email (both when using FileDataSource and when using UdpDataSource)
Issue description
When trying to play the .ts file sent via email, the player goes to prepared state but doesn't start playing anything. If we stream the .ts file by tsplay as a UDP multicast, the player won't throw any error. If we try playing the .ts file directly from the device, we get
OutOfMemoryErrorafter a few seconds. We've tried setting theFLAG_ALLOW_NON_IDR_KEYFRAMESandFLAG_DETECT_ACCESS_UNITSflags but it didn't have any effect.Also, regarding MPEG-TS content in general, we've been having issues with playing some content. From our experience, ExoPlayer is usually able to play about 90% of streams we encounter but we're often not sure why the problematic streams are problematic. Do you have any advice on what to pay attention to when debugging this or on what is ExoPlayer sensitive to?
Thank you.
Reproduction steps
Either play the .ts file directly using
FileDataSourceandExtractorMediaSourceor stream the .ts file using tsplay and play the stream usingUdpDataSourceandExtractorMediaSource.Link to test content
Sent via email
Version of ExoPlayer being used
ExoPlayer 2.9.0
Device(s) and version(s) of Android being used
Amlogic S905X, 1GB RAM, Android 6.0.1
HiSillicon Hi3798M V200, 2GB RAM, Android 8.0
A full bug report captured from the device
Sent via email (both when using
FileDataSourceand when usingUdpDataSource)