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

Commit 7f16d5bf authored by Android Build Coastguard Worker's avatar Android Build Coastguard Worker
Browse files

Snap for 8470411 from 8782a6ba to tm-qpr1-release

Change-Id: I08c7fc7c261c07014a066adbde259e0230f53166
parents 78dbda4b 8782a6ba
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -77,7 +77,7 @@ public:
     * have
     */
    [[nodiscard]] status_t setupInetServer(const char* address, unsigned int port,
                                           unsigned int* assignedPort);
                                           unsigned int* assignedPort = nullptr);

    /**
     * If setup*Server has been successful, return true. Otherwise return false.
+5 −0
Original line number Diff line number Diff line
@@ -17,6 +17,7 @@
#pragma once

#include <aidl/android/hardware/graphics/composer3/DimmingStage.h>
#include <aidl/android/hardware/graphics/composer3/RenderIntent.h>
#include <iosfwd>

#include <math/mat4.h>
@@ -73,6 +74,10 @@ struct DisplaySettings {
    // Configures when dimming should be applied for each layer.
    aidl::android::hardware::graphics::composer3::DimmingStage dimmingStage =
            aidl::android::hardware::graphics::composer3::DimmingStage::NONE;

    // Configures the rendering intent of the output display. This is used for tonemapping.
    aidl::android::hardware::graphics::composer3::RenderIntent renderIntent =
            aidl::android::hardware::graphics::composer3::RenderIntent::TONE_MAP_COLORIMETRIC;
};

static inline bool operator==(const DisplaySettings& lhs, const DisplaySettings& rhs) {
+1 −1
Original line number Diff line number Diff line
@@ -662,7 +662,7 @@ sk_sp<SkShader> SkiaGLRenderEngine::createRuntimeEffectShader(
                                        parameters.display.maxLuminance,
                                        parameters.display.currentLuminanceNits,
                                        parameters.layer.source.buffer.maxLuminanceNits,
                                        hardwareBuffer);
                                        hardwareBuffer, parameters.display.renderIntent);
    }
    return parameters.shader;
}
+7 −7
Original line number Diff line number Diff line
@@ -40,12 +40,11 @@ sk_sp<SkRuntimeEffect> buildRuntimeEffect(const shaders::LinearEffect& linearEff
    return shader;
}

sk_sp<SkShader> createLinearEffectShader(sk_sp<SkShader> shader,
                                         const shaders::LinearEffect& linearEffect,
                                         sk_sp<SkRuntimeEffect> runtimeEffect,
                                         const mat4& colorTransform, float maxDisplayLuminance,
                                         float currentDisplayLuminanceNits, float maxLuminance,
                                         AHardwareBuffer* buffer) {
sk_sp<SkShader> createLinearEffectShader(
        sk_sp<SkShader> shader, const shaders::LinearEffect& linearEffect,
        sk_sp<SkRuntimeEffect> runtimeEffect, const mat4& colorTransform, float maxDisplayLuminance,
        float currentDisplayLuminanceNits, float maxLuminance, AHardwareBuffer* buffer,
        aidl::android::hardware::graphics::composer3::RenderIntent renderIntent) {
    ATRACE_CALL();
    SkRuntimeShaderBuilder effectBuilder(runtimeEffect);

@@ -53,7 +52,8 @@ sk_sp<SkShader> createLinearEffectShader(sk_sp<SkShader> shader,

    const auto uniforms =
            shaders::buildLinearEffectUniforms(linearEffect, colorTransform, maxDisplayLuminance,
                                               currentDisplayLuminanceNits, maxLuminance, buffer);
                                               currentDisplayLuminanceNits, maxLuminance, buffer,
                                               renderIntent);

    for (const auto& uniform : uniforms) {
        effectBuilder.uniform(uniform.name.c_str()).set(uniform.value.data(), uniform.value.size());
+7 −6
Original line number Diff line number Diff line
@@ -42,12 +42,13 @@ sk_sp<SkRuntimeEffect> buildRuntimeEffect(const shaders::LinearEffect& linearEff
// or as the max light level from the CTA 861.3 standard.
// * An AHardwareBuffer for implementations that support gralloc4 metadata for
// communicating any HDR metadata.
sk_sp<SkShader> createLinearEffectShader(sk_sp<SkShader> inputShader,
                                         const shaders::LinearEffect& linearEffect,
                                         sk_sp<SkRuntimeEffect> runtimeEffect,
                                         const mat4& colorTransform, float maxDisplayLuminance,
                                         float currentDisplayLuminanceNits, float maxLuminance,
                                         AHardwareBuffer* buffer);
// * A RenderIntent that communicates the downstream renderintent for a physical display, for image
// quality compensation.
sk_sp<SkShader> createLinearEffectShader(
        sk_sp<SkShader> inputShader, const shaders::LinearEffect& linearEffect,
        sk_sp<SkRuntimeEffect> runtimeEffect, const mat4& colorTransform, float maxDisplayLuminance,
        float currentDisplayLuminanceNits, float maxLuminance, AHardwareBuffer* buffer,
        aidl::android::hardware::graphics::composer3::RenderIntent renderIntent);
} // namespace skia
} // namespace renderengine
} // namespace android
Loading