Closed shamun closed 6 years ago
Its impossible to use RTSP in Google chrome with quality. Are we going to keep NPAPI for future? Else i have to also avoid using the VLC. This way of streaming capture is not real-time lot of delay and lipsync, Chrome/Canary team did a serious bad decision.
/*
$ go build -o id.exe source.go
$ go run source.go
*/
package main
import "os/exec"
import "runtime"
//import "fmt"
func main() {
myos := runtime.GOOS;
myarch := runtime.GOARCH;
var chrome = "";
var tpt = "";
var cmdopen *exec.Cmd;
if myos == "windows" {
if myarch == "386" {
chrome = "C:/Program Files/VideoLan/VLC/vlc.exe";
tpt = "C:/Program Files/Google/Chrome/Application/chrome.exe";
} else {
chrome = "C:/Program Files (x86)/VideoLan/VLC/vlc.exe";
tpt = "C:/Program Files (x86)/Google/Chrome/Application/chrome.exe";
}
cmdopen = exec.Command(chrome, "vlc://quit");
err := cmdopen.Start();
if err != nil {
println("Failed: ", err);
}
cmdopen = exec.Command(chrome, "rtsp://admin:9999@192.168.100.150:8557/h264", ":sout=#transcode{vcodec=theo,vb=1400,fps=30,scale=Auto,acodec=none}:http{mux=ogg,dst=:8081/test}", ":no-sout-keep", ":no-sout-audio", "--one-instance");
err1 := cmdopen.Start();
if err1 != nil {
println("Failed: ", err1);
} else {
println("Success: ", err1);
cmdopen = exec.Command(tpt, "--chrome-frame", "C:/Program Files (x86)/me/vlc.html");
/* vlc.html = show the RTSP stream
<video width="640" height="480" autoplay>
<source src="http://localhost:8081/test" type='video/ogg' />
HTML5 video not supported.
</video>
*/
cmdopen.Start();
}
} else {
// Linux
}
}
Wouldn't a PPAPI VLC Plug-in solve this problem? Seeing NPAPI will be dropped soon?
NPAPI solved this problem to have quality RTSP stream from many cameras such as Lummens, Polycom, LifeSize, Axis by placing the VLC plugin in Chrome/Canary.
But because NPAPI will be removed permanently by Chrome/Canary team we will lose the whole RTSP + some other Streaming features.
The alternative way was to stream it but you can use the above code which is not as good as NPAPI. So i think NodeWebKit also have to think should it be kept or removed.
NPAPI is only the only way to write high-performance imaging applications, since i dont see how Pepper would allow to use features like Memory Mapping, IPC etc.
In our case we would love to do high-performance imaging using NPAPI (basically we render an out-of-process memory map as image into the browser), the only alternative is to stream images one by one into the browser and display e.g. using WebGL (we are experimenting with that, but that includes multiple copies of the rendered image and chrome would even have to garbage collect the websocket message fragments coming it at a couple MB/s)
YES - i agree with you.
Basically RTSP protocol is very standard commonly used everywhere. We have bought very expensive camera's and because it does not work in Chrome/canary natively, we have to return the camera just because of no RTSP compatibility yet available (which is very standard protocol now, applying hacking tricky way to capture such stream cause crash or slow or low quality), each camera's cost above 2 thousand euros.
Its so embarrassing that common RTSP standards cant be captured in Chrome/Canary
Until no solution found for Node-webkit natively.
I am working with Chrome/Canary JNLP to access JavaSE with VLCj wrapper, but unfortunately the VLC nightly only working in Linux to play RTSP stream.
Its a total mess now to make it compatible for Windows 8.1, OSX.
Wouldn't a PPAPI VLC Plug-in solve this problem?
As I know nobody work in this direction.
Maybe somebody know - if it worth trying extend video
tag implementation in NW.js to allow use extern decode engines like libvlc?
does anybody know what the official statement of nwjs is on this topic ? will they drop NPAPI anytime soon ?
btw, #3293
hello
i discuted with the chromium team on irc about this
they told me that for linux it s already totally removed since chromium 35 because it was impossible for them to rewrite chromium with the aura ui and this api
they told me too that ppapi is there but they wish developers stop totally using plugin and use only browser's integrated technologies... so i don t think plugins have a "great futur"
personaly i build node-webkit myself with custom ffmpeg and enable many many more codecs first and just in case i have a modified elements.js html5 player with full ffmpeg live transcoding system so i can do anything i want with any codecs or protocol audio or video :) (little cost with cpu but works very very well)
think it s the best solution
Le 25/03/2015 09:49, matthiasg a écrit :
does anybody know what the official statement of nwjs is on this topic ? will they drop NPAPI anytime soon ?
— Reply to this email directly or view it on GitHub https://github.com/nwjs/nw.js/issues/3241#issuecomment-85934001.
I agree.
Make sense to me too. But we cant drop the ball as easy as it sounds, because there are millions of devices using RTSP protocol for streaming/broadcasting. Today or tomorrow you will get your customer request "CAN WE USE OUR RTSP WITH YOUR NODE-WEBKIT OR CHROME, SADLY YOU HAVE TO SAY {NO}, which i do not like to say."
We cant be so naive and agree to drop the NPAPI just like that!! (which was forever available for such a long time and in almost for every browsers). But yes we can drop it but we need manual/alternative way to embed it in case emergency projects (you never know).
Best alternative would be, if we can at-least use Gstreamer RTSP (Very stable then VLC RTSP i have tested with many many hardwares and found that RTSP compatibility in Gstreamer is better then VLC, maybe NodeWebkit should implement some RTSP stream capture from Gstreamer so that manually we can at-least use it in NW and let Chromium team decide or get less stress for there "having NPAPI" issue)
i agree but what can we do ...
think the futur is webrtc but don t know about it and rtsp, but once again look ffmpeg, streaming rstp is really easy thru nodejs :p
Le 25/03/2015 10:29, Shamun Toha a écrit :
I agree.
Make sense to me too. But we cant drop the ball as easy as it sounds, because there are millions of devices using RTSP protocol for streaming/broadcasting. Today or tomorrow you will get your customer request "CAN WE USE OUR RTSP WITH YOUR NODE-WEBKIT OR CHROME, SADLY YOU HAVE TO SAY {NO}, which i do not like to say."
We cant be so naive and agree to drop the NPAPI just like that!! (which was forever available for such a long time and in almost for every browsers). But yes we can drop it but we need manual/alternative way to embed it in case emergency projects (you never know).
Best alternative would be, if we can at-least use Gstreamer RTSP (Very stable then VLC RTSP i have tested with many many hardwares and found that RTSP compatibility in Gstreamer is better then VLC, maybe NodeWebkit should implement some RTSP stream capture from Gstreamer so that manually we can at-least use it in NW and let Chromium team decide or get less stress for there "having NPAPI" issue)
— Reply to this email directly or view it on GitHub https://github.com/nwjs/nw.js/issues/3241#issuecomment-85952698.
Do not go with STREAM(ing) concept only.
I would suggest to do something like NPAPI had so that we can have real-time/speed processing. Having the VLC and Gstreamer straight "render video to html canvas #3293".
In that way we at-least have better win with issues related to: lipsync, latency, rendering sync or async, drop frame/packet loss, jitter
@shamun absolutely. It is essential to have a method of high-speed bitmap updates from another process or at least dll. E.g in our case we have two different use cases where neither NaCL will help nor video streaming. The only way we found for now is to implement a virtual wdm capture device driver but that is quite an involved process.
I think this issue could be closed, since https://www.npmjs.com/package/webchimera.js now available
@RSATom How does webchimera solve this issue?
@wildeyes, WebChimera
- no, since it uses NPAPI, but WebChiemera.js
- yes, since it not using NPAPI but only Node.js/V8 API.
don't be confusing with names WebChimera
vs WebChiemera.js
- it's totally different projects, just was created to solve similar task and that's why named similar.
@RSATom Checking it out tonight, if it works like VLC's embed, it might just close this issue :)
I use VXG Media Player http://www.videoexpertsgroup.com/chrome-media-player-plug-in/ It works perfect. Here is demo player : http://rtpstream.com/nacl_player/
@konstr, Did you try it with nw.js? Why there are no public download link?
@konstr Does it works with nwjs drop in Plugins folder? If so this looks valuable as it supports RTSP.
@mscreenie, this plugin is closed source and not free. So be ready pay for it.
@mscreenie, why do you need it if WebChimera.js
is ready to use with both NW.js
and Electron
? Even dev team of Popcorn Time
working on switching to WebChimera.js
atm...
GStremer binding proof-of-concept: https://github.com/RSATom/wcjs-gs It works only on Linux with Electron atm. Though сould be ported to NW.js without any problem...
NW.js will not maintain NPAPI. Thanks.
Canary decided to permanently remove NPAPI: http://www.chromium.org/developers/npapi-deprecation
http://people.videolan.org/~dionoea/vlc-plugin-demo/plugin.php?url=rtsp://people.videolan.org:5554/storewars8&width=320&height=180
Will NodeWebkit keep it or remove it too?
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.