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

Side by Side Diff: talk/media/base/mediachannel.h

Issue 1505253004: Support for remote audio into tracks (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Address comments 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
OLDNEW
1 /* 1 /*
2 * libjingle 2 * libjingle
3 * Copyright 2004 Google Inc. 3 * Copyright 2004 Google Inc.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are met: 6 * modification, are permitted provided that the following conditions are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright notice, 8 * 1. Redistributions of source code must retain the above copyright notice,
9 * this list of conditions and the following disclaimer. 9 * this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright notice, 10 * 2. Redistributions in binary form must reproduce the above copyright notice,
(...skipping 13 matching lines...) Expand all
24 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 24 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
25 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 25 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 */ 26 */
27 27
28 #ifndef TALK_MEDIA_BASE_MEDIACHANNEL_H_ 28 #ifndef TALK_MEDIA_BASE_MEDIACHANNEL_H_
29 #define TALK_MEDIA_BASE_MEDIACHANNEL_H_ 29 #define TALK_MEDIA_BASE_MEDIACHANNEL_H_
30 30
31 #include <string> 31 #include <string>
32 #include <vector> 32 #include <vector>
33 33
34 #include "talk/media/base/audiorenderer.h"
34 #include "talk/media/base/codec.h" 35 #include "talk/media/base/codec.h"
35 #include "talk/media/base/constants.h" 36 #include "talk/media/base/constants.h"
36 #include "talk/media/base/streamparams.h" 37 #include "talk/media/base/streamparams.h"
37 #include "webrtc/base/basictypes.h" 38 #include "webrtc/base/basictypes.h"
38 #include "webrtc/base/buffer.h" 39 #include "webrtc/base/buffer.h"
39 #include "webrtc/base/dscp.h" 40 #include "webrtc/base/dscp.h"
40 #include "webrtc/base/logging.h" 41 #include "webrtc/base/logging.h"
41 #include "webrtc/base/optional.h" 42 #include "webrtc/base/optional.h"
42 #include "webrtc/base/sigslot.h" 43 #include "webrtc/base/sigslot.h"
43 #include "webrtc/base/socket.h" 44 #include "webrtc/base/socket.h"
44 #include "webrtc/base/window.h" 45 #include "webrtc/base/window.h"
45 // TODO(juberti): re-evaluate this include 46 // TODO(juberti): re-evaluate this include
46 #include "talk/session/media/audiomonitor.h" 47 #include "talk/session/media/audiomonitor.h"
47 48
48 namespace rtc { 49 namespace rtc {
49 class Buffer; 50 class Buffer;
50 class RateLimiter; 51 class RateLimiter;
51 class Timing; 52 class Timing;
52 } 53 }
53 54
55 namespace webrtc {
56 class AudioSinkInterface;
57 }
58
54 namespace cricket { 59 namespace cricket {
55 60
56 class AudioRenderer;
57 struct RtpHeader; 61 struct RtpHeader;
58 class ScreencastId; 62 class ScreencastId;
59 struct VideoFormat; 63 struct VideoFormat;
60 class VideoCapturer; 64 class VideoCapturer;
61 class VideoRenderer; 65 class VideoRenderer;
62 66
63 const int kMinRtpHeaderExtensionId = 1; 67 const int kMinRtpHeaderExtensionId = 1;
64 const int kMaxRtpHeaderExtensionId = 255; 68 const int kMaxRtpHeaderExtensionId = 255;
65 const int kScreencastDefaultFps = 5; 69 const int kScreencastDefaultFps = 5;
66 70
(...skipping 954 matching lines...) Expand 10 before | Expand all | Expand 10 after
1021 virtual bool SetOutputVolume(uint32_t ssrc, double volume) = 0; 1025 virtual bool SetOutputVolume(uint32_t ssrc, double volume) = 0;
1022 // Returns if the telephone-event has been negotiated. 1026 // Returns if the telephone-event has been negotiated.
1023 virtual bool CanInsertDtmf() = 0; 1027 virtual bool CanInsertDtmf() = 0;
1024 // Send a DTMF |event|. The DTMF out-of-band signal will be used. 1028 // Send a DTMF |event|. The DTMF out-of-band signal will be used.
1025 // The |ssrc| should be either 0 or a valid send stream ssrc. 1029 // The |ssrc| should be either 0 or a valid send stream ssrc.
1026 // The valid value for the |event| are 0 to 15 which corresponding to 1030 // The valid value for the |event| are 0 to 15 which corresponding to
1027 // DTMF event 0-9, *, #, A-D. 1031 // DTMF event 0-9, *, #, A-D.
1028 virtual bool InsertDtmf(uint32_t ssrc, int event, int duration) = 0; 1032 virtual bool InsertDtmf(uint32_t ssrc, int event, int duration) = 0;
1029 // Gets quality stats for the channel. 1033 // Gets quality stats for the channel.
1030 virtual bool GetStats(VoiceMediaInfo* info) = 0; 1034 virtual bool GetStats(VoiceMediaInfo* info) = 0;
1035
1036 virtual void SetRawAudioSink(
1037 uint32_t ssrc,
1038 rtc::scoped_ptr<webrtc::AudioSinkInterface> sink) = 0;
1031 }; 1039 };
1032 1040
1033 struct VideoSendParameters : RtpSendParameters<VideoCodec, VideoOptions> { 1041 struct VideoSendParameters : RtpSendParameters<VideoCodec, VideoOptions> {
1034 }; 1042 };
1035 1043
1036 struct VideoRecvParameters : RtpParameters<VideoCodec> { 1044 struct VideoRecvParameters : RtpParameters<VideoCodec> {
1037 }; 1045 };
1038 1046
1039 class VideoMediaChannel : public MediaChannel { 1047 class VideoMediaChannel : public MediaChannel {
1040 public: 1048 public:
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
1208 // Signal when the media channel is ready to send the stream. Arguments are: 1216 // Signal when the media channel is ready to send the stream. Arguments are:
1209 // writable(bool) 1217 // writable(bool)
1210 sigslot::signal1<bool> SignalReadyToSend; 1218 sigslot::signal1<bool> SignalReadyToSend;
1211 // Signal for notifying that the remote side has closed the DataChannel. 1219 // Signal for notifying that the remote side has closed the DataChannel.
1212 sigslot::signal1<uint32_t> SignalStreamClosedRemotely; 1220 sigslot::signal1<uint32_t> SignalStreamClosedRemotely;
1213 }; 1221 };
1214 1222
1215 } // namespace cricket 1223 } // namespace cricket
1216 1224
1217 #endif // TALK_MEDIA_BASE_MEDIACHANNEL_H_ 1225 #endif // TALK_MEDIA_BASE_MEDIACHANNEL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698