OLD | NEW |
---|---|
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 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
96 struct MediaSessionOptions { | 96 struct MediaSessionOptions { |
97 MediaSessionOptions() : | 97 MediaSessionOptions() : |
98 recv_audio(true), | 98 recv_audio(true), |
99 recv_video(false), | 99 recv_video(false), |
100 data_channel_type(DCT_NONE), | 100 data_channel_type(DCT_NONE), |
101 is_muc(false), | 101 is_muc(false), |
102 vad_enabled(true), // When disabled, removes all CN codecs from SDP. | 102 vad_enabled(true), // When disabled, removes all CN codecs from SDP. |
103 rtcp_mux_enabled(true), | 103 rtcp_mux_enabled(true), |
104 bundle_enabled(false), | 104 bundle_enabled(false), |
105 video_bandwidth(kAutoBandwidth), | 105 video_bandwidth(kAutoBandwidth), |
106 data_bandwidth(kDataMaxBandwidth) { | 106 data_bandwidth(kDataMaxBandwidth), |
107 enable_gcm_crypto_suites(false) { | |
107 } | 108 } |
108 | 109 |
109 bool has_audio() const { | 110 bool has_audio() const { |
110 return recv_audio || HasSendMediaStream(MEDIA_TYPE_AUDIO); | 111 return recv_audio || HasSendMediaStream(MEDIA_TYPE_AUDIO); |
111 } | 112 } |
112 bool has_video() const { | 113 bool has_video() const { |
113 return recv_video || HasSendMediaStream(MEDIA_TYPE_VIDEO); | 114 return recv_video || HasSendMediaStream(MEDIA_TYPE_VIDEO); |
114 } | 115 } |
115 bool has_data() const { return data_channel_type != DCT_NONE; } | 116 bool has_data() const { return data_channel_type != DCT_NONE; } |
116 | 117 |
(...skipping 20 matching lines...) Expand all Loading... | |
137 bool recv_audio; | 138 bool recv_audio; |
138 bool recv_video; | 139 bool recv_video; |
139 DataChannelType data_channel_type; | 140 DataChannelType data_channel_type; |
140 bool is_muc; | 141 bool is_muc; |
141 bool vad_enabled; | 142 bool vad_enabled; |
142 bool rtcp_mux_enabled; | 143 bool rtcp_mux_enabled; |
143 bool bundle_enabled; | 144 bool bundle_enabled; |
144 // bps. -1 == auto. | 145 // bps. -1 == auto. |
145 int video_bandwidth; | 146 int video_bandwidth; |
146 int data_bandwidth; | 147 int data_bandwidth; |
148 bool enable_gcm_crypto_suites; | |
147 TransportOptions transport_options; | 149 TransportOptions transport_options; |
148 | 150 |
149 struct Stream { | 151 struct Stream { |
150 Stream(MediaType type, | 152 Stream(MediaType type, |
151 const std::string& id, | 153 const std::string& id, |
152 const std::string& sync_label, | 154 const std::string& sync_label, |
153 int num_sim_layers) | 155 int num_sim_layers) |
154 : type(type), id(id), sync_label(sync_label), | 156 : type(type), id(id), sync_label(sync_label), |
155 num_sim_layers(num_sim_layers) { | 157 num_sim_layers(num_sim_layers) { |
156 } | 158 } |
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
536 const ContentInfo* GetFirstAudioContent(const SessionDescription* sdesc); | 538 const ContentInfo* GetFirstAudioContent(const SessionDescription* sdesc); |
537 const ContentInfo* GetFirstVideoContent(const SessionDescription* sdesc); | 539 const ContentInfo* GetFirstVideoContent(const SessionDescription* sdesc); |
538 const ContentInfo* GetFirstDataContent(const SessionDescription* sdesc); | 540 const ContentInfo* GetFirstDataContent(const SessionDescription* sdesc); |
539 const AudioContentDescription* GetFirstAudioContentDescription( | 541 const AudioContentDescription* GetFirstAudioContentDescription( |
540 const SessionDescription* sdesc); | 542 const SessionDescription* sdesc); |
541 const VideoContentDescription* GetFirstVideoContentDescription( | 543 const VideoContentDescription* GetFirstVideoContentDescription( |
542 const SessionDescription* sdesc); | 544 const SessionDescription* sdesc); |
543 const DataContentDescription* GetFirstDataContentDescription( | 545 const DataContentDescription* GetFirstDataContentDescription( |
544 const SessionDescription* sdesc); | 546 const SessionDescription* sdesc); |
545 | 547 |
546 void GetSupportedAudioCryptoSuites(std::vector<int>* crypto_suites); | 548 void GetSupportedAudioCryptoSuites(std::vector<int>* crypto_suites, |
547 void GetSupportedVideoCryptoSuites(std::vector<int>* crypto_suites); | 549 const MediaSessionOptions& options); |
pthatcher1
2015/12/21 22:30:27
This looks a lot better, but two things:
1. The
joachim
2015/12/21 23:37:57
Done
| |
548 void GetSupportedDataCryptoSuites(std::vector<int>* crypto_suites); | 550 void GetSupportedVideoCryptoSuites(std::vector<int>* crypto_suites, |
549 void GetDefaultSrtpCryptoSuites(std::vector<int>* crypto_suites); | 551 const MediaSessionOptions& options); |
552 void GetSupportedDataCryptoSuites(std::vector<int>* crypto_suites, | |
553 const MediaSessionOptions& options); | |
554 void GetDefaultSrtpCryptoSuites(std::vector<int>* crypto_suites, | |
555 const MediaSessionOptions& options); | |
550 void GetSupportedAudioCryptoSuiteNames( | 556 void GetSupportedAudioCryptoSuiteNames( |
551 std::vector<std::string>* crypto_suite_names); | 557 std::vector<std::string>* crypto_suite_names, |
558 const MediaSessionOptions& options); | |
552 void GetSupportedVideoCryptoSuiteNames( | 559 void GetSupportedVideoCryptoSuiteNames( |
553 std::vector<std::string>* crypto_suite_names); | 560 std::vector<std::string>* crypto_suite_names, |
561 const MediaSessionOptions& options); | |
554 void GetSupportedDataCryptoSuiteNames( | 562 void GetSupportedDataCryptoSuiteNames( |
555 std::vector<std::string>* crypto_suite_names); | 563 std::vector<std::string>* crypto_suite_names, |
564 const MediaSessionOptions& options); | |
556 void GetDefaultSrtpCryptoSuiteNames( | 565 void GetDefaultSrtpCryptoSuiteNames( |
557 std::vector<std::string>* crypto_suite_names); | 566 std::vector<std::string>* crypto_suite_names, |
567 const MediaSessionOptions& options); | |
558 | 568 |
559 } // namespace cricket | 569 } // namespace cricket |
560 | 570 |
561 #endif // TALK_SESSION_MEDIA_MEDIASESSION_H_ | 571 #endif // TALK_SESSION_MEDIA_MEDIASESSION_H_ |
OLD | NEW |