OLD | NEW |
---|---|
1 /* | 1 /* |
2 * libjingle | 2 * libjingle |
3 * Copyright 2014 Google Inc. | 3 * Copyright 2014 Google Inc. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are met: | 6 * modification, are permitted provided that the following conditions are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright notice, | 8 * 1. Redistributions of source code must retain the above copyright notice, |
9 * this list of conditions and the following disclaimer. | 9 * this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright notice, | 10 * 2. Redistributions in binary form must reproduce the above copyright notice, |
(...skipping 2473 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2484 } | 2484 } |
2485 } | 2485 } |
2486 | 2486 |
2487 VideoRenderer* WebRtcVideoChannel2::WebRtcVideoReceiveStream::GetRenderer() { | 2487 VideoRenderer* WebRtcVideoChannel2::WebRtcVideoReceiveStream::GetRenderer() { |
2488 // TODO(pbos): Remove GetRenderer and all uses of it, it's thread-unsafe by | 2488 // TODO(pbos): Remove GetRenderer and all uses of it, it's thread-unsafe by |
2489 // design. | 2489 // design. |
2490 rtc::CritScope crit(&renderer_lock_); | 2490 rtc::CritScope crit(&renderer_lock_); |
2491 return renderer_; | 2491 return renderer_; |
2492 } | 2492 } |
2493 | 2493 |
2494 void WebRtcVideoChannel2::WebRtcVideoReceiveStream::SetSize(int width, | 2494 void WebRtcVideoChannel2::WebRtcVideoReceiveStream::SetSize(int width, |
pbos-webrtc
2016/01/11 10:25:01
I think you should be able to remove this method c
nisse-webrtc
2016/01/11 12:26:06
I'm deleting the SetSize method. But last_width_ a
| |
2495 int height) { | 2495 int height) { |
2496 rtc::CritScope crit(&renderer_lock_); | 2496 rtc::CritScope crit(&renderer_lock_); |
2497 if (!renderer_->SetSize(width, height, 0)) { | |
2498 LOG(LS_ERROR) << "Could not set renderer size."; | |
2499 } | |
2500 last_width_ = width; | 2497 last_width_ = width; |
2501 last_height_ = height; | 2498 last_height_ = height; |
2502 } | 2499 } |
2503 | 2500 |
2504 std::string | 2501 std::string |
2505 WebRtcVideoChannel2::WebRtcVideoReceiveStream::GetCodecNameFromPayloadType( | 2502 WebRtcVideoChannel2::WebRtcVideoReceiveStream::GetCodecNameFromPayloadType( |
2506 int payload_type) { | 2503 int payload_type) { |
2507 for (const webrtc::VideoReceiveStream::Decoder& decoder : config_.decoders) { | 2504 for (const webrtc::VideoReceiveStream::Decoder& decoder : config_.decoders) { |
2508 if (decoder.payload_type == payload_type) { | 2505 if (decoder.payload_type == payload_type) { |
2509 return decoder.payload_name; | 2506 return decoder.payload_name; |
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2663 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id]; | 2660 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id]; |
2664 } | 2661 } |
2665 } | 2662 } |
2666 | 2663 |
2667 return video_codecs; | 2664 return video_codecs; |
2668 } | 2665 } |
2669 | 2666 |
2670 } // namespace cricket | 2667 } // namespace cricket |
2671 | 2668 |
2672 #endif // HAVE_WEBRTC_VIDEO | 2669 #endif // HAVE_WEBRTC_VIDEO |
OLD | NEW |