From a8699aa56903e201164b4e0f1b7dca7ce350bbd6 Mon Sep 17 00:00:00 2001 From: Youenn Fablet Date: Thu, 25 Aug 2022 16:48:32 +0200 Subject: [PATCH] Update enumerateDevices algorithm to make use of device-kind specific exposure checks when building cameraList and microphoneList. This ensures we do not get dummy similar audioinput or camera devices if only camera or only microphone is used. --- getusermedia.html | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/getusermedia.html b/getusermedia.html index a585e588..5b8638b6 100644 --- a/getusermedia.html +++ b/getusermedia.html @@ -2933,16 +2933,12 @@

Methods

  • -

    If [=device information can be exposed=] is false, - run the following sub steps:

    -

      -
    1. -

      If microphoneList is not empty, truncate microphoneList to its first item.

      -
    2. -
    3. -

      If cameraList is not empty, truncate cameraList to its first item.

      -
    4. -
    +

    If [=microphone information can be exposed=] is false, + truncate microphoneList to its first item.

    +
  • +
  • +

    If [=camera information can be exposed=] is false, + truncate cameraList to its first item.

  • Run the following sub steps for each discovered device in deviceList, device: