diff options
author | 2021-10-14 00:39:15 +0000 | |
---|---|---|
committer | 2021-10-15 23:15:03 +0000 | |
commit | b398ee21f8cac1d785994e8cc313d32d98ed4c75 (patch) | |
tree | 9f8a1463b98b356010f8d150f62a96601d1fc7ca /services/surfaceflinger/RegionSamplingThread.h | |
parent | 2c57783414c8343114c9d8548ac7c3dbbb26898c (diff) |
Consolidate WpHash declaration to a common file
Bug: b/193932763
Test: frameworks/native/test
Change-Id: Ib19f191ed8031b77c059b644fe5df3c8137e6619
Diffstat (limited to 'services/surfaceflinger/RegionSamplingThread.h')
-rw-r--r-- | services/surfaceflinger/RegionSamplingThread.h | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/services/surfaceflinger/RegionSamplingThread.h b/services/surfaceflinger/RegionSamplingThread.h index 2231853fcb..f715309b2e 100644 --- a/services/surfaceflinger/RegionSamplingThread.h +++ b/services/surfaceflinger/RegionSamplingThread.h @@ -30,6 +30,7 @@ #include <unordered_map> #include "Scheduler/OneShotTimer.h" +#include "WpHash.h" namespace android { @@ -88,11 +89,6 @@ private: sp<IRegionSamplingListener> listener; }; - struct WpHash { - size_t operator()(const wp<IBinder>& p) const { - return std::hash<IBinder*>()(p.unsafe_get()); - } - }; std::vector<float> sampleBuffer( const sp<GraphicBuffer>& buffer, const Point& leftTop, const std::vector<RegionSamplingThread::Descriptor>& descriptors, uint32_t orientation); |