
Build an app that uses screen capture in Google Chrome - philnash
https://www.twilio.com/blog/2017/10/screen-capture-in-google-chrome.html
======
speps
I made something similar that uses the Chrome App API. Basically it creates a
HTTP server that acts an MJPEG server which sends the currently captured tab.
All of those APIs have a really vast array of features... kind of scary
actually.

Source code: [https://github.com/speps/grumpy-pi-
cast](https://github.com/speps/grumpy-pi-cast)

------
janci
Is there possibility for remote control? Like simulating keyboard and mouse. I
did not find an API for this.

~~~
victor106
This would be great.

Also any one know of open source tools that have remote control of the users
machine?

~~~
skzo
Guacamole:
[https://guacamole.incubator.apache.org/](https://guacamole.incubator.apache.org/)

~~~
GFischer
That's just what I needed, thanks for sharing !!!

------
VMG
Unfortunately still broken on gnome/wayland:
[https://bugzilla.gnome.org/show_bug.cgi?id=784199](https://bugzilla.gnome.org/show_bug.cgi?id=784199)

edit: gnome bug not linux

~~~
kuschku
The GNOME bug is indirectly related, but linking to just it distorts the
situation quite a lot.

Wayland has no screen recording API by default, so compositors implement their
own - some already have their own, some, such as GNOME's mutter, don't.

But even if mutter implements it, that doesn't really fix it for all
situations - there's many users on KDE, for example, for whom the GNOME bug is
entirely irrelevant.

Linux != GNOME.

~~~
shakna
Mutter has experimental support for a PipeWire stream, exposing two APIs:
org.gnome.Mutter.RemoteDesktop and org.gnome.Mutter.ScreenCast

Thanks to the gnome-remote-desktop project, which landed in stable Fedora back
in September.

------
DinoMobile
What about using WebRTCs to record, stream screen data? This should work on
Firefox, ... as well.

~~~
TD-Linux
In fact, in Firefox it works without creating the extension.

~~~
philnash
I'm going to be following this post up with how to do the same in Firefox and
how to put that all together for as much support as possible.

------
icantrank
bros... can we use es6 and more in a chrome extension bc it's defo running in
chrome? Just a thought from scrolling through this post and spotting some sexy
arrow functions which I've been dropping from anything client side

~~~
philnash
That's an interesting question, depends on the support you're expecting.

In this case the desktopCapture API was introduced in Chrome 34 but arrow
functions only turned up in version 45 onwards.

You can set a minimum Chrome version in the extension manifest though, which
would mean you can set a version that guarantees the JS support that you want.

