OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 370 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
381 config_.pre_render_callback->FrameCallback(video_frame); | 381 config_.pre_render_callback->FrameCallback(video_frame); |
382 } | 382 } |
383 } | 383 } |
384 | 384 |
385 int VideoReceiveStream::RenderFrame(const uint32_t /*stream_id*/, | 385 int VideoReceiveStream::RenderFrame(const uint32_t /*stream_id*/, |
386 const VideoFrame& video_frame) { | 386 const VideoFrame& video_frame) { |
387 int64_t sync_offset_ms; | 387 int64_t sync_offset_ms; |
388 if (vie_sync_.GetStreamSyncOffsetInMs(video_frame, &sync_offset_ms)) | 388 if (vie_sync_.GetStreamSyncOffsetInMs(video_frame, &sync_offset_ms)) |
389 stats_proxy_.OnSyncOffsetUpdated(sync_offset_ms); | 389 stats_proxy_.OnSyncOffsetUpdated(sync_offset_ms); |
390 | 390 |
391 // TODO(pbos): Wire up config_.render->IsTextureSupported() and convert if not | 391 // TODO(pbos): Wire up config_.render->IsTextureSupported() and convert if not |
pbos-webrtc
2016/03/17 14:47:23
Remove this TODO
| |
392 // supported. Or provide methods for converting a texture frame in | 392 // supported. Or provide methods for converting a texture frame in |
393 // VideoFrame. | 393 // VideoFrame. |
394 | 394 |
395 if (config_.renderer != nullptr) | 395 if (config_.renderer != nullptr) |
396 config_.renderer->RenderFrame( | 396 config_.renderer->OnFrame(video_frame); |
397 video_frame, | |
398 video_frame.render_time_ms() - clock_->TimeInMilliseconds()); | |
399 | 397 |
400 stats_proxy_.OnRenderedFrame(video_frame); | 398 stats_proxy_.OnRenderedFrame(video_frame); |
401 | 399 |
402 return 0; | 400 return 0; |
403 } | 401 } |
404 | 402 |
405 // TODO(asapersson): Consider moving callback from video_encoder.h or | 403 // TODO(asapersson): Consider moving callback from video_encoder.h or |
406 // creating a different callback. | 404 // creating a different callback. |
407 int32_t VideoReceiveStream::Encoded( | 405 int32_t VideoReceiveStream::Encoded( |
408 const EncodedImage& encoded_image, | 406 const EncodedImage& encoded_image, |
(...skipping 27 matching lines...) Expand all Loading... | |
436 const std::vector<uint16_t>& sequence_numbers) { | 434 const std::vector<uint16_t>& sequence_numbers) { |
437 rtp_rtcp_->SendNack(sequence_numbers); | 435 rtp_rtcp_->SendNack(sequence_numbers); |
438 } | 436 } |
439 | 437 |
440 void VideoReceiveStream::RequestKeyFrame() { | 438 void VideoReceiveStream::RequestKeyFrame() { |
441 rtp_rtcp_->RequestKeyFrame(); | 439 rtp_rtcp_->RequestKeyFrame(); |
442 } | 440 } |
443 | 441 |
444 } // namespace internal | 442 } // namespace internal |
445 } // namespace webrtc | 443 } // namespace webrtc |
OLD | NEW |