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

Side by Side Diff: talk/session/media/mediasession.h

Issue 1453813005: Fixing some issues with ICE restart signaling. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Fixing typo. Created 5 years, 1 month 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 | « talk/app/webrtc/webrtcsessiondescriptionfactory.cc ('k') | talk/session/media/mediasession.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 * 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 128 matching lines...) Expand 10 before | Expand all | Expand 10 after
139 DataChannelType data_channel_type; 139 DataChannelType data_channel_type;
140 bool is_muc; 140 bool is_muc;
141 bool vad_enabled; 141 bool vad_enabled;
142 bool rtcp_mux_enabled; 142 bool rtcp_mux_enabled;
143 bool bundle_enabled; 143 bool bundle_enabled;
144 // bps. -1 == auto. 144 // bps. -1 == auto.
145 int video_bandwidth; 145 int video_bandwidth;
146 int data_bandwidth; 146 int data_bandwidth;
147 TransportOptions transport_options; 147 TransportOptions transport_options;
148 148
149 bool audio_ice_restart = false;
150 bool video_ice_restart = false;
151 bool data_ice_restart = false;
152
149 struct Stream { 153 struct Stream {
150 Stream(MediaType type, 154 Stream(MediaType type,
151 const std::string& id, 155 const std::string& id,
152 const std::string& sync_label, 156 const std::string& sync_label,
153 int num_sim_layers) 157 int num_sim_layers)
154 : type(type), id(id), sync_label(sync_label), 158 : type(type), id(id), sync_label(sync_label),
155 num_sim_layers(num_sim_layers) { 159 num_sim_layers(num_sim_layers) {
156 } 160 }
157 MediaType type; 161 MediaType type;
158 std::string id; 162 std::string id;
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after
446 const SessionDescription* current_description) const; 450 const SessionDescription* current_description) const;
447 451
448 private: 452 private:
449 void GetCodecsToOffer(const SessionDescription* current_description, 453 void GetCodecsToOffer(const SessionDescription* current_description,
450 AudioCodecs* audio_codecs, 454 AudioCodecs* audio_codecs,
451 VideoCodecs* video_codecs, 455 VideoCodecs* video_codecs,
452 DataCodecs* data_codecs) const; 456 DataCodecs* data_codecs) const;
453 void GetRtpHdrExtsToOffer(const SessionDescription* current_description, 457 void GetRtpHdrExtsToOffer(const SessionDescription* current_description,
454 RtpHeaderExtensions* audio_extensions, 458 RtpHeaderExtensions* audio_extensions,
455 RtpHeaderExtensions* video_extensions) const; 459 RtpHeaderExtensions* video_extensions) const;
456 bool AddTransportOffer( 460 bool AddTransportOffer(const std::string& content_name,
457 const std::string& content_name, 461 const TransportOptions& transport_options,
458 const TransportOptions& transport_options, 462 bool ice_restart,
459 const SessionDescription* current_desc, 463 const SessionDescription* current_desc,
460 SessionDescription* offer) const; 464 SessionDescription* offer) const;
461 465
462 TransportDescription* CreateTransportAnswer( 466 TransportDescription* CreateTransportAnswer(
463 const std::string& content_name, 467 const std::string& content_name,
464 const SessionDescription* offer_desc, 468 const SessionDescription* offer_desc,
465 const TransportOptions& transport_options, 469 const TransportOptions& transport_options,
470 bool ice_restart,
466 const SessionDescription* current_desc) const; 471 const SessionDescription* current_desc) const;
467 472
468 bool AddTransportAnswer( 473 bool AddTransportAnswer(
469 const std::string& content_name, 474 const std::string& content_name,
470 const TransportDescription& transport_desc, 475 const TransportDescription& transport_desc,
471 SessionDescription* answer_desc) const; 476 SessionDescription* answer_desc) const;
472 477
473 // Helpers for adding media contents to the SessionDescription. Returns true 478 // Helpers for adding media contents to the SessionDescription. Returns true
474 // it succeeds or the media content is not needed, or false if there is any 479 // it succeeds or the media content is not needed, or false if there is any
475 // error. 480 // error.
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
527 bool add_legacy_; 532 bool add_legacy_;
528 std::string lang_; 533 std::string lang_;
529 const TransportDescriptionFactory* transport_desc_factory_; 534 const TransportDescriptionFactory* transport_desc_factory_;
530 }; 535 };
531 536
532 // Convenience functions. 537 // Convenience functions.
533 bool IsMediaContent(const ContentInfo* content); 538 bool IsMediaContent(const ContentInfo* content);
534 bool IsAudioContent(const ContentInfo* content); 539 bool IsAudioContent(const ContentInfo* content);
535 bool IsVideoContent(const ContentInfo* content); 540 bool IsVideoContent(const ContentInfo* content);
536 bool IsDataContent(const ContentInfo* content); 541 bool IsDataContent(const ContentInfo* content);
542 const ContentInfo* GetFirstMediaContent(const ContentInfos& contents,
543 MediaType media_type);
537 const ContentInfo* GetFirstAudioContent(const ContentInfos& contents); 544 const ContentInfo* GetFirstAudioContent(const ContentInfos& contents);
538 const ContentInfo* GetFirstVideoContent(const ContentInfos& contents); 545 const ContentInfo* GetFirstVideoContent(const ContentInfos& contents);
539 const ContentInfo* GetFirstDataContent(const ContentInfos& contents); 546 const ContentInfo* GetFirstDataContent(const ContentInfos& contents);
540 const ContentInfo* GetFirstAudioContent(const SessionDescription* sdesc); 547 const ContentInfo* GetFirstAudioContent(const SessionDescription* sdesc);
541 const ContentInfo* GetFirstVideoContent(const SessionDescription* sdesc); 548 const ContentInfo* GetFirstVideoContent(const SessionDescription* sdesc);
542 const ContentInfo* GetFirstDataContent(const SessionDescription* sdesc); 549 const ContentInfo* GetFirstDataContent(const SessionDescription* sdesc);
543 const AudioContentDescription* GetFirstAudioContentDescription( 550 const AudioContentDescription* GetFirstAudioContentDescription(
544 const SessionDescription* sdesc); 551 const SessionDescription* sdesc);
545 const VideoContentDescription* GetFirstVideoContentDescription( 552 const VideoContentDescription* GetFirstVideoContentDescription(
546 const SessionDescription* sdesc); 553 const SessionDescription* sdesc);
547 const DataContentDescription* GetFirstDataContentDescription( 554 const DataContentDescription* GetFirstDataContentDescription(
548 const SessionDescription* sdesc); 555 const SessionDescription* sdesc);
549 556
550 void GetSupportedAudioCryptoSuites(std::vector<std::string>* crypto_suites); 557 void GetSupportedAudioCryptoSuites(std::vector<std::string>* crypto_suites);
551 void GetSupportedVideoCryptoSuites(std::vector<std::string>* crypto_suites); 558 void GetSupportedVideoCryptoSuites(std::vector<std::string>* crypto_suites);
552 void GetSupportedDataCryptoSuites(std::vector<std::string>* crypto_suites); 559 void GetSupportedDataCryptoSuites(std::vector<std::string>* crypto_suites);
553 void GetDefaultSrtpCryptoSuiteNames(std::vector<std::string>* crypto_suites); 560 void GetDefaultSrtpCryptoSuiteNames(std::vector<std::string>* crypto_suites);
554 } // namespace cricket 561 } // namespace cricket
555 562
556 #endif // TALK_SESSION_MEDIA_MEDIASESSION_H_ 563 #endif // TALK_SESSION_MEDIA_MEDIASESSION_H_
OLDNEW
« no previous file with comments | « talk/app/webrtc/webrtcsessiondescriptionfactory.cc ('k') | talk/session/media/mediasession.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698