I'm searching for a web video player. It needs to be free and for commercial use. It shouldn't not be Flash-based because iOS doesn't support it. It should also support streaming and MPEG-4, AVI, etc.
A pure Javascript library GUI controls (play, plause, ..) for data streams.
you can find here https://github.com/romsson/StreamPlayer
For more detail read here https://github.com/romsson/StreamPlayer/wiki
Related
I have a web program which makes use of Web Audio API. The issue here is that i want to make it compatible for IE. Is there any alternate for the Web Audio API, so that i can make the same code run on IE specifically?
What are your needs? If you need to do dynamic synthesis, audio routing, etc, you will only be able to achieve that with the Web Audio API, so your IE users are out of luck.
However, if all you need to do is play audio files, then I would recommend that you use howler.js. Howler has great compatibility across different browsers and operating systems, including various versions of IE.
Microsoft have been working on implementing the web audio API, it looks like a preview implementation is available. https://status.modern.ie/webaudioapi If you can wait until the next version of IE which I believe is expected to be released with Windows 10, which should be out this year IIRC, it may not be worth taking the time to implement an alternative.
That said, to answer your question, there's no way that I could find to generate audio with an oscillator in the web without the Web Audio API other than writing flash code, which has its own major disadvantages.
Minor note: you could possibly hack the html5 audio node to play back audio buffers that you generate in javascript code, but keeping everything in sync and preventing jumps in the waveform would be an awful task.
I understand that the best bet when streaming a video as a source in an HTML5 tag would be .mp4. But let's say that I have a source that only outputs fragmented to an ism/manifest.
Is there any way at all, whether through other libraries or messy hacks, that I can bring this video into something rendered as a tag onscreen? The closest I have found is Walkthrough: Building Your First HTML5 Smooth Streaming Player because it allows this to be done - but I neither have Windows 8, or want to have this running a server capable of .NET. I was hoping there was something, messy or not, that I could achieve this with entirely within javascript and executable locally without a deploy.
Thanks
Firstly, W3C does not provide a standard for adaptive bitrate streaming, yet. So for the time being most browsers only support simple progressive download playback.
Hence, there is no JS implementation of a Smooth Streaming player and Microsoft is not working on one, as far as I know.
The example you provide uses the "Microsoft Smooth Streaming Client SDK Beta 2 for Windows 8" which is a C++ library and is only available for Windows Store Apps development. It has nothing to do with browsers.
So, unfortunately this is not yet possible. Even more, I doubt that this will ever happen, because everybody is waiting for MPEG DASH to be finalized.
UPDATE.
Please, notice that you always can use Siverlight application for playing SmoothStreaming. The referenced HTML5 Player framework is capable of falling back to Silverlight.
no luck for Microsoft Smooth Streaming, but regarding MPEG-DASH which is similar (see http://blog.johndeutscher.com/2013/06/10/mpeg-dash-preview-from-windows-azure-media-services):
"Dash.js is permissively licensed (under the BSD license) and can therefore be studied and reused by anyone seeking to provide their own DASH-AVC/264 compliant player. The goal is to make it easier for third-parties to build adaptive streaming video players."
http://msopentech.com/blog/2013/06/20/ms-open-tech-contributes-to-open-source-adaptive-streaming-video-player/
also see:
https://dvcs.w3.org/hg/html-media/raw-file/tip/media-source/media-source.html
which is required for Dash.js
I'm teaching kids how to add audio to their JavaScript games and webpages. I knew about the HTML5 Audio API and am just now learning about the issues around the various browsers (IE surprisingly doesn't support WAV at all, etc).
However, apparently there's a new Web Audio standard I was unaware of. Chrome fully supports it. Mozilla states the following about Web Audio and Firefox:
Firefox currently supports the incompatible, Mozilla-specific Audio
Data API, but it is marked as "deprecated" in favor of the W3C
standard. Work has started to support the new Web Audio API in
Firefox.
caniuse.com reports the following about support for Web Audio API.
I don't mind at all forcing the kids to use Google Chrome for development and sound not working in many other browsers. However, I don't want to be teaching them something that will not be in other browsers in the future.
I'm also reading about a possible alternative to Web Audio called MediaStreaming... Which is the future that I should be teaching?
Strictly speaking, there's really no HTML5 Audio API. But HTML5 did introduce the <audio/> element, which is great for simple use-cases.
If you need high-precision timing, or the ability to perform DSP -- I'd go with the Web Audio API. It's still a draft as far as the W3C is concerned, but it seems fairly clear that this is the direction they're going in: http://www.w3.org/2011/audio/wiki/PubStatus
There is no promise that the web audio API will be in all browsers but it is available in Chrome,Safari,and supposedly scheduled for Firefox. Opera has just changed their engine to webkit which is the engine used for the current batch of Web Audio API supporting browsers.
Internet Explorer is completely up in the air.
If all you need to do is play audio files, I would strongly recommend using howler.js. It doesn't have a ton of features, but it is very reliable, and works well across browsers.
The Web Audio API is definitely 'the future' of audio on the web, but it can be pretty complicated, especially if you're trying to teach it to children.
I read somewhere that microsoft is also getting engaged in the web audio api and others
Also some features like capturing audio are only supported by canary or has this changed lately? When will the entire API be supported by the standard chrome webbrowser? Another problem I had with the audio API is that when you have to do some calculations for DSP as Kevin Ennis mentioned, then javascript has problems to do so and your browser crashes. I tried to figure out why it crashes but all I could find is that javascript is not the rights choice for heavy calculations. So as far as web audio API supporting DSP I'm not convinced.
I think it will still take a lot of time since you can create a website that uses web audio API and that will be supported in a lot of browsers and that will not crash randomly. But there is not real other choice for the moment so in the future I am guessing that more and more browsers will start supporting it.
If you are expecting the game should run only in the modern browsers you can checkout the audio library musquito. It's relatively new and it's completely based on Web Audio API.
musquito also supports audio sprites that helps very much in games.
If you are looking for a fallback mechanism for older browsers then howler.js is a good option.
[Disclaimer: I'm the creator of musquito]
Is it possible to play H.264 HD video in an HTML/Javascript (no Flash) AIR app with hardware acceleration support? I can't seem to find any resources or tutorials.
I've been able to play FLVs using the AIR Javascript API, but with mediocre performance; and I'd rather use H.264 anyway.
Thanks,
Wayne
If I'm not mistaken (I'm having similar problems), AIR simply doesn't support the tag.
You can use the netstream class and mp4 video files
I am a little new to embedding videos on a website. What is the best way to go about it? I just started reading up on it.
I read that I should use HTML5 and the browser's native player. -- Does anyone know of a javascript library that will use the browser's player and detect if the browser is not using HTML5 to downgrade to a flash player?
As far as encoding what is the best approach? I am planning on writing a little console app to use FFMPEG to convert the videos. But what encoding should I use? I heard H.264 is promising? But
This is what you're looking for: http://videojs.com/
Encoding wise, I think H.264 and WebM is a wise choice. That way you'll satisfy all modern browsers and mobile devices (incl. iOS and Android), and only fall back to Flash for older, pre-HTML5 browsers (and FF 3.6, which only supports Theora.)
The DIY approach would be to use the Video For Everybody embed code. That will lead with HTML5 video and fallback to flash.
Then for video encoding, you can use FFmpeg like you said.
To make your life easier, you should check out VideoJS for your HTML5 video player. It handles a lot of cross browser issues and some extra features that browsers don't support yet.
For video encoding, if you're planning to use FFmpeg specifically for automating encoding, you should check out Zencoder's video encoding API. It could save you some set up time and compatibility issues.
For codecs, #1 priority should be h.264, specifically using the baseline profile so it will work on smartphones. After that, ogg and webm are both good choices. WebM is higher quality for file size, but Ogg can be viewed by way more users because older version of Firefox support it. And just to note, if you only do h.264, the Video For Everybody code won't fallback to Flash in Firefox and Opera (that don't support h.264) so you'll need to use a player like VideoJS.
Use Handbrake for video encoding, especially for HTML 5 support.
HTML 5 is an awesome way of embedding video, however it hasn't been standardized yet. You definitely want to use it if you're supporting iOS devices, as they of course don't support Flash which is the most mainstream way of embedding video.
HTML5 is pretty awesome because this is how simple it is:
<video src="video.m4v" />
Here is a fantastic link you will find useful:
http://www.robwalshonline.com/posts/tutorial-serving-html5-video-cross-browser-including-ipad/
I read that I should use HTML5 and the
browser's native player
Which idiot told you that? Given that you will loose out on a significant portion of the client population you either run a monoculture of HTML 5 browsers, of whoever said that should be serving burgers at McDonalds, not give advice to people. HTML 5 and the integrated player are nice, but not there yet for the general public. In a couple of years, yes. Now - if I hire a web company for putting videos on a website and they do that, they get sued for gross neglect and incompetence.
Today, playback is mostly flash - that has a high penetration. A flash video player is also what sites like youtube currently use. If you go for less (penetration), Silverlight is very good and has the complete backend infrastructure.
I heard H.264 is promising?
So what? FIRST you need to fix the playback side, then you use whatever format is most efficient given your playback decision.