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

Side by Side Diff: webrtc/voice_engine/voe_base_impl.h

Issue 1459083007: Open backdoor in VoiceEngineImpl to get at the actual voe::Channel objects from an ID. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: presubmit complaints Created 5 years 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
« no previous file with comments | « webrtc/voice_engine/channel_proxy.cc ('k') | webrtc/voice_engine/voe_base_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 47
48 int GetVersion(char version[1024]) override; 48 int GetVersion(char version[1024]) override;
49 49
50 int LastError() override; 50 int LastError() override;
51 51
52 AudioTransport* audio_transport() override { return this; } 52 AudioTransport* audio_transport() override { return this; }
53 53
54 int AssociateSendChannel(int channel, int accociate_send_channel) override; 54 int AssociateSendChannel(int channel, int accociate_send_channel) override;
55 55
56 // AudioTransport 56 // AudioTransport
57 int32_t RecordedDataIsAvailable(const void* audioSamples, size_t nSamples, 57 int32_t RecordedDataIsAvailable(const void* audioSamples,
58 size_t nBytesPerSample, uint8_t nChannels, 58 const size_t nSamples,
59 uint32_t samplesPerSec, uint32_t totalDelayMS, 59 const size_t nBytesPerSample,
60 int32_t clockDrift, uint32_t micLevel, 60 const uint8_t nChannels,
61 bool keyPressed, 61 const uint32_t samplesPerSec,
62 const uint32_t totalDelayMS,
63 const int32_t clockDrift,
64 const uint32_t currentMicLevel,
65 const bool keyPressed,
62 uint32_t& newMicLevel) override; 66 uint32_t& newMicLevel) override;
63 int32_t NeedMorePlayData(size_t nSamples, size_t nBytesPerSample, 67 int32_t NeedMorePlayData(const size_t nSamples,
64 uint8_t nChannels, uint32_t samplesPerSec, 68 const size_t nBytesPerSample,
65 void* audioSamples, size_t& nSamplesOut, 69 const uint8_t nChannels,
70 const uint32_t samplesPerSec,
71 void* audioSamples,
72 size_t& nSamplesOut,
66 int64_t* elapsed_time_ms, 73 int64_t* elapsed_time_ms,
67 int64_t* ntp_time_ms) override; 74 int64_t* ntp_time_ms) override;
68 int OnDataAvailable(const int voe_channels[], int number_of_voe_channels, 75 int OnDataAvailable(const int voe_channels[],
69 const int16_t* audio_data, int sample_rate, 76 int number_of_voe_channels,
70 int number_of_channels, size_t number_of_frames, 77 const int16_t* audio_data,
71 int audio_delay_milliseconds, int volume, 78 int sample_rate,
72 bool key_pressed, bool need_audio_processing) override; 79 int number_of_channels,
73 void OnData(int voe_channel, const void* audio_data, int bits_per_sample, 80 size_t number_of_frames,
74 int sample_rate, int number_of_channels, 81 int audio_delay_milliseconds,
82 int current_volume,
83 bool key_pressed,
84 bool need_audio_processing) override;
85 void OnData(int voe_channel,
86 const void* audio_data,
87 int bits_per_sample,
88 int sample_rate,
89 int number_of_channels,
75 size_t number_of_frames) override; 90 size_t number_of_frames) override;
76 void PushCaptureData(int voe_channel, const void* audio_data, 91 void PushCaptureData(int voe_channel,
77 int bits_per_sample, int sample_rate, 92 const void* audio_data,
93 int bits_per_sample,
94 int sample_rate,
78 int number_of_channels, 95 int number_of_channels,
79 size_t number_of_frames) override; 96 size_t number_of_frames) override;
80 void PullRenderData(int bits_per_sample, int sample_rate, 97 void PullRenderData(int bits_per_sample,
81 int number_of_channels, size_t number_of_frames, 98 int sample_rate,
82 void* audio_data, int64_t* elapsed_time_ms, 99 int number_of_channels,
100 size_t number_of_frames,
101 void* audio_data,
102 int64_t* elapsed_time_ms,
83 int64_t* ntp_time_ms) override; 103 int64_t* ntp_time_ms) override;
84 104
85 // AudioDeviceObserver 105 // AudioDeviceObserver
86 void OnErrorIsReported(ErrorCode error) override; 106 void OnErrorIsReported(const ErrorCode error) override;
87 void OnWarningIsReported(WarningCode warning) override; 107 void OnWarningIsReported(const WarningCode warning) override;
88 108
89 protected: 109 protected:
90 VoEBaseImpl(voe::SharedData* shared); 110 VoEBaseImpl(voe::SharedData* shared);
91 ~VoEBaseImpl() override; 111 ~VoEBaseImpl() override;
92 112
93 private: 113 private:
94 int32_t StartPlayout(); 114 int32_t StartPlayout();
95 int32_t StopPlayout(); 115 int32_t StopPlayout();
96 int32_t StartSend(); 116 int32_t StartSend();
97 int32_t StopSend(); 117 int32_t StopSend();
(...skipping 27 matching lines...) Expand all
125 VoiceEngineObserver* voiceEngineObserverPtr_; 145 VoiceEngineObserver* voiceEngineObserverPtr_;
126 CriticalSectionWrapper& callbackCritSect_; 146 CriticalSectionWrapper& callbackCritSect_;
127 147
128 AudioFrame audioFrame_; 148 AudioFrame audioFrame_;
129 voe::SharedData* shared_; 149 voe::SharedData* shared_;
130 }; 150 };
131 151
132 } // namespace webrtc 152 } // namespace webrtc
133 153
134 #endif // WEBRTC_VOICE_ENGINE_VOE_BASE_IMPL_H 154 #endif // WEBRTC_VOICE_ENGINE_VOE_BASE_IMPL_H
OLDNEW
« no previous file with comments | « webrtc/voice_engine/channel_proxy.cc ('k') | webrtc/voice_engine/voe_base_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698