play youtube music in application - c#

Does anyone know how to play music from youtube in my c# .net 4.0 app ? I've installed all the apis and sdks from google but i can't seem to find a tutorial that lets me play music in my desktop app .
regards,
Alexandru Badescu

If it's an asp.net application, you can just embed an object tag in your markup. Check out the "<embed>" button to get the tag info for an individual video.
If it's a Windows Forms or WPF desktop application, why not just embed a browser control with the same tag?
Either way, you should be able to just make the object tag invisible and still be able to hear the music.

Here's a tutorial on how to put youtube videos into an MVC app it should help.
http://webpangea.blogspot.com/2009/12/youtube-ms-mvc-and-jquery.html

Related

Watching full-screen videos using C# Web Browser

I'm currently working with Visual Studio and Windows Forms. I want to be able to watch full-screen videos from sources such as Youtube and Vimeo.
I am attempting to do this with a Web Browser but I get issues where the web browser opens YouTube and attempts to download something and Vimeo reports that there could be an issue and refuses to play the video. I already know the URL's of each video as they are responses to inputs.
What would be the best way to watch videos using a Windows Form?
At the moment I am currently just using;
webBrowser1.Navigate("http://www.youtube.com")
You need to embed the video on a web browser control...
check out the following thread on MSDN
I was plagued with the issue that my browser did not support HTML5, although I had IE 11 installed and it did not go away.
I found that using a Shockwave Flash Object was the best method to display movies/youtube videos. I simply added the component to the form and entered the desired movie and worked as intended, I'll use web browsers for non-media content.

Is there a Webbrowser control that supports html5 video (WebRTC) available for .Net?

I was looking for a way to embed a page that hosts WebRTC video such as the demo from http://www.webrtc.org/demo into a WinForms app so the user doesn't need to install nor launch any external browsers that may contain toolbars, etc, I looked into a few components such as GeckoFX and WebKit.Net but they fail to load the webcam video.
Do you know of any hack or other project that may support WebRTC inside .Net?
Thanks a lot
Chromium Embedded Framework claims to support WebRTC (I haven't confirmed it myself).
https://code.google.com/p/chromiumembedded/
http://en.wikipedia.org/wiki/Chromium_Embedded_Framework
WebRTC is supported by Mozilla Firefox:
http://www.webrtc.org/
If you want to embed Firefox in you project you can easily embed GeckoFX web browser control in your Windows Forms application.
The GeckoFX engine (Mozilla Firefox) says it can use WebRTC. This seem to be right (as far as I have seen yet) but there seem to be a problem with some parts of it. I'm using it actual for WebRTC and have a problem with the video part - see here: Embedded GeckoFx in C#.NET - WebRTC Video not working

how to embed vlc media player into my c# windows form app?

I know how to use windows media player in my app but it doesn't work for some files.I have search the web but found nothing that could be understood about using vlc in form.Could sb help me step by step to do this please?Thanks
http://sourceforge.net/projects/libvlcnet/
http://forum.videolan.org/viewtopic.php?f=32&t=58438
NET wrapper for VLC media player. This library allows you to use libvlc from .NET code without dll imports. Simple and easy to use for playing, streaming, transcoding of video streams. Visit the home page for more info.

Embed a windows media player in a web page during runtime in c# and asp.net

i want to embed windows media player in my own created web page. can any one please guide me how can i do it in c# and Asp.net. that also should be supported in all browsers.
Thanks in advance,
Arun
It is not possible to embed Windows Media Player on non-Windows browsers.
You should use the HTML5 <video> tag, with a Flash fallback.
Have a look at this page. The procedure should be the same for ASP.NET also.
As SLaks suggested explore the HTML5 video tag option also. Both has its advantages and disadvantages, your target audience should drive which option you go with(if you have a lot of IE6/7/8 users, HTML5 wont work for them).

Windows Form Application Inside An ASP.NET Page?

I have a game I made in windows form and an asp.net website(with a masterpage)
I made a new page in the website called game.aspx and I want that users could play the game inside the website (inside a frame, not another window)
It is possible to host a WinForms user control in a web page, but it is only supported in Internet Explorer, and even there the support is poor.
I would rather suggest that you package the game as a ClickOnce application that you deploy from your web site.
Edit:
If you REALLY want to do it you will find many examples on the web. Try this google search: http://www.google.com/search?q=user+control+host+winforms+web+page+html
This article from codebetter.com looks interesting for example:
http://codebetter.com/petervanooijen/2007/06/18/including-a-winforms-user-control-in-an-asp-net-web-page/
If the game is HTML/JavaScript based then you're all set. But if the game is written in WinForms there is no way to host it from within a webpage without it being installed on the client's machine and using some kind of container (like ActiveX) and some fancy footwork.
You probably want to look at Silverlight or Flash or even HTML5. Implement your game in one of those and it can be played inside the client's browser.

Categories