ExoPlayer を使用して AAC ストリームを再生しようとしています。ビルドしたMediaPlayerを使用していたのと同じ問題が発生しています.KitCatで起動するのに15〜20秒かかります(おそらく他のバージョンでも同じことが起こりますが、現在テストするものはありません).
ExoPlayer では、バックグラウンドで何が起こっているかについての情報を得ることができました。
、メソッドMediaExtractor.getDataSource()
でフローがスタックするFrameworkSampleDataSource
prepare
extractor = new MediaExtractor();
extractor.setDataSource(context, uri, headers);
readAt
ログには、メソッドのタイムアウトに関する何かが記載されています
01-12 12:07:03.458 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ mDisconnectAtHighwatermark = 0, cacheConfig is NULL(1)
01-12 12:07:03.463 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: mIsMetadataRetriever == 0
01-12 12:07:03.463 4537-4615/com.example.claudio.exopla I/ChromiumHTTPDataSource﹕ readAt offset =0 , mCurrentOffset = 0 size = 65536
01-12 12:07:04.298 4537-4615/com.example.claudio.exopla D/HTTPBase﹕ [1] Network BandWidth = 0 Kbps
01-12 12:07:04.298 4537-4615/com.example.claudio.exopla D/NuCachedSource2﹕ Remaining (64K), HighWaterThreshold (20480)
01-12 12:07:04.298 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: waiting end ( player case )
01-12 12:07:04.298 4537-4615/com.example.claudio.exopla I/ChromiumHTTPDataSource﹕ readAt offset =65536 , mCurrentOffset = 65536 size = 65536
01-12 12:07:04.298 4537-4584/com.example.claudio.exopla V/ChromiumHTTPDataSource﹕ mContentSize is undefined or network might be disconnected
01-12 12:07:04.298 4537-4584/com.example.claudio.exopla V/ChromiumHTTPDataSource﹕ mContentSize is undefined or network might be disconnected
01-12 12:07:04.323 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: mIsMetadataRetriever == 0
01-12 12:07:06.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: waiting end ( player case )
01-12 12:07:06.328 4537-4584/com.example.claudio.exopla E/NuCachedSource2﹕ readAt:Timeout ( player case )
01-12 12:07:06.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: mIsMetadataRetriever == 0
01-12 12:07:08.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: waiting end ( player case )
01-12 12:07:08.328 4537-4584/com.example.claudio.exopla E/NuCachedSource2﹕ readAt:Timeout ( player case )
01-12 12:07:08.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: mIsMetadataRetriever == 0
01-12 12:07:10.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: waiting end ( player case )
01-12 12:07:10.328 4537-4584/com.example.claudio.exopla E/NuCachedSource2﹕ readAt:Timeout ( player case )
01-12 12:07:10.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: mIsMetadataRetriever == 0
01-12 12:07:12.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: waiting end ( player case )
01-12 12:07:12.328 4537-4584/com.example.claudio.exopla E/NuCachedSource2﹕ readAt:Timeout ( player case )
01-12 12:07:12.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: mIsMetadataRetriever == 0
01-12 12:07:14.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: waiting end ( player case )
01-12 12:07:14.328 4537-4584/com.example.claudio.exopla E/NuCachedSource2﹕ readAt:Timeout ( player case )
01-12 12:07:14.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: mIsMetadataRetriever == 0
01-12 12:07:16.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: waiting end ( player case )
01-12 12:07:16.328 4537-4584/com.example.claudio.exopla E/NuCachedSource2﹕ readAt:Timeout ( player case )
01-12 12:07:16.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: mIsMetadataRetriever == 0
01-12 12:07:18.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: waiting end ( player case )
01-12 12:07:18.328 4537-4584/com.example.claudio.exopla E/NuCachedSource2﹕ readAt:Timeout ( player case )
01-12 12:07:18.328 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: mIsMetadataRetriever == 0
01-12 12:07:18.413 4537-4615/com.example.claudio.exopla D/HTTPBase﹕ [2] Network BandWidth = 70 Kbps
01-12 12:07:18.413 4537-4615/com.example.claudio.exopla D/NuCachedSource2﹕ Remaining (127K), HighWaterThreshold (20480)
01-12 12:07:18.413 4537-4615/com.example.claudio.exopla D/NuCachedSource2﹕ readInternal - late!!!
01-12 12:07:18.418 4537-4584/com.example.claudio.exopla I/NuCachedSource2﹕ readAt: waiting end ( player case )
01-12 12:07:18.418 4537-4615/com.example.claudio.exopla I/ChromiumHTTPDataSource﹕ readAt offset =131072 , mCurrentOffset = 131072 size = 65536
01-12 12:07:18.423 4537-4584/com.example.claudio.exopla E/tmiMPEG2TSExtractor﹕ SnifftmiMPEG2TS @LINE=1372
MediaPlayer にも同様の問題があるため、これはバッファリングに関連するものである可能性があると思います。これは実際のデバイスでのみ発生し、エミュレータはすぐに起動します。