Commit 180f9985 authored by khushalsagar's avatar khushalsagar Committed by Commit bot

Revert of MediaRecorder: enable encode acceleration for VP8 in Android...

Revert of MediaRecorder: enable encode acceleration for VP8 in Android (patchset #1 id:40001 of https://codereview.chromium.org/2852583002/ )

Reason for revert:
Speculatively reverting since WebRtcMediaRecorderTest.PeerConnection tests on Marshmallow 64 bit Tester have become flaky since the patch landed.

Original issue's description:
> MediaRecorder: enable encode acceleration for VP8 in Android
>
> This is a refry of https://crrev.com/2801803002 (as pointed out
> in https://crrev.com/2836013006) that enables only VP8
> hardware encoding in Android.
>
> Tested via webrtc_media_recorder_browsertest.cc [1]
>
> [1] https://cs.chromium.org/chromium/src/content/browser/webrtc/webrtc_media_recorder_browsertest.cc?q=webrtc+mediarecorder&sq=package:chromium&dr=CSs&l=27
>
> BUG=638664
>
> Review-Url: https://codereview.chromium.org/2852583002
> Cr-Commit-Position: refs/heads/master@{#467879}
> Committed: https://chromium.googlesource.com/chromium/src/+/6089c73618b3b5010bdb81441c6f5f58936f9e58

TBR=emircan@chromium.org,mcasas@chromium.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=638664

Review-Url: https://codereview.chromium.org/2846403002
Cr-Commit-Position: refs/heads/master@{#468204}
parent 56637492
......@@ -109,6 +109,11 @@ CodecEnumerator::CodecEnumerator() {
return;
#endif
#if defined(OS_ANDROID)
// See https://crbug.com/653864.
return;
#endif
content::RenderThreadImpl* const render_thread_impl =
content::RenderThreadImpl::current();
if (!render_thread_impl) {
......@@ -127,17 +132,12 @@ CodecEnumerator::CodecEnumerator() {
gpu_factories->GetVideoEncodeAcceleratorSupportedProfiles();
for (const auto& supported_profile : vea_supported_profiles) {
for (auto& codec_id_and_profile : kPreferredCodecIdAndVEAProfiles) {
const media::VideoCodecProfile codec = supported_profile.profile;
#if defined(OS_ANDROID)
// TODO(mcasas): enable other codecs, https://crbug.com/653864.
if (codec < media::VP8PROFILE_MIN || codec > media::VP8PROFILE_MAX)
continue;
#endif
if (codec >= codec_id_and_profile.min_profile &&
codec <= codec_id_and_profile.max_profile) {
DVLOG(2) << "Accelerated codec found: " << media::GetProfileName(codec);
codec_id_to_profile_.insert(
std::make_pair(codec_id_and_profile.codec_id, codec));
if (supported_profile.profile >= codec_id_and_profile.min_profile &&
supported_profile.profile <= codec_id_and_profile.max_profile) {
DVLOG(2) << "Accelerated codec found: "
<< media::GetProfileName(supported_profile.profile);
codec_id_to_profile_.insert(std::make_pair(
codec_id_and_profile.codec_id, supported_profile.profile));
}
}
}
......
......@@ -32,13 +32,8 @@ class VideoFrame;
} // namespace media
namespace video_track_recorder {
#if defined(OS_ANDROID)
const int kVEAEncoderMinResolutionWidth = 176;
const int kVEAEncoderMinResolutionHeight = 144;
#else
const int kVEAEncoderMinResolutionWidth = 640;
const int kVEAEncoderMinResolutionHeight = 480;
#endif
} // namespace video_track_recorder
namespace content {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment