Intel® Integrated Performance Primitives
Community support and discussions relating to developing high-performance vision, signal, security, and storage applications.
Announcements
Welcome to the Intel Community. If you get an answer you like, please mark it as an Accepted Solution to help others. Thank you!
6594 Discussions

crash when using ippiResizeSqrPixel to scale-up YUV420 image

Changhui_L_
Beginner
90 Views

Hello guys,
I'm trying to scale YUV420 image (720x480) up to 1280x720 with the follow
code, but ippiResizeSqrPixel crashed at " t7_ownpi_CalcBorder8plC() + 0x5d6 bytes " .


// ( IPP version is 5.3 . )
void scale ( VideoData* in, VideoData* out )
{
IppiRect rectSrc = { 0, 0, in->GetWidth(), in->GetHeight() };

IppiRect rectDst = { 0, 0, out->GetWidth(), out->GetHeight() };

Ipp8u* ppSrc[3] = { (Ipp8u*) in->GetPlanePointer (0),
(Ipp8u*) in->GetPlanePointer (1),
(Ipp8u*) in->GetPlanePointer (2) };

Ipp8u* ppDst[3] = { (Ipp8u*) out->GetPlanePointer (0),
(Ipp8u*) out->GetPlanePointer (1),
(Ipp8u*) out->GetPlanePointer (2) };

Ipp64f xRatio = static_cast (rectDst.width) /
static_cast (rectSrc.width);
Ipp64f yRatio = static_cast (rectDst.height) /
static_cast (rectSrc.height);

int reqSize = 0;
IppiSize dstSize = { rectDst.width, rectDst.height } ;
ippiResizeSqrPixelGetBufSize ( dstSize, 3, IPPI_INTER_CUBIC, &reqSize ) ;
Ipp8u* pScaleBuf = (Ipp8u*)ippMalloc ( reqSize ) ;

in->GetPlaneInfo ( &srcInfo, 0 );
out->GetPlaneInfo ( &dstInfo, 0 );

status = ippiResizeSqrPixel_8u_P3R ( ppSrc,
srcInfo.m_ippSize,
srcInfo.m_nPitch,
rectSrc,
ppDst,
dstInfo.m_nPitch,
  ; rectDst,
xRatio,
yRatio,
0.5,
0.5,
IPPI_INTER_CUBIC,
pScaleBuf );

ippFree ( pScaleBuf );

}

Anyone has some suggestion about this issue?

Thanks very much.


0 Kudos
1 Reply
Changhui_L_
Beginner
90 Views

Hi Nikolay,

We have known the reason, thanks very much for your reply.

Kind regards,

Reply