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

Commit fa79af6d authored by Jerome Gaillard's avatar Jerome Gaillard Committed by Android (Google) Code Review
Browse files

Merge "Use HWUIProperties.sysprop in host builds" into main

parents f05ab200 ea9bf2a5
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -563,6 +563,7 @@ cc_defaults {
        "FrameInfoVisualizer.cpp",
        "FrameMetricsReporter.cpp",
        "Gainmap.cpp",
        "HWUIProperties.sysprop",
        "Interpolator.cpp",
        "JankTracker.cpp",
        "LightingInfo.cpp",
@@ -628,7 +629,6 @@ cc_defaults {
                "AutoBackendTextureRelease.cpp",
                "DeferredLayerUpdater.cpp",
                "HardwareBitmapUploader.cpp",
                "HWUIProperties.sysprop",
                "Layer.cpp",
                "LayerUpdateQueue.cpp",
                "ProfileDataContainer.cpp",
+2 −14
Original line number Diff line number Diff line
@@ -16,10 +16,6 @@

#include "Properties.h"

#include "Debug.h"
#ifdef __ANDROID__
#include "HWUIProperties.sysprop.h"
#endif
#include <android-base/properties.h>
#include <cutils/compiler.h>
#include <log/log.h>
@@ -28,6 +24,8 @@
#include <cstdlib>
#include <optional>

#include "Debug.h"
#include "HWUIProperties.sysprop.h"
#include "src/core/SkTraceEventCommon.h"

#ifdef __ANDROID__
@@ -47,16 +45,6 @@ constexpr bool hdr_10bit_plus() {
namespace android {
namespace uirenderer {

#ifndef __ANDROID__ // Layoutlib does not compile HWUIProperties.sysprop as it depends on cutils properties
std::optional<bool> use_vulkan() {
    return base::GetBoolProperty("ro.hwui.use_vulkan", true);
}

std::optional<std::int32_t> render_ahead() {
    return base::GetIntProperty("ro.hwui.render_ahead", 0);
}
#endif

bool Properties::debugLayersUpdates = false;
bool Properties::debugOverdraw = false;
bool Properties::debugTraceGpuResourceCategories = false;