[UWP] [C#] UWP中的流媒体 [英] [UWP][C#]Stream Media in UWP
问题描述
我正在创建一个UWP应用程序,需要在下载时播放媒体 - 媒体不完整。
我尝试使用下面的代码,但它首先下载了音频然后播放音频..
$
string audioURL =" http://docs.google.com/uc?export = download& id = 0B6u8YFm5Y0GeLXRtd2Z6X0RjNTA" ;;
    myMedia = new MediaPlayer();
myMedia.Source = MediaSource.CreateFromUri(new Uri(audioURL));
myMedia.RealTimePlayback = true;
myMedia.Play();
$
我们将非常感谢任何指导?谢谢你
你好
mp3文件和mp3流之间有区别
你想要的是一个mp3流,但你的音频网址只提供一个mp3文件
br
Andre
I'm creating a UWP app that needs to play media while downloading - the media is not complete.
I tried using below code but it first downloads the audio then plays the audio..
string audioURL = "http://docs.google.com/uc?export=download&id=0B6u8YFm5Y0GeLXRtd2Z6X0RjNTA";
myMedia = new MediaPlayer();
myMedia.Source = MediaSource.CreateFromUri(new Uri(audioURL));
myMedia.RealTimePlayback = true;
myMedia.Play();
Any guidance would be greatly appreciated? Thanks
hello
there is a difference between mp3 file and mp3 stream
what you want is a mp3 stream but your audio URL only provides a mp3 file
br
Andre
这篇关于[UWP] [C#] UWP中的流媒体的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!