Closed Bug 1316241 Opened 3 years ago Closed Last year

[geckoview] Make WebRTC work with GeckoView

Categories

(GeckoView :: General, defect, P2)

defect

Tracking

(geckoview62 verified)

RESOLVED FIXED
Tracking Status
geckoview62 --- verified

People

(Reporter: nalexander, Assigned: snorp)

References

Details

(Whiteboard: [geckoview:crow][geckoview:klar])

Attachments

(1 file)

Right now, we have WebRTC in Fennec and not in GeckoView.  See https://dxr.mozilla.org/mozilla-central/source/mobile/android/geckoview/build.gradle?q=path%3Ageckoview%2Fbuild.gradle&redirect_type=single#42.

This ticket tracks moving that into GeckoView and figuring out what needs to be exposed to make it all work.
Kevin I think this should work, but do you wanna try it?
Flags: needinfo?(kbrosnan)
Does not work in Klar Geckoview or geckoview example on a Pixel 2 XL.
Flags: needinfo?(kbrosnan)
Priority: -- → P2
Whiteboard: [geckoview:crow][geckoview:klar]
Yeah, a simple GUM test[0] is not working here, at least with e10s. First I get a crash, but then after fixing that I have:

04-30 14:36:45.550  4931  4950 I Gecko   : [Child 4931, Main Thread] ###!!! ASSERTION: Cannot perform action in content process!: 'Error', file /home/snorp/source/gecko/extensions/cookie/nsPermissionManager.cpp, line 1696
04-30 14:36:45.551  4931  4950 E Web Content: [JavaScript Error: "Media device error: [Exception... "Component returned failure code: 0x80040111 (NS_ERROR_NOT_AVAILABLE) [nsIPermissionManager.add]"  nsresult: "0x80040111 (NS_ERROR_NOT_AVAILABLE)"  location: "JS frame :: jar:jar:file:///data/app/org.mozilla.geckoview_example-fyeXVGIZjHvl59jv5JqgxQ==/base.apk!/assets/omni.ja!/components/GeckoViewPermission.js :: handleMediaRequest/</< :: line 131"  data: no]" {file: "jar:jar:file:///data/app/org.mozilla.geckoview_example-fyeXVGIZjHvl59jv5JqgxQ==/base.apk!/assets/omni.ja!/components/GeckoViewPermission.js" line: 147}]
04-30 14:36:45.551  4931  4950 E Web Content: handleMediaRequest/<@jar:jar:file:///data/app/org.mozilla.geckoview_example-fyeXVGIZjHvl59jv5JqgxQ==/base.apk!/assets/omni.ja!/components/GeckoViewPermission.js:147:7

So it looks like the permissions stuff needs split up into parent/child bits. Jim can you take a look?

[0] https://webrtc.github.io/samples/src/content/getusermedia/gum/
Flags: needinfo?(nchen)
The attached patch fixes it for non-e10s. I'll move the e10s bit over to bug 1458020.
Flags: needinfo?(nchen)
Comment on attachment 8972118 [details]
Bug 1316241 - Fix media prompts with GeckoView

https://reviewboard.mozilla.org/r/240830/#review247360
Attachment #8972118 - Flags: review?(esawin) → review+
Pushed by jwillcox@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/3550cb0d54d4
Fix media prompts with GeckoView r=esawin
> Keywords: leave-open

James, does WebRTC work in GV 62? Why did you tag this bug as leave-open when landing your media prompts fix in May?
Flags: needinfo?(snorp)
It seems to be working in 62, yeah. I can't remember why I marked it leave-open. I guess because of the e10s case?
Status: NEW → RESOLVED
Closed: Last year
Flags: needinfo?(snorp)
Resolution: --- → FIXED
Assignee: nobody → snorp
Product: Firefox for Android → GeckoView
You need to log in before you can comment on or make changes to this bug.