安卓无法玩ogg

发布于 2024-11-10 01:16:03 字数 646 浏览 6 评论 0原文

有人知道这是什么意思吗? ogg是用phonegap的Meda播放的,它使用MediaPlayer

05-26 15:41:50.007  1160  3631 E AudioFlinger: no more track names available
05-26 15:41:50.007  1160  3631 E AudioTrack: AudioFlinger could not create track, status: -12
05-26 15:41:50.007  1160  3631 E AudioSink: Unable to create audio track
05-26 15:41:50.007  1160  3631 E VorbisPlayer: mAudioSink open failed

,谢谢!

编辑:

new Media('/android_asset/www/sounds/0.mp3',
        function() {
        //alert("playAudio():Audio Success");
    },
        function(err, arg) {
            alert(err + ' ' + arg);
    }).play()

does somenone knows what this means?
the ogg is played with phonegap`s Meda, which uses MediaPlayer

05-26 15:41:50.007  1160  3631 E AudioFlinger: no more track names available
05-26 15:41:50.007  1160  3631 E AudioTrack: AudioFlinger could not create track, status: -12
05-26 15:41:50.007  1160  3631 E AudioSink: Unable to create audio track
05-26 15:41:50.007  1160  3631 E VorbisPlayer: mAudioSink open failed

thanks!

edit:

new Media('/android_asset/www/sounds/0.mp3',
        function() {
        //alert("playAudio():Audio Success");
    },
        function(err, arg) {
            alert(err + ' ' + arg);
    }).play()

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

随心而道 2024-11-17 01:16:03

我有 Ogg Vorbis 音乐文件,内部 Android 播放器无法播放,我发现删除文件中嵌入的所有标签可以解决问题。可变比特率和高比特率对我来说似乎不是问题。问题似乎是,如果 Ogg Vorbis 文件包含某些格式的标签,内部 Android 播放器就会卡住。我还没有确切地弄清楚哪些格式的标签有问题。一些工作。有些则不然。我会继续调查这个问题。

I've had Ogg Vorbis music files that the internal Android player wouldn't play and I've found that removing all the Tags embedded in the file solved the problem. Variable bit rate and high bit rate doesn't seem to be the issue for me. The issue seems to be that the internal Android player chokes if the Ogg Vorbis file contains tags in certain formats. I haven't figured out precisely which tags in which formats are the problem. Some work. Some don't. I'll keep looking into the issue.

孤云独去闲 2024-11-17 01:16:03

According to this post, you need to play ogg files with constant bitrate. Variable bitrate will cause SoundPool to crash.

There is a bug report about the same error message, but a different cause, here: http://code.google.com/p/android/issues/detail?id=13453

独留℉清风醉 2024-11-17 01:16:03

我能够解决这个问题,但这更像是一种解决方法。
对我来说,Android 似乎无法播放比特率太高的 ogg 文件。
我大胆地重新编码了我的 ogg 文件。在 Audacity 的“文件 - 导出 - 选项”下,您可以配置 ogg 质量。我已将质量设置为 0(我没有听到任何差异)。

对于另一首歌,我必须将 ogg 重新编码为 mp3 (48khz),然后再编码回 ogg。

I was able to solve this, but it is more like a workaround.
To me it seems like Android is not capable to play ogg-files which have a too high bitrate.
I re-encoded my ogg-files in audacity. In Audacity under 'file - export - options' you can configure the ogg-quality. I have set the quality to 0 (I do not hear any difference).

For another song I had to re-encode my ogg to mp3 (48khz) and then back to ogg.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文