Closed Bug 797796 Opened 13 years ago Closed 13 years ago

getUserMedia backend needs to pass all necessary data to the UI

Categories

(Core :: WebRTC, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla18

People

(Reporter: dao, Assigned: anant)

References

Details

(Whiteboard: [getUserMedia] [blocking-gum+] [qa-])

Attachments

(1 file, 2 obsolete files)

data needed: - DOM window - nsIMediaStreamOptions - id or handle for the UI to approve or deny the request
Whiteboard: [getUserMedia] [blocking-gum+]
Attached patch Hookup gUM backend with the UI (obsolete) — Splinter Review
The only change from the patch in bug 729522 is that we now pass a JSON structure with the windowID and callID instead of just the callID.
Attachment #668105 - Flags: review?(rjesup)
Attached patch Hookup gUM backend with the UI (obsolete) — Splinter Review
Forgot to qref :/
Attachment #668105 - Attachment is obsolete: true
Attachment #668105 - Flags: review?(rjesup)
Attachment #668106 - Flags: review?(rjesup)
Pass outer window ID instead of inner window ID.
Attachment #668106 - Attachment is obsolete: true
Attachment #668106 - Flags: review?(rjesup)
Attachment #668183 - Flags: review?(rjesup)
Comment on attachment 668183 [details] [diff] [review] Hookup gUM backend with the UI Review of attachment 668183 [details] [diff] [review]: ----------------------------------------------------------------- r=jesup with the snprintf(windowBuffer,sizeof(windowBuffer),...) ::: dom/media/MediaManager.cpp @@ +390,5 @@ > + Denied() > + { > + if (NS_IsMainThread()) { > + nsCOMPtr<nsIDOMGetUserMediaErrorCallback> error(mError); > + error->OnError(NS_LITERAL_STRING("PERMISSION_DENIED")); trailing space @@ +725,5 @@ > + data.Append(NS_LITERAL_STRING("{\"windowID\":")); > + > + // Convert window ID to string. > + char windowBuffer[32]; > + sprintf(windowBuffer, "%ld", aWindow->GetOuterWindow()->WindowID()); paranoia: snprintf please. Yes, I know MAX_UINT64_T is less than 32 characters @@ +822,5 @@ > + // Close off any remaining active windows. > + mActiveWindows.Clear(); > + mActiveCallbacks.Clear(); > + sSingleton = nullptr; > + trialing spaces a couple of places here. Search the file for them. Emacs has a function (of course)
Attachment #668183 - Flags: review?(rjesup) → review+
What happens with regards to audio if both video and audio are requested and the front-end sends getUserMedia:response:allow for a particular video device?
The default audio device will be selected. I guess we'll need a way to signal a specific audio device as well. Right now, getUserMedia can only return a stream from a single device, but this is an issue when we fix that bug. Since we have to pass an object across the event using the subject parameter, the only way I can think of doing this is with two getUserMedia:response:allow messages, with the first one signaling somehow that there is another event on the way.
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla18
Whiteboard: [getUserMedia] [blocking-gum+] → [getUserMedia] [blocking-gum+] [qa-]
Flags: in-testsuite-
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: