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

Commit 2bb83067 authored by Jesse Hall's avatar Jesse Hall Committed by Android Git Automerger
Browse files

am 68c4d784: am 7127d17d: Merge "Fix HWComposer dumping of float source crops" into klp-dev

* commit '68c4d784':
  Fix HWComposer dumping of float source crops
parents a482ef80 68c4d784
Loading
Loading
Loading
Loading
+20 −10
Original line number Original line Diff line number Diff line
@@ -988,8 +988,8 @@ void HWComposer::dump(String8& result) const {


                result.append(
                result.append(
                        "    type    |  handle  |   hints  |   flags  | tr | blend |  format  |          source crop            |           frame           name \n"
                        "    type    |  handle  |   hints  |   flags  | tr | blend |  format  |          source crop            |           frame           name \n"
                        "------------+----------+----------+----------+----+-------+----------+---------------------------+--------------------------------\n");
                        "------------+----------+----------+----------+----+-------+----------+---------------------------------+--------------------------------\n");
                //      " __________ | ________ | ________ | ________ | __ | _____ | ________ | [_____,_____,_____,_____] | [_____,_____,_____,_____]
                //      " __________ | ________ | ________ | ________ | __ | _____ | ________ | [_____._,_____._,_____._,_____._] | [_____,_____,_____,_____]
                for (size_t i=0 ; i<disp.list->numHwLayers ; i++) {
                for (size_t i=0 ; i<disp.list->numHwLayers ; i++) {
                    const hwc_layer_1_t&l = disp.list->hwLayers[i];
                    const hwc_layer_1_t&l = disp.list->hwLayers[i];
                    int32_t format = -1;
                    int32_t format = -1;
@@ -1020,8 +1020,17 @@ void HWComposer::dump(String8& result) const {
                    if (type >= NELEM(compositionTypeName))
                    if (type >= NELEM(compositionTypeName))
                        type = NELEM(compositionTypeName) - 1;
                        type = NELEM(compositionTypeName) - 1;


                    if (hwcHasApiVersion(mHwc, HWC_DEVICE_API_VERSION_1_3)) {
                        result.appendFormat(
                                " %10s | %08x | %08x | %08x | %02x | %05x | %08x | [%7.1f,%7.1f,%7.1f,%7.1f] | [%5d,%5d,%5d,%5d] %s\n",
                                        compositionTypeName[type],
                                        intptr_t(l.handle), l.hints, l.flags, l.transform, l.blending, format,
                                        l.sourceCropf.left, l.sourceCropf.top, l.sourceCropf.right, l.sourceCropf.bottom,
                                        l.displayFrame.left, l.displayFrame.top, l.displayFrame.right, l.displayFrame.bottom,
                                        name.string());
                    } else {
                        result.appendFormat(
                        result.appendFormat(
                            " %10s | %08x | %08x | %08x | %02x | %05x | %08x | [%5d,%5d,%5d,%5d] | [%5d,%5d,%5d,%5d] %s\n",
                                " %10s | %08x | %08x | %08x | %02x | %05x | %08x | [%7d,%7d,%7d,%7d] | [%5d,%5d,%5d,%5d] %s\n",
                                        compositionTypeName[type],
                                        compositionTypeName[type],
                                        intptr_t(l.handle), l.hints, l.flags, l.transform, l.blending, format,
                                        intptr_t(l.handle), l.hints, l.flags, l.transform, l.blending, format,
                                        l.sourceCrop.left, l.sourceCrop.top, l.sourceCrop.right, l.sourceCrop.bottom,
                                        l.sourceCrop.left, l.sourceCrop.top, l.sourceCrop.right, l.sourceCrop.bottom,
@@ -1031,6 +1040,7 @@ void HWComposer::dump(String8& result) const {
                }
                }
            }
            }
        }
        }
    }


    if (mHwc && mHwc->dump) {
    if (mHwc && mHwc->dump) {
        const size_t SIZE = 4096;
        const size_t SIZE = 4096;