| 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/pepper/pepper_media_stream_video_track_host.h" | 5 #include "content/renderer/pepper/pepper_media_stream_video_track_host.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include "base/base64.h" | 9 #include "base/base64.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 428 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 439 } | 439 } |
| 440 | 440 |
| 441 void StopSourceImpl() final { | 441 void StopSourceImpl() final { |
| 442 if (host_) | 442 if (host_) |
| 443 host_->frame_deliverer_ = nullptr; | 443 host_->frame_deliverer_ = nullptr; |
| 444 } | 444 } |
| 445 | 445 |
| 446 private: | 446 private: |
| 447 base::Optional<media::VideoCaptureFormat> GetCurrentFormatImpl() | 447 base::Optional<media::VideoCaptureFormat> GetCurrentFormatImpl() |
| 448 const override { | 448 const override { |
| 449 DCHECK(!IsOldVideoConstraints()); | |
| 450 if (host_) { | 449 if (host_) { |
| 451 return base::Optional<media::VideoCaptureFormat>( | 450 return base::Optional<media::VideoCaptureFormat>( |
| 452 media::VideoCaptureFormat( | 451 media::VideoCaptureFormat( |
| 453 host_->plugin_frame_size_, kDefaultOutputFrameRate, | 452 host_->plugin_frame_size_, kDefaultOutputFrameRate, |
| 454 ToPixelFormat(host_->plugin_frame_format_))); | 453 ToPixelFormat(host_->plugin_frame_format_))); |
| 455 } | 454 } |
| 456 return base::Optional<media::VideoCaptureFormat>(); | 455 return base::Optional<media::VideoCaptureFormat>(); |
| 457 } | 456 } |
| 458 | 457 |
| 459 const base::WeakPtr<PepperMediaStreamVideoTrackHost> host_; | 458 const base::WeakPtr<PepperMediaStreamVideoTrackHost> host_; |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 545 } | 544 } |
| 546 | 545 |
| 547 void PepperMediaStreamVideoTrackHost::OnTrackStarted( | 546 void PepperMediaStreamVideoTrackHost::OnTrackStarted( |
| 548 MediaStreamSource* source, | 547 MediaStreamSource* source, |
| 549 MediaStreamRequestResult result, | 548 MediaStreamRequestResult result, |
| 550 const blink::WebString& result_name) { | 549 const blink::WebString& result_name) { |
| 551 DVLOG(3) << "OnTrackStarted result: " << result; | 550 DVLOG(3) << "OnTrackStarted result: " << result; |
| 552 } | 551 } |
| 553 | 552 |
| 554 } // namespace content | 553 } // namespace content |
| OLD | NEW |