Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Beginner
9 Views

crash with ippiRemap_8u_C1R when size is 32*32

running the ippiRemap_8u_C1R using the example of 4 by 4 is ok, but when increase the size to 16 by 16 and many other size above 16*16, the function crash. my code like

IppiSize size = { 16, 16 };
IppiRect srcRect1 = { 0, 0, 16, 16 };
Ipp8u src[16*16] =
{
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5
};
Ipp8u dst[16*16];
Ipp32f pxMap1[16*16] = {
0, 1, 2, 3, 0, 1, 2, 0, 0, 1, 0, 0,0, 1, 2, 3,
0, 1, 2, 3, 0, 1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0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3
}; // some order of pixels coordinates to write
ippiRemap_8u_C1R ( src, size, 16, srcRect1, pxMap1, 16, pyMap1, 16, dst, 16,
size, IPPI_INTER_NN);

any thing wrong ?

have tried many other size, with setting all 0 to xmap....

thanks
0 Kudos
3 Replies
Highlighted
Moderator
9 Views

Quoting - zy9
running the ippiRemap_8u_C1R using the example of 4 by 4 is ok, but when increase the size to 16 by 16 and many other size above 16*16, the function crash. my code like

IppiSize size = { 16, 16 };
IppiRect srcRect1 = { 0, 0, 16, 16 };
Ipp8u src[16*16] =
{
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 7,8, 9, 0, 1,2, 3, 4, 5,
0, 1, 2, 3, 4, 5, 6, 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0,0, 1, 2, 3,
0, 1, 2, 3, 0, 1, 2, 0, 0, 1, 0, 0,0, 1, 2, 3,
0, 1, 2, 3, 0, 1, 2, 0, 0, 1, 0, 0,0, 1, 2, 3,
0, 1, 2, 3, 0, 1, 2, 0, 0, 1, 0, 0,0, 1, 2, 3
};
Ipp32f pyMap1[16*16] = {
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3,
0, 0, 0, 0,1, 1, 1, 0,2, 2, 0, 0,3, 3, 3, 3
}; // some order of pixels coordinates to write
ippiRemap_8u_C1R ( src, size, 16, srcRect1, pxMap1, 16, pyMap1, 16, dst, 16,
size, IPPI_INTER_NN);

any thing wrong ?

have tried many other size, with setting all 0 to xmap....

thanks

What IPP version you are using?
What would be if you use other interpolation mode?
--Gennady
0 Kudos
Highlighted
Beginner
9 Views


What IPP version you are using?
What would be if you use other interpolation mode?
--Gennady

have tried both 5.0 and 6.1.1.035.

I noticed, ippiRemap_8u_C1R xmapstep param, in the given example, it's 4*4 =16, and the result is right, but in the ippdemo runremap.cpp, I run a debug mode, this xmapstep=imagwidth*4, just confused about the parameter and the crash.
0 Kudos
Highlighted
Beginner
9 Views

Quoting - zy9

have tried both 5.0 and 6.1.1.035.

I noticed, ippiRemap_8u_C1R xmapstep param, in the given example, it's 4*4 =16, and the result is right, but in the ippdemo runremap.cpp, I run a debug mode, this xmapstep=imagwidth*4, just confused about the parameter and the crash.

got the answer, the pXmapStep should equal to imageWidth*sizeof(Ipp32f), Ipp32f size is 4, so the example of 4by4 given the step 16, actually is 4*sizeof(Ipp32f), not the the height.

thanks
0 Kudos