mesa/src/android_stub/nativewindow_stub.cpp
David Stevens a2fb87eea6 egl/android: implement image cleanup callback
According to ANDROID_get_native_client_buffer, EGL implementations must
guarantee that the lifetime of an EGLClientBuffer returned by
eglGetNativeClientBufferANDROID is at least as long as that of the
EGLImage which is bound to. Do this by acquiring a reference to the
underlying AHardwareBuffer for all ANativeWindowBuffers which are bound
to an _EGLImage.

Signed-off-by: David Stevens <stevensd@chromium.org>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7805>
2020-12-15 06:05:27 +00:00

15 lines
265 B
C++

#include <vndk/window.h>
extern "C" {
AHardwareBuffer* ANativeWindowBuffer_getHardwareBuffer(ANativeWindowBuffer* anwb) {
return nullptr;
}
void AHardwareBuffer_acquire(AHardwareBuffer* buffer) {
}
void AHardwareBuffer_release(AHardwareBuffer* buffer) {
}
}