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

Commit 2b739bbb authored by Bo Liu's avatar Bo Liu
Browse files

Performance hint ndk APIs

Test: atest PerformanceHintNativeTestCases
Change-Id: I8f410cf5ee8cee90465d1ce48a42c9ff8bbe80c4
parent e469cfae
Loading
Loading
Loading
Loading
+4 −5
Original line number Diff line number Diff line
@@ -16,19 +16,18 @@
#ifndef DRAWFRAMETASK_H
#define DRAWFRAMETASK_H

#include <optional>
#include <vector>

#include <performance_hint_private.h>
#include <android/performance_hint.h>
#include <utils/Condition.h>
#include <utils/Mutex.h>
#include <utils/StrongPointer.h>

#include "RenderTask.h"
#include <optional>
#include <vector>

#include "../FrameInfo.h"
#include "../Rect.h"
#include "../TreeInfo.h"
#include "RenderTask.h"

namespace android {
namespace uirenderer {
+6 −6
Original line number Diff line number Diff line
@@ -314,18 +314,18 @@ LIBANDROID {
    AThermal_registerThermalStatusListener; # introduced=30
    AThermal_unregisterThermalStatusListener; # introduced=30
    AThermal_getThermalHeadroom; # introduced=31
    APerformanceHint_getManager; # introduced=Tiramisu
    APerformanceHint_createSession; # introduced=Tiramisu
    APerformanceHint_getPreferredUpdateRateNanos; # introduced=Tiramisu
    APerformanceHint_updateTargetWorkDuration; # introduced=Tiramisu
    APerformanceHint_reportActualWorkDuration; # introduced=Tiramisu
    APerformanceHint_closeSession; # introduced=Tiramisu
  local:
    *;
};

LIBANDROID_PLATFORM {
  global:
    APerformanceHint_getManager;
    APerformanceHint_createSession;
    APerformanceHint_getPreferredUpdateRateNanos;
    APerformanceHint_updateTargetWorkDuration;
    APerformanceHint_reportActualWorkDuration;
    APerformanceHint_closeSession;
    APerformanceHint_setIHintManagerForTesting;
    extern "C++" {
        ASurfaceControl_registerSurfaceStatsListener*;
+4 −3
Original line number Diff line number Diff line
@@ -16,17 +16,18 @@

#define LOG_TAG "perf_hint"

#include <utility>
#include <vector>

#include <android/os/IHintManager.h>
#include <android/os/IHintSession.h>
#include <android/performance_hint.h>
#include <binder/Binder.h>
#include <binder/IBinder.h>
#include <binder/IServiceManager.h>
#include <performance_hint_private.h>
#include <utils/SystemClock.h>

#include <utility>
#include <vector>

using namespace android;
using namespace android::os;

+2 −0
Original line number Diff line number Diff line
@@ -18,10 +18,12 @@

#include <android/os/IHintManager.h>
#include <android/os/IHintSession.h>
#include <android/performance_hint.h>
#include <binder/IBinder.h>
#include <gmock/gmock.h>
#include <gtest/gtest.h>
#include <performance_hint_private.h>

#include <memory>
#include <vector>