Skip to content
  • olka's avatar
    Caching AudioOutputDevice instances in mixer manager. · 7a467939
    olka authored
    * AudioRendererSinkCache introduced - keeps references to the sinks created to get output device info or to pass to a mixer; helps to reuse thinks to get output device info.
    * Some factory methods are added to simplify mocking/unit tests creation.
    * HardwareConfig usage is removed from the renderer (except GetHighlatencyBufferSize() call); sink is used to obtain output parameters.
    * Unit tests and some mocks updated.
    
    - see bugs for more info.
    
    *** The follow-up plan is:
    1) Add UMA stats on cache usage?
    2) Probably switch other clients to get sinks through the cache (basically it means that the cache will work as AudioDeviceFactory, and they both probably should be merged, except factory part which handles input devices)
    3) Remove the rest of AudioHardwareConfig usage across the code.
    
    BUG=536843,586161,587461
    
    TESTSING=manual testing on several sample pages with media elements + media_unittests + content_unittests + media_blink_unittests (all updated)
    
    Review-Url: https://codereview.chromium.org/1942803002
    Cr-Commit-Position: refs/heads/master@{#396471}
    7a467939