Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d71c11da authored by Ray Essick's avatar Ray Essick
Browse files

Enable media format shaping by default

can be overridden with property debug.stagefright.enableshaping
(set to 0 means off)

Bug: 184861758
Test: Video Quality test Suite
Change-Id: I5905b19ee23589ddd249e9b396ca069012cb6eb9
parent 178db0fa
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -1422,6 +1422,7 @@ status_t MediaCodec::setOnFirstTunnelFrameReadyNotification(const sp<AMessage> &
 * MediaFormat Shaping forward declarations
 * including the property name we use for control.
 */
static int enableMediaFormatShapingDefault = 1;
static const char enableMediaFormatShapingProperty[] = "debug.stagefright.enableshaping";
static void mapFormat(AString componentName, const sp<AMessage> &format, const char *kind,
                      bool reverse);
@@ -1497,7 +1498,8 @@ status_t MediaCodec::configure(
    }

    if (flags & CONFIGURE_FLAG_ENCODE) {
        int8_t enableShaping = property_get_bool(enableMediaFormatShapingProperty, 0);
        int8_t enableShaping = property_get_bool(enableMediaFormatShapingProperty,
                                                 enableMediaFormatShapingDefault);
        if (!enableShaping) {
            ALOGI("format shaping disabled, property '%s'", enableMediaFormatShapingProperty);
        } else {