OpenCV APIs for C/C++ which retrieves frames from camera or videos, perform their own memory allocation and return pointer to the buffered data. Is it possible to make these APIs store data in buffers allocated by the user? The reason being to avoid superfluous copying to this location which then consumes time. The reason for the specific buffers is its use with DMA which needs physical address to start transfers.