• Guido Urdaneta's avatar
    Use heuristic to group ID for video-input devices in enumerateDevices · 848ce57f
    Guido Urdaneta authored
    This CL adds a heuristic to find associations between video-input and
    audio-input devices.
    
    The heuristic considers an association to exist if the label for the
    video device (minus the VID:PID suffix, if it exists) appears as a
    substring of the audio label.
    
    If zero or more than one association is found then the video device ID
    is used as its group ID. This also fixes the problem of having all
    video devices with empty group IDs.
    
    We expect this heuristic to have a relatively high false-negative rate
    and a low false-positive rate.
    
    Bug: 627793
    Change-Id: Iebc9228ca6a8acd5f0e740f3120ef851fecc1cb1
    Reviewed-on: https://chromium-review.googlesource.com/883534Reviewed-by: default avatarHenrik Boström <hbos@chromium.org>
    Reviewed-by: default avatarHarald Alvestrand <hta@chromium.org>
    Commit-Queue: Guido Urdaneta <guidou@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#532119}
    848ce57f
media_devices_manager.cc 24.8 KB