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 511 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
522 } | 522 } |
523 | 523 |
524 bool VCMCodecDataBase::MatchesCurrentResolution(int width, int height) const { | 524 bool VCMCodecDataBase::MatchesCurrentResolution(int width, int height) const { |
525 return send_codec_.width == width && send_codec_.height == height; | 525 return send_codec_.width == width && send_codec_.height == height; |
526 } | 526 } |
527 | 527 |
528 VCMGenericDecoder* VCMCodecDataBase::CreateAndInitDecoder( | 528 VCMGenericDecoder* VCMCodecDataBase::CreateAndInitDecoder( |
529 const VCMEncodedFrame& frame, | 529 const VCMEncodedFrame& frame, |
530 VideoCodec* new_codec) const { | 530 VideoCodec* new_codec) const { |
531 uint8_t payload_type = frame.PayloadType(); | 531 uint8_t payload_type = frame.PayloadType(); |
| 532 LOG(LS_INFO) << "Initializing decoder with payload type '" |
| 533 << static_cast<int>(payload_type) << "'."; |
532 assert(new_codec); | 534 assert(new_codec); |
533 const VCMDecoderMapItem* decoder_item = FindDecoderItem(payload_type); | 535 const VCMDecoderMapItem* decoder_item = FindDecoderItem(payload_type); |
534 if (!decoder_item) { | 536 if (!decoder_item) { |
535 LOG(LS_ERROR) << "Can't find a decoder associated with payload type: " | 537 LOG(LS_ERROR) << "Can't find a decoder associated with payload type: " |
536 << static_cast<int>(payload_type); | 538 << static_cast<int>(payload_type); |
537 return nullptr; | 539 return nullptr; |
538 } | 540 } |
539 VCMGenericDecoder* ptr_decoder = nullptr; | 541 VCMGenericDecoder* ptr_decoder = nullptr; |
540 const VCMExtDecoderMapItem* external_dec_item = | 542 const VCMExtDecoderMapItem* external_dec_item = |
541 FindExternalDecoderItem(payload_type); | 543 FindExternalDecoderItem(payload_type); |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
606 | 608 |
607 const VCMExtDecoderMapItem* VCMCodecDataBase::FindExternalDecoderItem( | 609 const VCMExtDecoderMapItem* VCMCodecDataBase::FindExternalDecoderItem( |
608 uint8_t payload_type) const { | 610 uint8_t payload_type) const { |
609 ExternalDecoderMap::const_iterator it = dec_external_map_.find(payload_type); | 611 ExternalDecoderMap::const_iterator it = dec_external_map_.find(payload_type); |
610 if (it != dec_external_map_.end()) { | 612 if (it != dec_external_map_.end()) { |
611 return (*it).second; | 613 return (*it).second; |
612 } | 614 } |
613 return nullptr; | 615 return nullptr; |
614 } | 616 } |
615 } // namespace webrtc | 617 } // namespace webrtc |
OLD | NEW |