【问题标题】:android playing audio stream to default or installed music playerandroid将音频流播放到默认或安装的音乐播放器
【发布时间】:2023-04-07 00:04:02
【问题描述】:

我正在开发一个应用程序,我可以在其中流式传输来自 http get 请求的音频并将其播放到默认的 android 音乐播放器或已安装的音乐播放器?我不知道该怎么做? 谢谢。

【问题讨论】:

    标签: android


    【解决方案1】:

    这样做

    Uri uri = Uri.parse("http://www.example.com/file.mp3");
                    Intent intent = new Intent(Intent.ACTION_VIEW, uri);
                    startActivity(intent);
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-09-18
      • 1970-01-01
      • 2012-02-12
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多