Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(129)

Side by Side Diff: media/base/audio_renderer_mixer_pool.h

Issue 1942803002: Caching AudioOutputDevice instances in mixer manager (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: First round of comments addressed Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef MEDIA_BASE_AUDIO_RENDERER_MIXER_POOL_H_
6 #define MEDIA_BASE_AUDIO_RENDERER_MIXER_POOL_H_
7
8 #include <string>
9
10 #include "media/base/output_device_info.h"
11
12 namespace url {
13 class Origin;
14 }
15
16 namespace media {
17 class AudioParameters;
18 class AudioRendererMixer;
19
20 class AudioRendererMixerPool {
21 public:
22 AudioRendererMixerPool() {}
23 virtual ~AudioRendererMixerPool() {}
24
25 // Obtains a pointer to mixer instance based on AudioParameters. The pointer
26 // is guaranteed to be valid (at least) until it's rereleased by a call to
27 // ReturnMixer()
28 virtual media::AudioRendererMixer* GetMixer(
29 int source_render_frame_id,
30 const media::AudioParameters& params,
31 const std::string& device_id,
32 const url::Origin& security_origin,
33 media::OutputDeviceStatus* device_status) = 0;
34
35 // Returns mixer back to the pool.
36 virtual void ReturnMixer(int source_render_frame_id,
37 const media::AudioParameters& params,
38 const std::string& device_id,
39 const url::Origin& security_origin) = 0;
40
41 // Returns output device information
42 virtual media::OutputDeviceInfo GetOutputDeviceInfo(
43 int source_render_frame_id,
44 int session_id,
45 const std::string& device_id,
46 const url::Origin& security_origin) = 0;
47
48 private:
49 DISALLOW_COPY_AND_ASSIGN(AudioRendererMixerPool);
50 };
51
52 } // namespace media
53
54 #endif // MEDIA_BASE_AUDIO_RENDERER_MIXER_POOL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698