OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 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 554 matching lines...) Loading... |
565 IncomingVideoStreamMap::const_iterator item = | 565 IncomingVideoStreamMap::const_iterator item = |
566 _streamRenderMap.find(streamId); | 566 _streamRenderMap.find(streamId); |
567 if (item == _streamRenderMap.end()) | 567 if (item == _streamRenderMap.end()) |
568 { | 568 { |
569 // This stream doesn't exist | 569 // This stream doesn't exist |
570 WEBRTC_TRACE(kTraceError, kTraceVideoRenderer, _id, | 570 WEBRTC_TRACE(kTraceError, kTraceVideoRenderer, _id, |
571 "%s: stream doesn't exist", __FUNCTION__); | 571 "%s: stream doesn't exist", __FUNCTION__); |
572 return -1; | 572 return -1; |
573 } | 573 } |
574 assert (item->second != NULL); | 574 assert (item->second != NULL); |
575 return item->second->SetStartImage(videoFrame); | 575 item->second->SetStartImage(videoFrame); |
| 576 return 0; |
576 | 577 |
577 } | 578 } |
578 | 579 |
579 int32_t ModuleVideoRenderImpl::SetTimeoutImage(const uint32_t streamId, | 580 int32_t ModuleVideoRenderImpl::SetTimeoutImage(const uint32_t streamId, |
580 const VideoFrame& videoFrame, | 581 const VideoFrame& videoFrame, |
581 const uint32_t timeout) { | 582 const uint32_t timeout) { |
582 CriticalSectionScoped cs(&_moduleCrit); | 583 CriticalSectionScoped cs(&_moduleCrit); |
583 | 584 |
584 if (!_ptrRenderer) | 585 if (!_ptrRenderer) |
585 { | 586 { |
586 WEBRTC_TRACE(kTraceError, kTraceVideoRenderer, _id, | 587 WEBRTC_TRACE(kTraceError, kTraceVideoRenderer, _id, |
587 "%s: No renderer", __FUNCTION__); | 588 "%s: No renderer", __FUNCTION__); |
588 return -1; | 589 return -1; |
589 } | 590 } |
590 | 591 |
591 IncomingVideoStreamMap::const_iterator item = | 592 IncomingVideoStreamMap::const_iterator item = |
592 _streamRenderMap.find(streamId); | 593 _streamRenderMap.find(streamId); |
593 if (item == _streamRenderMap.end()) | 594 if (item == _streamRenderMap.end()) |
594 { | 595 { |
595 // This stream doesn't exist | 596 // This stream doesn't exist |
596 WEBRTC_TRACE(kTraceError, kTraceVideoRenderer, _id, | 597 WEBRTC_TRACE(kTraceError, kTraceVideoRenderer, _id, |
597 "%s: stream doesn't exist", __FUNCTION__); | 598 "%s: stream doesn't exist", __FUNCTION__); |
598 return -1; | 599 return -1; |
599 } | 600 } |
600 assert(item->second != NULL); | 601 assert(item->second != NULL); |
601 return item->second->SetTimeoutImage(videoFrame, timeout); | 602 item->second->SetTimeoutImage(videoFrame, timeout); |
| 603 return 0; |
602 } | 604 } |
603 | 605 |
604 } // namespace webrtc | 606 } // namespace webrtc |
OLD | NEW |