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

Side by Side Diff: trunk/src/media/audio/alsa/alsa_input.h

Issue 335343004: Revert 277794 "Modifies AudioInputCallback::OnData and use media..." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « trunk/src/media/audio/agc_audio_stream.h ('k') | trunk/src/media/audio/alsa/alsa_input.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 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef MEDIA_AUDIO_ALSA_ALSA_INPUT_H_ 5 #ifndef MEDIA_AUDIO_ALSA_ALSA_INPUT_H_
6 #define MEDIA_AUDIO_ALSA_ALSA_INPUT_H_ 6 #define MEDIA_AUDIO_ALSA_ALSA_INPUT_H_
7 7
8 #include <alsa/asoundlib.h> 8 #include <alsa/asoundlib.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 int bytes_per_buffer_; 75 int bytes_per_buffer_;
76 AlsaWrapper* wrapper_; 76 AlsaWrapper* wrapper_;
77 base::TimeDelta buffer_duration_; // Length of each recorded buffer. 77 base::TimeDelta buffer_duration_; // Length of each recorded buffer.
78 AudioInputCallback* callback_; // Valid during a recording session. 78 AudioInputCallback* callback_; // Valid during a recording session.
79 base::TimeTicks next_read_time_; // Scheduled time for next read callback. 79 base::TimeTicks next_read_time_; // Scheduled time for next read callback.
80 snd_pcm_t* device_handle_; // Handle to the ALSA PCM recording device. 80 snd_pcm_t* device_handle_; // Handle to the ALSA PCM recording device.
81 snd_mixer_t* mixer_handle_; // Handle to the ALSA microphone mixer. 81 snd_mixer_t* mixer_handle_; // Handle to the ALSA microphone mixer.
82 snd_mixer_elem_t* mixer_element_handle_; // Handle to the capture element. 82 snd_mixer_elem_t* mixer_element_handle_; // Handle to the capture element.
83 scoped_ptr<uint8[]> audio_buffer_; // Buffer used for reading audio data. 83 scoped_ptr<uint8[]> audio_buffer_; // Buffer used for reading audio data.
84 bool read_callback_behind_schedule_; 84 bool read_callback_behind_schedule_;
85 scoped_ptr<AudioBus> audio_bus_;
86 85
87 // NOTE: Weak pointers must be invalidated before all other member variables. 86 // NOTE: Weak pointers must be invalidated before all other member variables.
88 base::WeakPtrFactory<AlsaPcmInputStream> weak_factory_; 87 base::WeakPtrFactory<AlsaPcmInputStream> weak_factory_;
89 88
90 DISALLOW_COPY_AND_ASSIGN(AlsaPcmInputStream); 89 DISALLOW_COPY_AND_ASSIGN(AlsaPcmInputStream);
91 }; 90 };
92 91
93 } // namespace media 92 } // namespace media
94 93
95 #endif // MEDIA_AUDIO_ALSA_ALSA_INPUT_H_ 94 #endif // MEDIA_AUDIO_ALSA_ALSA_INPUT_H_
OLDNEW
« no previous file with comments | « trunk/src/media/audio/agc_audio_stream.h ('k') | trunk/src/media/audio/alsa/alsa_input.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698