×
Namespaces

Variants
Actions

Talk:Video Playback with MediaElement in Windows Phone

From Nokia Developer Wiki
Jump to: navigation, search

Contents

Arkoz84PE - Youtube Videos

I am trying to use a link to a Video on Internet. I already have the videos on YouTube but YouTube links do not work. Is there another internet video page I can use?

Arkoz84PE 02:08, 7 April 2013 (EEST)

Somnathbanik - Compatibility

This article is Compatible for both Windows Phone 7 and Windows Phone 8.

We will update the title accordingly.

somnathbanik 14:40, 5 June 2013 (EEST)

Parth mehta - Source code is not working....

download the code and try to execute but its not working after that i have made one new solution for this demo but it returns me 3113 error in var errorException = e.ErrorException;

i would like to play youtube video's url into windows phone 7.5 . any idea ?

parth mehta 14:40, 6 June 2013 (EEST)

Somnathbanik - @Parth mehta

1. Just to double check I downloaded the code twice, and run on Windows Phone SDK 7.1 and tested on Nokia Lumia 800. All the features are working perfect.

2. Regarding YouTube video, if you just copy/paste the URL from web browser then its expected not to work. You need to probably use YouTube API to get the Mp4/WAV files which I have done here (http://www.developer.nokia.com/Community/Wiki/Streaming_YouTube_videos_using_Qt_Quick_in_Nokia_N9) for 3gp videos. For your reference I have used a latest YouTube video URL in the code and played in default player.

private void button3_Click(object sender, RoutedEventArgs e)

       {
           mediaElement1.Stop();
           MediaPlayerLauncher mediaPlayerLauncher = new MediaPlayerLauncher();
         //  mediaPlayerLauncher.Media = new Uri(@"http://video-js.zencoder.com/oceans-clip.mp4", UriKind.Absolute);
           //mediaPlayerLauncher.Media = new Uri(@"http://r3---sn-q8vpn-cvhe.c.youtube.com/videoplayback?newshard=yes&source=youtube&upn=2sdl0PRdtKA&ratebypass=yes&ipbits=8&sver=3&key=yt1&itag=22&ip=114.79.130.218&ms=au&sparams=cp,id,ip,ipbits,itag,ratebypass,source,upn,expire&mv=m&fexp=912517,923002,900320,916613,929305,900352,924605,928201,901208,929123,929121,929915,929906,925714,929919,929119,931202,928017,912512,912515,912521,906906,904830,919373,906836,933701,926403,912711,930621,935000,929606,910075&mt=1370853679&id=23cb4470c8d5ff31&cp=U0hWRVhSVF9HS0NONl9QTFhCOlJPTDNUNFE1Mk9S&expire=1370876121&signature=B76D9972FEAF2CBD371718BB58A11A0A1B97476A.28323E19C055D899755C6000E5A27C919F88D2E1", UriKind.RelativeOrAbsolute);
           mediaPlayerLauncher.Media = new Uri(@"http://r3---sn-q8vpn-cvhe.c.youtube.com/videoplayback?newshard=yes&source=youtube&upn=2sdl0PRdtKA&ratebypass=yes&ipbits=8&sver=3&key=yt1&itag=18&ip=114.79.130.218&ms=au&sparams=cp,id,ip,ipbits,itag,ratebypass,source,upn,expire&mv=m&fexp=912517,923002,900320,916613,929305,900352,924605,928201,901208,929123,929121,929915,929906,925714,929919,929119,931202,928017,912512,912515,912521,906906,904830,919373,906836,933701,926403,912711,930621,935000,929606,910075&mt=1370853679&id=23cb4470c8d5ff31&cp=U0hWRVhSVF9HS0NONl9QTFhCOlJPTDNUNFE1Mk9S&expire=1370876121&signature=9C6835280D82F2277C7D104D2133A92D5279D875.4E2C17E0B60E49ED9BFF87DBAE29EBD14A0ED5BC", UriKind.RelativeOrAbsolute);
       
         
           mediaPlayerLauncher.Show();
       } 

Please check the supported type (progressive download/ streaming video) of video by the default player and MediaElement on MSDN.

http://msdn.microsoft.com/en-us/library/windowsphone/develop/system.windows.controls.mediaelement.source%28v=vs.95%29.aspx

somnathbanik 11:55, 10 June 2013 (EEST)

Hamishwillee - Thanks Somnath

Great to hear it is all still working!

hamishwillee 05:51, 20 June 2013 (EEST)

Pooja 1650 - Error while playing video locally

Hi Somnath,

Was trying to run the sample demo on Lumia 920 but the video through "Local" button (trying to play video.mp4) wasn't running. I always got Error #3100. Trying to get info about it. Would be great if you can provide some info simultaneously.

Thanks,

Pooja

pooja_1650 (talk) 13:19, 17 July 2013 (EEST)

Somnathbanik - Try this

Hi Pooja,

I couldn't test it as I don't have a phone in hand right now. But for playing video from local folder here is a link

http://msdn.microsoft.com/en-us/library/windowsphone/develop/jj207066%28v=vs.105%29.aspx


Regards

Somnath

somnathbanik (talk) 17:53, 17 July 2013 (EEST)

Somnathbanik - YouTube Videos

Hi Friends,

I am created a new article on YouTube videos, this might be helpful. Please have a look.

http://developer.nokia.com/Community/Wiki/YouTube_Videos_on_Windows_Phone


Regards

Somnath

somnathbanik (talk) 17:17, 23 July 2013 (EEST)

 

Was this page helpful?

Your feedback about this content is important. Let us know what you think.

 

Thank you!

We appreciate your feedback.

×