From 7cff1b7359a6348d17c9ce7f877d4ac71898f046 Mon Sep 17 00:00:00 2001 From: Harish Mahendrakar Date: Tue, 7 Apr 2020 01:35:52 +0530 Subject: [PATCH] C2SoftAVCEnc: Change default dimensions and frame rate In order to support signalling lower levels, default dimensions and frame rate are set to smaller values, such that minimum level calculations done with default values still stay at lowest level supported Bug: 149360064 Bug: 151423508 Test: atest android.media.cts.MediaRecorderTest#\ testProfileAvcBaselineLevel1 Change-Id: Ic86e5d728d99652ea4e4a46df4f46b3ff3b357ac Merged-In: Ic86e5d728d99652ea4e4a46df4f46b3ff3b357ac --- media/codec2/components/avc/C2SoftAvcEnc.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/media/codec2/components/avc/C2SoftAvcEnc.cpp b/media/codec2/components/avc/C2SoftAvcEnc.cpp index e3d419c8db..ab93ce39f5 100644 --- a/media/codec2/components/avc/C2SoftAvcEnc.cpp +++ b/media/codec2/components/avc/C2SoftAvcEnc.cpp @@ -103,7 +103,7 @@ public: addParameter( DefineParam(mSize, C2_PARAMKEY_PICTURE_SIZE) - .withDefault(new C2StreamPictureSizeInfo::input(0u, 320, 240)) + .withDefault(new C2StreamPictureSizeInfo::input(0u, 16, 16)) .withFields({ C2F(mSize, width).inRange(2, 2560, 2), C2F(mSize, height).inRange(2, 2560, 2), @@ -129,7 +129,7 @@ public: addParameter( DefineParam(mFrameRate, C2_PARAMKEY_FRAME_RATE) - .withDefault(new C2StreamFrameRateInfo::output(0u, 30.)) + .withDefault(new C2StreamFrameRateInfo::output(0u, 1.)) // TODO: More restriction? .withFields({C2F(mFrameRate, value).greaterThan(0.)}) .withSetter(Setter::StrictValueWithNoDeps)