|
|
|
@ -58,8 +58,8 @@ namespace cv { namespace gpu { namespace device |
|
|
|
|
CTA_SIZE_X = 32, |
|
|
|
|
CTA_SIZE_Y = 8, |
|
|
|
|
|
|
|
|
|
STA_SIZE_MARGE_Y = 4, |
|
|
|
|
STA_SIZE_MARGE_X = 32, |
|
|
|
|
STA_SIZE_MERGE_Y = 4, |
|
|
|
|
STA_SIZE_MERGE_X = 32, |
|
|
|
|
|
|
|
|
|
TPB_X = 1, |
|
|
|
|
TPB_Y = 4, |
|
|
|
@ -500,7 +500,7 @@ namespace cv { namespace gpu { namespace device |
|
|
|
|
while (grid.x > 1 || grid.y > 1) |
|
|
|
|
{ |
|
|
|
|
dim3 mergeGrid(ceilf(grid.x / 2.0), ceilf(grid.y / 2.0)); |
|
|
|
|
dim3 mergeBlock(STA_SIZE_MARGE_X, STA_SIZE_MARGE_Y); |
|
|
|
|
dim3 mergeBlock(STA_SIZE_MERGE_X, STA_SIZE_MERGE_Y); |
|
|
|
|
// debug log |
|
|
|
|
// std::cout << "merging: " << grid.y << " x " << grid.x << " ---> " << mergeGrid.y << " x " << mergeGrid.x << " for tiles: " << tileSizeY << " x " << tileSizeX << std::endl; |
|
|
|
|
crossMerge<<<mergeGrid, mergeBlock, 0, stream>>>(2, 2, tileSizeY, tileSizeX, edges, comps, ceilf(grid.y / 2.0) - grid.y / 2, ceilf(grid.x / 2.0) - grid.x / 2); |
|
|
|
|