1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-31 00:03:03 +04:00

Move big objects (>20k) from stack to heap.

This commit is contained in:
Vincent Rabaud
2020-12-16 17:27:55 +01:00
parent d159417474
commit ec3ef520e6
3 changed files with 8 additions and 5 deletions
+2 -1
View File
@@ -2167,7 +2167,8 @@ public:
virtual void operator() (const Range& range) const CV_OVERRIDE
{
const int BLOCK_SZ = 64;
short XY[BLOCK_SZ*BLOCK_SZ*2], A[BLOCK_SZ*BLOCK_SZ];
AutoBuffer<short, 0> __XY(BLOCK_SZ * BLOCK_SZ * 2), __A(BLOCK_SZ * BLOCK_SZ);
short *XY = __XY.data(), *A = __A.data();
const int AB_BITS = MAX(10, (int)INTER_BITS);
const int AB_SCALE = 1 << AB_BITS;
int round_delta = interpolation == INTER_NEAREST ? AB_SCALE/2 : AB_SCALE/INTER_TAB_SIZE/2, x, y, x1, y1;