WebRTC to render H.264 video streams - html

I am developing a web application where I need to integrate H.264 UDP Streams. I am currently using HTML5. I want to know if I can do the same using WebRTC before I proceed.

WebRTC has lots of code related to h.264 decoding and rendering (i.e. here is WebRTC calling Mac APIs).
However, WebRTC is a monolithic piece of code, in that the networking and decoding are tied together. I don't believe you can build your own networking component, and then give the h.264 stream to WebRTC to decode and render.

Related

Capture audio stream from NaCl with Web Audio API?

I have a compiled NaCl module that plays audio directly on the speakers. Is it possible to capture the audio buffer with the Web Audio API, or do I need to get the source code for the NaCl module and modify it (and learn Pepper and C++) to achieve this?
Not entirely sure (at all) how NaCl works, but https://github.com/mattdiamond/Recorderjs can be used to capture audio in Web Audio. It seems likely it'd work in this scenario too.

HTML5 <video> tag: RTMP streaming without Flash?

I am building a video-site for long lecture recordings. So a streaming server is a must. We only have to support newest browsers, which support the HTML5 <video> tag. So when the stream is done via RTMP protocol (Red5 server for example), will clients have to have adobe flash installed or is a browser capable of the <video> tag enough?
I think that for a simple video streaming service (for VOD) you are not forced to use a streaming server (like AMS, Wowza, Red5, ...) just a HTTP server (like Apache, nginx, ...) with a good configuration and some special modules (like nginx ngx_http_mp4_module, H264 Streaming Module for Apache, ...) can do the job because it can provide a HTTP stream available for Flash Player and HTML5.
So for your question, you should know that to play an RTMP stream on a browser, you should have Flash Player, HTML5 can not play it. That's why you have to provide a HTTP stream for HTML5 based video player. After that, you can use a Flash to HTML5 fallback or the inverse.
Hope that can help.
In case anyone else ends up here looking for a non-Flash solution for a non-http-based protocol i.e. RTSP (beware that OP asks for RTMP) here's a solution https://github.com/Streamedian/html5_rtsp_player.

How to access video streams which are transferred by WebRTC in Chrome

guys.
I want to access my video streams which are generated by WebRTC in Chrome.
It seems impossible for javaScript to access my streams, am I right?
How to deal with?
How about you start by looking at this very simple tutorial:
http://www.html5rocks.com/en/tutorials/webrtc/basics/
It will teach you the basics of WebRTC web interface, then you can move up from there ;)

How to use Hardware MFT for encoding audio from PCM to AMR in windows phone 8.1?

i need to encode my audio PCM raw stream to AMR. but i didn't find anything much regarding that.i need to know is it possible to use Hardware MFT for encoding and decoding the Audio stream. if yes then how it is possible some idea please.
or any other way to encode Audio Stream from PCM raw to AMR codec?
I posted this question in Microsoft forum and i got the answer, the answer is Microsoft doesn't support in-build AMR codec, to support AMR codec in windows phone we need to use Third Party Codec Library.
The response was:
Unfortunately it doesn't appear that we supply an AMR encoder in box. Because of this you will need to find a 3rd party encoder or use the in box low latency mp4 codec that we do provide.
and then also:
Let me try and clarify. We have limited AMR, 3GP and h.263 support for Windows Phone Silverlight apps. Encoding support for these codecs is not exposed in Runtime apps since we do not provide a default encoding profile implementation. These codecs should only be exposed in Silverlight. There doesn't appear to be a runtime activateable class associated with these codecs so there is no reflection into Media Foundation.

Display RTSP stream in Adobe AIR

I am working on a project that involves displaying video feed from an IP camera using Adobe AIR. I know that Flash does not have a native support of RTSP protocol and therefore I am evaluating all possible routes I can take to solve this issue:
Use Adobe Media Server to convert incoming RTSP stream to RTMP and then use Flash API (NetConnection & NetStream) directly.
Write a custom class to fetch, decode and display the stream in adobe AIR. [I am unable to confirm if this is possible due to insufficient info on the net]
Give up on RTSP and instead fetch JPEG/MJPEG sequence of images and display them in AIR relatively easily but with doubtful live performance. [due to JPEG/MJPEG refresh interval of IP camera and same interval separately in AIR]
Use DirectShow Video Source Filter for JPEG and M-JPEG IP Cameras to process the JPEG/MJPEG stream, create a virtual Webcam device (the filter does this automatically) and then use Camera class to display the video feed in AIR.
Use webcam 7 - A software designed to handle RTSP, JPEG/MJPEG and other stream protocols for many camera brands/models. It installs a driver in system that creates a virtual camera, and that all the other applications can then use as a normal webcam.
Unfortunately this software is buggy and often becomes unstable (could be with my particular camera model only though) and might even crash.
Are there any better, easier options that might not require any third-party software?
EDIT:
In case anybody else bumps into same problem:
As suggested by Rudolfs Bundulis, I decided to write a NativeProcess (ANE) that uses FFMPEG to fetch the RTSP stream data, transcode it, and feed it to Flash player.
You might want to look at these for more specific steps:
http://www.purplesquirrels.com.au/2013/02/converting-video-with-ffmpeg-and-adobe-air/
https://www.youtube.com/watch?v=6N7eN9wvAGQ
Take the route described in option 2 - write a Adobe AIR native extension (ANE) that uses FFMpeg to handle the RTSP stream, decode it and pass the RGB data back to AIR for rendering. The hardest part would be compiling FFmpeg if you need cross platform functionality, however, since you mention DirectShow that is Windows only, then I assume you are bound to Windows. Zeranoe provides prebuild FFmpeg libraries for Windows, Stackoverflow has a lot of topics on decoding a stream using FFmpeg and then all you need is a callback to AIR and you're good.