Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(204)

Side by Side Diff: talk/media/webrtc/webrtcvideoengine2.cc

Issue 1306813009: H.264 video codec support using OpenH264/FFmpeg (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Misc (WebRtcVideoChannel2::...::ConfigureVideoEncoderSettings care about H264 case) Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 479 matching lines...) Expand 10 before | Expand all | Expand 10 after
490 // No automatic resizing when using simulcast. 490 // No automatic resizing when using simulcast.
491 bool automatic_resize = !is_screencast && ssrcs_.size() == 1; 491 bool automatic_resize = !is_screencast && ssrcs_.size() == 1;
492 bool frame_dropping = !is_screencast; 492 bool frame_dropping = !is_screencast;
493 bool denoising; 493 bool denoising;
494 if (is_screencast) { 494 if (is_screencast) {
495 denoising = false; 495 denoising = false;
496 } else { 496 } else {
497 options.video_noise_reduction.Get(&denoising); 497 options.video_noise_reduction.Get(&denoising);
498 } 498 }
499 499
500 if (CodecNamesEq(codec.name, kH264CodecName)) {
501 encoder_settings_.h264 = webrtc::VideoEncoder::GetDefaultH264Settings();
502 encoder_settings_.h264.frameDroppingOn = frame_dropping;
503 return &encoder_settings_.h264;
504 }
500 if (CodecNamesEq(codec.name, kVp8CodecName)) { 505 if (CodecNamesEq(codec.name, kVp8CodecName)) {
501 encoder_settings_.vp8 = webrtc::VideoEncoder::GetDefaultVp8Settings(); 506 encoder_settings_.vp8 = webrtc::VideoEncoder::GetDefaultVp8Settings();
502 encoder_settings_.vp8.automaticResizeOn = automatic_resize; 507 encoder_settings_.vp8.automaticResizeOn = automatic_resize;
503 encoder_settings_.vp8.denoisingOn = denoising; 508 encoder_settings_.vp8.denoisingOn = denoising;
504 encoder_settings_.vp8.frameDroppingOn = frame_dropping; 509 encoder_settings_.vp8.frameDroppingOn = frame_dropping;
505 return &encoder_settings_.vp8; 510 return &encoder_settings_.vp8;
506 } 511 }
507 if (CodecNamesEq(codec.name, kVp9CodecName)) { 512 if (CodecNamesEq(codec.name, kVp9CodecName)) {
508 encoder_settings_.vp9 = webrtc::VideoEncoder::GetDefaultVp9Settings(); 513 encoder_settings_.vp9 = webrtc::VideoEncoder::GetDefaultVp9Settings();
509 encoder_settings_.vp9.denoisingOn = denoising; 514 encoder_settings_.vp9.denoisingOn = denoising;
(...skipping 2263 matching lines...) Expand 10 before | Expand all | Expand 10 after
2773 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id]; 2778 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id];
2774 } 2779 }
2775 } 2780 }
2776 2781
2777 return video_codecs; 2782 return video_codecs;
2778 } 2783 }
2779 2784
2780 } // namespace cricket 2785 } // namespace cricket
2781 2786
2782 #endif // HAVE_WEBRTC_VIDEO 2787 #endif // HAVE_WEBRTC_VIDEO
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698