| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/media_stream_video_source.h" | 5 #include "content/renderer/media/media_stream_video_source.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <limits> | 8 #include <limits> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 301 return true; | 301 return true; |
| 302 } | 302 } |
| 303 return false; | 303 return false; |
| 304 } | 304 } |
| 305 | 305 |
| 306 MediaStreamVideoSource::MediaStreamVideoSource( | 306 MediaStreamVideoSource::MediaStreamVideoSource( |
| 307 MediaStreamDependencyFactory* factory) | 307 MediaStreamDependencyFactory* factory) |
| 308 : state_(NEW), | 308 : state_(NEW), |
| 309 factory_(factory), | 309 factory_(factory), |
| 310 capture_adapter_(NULL) { | 310 capture_adapter_(NULL) { |
| 311 DCHECK(factory_); | |
| 312 } | 311 } |
| 313 | 312 |
| 314 MediaStreamVideoSource::~MediaStreamVideoSource() { | 313 MediaStreamVideoSource::~MediaStreamVideoSource() { |
| 315 } | 314 } |
| 316 | 315 |
| 317 void MediaStreamVideoSource::AddTrack( | 316 void MediaStreamVideoSource::AddTrack( |
| 318 MediaStreamVideoTrack* track, | 317 MediaStreamVideoTrack* track, |
| 319 const blink::WebMediaConstraints& constraints, | 318 const blink::WebMediaConstraints& constraints, |
| 320 const ConstraintsCallback& callback) { | 319 const ConstraintsCallback& callback) { |
| 321 DCHECK(CalledOnValidThread()); | 320 DCHECK(CalledOnValidThread()); |
| (...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 530 MediaStreamVideoSource::RequestedConstraints::RequestedConstraints( | 529 MediaStreamVideoSource::RequestedConstraints::RequestedConstraints( |
| 531 const blink::WebMediaConstraints& constraints, | 530 const blink::WebMediaConstraints& constraints, |
| 532 const ConstraintsCallback& callback) | 531 const ConstraintsCallback& callback) |
| 533 : constraints(constraints), callback(callback) { | 532 : constraints(constraints), callback(callback) { |
| 534 } | 533 } |
| 535 | 534 |
| 536 MediaStreamVideoSource::RequestedConstraints::~RequestedConstraints() { | 535 MediaStreamVideoSource::RequestedConstraints::~RequestedConstraints() { |
| 537 } | 536 } |
| 538 | 537 |
| 539 } // namespace content | 538 } // namespace content |
| OLD | NEW |