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 #include "content/renderer/media/rtc_peer_connection_handler.h" | 5 #include "content/renderer/media/rtc_peer_connection_handler.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <map> | 9 #include <map> |
10 #include <memory> | 10 #include <memory> |
(...skipping 283 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
294 blink::WebString::FromUTF8("audio_track"), | 294 blink::WebString::FromUTF8("audio_track"), |
295 false /* remote */); | 295 false /* remote */); |
296 ProcessedLocalAudioSource* const audio_source = | 296 ProcessedLocalAudioSource* const audio_source = |
297 new ProcessedLocalAudioSource( | 297 new ProcessedLocalAudioSource( |
298 -1 /* consumer_render_frame_id is N/A for non-browser tests */, | 298 -1 /* consumer_render_frame_id is N/A for non-browser tests */, |
299 StreamDeviceInfo(MEDIA_DEVICE_AUDIO_CAPTURE, "Mock device", | 299 StreamDeviceInfo(MEDIA_DEVICE_AUDIO_CAPTURE, "Mock device", |
300 "mock_device_id", | 300 "mock_device_id", |
301 media::AudioParameters::kAudioCDSampleRate, | 301 media::AudioParameters::kAudioCDSampleRate, |
302 media::CHANNEL_LAYOUT_STEREO, | 302 media::CHANNEL_LAYOUT_STEREO, |
303 media::AudioParameters::kAudioCDSampleRate / 100), | 303 media::AudioParameters::kAudioCDSampleRate / 100), |
304 MockConstraintFactory().CreateWebMediaConstraints(), | 304 AudioProcessingProperties(), |
305 base::Bind(&RTCPeerConnectionHandlerTest::OnAudioSourceStarted), | 305 base::Bind(&RTCPeerConnectionHandlerTest::OnAudioSourceStarted), |
306 mock_dependency_factory_.get()); | 306 mock_dependency_factory_.get()); |
307 audio_source->SetAllowInvalidRenderFrameIdForTesting(true); | 307 audio_source->SetAllowInvalidRenderFrameIdForTesting(true); |
308 blink_audio_source.SetExtraData(audio_source); // Takes ownership. | 308 blink_audio_source.SetExtraData(audio_source); // Takes ownership. |
309 | 309 |
310 blink::WebMediaStreamSource video_source; | 310 blink::WebMediaStreamSource video_source; |
311 video_source.Initialize(blink::WebString::FromUTF8(video_track_label), | 311 video_source.Initialize(blink::WebString::FromUTF8(video_track_label), |
312 blink::WebMediaStreamSource::kTypeVideo, | 312 blink::WebMediaStreamSource::kTypeVideo, |
313 blink::WebString::FromUTF8("video_track"), | 313 blink::WebString::FromUTF8("video_track"), |
314 false /* remote */); | 314 false /* remote */); |
(...skipping 1145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1460 testing::Ref(tracks[0]))); | 1460 testing::Ref(tracks[0]))); |
1461 | 1461 |
1462 std::unique_ptr<blink::WebRTCDTMFSenderHandler> sender( | 1462 std::unique_ptr<blink::WebRTCDTMFSenderHandler> sender( |
1463 pc_handler_->CreateDTMFSender(tracks[0])); | 1463 pc_handler_->CreateDTMFSender(tracks[0])); |
1464 EXPECT_TRUE(sender.get()); | 1464 EXPECT_TRUE(sender.get()); |
1465 | 1465 |
1466 StopAllTracks(local_stream); | 1466 StopAllTracks(local_stream); |
1467 } | 1467 } |
1468 | 1468 |
1469 } // namespace content | 1469 } // namespace content |
OLD | NEW |