On an H7 R2, image replace of a grayscale QVGA image using HMIRROR and TRANSPOSE worked in FW V4.3.3, but in FW V 4.5.9 it causes an "Out of fast frame buffer stack memory.
Here is code that recreates the issue.
This is a bug due to the addition of GPU support. A memory request for a color lookup table happens after all frame buffer ram is allocated for transpose.
The error will not happen on any camera that has SDRAM as the alloc_all which is exhausting memory is only issued to allocate all internal SRAM.
Also, the API has change for this. Replace/Set/Assign are all just aliases of draw_image now. They as binary operations (two arguments) and do not modify the destination image other than it’s pixels. Please use the unary image operations to modify an image with transpose.
Use scale()/crop() as these are the unary operations which don’t change the pixel format. They are both aliases of each other. I couldn’t think of a good name for a generic unary image operation function that can scale, crop, mirror, transpose, flip. So, scale()/crop() are what’s there now.
Attached is an H7 firmware with a fix for this. This is from the tip of dev though which is undergoing major changes right now. firmware.zip (1.1 MB)