How to stream audio in Windows Phone 8.1?

I have a Windows Phone Silverlight 8.0 app I want to update to 8.1 using WinRT. It streams audio in the background.  In Silverlight, I used
BackgroundAudioPlayer to set the Track to a Uri.  It's not clear how to do this with
MediaPlayer in WinRT.  I don't think I can just use a Uri.  Instead, I wonder if I have to use
MediaPlayer.SetStreamSource(IRandomAccessStream
stream).  If so, I don't know how to get an IRandomAccessStream from a
Uri.  I want to stream from a Uri on the internet over HTTP, not from a local file. Any help?

Refer following links to stream audio in background in Windows Phone 8.1 Runtime app.
https://code.msdn.microsoft.com/windowsapps/Background-Audio-in-WinRT-344bcf4d
http://blogs.msdn.com/b/johnkenn/archive/2013/12/31/supporting-background-audio-in-your-windows-8-1-app.aspx
Thank you for thinking about my problem. I may be mistaken, but I think the above links refer to Windows 8 apps, not Windows
Phone 8.1 apps. I'm under the impression that background audio is done differently in Windows Phone 8.1 from Windows 8. The
Background Audio Overview for Windows Phone Store apps explains more. 
It's a good overview, but does not explain how to play audio from a stream rather than a file.  That's what I'm stuck on.

Similar Messages

  • How to know whether my Windows Phone 8.1 App is Associated with the store or not?

    How to know whether my Windows Phone 8.1 App is Associated with the store or not? 
    I have an Windows Phone 8 app already in the store , Now i upgraded it to 8.1 it got upgraded to Windows Phone Silverlight 8.1.
    Now iam trying to use Single Sign on feature on this app but it is showing the error message like
    the App is not Configured correctly i followed the process from  Signing users in to OneDrive
    please guide me how to do this?
    Mohan Rajesh Komatlapalli

    You should post to publish forum.

  • How do i get my windows phone to install OSx Maverick if my mute button doesn't turn my screen brightness up?

    How do i get my windows phone to install OSx Maverick if my mute button doesn't turn my screen brightness up?

    A little clarification, you're trying to install mavericks on your windows phone?

  • How to sync a Lumia Windows Phone with Outlook

    Hi
    Like all I see I also bought a windows 800 on the basis that all our team of 50 would change from Iphones to windows so we could sync with our outlook which is not server based but we each run our own outlook folders but no there is no outlook sync.   Yes you can copy to the live account and then use that as your main calendar but who wants to do that?
    I asked and was told specifically that it would sync with outlook so the Carephone Warehouse guy either lied or did not know his stuff ( I know what my guess is!)    Amazingly my wife's samsung galaxy using Android does sync.
    If you can tell me how I can synchronise my windows phone with my Outlook without exporting and importing CSV and ICS files then please do so.
    Moderators note: changed thread title to reflect subject. Moved from another thread.

    Hi wobblybob,
    Welcome to the forum and thanks for posting!
    When you are told you can sync a Windows Phone with Outlook that would be correct. What you are really asking is 'can I connect my Lumia to the PC with the USB cable and sync with Outlook offline'. The answer to that would be no.
    How you sync with Outlook can be answered in a short and long version. The long and extensive version can be found here. The short version is:
    For Outlook 2003 and 2007 install the Outlook Hotmail connector and setup an account for your  LiveID, for Outlook 2010 just setup the account and it will prompt you to install the connector. A step by step guide can be found here.
    Hope this helps, let us know how you get on!
    Kosh
    Press the 'Accept As Solution' icon if I have solved your problem, click on the Star Icon below if my advice has helped you!

  • How is SQLite used for windows phone 8.1 in Visual Studio2013

    Hi, 
           I'm developing app on Windows 8.1 currently. Can any one please help me with the steps to proceed so that I can create a database using SQLite for windows phone 8.1 through Visual Studio2013.

    Hi SwetaSinha,
    Thank you for posting in MSDN forum.
    Since this forum is to discuss: Visual Studio WPF/SL Designer, Visual Studio Guidance Automation Toolkit, Developer Documentation and Help
    System, and Visual Studio Editor.
    Based on your issue, if you want to know how to create a database using SQLite, I suggest you can ask this issue directly to the  SQLite official website:
    http://www.sqlite.org/support.html, maybe you will get better support.
    In addition, since the SQLite is a extension tool for the Windows Phone 8.1, so I suggest you can post this case to the SQLite for Windows Phone 8.1:https://visualstudiogallery.msdn.microsoft.com/5d97faf6-39e3-4048-a0bc-adde2af75d1b,
    and then click “Q AND A”, you will get better support there.
    Thanks for your understanding.
    Best Regards,
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • How to stream audio/vide​o files on bb playbook and create different play lists from another pc and/or external hard disk drive connected with a share router

    hi guys
    i wish to use my external hard disk drive (1tb) connected with a belkin share router as main storage drive and stream audio/ video and other files on bb playbook through wifi.
    also wish to create different playlists directly on playbook.
    please tell me guys how can I do it.
    thank you in advance

    Try this...
    http://forums.crackberry.com/blackberry-playbook-f​222/how-stream-video-music-more-your-mac-pc-your-p​...

  • How to stream audio / video in java?

    Hello.
    I would live to develop a java application (JavaEE, with tomcat or JBoss) that could stream audio / video over the Internet, on a controlled matter.
    First, I would have to embed a flash player, correct? Need suggestions on one, paied or free.
    My questions are: How can I have the flash player stream audio to users by downloading it from a java app server, if the user has a session and is logged in, etc? (picture myspace here)
    Also, how do I measure network traffic in Java? (The flash player of each user will stream the songs, I'd like to know how much bandwith is going around).
    The reason that I'm asking this here is because I have no idea of which forum to ask this.
    I have been a Java app developper for the past five years, so coding won't be a problem, I just don't know which API / Frameworks to turn to.
    Thanks for all your help.
    Regard,
    Carlos.

    ragedd wrote:
    First, I would have to embed a flash player, correct?No. You're just taking ideas from other popular streaming sites. It's certainly not a requirement.
    My questions are: How can I have the flash player stream audio to users by downloading it from a java app server, if the user has a session and is logged in, etc? (picture myspace here)The same way you would authenticate any website. Usually a database and a challenge/response. If they're not logged in, then instead of writing out the content, write out a 403 status code (or do something more graceful, such as redirect them to the login page).
    Also, how do I measure network traffic in Java? (The flash player of each user will stream the songs, I'd like to know how much bandwith is going around).Just keep track of how much data you send to the OutputStream.

  • How to get PAID from Windows Phone Store?

    I have more than 300 USD app proceeds in my Windows Phone Dev Account. But I am not getting paid. How to get paid?
    I have also a Windows Store Dev Account. Last month, it reached 200 USD and I got paid. But I am confused about the
    Windows Phone Dev account. It crossed the threshold amount 2 months ago. But I am not seeing any chance to get paid. Is this only happening to me? Or do I have to earn more app proceeds?
    Kindly reply me as soon as possible. Thank you!

    Hello Shahriar,
    To open up a Service Request ticket you can click this link below and then click “Select your type of problem here”. Follow the steps on the next few screens and once
    you have the Service Request number you can post it back into this thread and we can make sure it’s being looked after. The Service Request number should look similar to SRX127xxxxx.
    Where to open up a Service Request ticket
    http://dev.windows.com/en-us/community/support
    Best Regards,
    Joe
    Windows Developer Support
    Send us your feedback about the Windows Platform

  • How to  stream audio/video to real Audio Player

    Hello
    I am planning on doing a project on streaming audio/video onto Real Audio Player . I am very new to JMF . I would appreciate some pointers on how to start off. I ahve read the documents but am not able to get started right .
    I wanted to know the following :
    1. Isnt the RTP streaming streaming for live audio or video ? If I want to stream something which I have stored in my local machine then how do i do it - do i need to use RTP ?
    2. I undertsand that if i need to stream the audio/video file I need to convert it to a format the Real Audio Player supports. How do i go about that ?
    Any help would be greatly appreciated!!!
    Thanks in advance
    Shailaja

    JMF doesn't have any support for Real media. Real has gone open source with their Helix Community, so maybe you could find some useful information there: http://www.helixcommunity.org

  • HT4437 How to stream audio from a Safari web site to Airport Express using Airplay?

    I'm able to stream audio from iTunes to my Airport Express using Airplay, but I can't stream audio from SoundCloud.com or any other system audio (not in iTunes) to the Airport Express. It is my understanding that AirFoil can do the trick but I do not want to spend 25$ if there is another way to do it.
    Thanks in advance.

    Tgara wrote:
    grunta22 wrote:
    I have played around and it's all fixed (not sure what I did and I don't think it was working all along), Tgara, you're right the icon colour has changed to orange for music (but still blue for you tube). 
    Cheers
    Good you got it sorted!
    I was wrong about one thing.   Regardless of how I connect (e.g., wifi or Bluetooth), the Airplay icon in an Apple App turns orange when connected to a device, not blue as I mentioned above.  This is probably why you see blue in the Youtube app.
    OK, I am retracting all my posts about the airplay icon and it's color scheme. 
    Seems as if the airplay icon on the music app is orange, but the airplay icon on the podcast app is blue. There appears to be no rhyme or reason to these color schemes or their significance, so I am abandoning all further speculation. 

  • Low-latency audio on Windows Phone 8 (hint: forget it for now...)

    My business specializes in audio and music apps for the Windows ecosystem. For this new project that I’m considering (a virtual instrument of sorts), I need to achieve the lowest possible audio latency from capture to render.
    A measured latency below 3 ms would be ideal, 20 ms would be ok, and anything above 30 ms would be a deal breaker. And just to be precise about my definition of latency, I’m strictly talking about “mic-to-speaker” latency (includes the processing in-between).
    I’m not talking about “glass-to-speaker” latency, although this topic is also of interest to me.
    I figured that I should be using WASAPI, as this is apparently the API that sits at the bottommost of the audio stack in WinRT / WinPRT. So I spent a couple of days re-familiarizing with C++ (happy to meet an old friend)
    and I coded a prototype capturing, processing and rendering audio using WASAPI having in mind the goal of achieving the lowest possible latency. After trying and comparing various methods, workflows, threading mechanisms, buffer values and mix formats, the
    best I could achieve using WASAPI on Windows Phone was ~140 ms of latency. This is using 3 ms buffers. And although the audio is glitch-free, I could have been using 30 ms buffers and it wouldn’t have made the slightest difference! The latency would still
    be around 140 ms. As I found out, the API/driver is extremely defensive in protecting against audio starvation, so it adds quite a bit of buffering at both ends. This is very unfortunate, because it basically disqualifies real-time audio/musical
    applications.
    I’d love to be able to provide quality audio/musical apps for the platform (both Windows Phone and Windows 8), but right now, this latency issue is kind of a deal breaker.
    I've been pointing out the importance of low latency audio to Microsoft for quite a while, and I know I'm not the only one, and I know a lot of people at Microsoft realize this is important. But in its execution,
    it seems Microsoft constantly fails to deliver a truly low-latency audio stack. In the pre-XP days, I've had talks with the sysaudio devs about this, and I was told, "yeah, we're working on a new architecture that will come out after XP and
    it will solve the latency problem for all audio and musical applications." Fast forward to mid-2010 (pre-Windows Phone 7), and I was still there pointing out the horrible latency figures one would get from the APIs that were about to ship. And
    now that WASAPI is available on WP8 (our best hope yet for low-latency audio), I discover the overly defensive and buffer-happy architecture of WASAPI (even though one of its promises was precisely low-latency audio).
    So, the question is…
    Is Microsoft aware of this issue? If so, is Microsoft giving up and simply conceding the pro-audio territory to iOS? If not, I’d be glad to discuss this issue with an engineer at Microsoft. I’m serious about bringing audio apps
    to the platform. I just need some assurance that Microsoft is taking action on its end, so that I can sync my development with the next product cycle.
    Thanks in advance for any help, advice, or insights!
    /Antoine

    Any update on this issue? Is there a roadmap for a fix?
    I ported a realtime sound analyzing application (requiring both audio input and output) to WinRT and was quite surprised at the high latency from WASAPI. I then searched around and posted some questions regarding this on various MS forums and got to the
    following conclusions based on feedback from people including MVPs and MS employees:
    A lot of those people are under the impression that WASAPI qualifies as a low-latency API.
    Apparently WinRT apps are not supposed to have high CPU usage, and this is purposefully baked into the framework (minimal thread priority control, async/await everywhere which results in thread priority inversion, and other issues).
    Why would anyone ever need high-priority threads? They must use a lot of CPU, right?
    A lot of people think low-latency audio means high CPU usage. You can see where this is going when you look at the previous point.
    Async/Await is being forced down to all levels, even though it should only be used at the UI level. What some people are actually now calling "old-school" multithreading is now being pushed out (lock, etc). Async/Await has horrible overhead and
    results in thread priority inversion amongst other issues. For example, witness that there is no StorageFile.Read, just StorageFile.ReadAsync. Do some IO benchmarks with some of these async methods and you will see some horrible performance compared to desktop
    file IO.
    To get an understanding of what low latency audio means and why it is important, see this video. It compares the latency of Android to iOS using the exact same music app. Ever wondered
    why there are no quality music apps for Android? Well now you know. And then realize that WinRT has
    twice as much latency as Android.
    And if anyone thinks this is a niche use case, consider that Apple created adds showcasing "musicians" playing their iPad "instruments". A use case that is essentially unavailable for WinRT apps. Why would Apple create
    adds for a niche use case?
    This should have been one of the high priority issues solved from the start in WinRT. MS solved this issue in Windows (desktop) long ago, with the ability to get insanely low latency there (0.3 ms in some stress tests,
    see here), even beating out OSX. It is as if there is a new generation of architects at MS that know nothing about this previous work and are doomed to make the same mistakes over again. I really don't
    understand why these pre-existing APIs can't be exposed in WinRT. No need to re-invent the wheel. But I guess it just isn't important enough.
    I find this situation really sad since otherwise it could be a great and powerful platform.

  • How do I upgrade my Windows Phone Silverlight/SQL CE app to Windows 10?

    I have currently a Silverlight app in Windows Phone Store which uses SQL CE database. Data stored in database is very essential and users may not loose it in any situation or they stop using the app.
    I know I could in theory upgrade my Silverlight app to use SQLite, then wait for 6-12 months to be sure that all users have upgraded into this SQLite version and only after that publish my Windows 10 version of the app. But I really would not like to do
    that because waiting for 6-12 months is too long. My app is used maybe 1-2 times a month by an average user, that's why I think minimum of 6-12 months wait time would be necessary.
    I believe many developers have the same issue.
    Is any of these options possible:
    1. Silverlight is still in Windows 10 so the code for reading SQL CE databases still exists there. So Microsoft could easily implement in Windows 10 APIs an utility function something like ExportSqlCeDatabase(DataContext context, string outputFolder)
    which would export all tables in a database to CSV files. Then in my Windows 10 app I could import data from those CSV files into my new SQLite database.
    2. Can I prevent automatic application upgrade from a too old Silverlight app to Windows 10 version? Upgrade should be allowed only if user has first installed the Silverlight upgrade which already uses SQLite database. If an automatic upgrade is performed
    from a too old Silverlight version still using the SQL CE database, all data is lost.
    3. Can Silverlight app access files of another Windows Runtime app (from same publisher) in Windows 10? If this is possible, I could then implement a separate utility application using Silverlight which upgrades the old SQL CE database to SQLite in
    the actual Windows Runtime app by accessing its files (read+write access to other app's files needed). This option would be the worst but better than nothing.

    Take a look at Sam Jawaran's Build session
    Moving to the Universal Windows Platform: Porting an App from Windows 8.1 XAML or Windows Phone Silverlight to Windows 10 tomorrow morning (and available recorded later).
    I don't believe there's a clean way to read the SQL CE database once the app is upgraded to a Windows Runtime app. The best is probably to upgrade your app to convert from SQLCE to SQLite in Silverlight ASAP. That will give some time for customers
    to run it and update their databases before Windows 10 ships and you publish the Windows 10 version of your app.
    --Rob

  • How can i register my Window phone lumia 520

    I have a problem in registration as a window phone developer. What are the steps for register as a window phone developer??

    Hi,
    Find below link to step-by- steps for register as a windows Phone Developer
    [mod: link to spam site deleted]
    Don't
    forget to mark the right answer and vote up if helps you.

  • How do notifications work in Windows Phone 7?

    Android and iOS both now have a "notification center" where all of your missed alerts go and you can see them all in one place. Does Windows Phone 7 have anything like this? Or is it more like the old notification system in iOS?

    Also, when you unlock the phone you get your 'wallpaper'. At the bottom, you'' get set of small  icons with numbers showing list of missed calls etc.
    If you then go to your home screen if you have the main 'calls' and 'messaging' tiles there they too wlll show number of unread items. Opening each will give the details. 

  • How to stream audio w/o connecting AX as gateway?

    Have been struggling with this one for a while – would appreciate any help you might offer.
    I have my MAC connected to my university network from my room. The Univ is fairly strict with network things and so will not allow students to run wireless networks (otherwise I'd happily plug in my Airport Express as the internet gateway and connect my Powerbook through that – we have to give our IT dept the MAC address of our computers and we get assigned a fixed IP address).
    All I want to do is use the AX to play iTunes audio through my stereo. Is there some sort of "standalone" mode for AX that allows me to use it just as a receiver of the audio stream from iTunes? I keep getting the dreaded blinking amber light since it's looking for a network. Seems like there must be a way...
    Thanks in advance
    PowerBook G4   Mac OS X (10.4.9)  

    "Is there some sort of "standalone" mode for AX that allows me to use it just as a receiver of the audio stream from iTunes?"
    Welcome to Discussions, rnorum!
    Yes, but that's still setting up a network between your Mac and your Express/stereo connection. Your AirPort Express does have its own MAC address - its AirPort ID. Every wireless device has a MAC address, even non-Macs have one. If the Univ is fairly strict and maintains the integrity of its network, they'll be able to easily discover any network you setup.
    If you turn on your AirPort and look in your menu bar's AirPort icon and can see no other networks, then it's safe to assume you shouldn't try this - as others will be able to easily discover it. If instead you can see that everyone else has an iTunes network, then ask around to see if they just did it, or went through the proper procedure.
    Assuming that you've already cleared the Express's old profiles by resetting to factory default
    [refer to the last section "How to perform a factory default reset" on this page: http://docs.info.apple.com/article.html?artnum=108044 ]
    you should see the Express's default name (Apple Network ____) in your menu bar's AirPort icon. If you've already connected your stereo to the Express with the proper audio cabling, use the utility "AirPort Setup Assistant" to setup that network. It's wise to give the connection its own name rather than to leave it set on the default network name. The Assistant should see your Express's stereo connection, if not, try again, don't continue on and setup a bogus internet connection. If you do that, you'll just have to again reset the Express:)

Maybe you are looking for

  • Pricing date on sales orders

    Hi Gurus, I have the following requirement: When the user is creating an order and put the Request Delivery Date equal to "tomorrow", the pricing date should NOT be the today's date but it has to be "tomorrow" date. Is there a BADI to be used to reca

  • How to set underlined text in a label

    i want to set text which is underlimned but i am not being able to do that can anyone help thanx

  • Navbar in fluid grid layout??

    I can't for the life of me find anything on changing changing the content and look of the navbar in desktop and mobile view to look different from eachother and fit the browsers properly. If anyone has any links or advice on how to do so please help.

  • Character Encoding Problem RequestDispatcher

    Hi Friends; I have a servlet and I use RequestDispatcher dispatcher = request.getRequestDispatcher(page);                response.setContentType("text/html;charset=UTF-8");                request.setCharacterEncoding("UTF-8");                PrintWri

  • Material ledger - Multilevel price determination

    Hello, When there are transfer postings from Sales order stock to free stock, system has calculated multilevel price differences during settlement. This material is a externally procured material and does not have any BOM. Can some one explain the sc