Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/android/186.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
HLS仅音频流不在Android MediaPlayer上播放_Android_Cordova_Audio_Http Live Streaming_M3u8 - Fatal编程技术网

HLS仅音频流不在Android MediaPlayer上播放

HLS仅音频流不在Android MediaPlayer上播放,android,cordova,audio,http-live-streaming,m3u8,Android,Cordova,Audio,Http Live Streaming,M3u8,我正在使用cordova媒体插件播放纯音频HLS流。HLS流将作为视频元素在chrome浏览器中播放,但不在MediaPlayer类中播放。以下是我的logcat的输出: 07-14 21:19:04.905 780 1346 I MediaFocusControl: AudioFocus requestAudioFocus() from android.media.AudioManager@4bf937corg.apache.cordova.media.AudioHandler$1@

我正在使用cordova媒体插件播放纯音频HLS流。HLS流将作为视频元素在chrome浏览器中播放,但不在MediaPlayer类中播放。以下是我的logcat的输出:

07-14 21:19:04.905   780  1346 I MediaFocusControl:  AudioFocus  requestAudioFocus() from android.media.AudioManager@4bf937corg.apache.cordova.media.AudioHandler$1@269c405 req=1flags=0x0
07-14 21:19:04.905   197  5274 I LiveSession: onConnect http://<suppressed>
07-14 21:19:05.193   197  5274 I LiveSession: #### Starting Bandwidth Switch: -1 => 0
07-14 21:19:05.473   197  5275 I ESQueue : found AAC codec config (48000 Hz, 2 channels)
07-14 21:19:05.643   197  5275 W PlaylistFetcher: MPEG2 Transport stream does not contain video data.
07-14 21:19:05.789   197  5273 D NuPlayerDriver: notifyListener_l(0xb363dba0), (200, 802, 0)
07-14 21:19:05.789  2057  2076 W MediaPlayer: info/warning (802, 0)
07-14 21:19:05.789  2057  2171 D MediaPlayer: setSubtitleAnchor in MediaPlayer
07-14 21:19:05.924   197  5275 W PlaylistFetcher: MPEG2 Transport stream does not contain video data.
07-14 21:19:06.141   197  5275 W PlaylistFetcher: MPEG2 Transport stream does not contain video data.
07-14 21:19:06.194   197  5273 W NuPlayer: Unknown video size, reporting 0x0!
07-14 21:19:06.194   197  5273 D NuPlayerDriver: notifyListener_l(0xb363dba0), (5, 0, 0)
07-14 21:19:06.194   197  5273 D NuPlayerDriver: notifyListener_l(0xb363dba0), (200, 801, 0)
07-14 21:19:06.194   197  5273 D NuPlayerDriver: notifyListener_l(0xb363dba0), (1, 0, 0)
07-14 21:19:06.194  2057  2075 W MediaPlayer: info/warning (801, 0)
07-14 21:19:06.195   197   197 E MediaPlayerService: getDuration returned -2147483648
07-14 21:19:06.195  2057  2171 W MediaPlayer: Stream has no duration and is therefore not seekable.
07-14 21:19:06.195  2057  2171 E MediaPlayer: error (-2147483648, 0)
07-14 21:19:06.195  2057  2171 D AudioPlayer: Send a onStatus update for the new seek
07-14 21:19:06.196  2057  2171 E MediaPlayer: start called in state 0
07-14 21:19:06.196  2057  2171 E MediaPlayer: error (-38, 0)
07-14 21:19:06.196  2057  2171 E MediaPlayer: Attempt to call getDuration without a valid mediaplayer
07-14 21:19:06.196  2057  2171 E MediaPlayer: error (-38, 0)
07-14 21:19:06.197  2057  2171 E MediaPlayer: Error (-2147483648,0)
07-14 21:19:06.197  2057  2171 D AudioPlayer: on completion is calling stopped
07-14 21:19:06.197  2057  2171 E MediaPlayer: Error (-38,0)
07-14 21:19:06.197  2057  2171 D AudioPlayer: on completion is calling stopped
07-14 21:19:06.197  2057  2171 E MediaPlayer: Error (-38,0)
07-14 21:19:06.200  2057  2171 D AudioPlayer: on completion is calling stopped
07-14 21:19:06.495   197  5275 W PlaylistFetcher: MPEG2 Transport stream does not contain video data.
07-14 21:19:13.306   197  5275 W PlaylistFetcher: MPEG2 Transport stream does not contain video data.
07-14 21:19:13.651   197  5275 W PlaylistFetcher: MPEG2 Transport stream does not contain video data.
07-14 21:19:17.576   197  5275 W PlaylistFetcher: MPEG2 Transport stream does not contain video data.
07-14 21:19:24.198   197  5275 W PlaylistFetcher: MPEG2 Transport stream does not contain video data.
07-14 21:19:04.905 780 1346 I MediaFocus控制:来自android.media的AudioFocus请求AudioFocus()。AudioManager@4bf937corg.apache.cordova.media.AudioHandler$1@269c405req=1flags=0x0
07-14 21:19:04.905 197 5274 I LiveSession:onConnect http://
07-14 21:19:05.193 197 5274 I LiveSession:#####启动带宽切换:-1=>0
07-14 21:19:05.473 197 5275 I ESQueue:找到AAC编解码器配置(48000 Hz,2个通道)
07-14 21:19:05.643 197 5275 W播放提取器:MPEG2传输流不包含视频数据。
07-14 21:19:05.789 197 5273 D NuPlayerDriver:notifyListener_l(0xb363dba0),(200802,0)
07-14 21:19:05.789 2057 2076 W MediaPlayer:信息/警告(802,0)
7-14 21:19:05.789 2057 2171 D MediaPlayer:在MediaPlayer中设置Subtitleanchor
07-14 21:19:05.924 197 5275 W播放提取器:MPEG2传输流不包含视频数据。
07-14 21:19:06.141 197 5275 W播放提取器:MPEG2传输流不包含视频数据。
07-14 21:19:06.194 197 5273 W NuPlayer:未知视频大小,报告0x0!
7-14 21:19:06.194 197 5273 D NuPlayerDriver:notifyListener_l(0xb363dba0),(5,0,0)
7-14 21:19:06.194 197 5273 D NuPlayerDriver:notifyListener_l(0xb363dba0),(2008010)
07-14 21:19:06.194 197 5273 D NuPlayerDriver:notifyListener_l(0xb363dba0),(1,0,0)
07-14 21:19:06.194 2057 2075 W MediaPlayer:信息/警告(801,0)
07-14 21:19:06.195 197 197 E MediaPlayerService:getDuration返回-2147483648
07-14 21:19:06.195 2057 2171 W MediaPlayer:流没有持续时间,因此不可查找。
07-14 21:19:06.195 2057 2171 E MediaPlayer:错误(-2147483648,0)
07-14 21:19:06.195 2057 2171 D音频播放器:发送新seek的onStatus更新
07-14 21:19:06.196 2057 2171 E MediaPlayer:在状态0下调用开始
07-14 21:19:06.196 2057 2171 E MediaPlayer:错误(-38,0)
07-14 21:19:06.196 2057 2171 E MediaPlayer:在没有有效MediaPlayer的情况下尝试调用getDuration
07-14 21:19:06.196 2057 2171 E MediaPlayer:错误(-38,0)
07-14 21:19:06.197 2057 2171 E MediaPlayer:错误(-2147483648,0)
07-14 21:19:06.197 2057 2171 D音频播放器:完成后呼叫是否停止
07-14 21:19:06.197 2057 2171 E MediaPlayer:错误(-38,0)
07-14 21:19:06.197 2057 2171 D音频播放器:完成后呼叫是否停止
07-14 21:19:06.197 2057 2171 E MediaPlayer:错误(-38,0)
07-14 21:19:06.200 2057 2171 D音频播放器:完成后呼叫是否停止
07-14 21:19:06.495 197 5275 W播放提取器:MPEG2传输流不包含视频数据。
07-14 21:19:13.306 197 5275 W播放提取器:MPEG2传输流不包含视频数据。
07-14 21:19:13.651 197 5275 W播放提取器:MPEG2传输流不包含视频数据。
07-14 21:19:17.576 197 5275 W播放提取器:MPEG2传输流不包含视频数据。
07-14 21:19:24.198 197 5275 W播放提取器:MPEG2传输流不包含视频数据。
通过cordova媒体插件播放mp3将起作用。我正在尝试播放的特定流端点可以在
http://api.badkitty.co/api/audio-stream/monstercat
。这不是流本身,流的位置是从那里得到的。我无法更改流中的m3u8文件