OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 REMOTING_HOST_LINUX_AUDIO_PIPE_READER_H_ | 5 #ifndef REMOTING_HOST_LINUX_AUDIO_PIPE_READER_H_ |
6 #define REMOTING_HOST_LINUX_AUDIO_PIPE_READER_H_ | 6 #define REMOTING_HOST_LINUX_AUDIO_PIPE_READER_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
11 | 11 |
12 #include "base/files/file.h" | 12 #include "base/files/file.h" |
13 #include "base/files/file_descriptor_watcher_posix.h" | 13 #include "base/files/file_descriptor_watcher_posix.h" |
14 #include "base/files/file_path.h" | 14 #include "base/files/file_path.h" |
15 #include "base/files/file_path_watcher.h" | 15 #include "base/files/file_path_watcher.h" |
16 #include "base/macros.h" | 16 #include "base/macros.h" |
17 #include "base/memory/ref_counted.h" | 17 #include "base/memory/ref_counted.h" |
18 #include "base/memory/ref_counted_memory.h" | 18 #include "base/memory/ref_counted_memory.h" |
19 #include "base/message_loop/message_loop.h" | 19 #include "base/message_loop/message_loop.h" |
20 #include "base/observer_list_threadsafe.h" | 20 #include "base/observer_list_threadsafe.h" |
| 21 #include "base/single_thread_task_runner.h" |
21 #include "base/time/time.h" | 22 #include "base/time/time.h" |
22 #include "base/timer/timer.h" | 23 #include "base/timer/timer.h" |
23 #include "remoting/proto/audio.pb.h" | 24 #include "remoting/proto/audio.pb.h" |
24 | 25 |
25 namespace remoting { | 26 namespace remoting { |
26 | 27 |
27 struct AudioPipeReaderTraits; | 28 struct AudioPipeReaderTraits; |
28 | 29 |
29 // AudioPipeReader class reads from a named pipe to which an audio server (e.g. | 30 // AudioPipeReader class reads from a named pipe to which an audio server (e.g. |
30 // pulseaudio) writes the sound that's being played back and then sends data to | 31 // pulseaudio) writes the sound that's being played back and then sends data to |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
108 }; | 109 }; |
109 | 110 |
110 // Destroys |audio_pipe_reader| on the audio thread. | 111 // Destroys |audio_pipe_reader| on the audio thread. |
111 struct AudioPipeReaderTraits { | 112 struct AudioPipeReaderTraits { |
112 static void Destruct(const AudioPipeReader* audio_pipe_reader); | 113 static void Destruct(const AudioPipeReader* audio_pipe_reader); |
113 }; | 114 }; |
114 | 115 |
115 } // namespace remoting | 116 } // namespace remoting |
116 | 117 |
117 #endif // REMOTING_HOST_LINUX_AUDIO_PIPE_READER_H_ | 118 #endif // REMOTING_HOST_LINUX_AUDIO_PIPE_READER_H_ |
OLD | NEW |