These geometric transforms can be quite useful. However when attempting to build for RP2350, the following linker error was produced:
/usr/lib/gcc/arm-none-eabi/13.2.1/../../../arm-none-eabi/bin/ld: firmware.elf section `.bss' will not fit in region `RAM'
/usr/lib/gcc/arm-none-eabi/13.2.1/../../../arm-none-eabi/bin/ld: region `RAM' overflowed by 212320 bytes
It turns out that OpenCV's warp functions make use of large interpolation tables that are made static:
https://github.com/opencv/opencv/blob/9cdd525bc59b34a3db8f6db905216c5398ca93d6/modules/imgproc/src/imgwarp.cpp#L129-L143
Rough napkin math shows these tables require >500kB of memory. And because they're static, they all get loaded into RAM. Yikes!
These geometric transforms can be quite useful. However when attempting to build for RP2350, the following linker error was produced:
It turns out that OpenCV's warp functions make use of large interpolation tables that are made
static:https://github.com/opencv/opencv/blob/9cdd525bc59b34a3db8f6db905216c5398ca93d6/modules/imgproc/src/imgwarp.cpp#L129-L143
Rough napkin math shows these tables require >500kB of memory. And because they're static, they all get loaded into RAM. Yikes!