Quantcast
Channel: Intel® Software - Intel® Integrated Performance Primitives
Viewing all articles
Browse latest Browse all 1489

Issue with Nearest Cross Correlation (Intel IPP 7.0)

$
0
0

So I'm trying to do a simple template match test with NCC based on code from the documentation. But I'm having trouble trying to come up with something I can use to determine a match. Image data is 8 bpp grayscale. Any advice?

IppiSize tmp1Size = { tmp1->width, tmp1->height };
IppiSize tmp2Size = { tmp2->width, tmp2->height };
IppiSize resSize = {tmp1->width+tmp2->width-1, tmp1->height+tmp2->height-1 };
Ipp32f min, max;
IppStatus status;
Ipp32f *out, *r;
Ipp32f normC;

out = malloc(sizeof(Ipp32f) * resSize.width * resSize.height);
r = malloc(sizeof(Ipp32f) * resSize.width * resSize.height);
status = ippiCrossCorrFull_Norm_8u32f_C1R(tmp2->data, tmp2->width, tmp2Size, tmp1->data, tmp1->width, tmp1Size, out, resSize.width);
status = ippiMinMax_32f_C1R( out, tmp1->width+tmp2->width, resSize, &min, &max );
normC = 1.0f/max;
status = ippiMulC_32f_C1R(out, resSize.width, normC, r, resSize.width, resSize);


Viewing all articles
Browse latest Browse all 1489

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>