← Back to team overview

ubuntu-phone team mailing list archive

WebContext.default[Audio | Video]CaptureDeviceId howto

 

Hi,

I have been trying to create a minimal web-app by creating a Qml WebView
using the default shared context plus some customization.

My problem is that I can't make the Microphone nor Camera work.

I have observed the following:

1. The defaultAudioCaptureDeviceId is empty by default
2. The defaultVideoCaptureDeviceId is empty by default
3. Independent of the Ids I set, I always get a Warning saying audio is not
implemented (see below)
4. The web-container is able to use the microphone and camera without
issues, so there is a way to make it work, I just don't know how.
5. There are apparmor violations which could be related to the issue
6. I'm using the following policies: networking, audio, camera, microphone,
push-notification-client, video.

So, the question is:  What would be the recommended way to make it work?


Thannks a lot for your help!

Best Regards,
Felipe.

PS:
The following is the debug output:

Loading module: 'libubuntu_application_api_touch_mirclient.so.3.0.0'

shm_open() failed: Permission denied

qml: Loaded 11 UA override(s) from
file:///usr/lib/arm-linux-gnueabihf/qt5/qml/Ubuntu/Web/ua-overrides-mobile.js

qml: Completed wv1

qml: context.userAgent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36
(KHTML, like Gecko) Ubuntu Chromium/52.0.2743.116 Chrome/52.0.2743.116
Safari/537.36

qml: context.dataPath:
file:///home/phablet/.local/share/wire-qmlweb.fdelapuente

qml: context.cachePath: file:///home/phablet/.cache/wire-qmlweb.fdelapuente

qml: context.defaultAudioCaptureDeviceId:

qml: context.defaultVideoCaptureDeviceId:

OxideQQuickWebContext: Cannot set hostMappingRules once the context is in
use

OxideQQuickWebContext: devtoolsBindIp was set to an invalid value. It must
be set to a valid IPv4 or IPv6 address

OxideQQuickWebContext: devtoolsPort was set to an invalid value. It must be
set between 1024 and 65535

OxideQQuickUserScript: url is a construct-only parameter

OxideQQuickUserScript: url is a construct-only parameter

OxideQQuickUserScript: url is a construct-only parameter

OxideQQuickUserScript: url is a construct-only parameter

OxideQQuickWebContext::Cannot set sessionCookieMode once the context is in
use

OxideQQuickWebContext: Cannot set maxCacheSizeHint once the context is in
use

OxideQQuickWebContext:: Cannot set cachePath once the context is in use

OxideQQuickWebContext: Cannot set dataPath once the context is in use

[1101/170239:ERROR:layer_tree_host_impl.cc(2233)] Forcing zero-copy tile
initialization as worker context is missing

Sdk-Launcher> There has been a AppArmor denial for your application.

Sdk-Launcher> Most likely it is missing a policy in the AppArmor file.

Syslog> Nov 1 17:02:39 ubuntu-phablet kernel: [28682.928291] type=1400
audit(1478030559.561:439): apparmor="DENIED" operation="open"
profile="wire-qmlweb.fdelapuente_Wire-qmlweb_0.1"
name="/sys/devices/platform/kgsl-3d0.0/kgsl/kgsl-3d0/reset_count" pid=17581
comm="Chrome_InProcGp" requested_mask="r" denied_mask="r" fsuid=32011 ouid=0

Sdk-Launcher> There has been a AppArmor denial for your application.

Sdk-Launcher> Most likely it is missing a policy in the AppArmor file.

Syslog> Nov 1 17:02:39 ubuntu-phablet kernel: [28682.930489] type=1400
audit(1478030559.561:440): apparmor="DENIED" operation="open"
profile="wire-qmlweb.fdelapuente_Wire-qmlweb_0.1"
name="/sys/devices/platform/kgsl-3d0.0/kgsl/kgsl-3d0/reset_count" pid=17581
comm="Chrome_InProcGp" requested_mask="r" denied_mask="r" fsuid=32011 ouid=0

Sdk-Launcher> There has been a AppArmor denial for your application.

Sdk-Launcher> Most likely it is missing a policy in the AppArmor file.

Syslog> Nov 1 17:02:39 ubuntu-phablet kernel: [28683.065572] type=1400
audit(1478030559.701:441): apparmor="DENIED" operation="open"
profile="wire-qmlweb.fdelapuente_Wire-qmlweb_0.1"
name="/sys/devices/platform/kgsl-3d0.0/kgsl/kgsl-3d0/reset_count" pid=17581
comm="Chrome_InProcGp" requested_mask="r" denied_mask="r" fsuid=32011 ouid=0

Sdk-Launcher> There has been a AppArmor denial for your application.

Sdk-Launcher> Most likely it is missing a policy in the AppArmor file.

Syslog> Nov 1 17:02:39 ubuntu-phablet kernel: [28683.068410] type=1400
audit(1478030559.701:442): apparmor="DENIED" operation="open"
profile="wire-qmlweb.fdelapuente_Wire-qmlweb_0.1"
name="/sys/devices/platform/kgsl-3d0.0/kgsl/kgsl-3d0/reset_count" pid=17581
comm="Chrome_InProcGp" requested_mask="r" denied_mask="r" fsuid=32011 ouid=0

Sdk-Launcher> There has been a AppArmor denial for your application.

Sdk-Launcher> Most likely it is missing a policy in the AppArmor file.

Syslog> Nov 1 17:02:39 ubuntu-phablet kernel: [28683.081168] type=1400
audit(1478030559.711:443): apparmor="DENIED" operation="open"
profile="wire-qmlweb.fdelapuente_Wire-qmlweb_0.1"
name="/sys/devices/platform/kgsl-3d0.0/kgsl/kgsl-3d0/reset_count" pid=17581
comm="Chrome_InProcGp" requested_mask="r" denied_mask="r" fsuid=32011 ouid=0

Sdk-Launcher> There has been a AppArmor denial for your application.

Sdk-Launcher> Most likely it is missing a policy in the AppArmor file.

Syslog> Nov 1 17:02:39 ubuntu-phablet kernel: [28683.081381] type=1400
audit(1478030559.711:444): apparmor="DENIED" operation="open"
profile="wire-qmlweb.fdelapuente_Wire-qmlweb_0.1"
name="/sys/devices/platform/kgsl-3d0.0/kgsl/kgsl-3d0/reset_count" pid=17581
comm="Chrome_InProcGp" requested_mask="r" denied_mask="r" fsuid=32011 ouid=0

ubuntumirclient: Attempted to deliver an event to a non-existent window,
ignoring.

Sdk-Launcher> Stopping Application

Follow ups