Webcam inside iframe

341 views
Skip to first unread message

martyno....@gmail.com

unread,
May 17, 2018, 10:08:14 AM5/17/18
to nw.js
Hello,

I'm unsucessfully trying to use webcam from inside iframe. It acts as if there was a permission dialog that was cancelled (neither accepted nor denied). It works from within browser window's main page.

Reproducing is really simple: just <iframe src="some-webcam-test-site">.

Is there an analog to Electron's 'session.setPermissionRequestHandler(handler)' in nw.js?

Things I tried so far unsuccessfully:

  "node-remote": "<all_urls>",
  "permissions": ["videoCapture", "audioCapture"],
  "chromium-args": "--use-fake-ui-for-media-stream"

I'm stuck with this issue, any help or tips appreciated.

Roger

unread,
May 17, 2018, 10:12:54 AM5/17/18
to Martynas Kazlauskas, nw.js
Please submit an issue and we'll fix it.

--
You received this message because you are subscribed to the Google Groups "nw.js" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nwjs-general...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

bschm...@gmail.com

unread,
May 21, 2018, 7:59:46 AM5/21/18
to nw.js
it's a Chromium security thing. You need to add an allow attribute to use webrtc inside an iframe. ex:
<iframe frameBorder="0" allow="microphone *; camera *; geolocation;" />
Reply all
Reply to author
Forward
0 new messages