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

Commit 77d406d3 authored by Ady Abraham's avatar Ady Abraham
Browse files

SF: add FrameRateCategory to dumpsys

Test: manual
Change-Id: I61872e7f1dd441c831212ffae519dbda1187176c
parent 81d8aadf
Loading
Loading
Loading
Loading
+9 −1
Original line number Diff line number Diff line
@@ -1718,10 +1718,18 @@ void Layer::miniDump(std::string& result, const frontend::LayerSnapshot& snapsho
    StringAppendF(&result, "%6.1f %6.1f %6.1f %6.1f | ", crop.left, crop.top, crop.right,
                  crop.bottom);
    const auto frameRate = snapshot.frameRate;
    std::string frameRateStr;
    if (frameRate.vote.rate.isValid()) {
        StringAppendF(&frameRateStr, "%.2f", frameRate.vote.rate.getValue());
    }
    if (frameRate.vote.rate.isValid() || frameRate.vote.type != FrameRateCompatibility::Default) {
        StringAppendF(&result, "%s %15s %17s", to_string(frameRate.vote.rate).c_str(),
        StringAppendF(&result, "%6s %15s %17s", frameRateStr.c_str(),
                      ftl::enum_string(frameRate.vote.type).c_str(),
                      ftl::enum_string(frameRate.vote.seamlessness).c_str());
    } else if (frameRate.category != FrameRateCategory::Default) {
        StringAppendF(&result, "%6s %15s %17s", frameRateStr.c_str(),
                      (std::string("Cat::") + ftl::enum_string(frameRate.category)).c_str(),
                      ftl::enum_string(frameRate.vote.seamlessness).c_str());
    } else {
        result.append(41, ' ');
    }