'get an image from the android buffer in BLOB format

I am trying to get an image from the Android buffer and which is in BLOB format. Does anyone know the solution in the CPP language?

AHardwareBuffer_Desc usage; AHardwareBuffer_describe(buffer, &usage);



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source