Use libnativewindow's AHardwareBuffer directly

This is a part of cutting dependency from libmediandk to
libandroid_runtime.

The following function is exported from libandroid_runtime.
* android_hardware_HardwareBuffer_convertToGrallocUsageBits

This function just delegates to libnativewindow's
AHardwareBuffer_convertToGrallocUsageBits function.

This commit is for libmediandk to call libnativewindow's
function directly in order to cut the dependency to libandroid_runtime.

Bug: 124268753
Test: m -j
Change-Id: I5f927fc26829031a8c91a7ba51178a34d737a953
diff --git a/media/ndk/NdkImage.cpp b/media/ndk/NdkImage.cpp
index 20b1667..1883f63 100644
--- a/media/ndk/NdkImage.cpp
+++ b/media/ndk/NdkImage.cpp
@@ -23,7 +23,7 @@
 #include "NdkImageReaderPriv.h"
 
 #include <android_media_Utils.h>
-#include <android_runtime/android_hardware_HardwareBuffer.h>
+#include <private/android/AHardwareBufferHelpers.h>
 #include <utils/Log.h>
 #include "hardware/camera3.h"
 
@@ -190,7 +190,7 @@
 
     auto lockedBuffer = std::make_unique<CpuConsumer::LockedBuffer>();
 
-    uint64_t grallocUsage = android_hardware_HardwareBuffer_convertToGrallocUsageBits(mUsage);
+    uint64_t grallocUsage = AHardwareBuffer_convertToGrallocUsageBits(mUsage);
 
     status_t ret =
             lockImageFromBuffer(mBuffer, grallocUsage, mBuffer->mFence->dup(), lockedBuffer.get());