<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic ippiSuperSampling_8u_P3R crashes in Intel® Integrated Performance Primitives</title>
    <link>https://community.intel.com/t5/Intel-Integrated-Performance/ippiSuperSampling-8u-P3R-crashes/m-p/765849#M187</link>
    <description>&lt;P&gt;Resizing of the YV12 (planar) data using ippiSuperSampling_8u_P3R crashes, with invalid access in reading memory location. Below is the code and the details of the buffer and parameters&lt;/P&gt;&lt;P&gt;Input buffer size(pInputImage) is 518400, srcwidth = 720, srcheight = 480, dstwidth = 400, dstheight = 300. It crashes trying to access memory outside the boundary for eg:&lt;/P&gt;&lt;P&gt;address of pI420SrcData[0] = 0x04020000&lt;/P&gt;&lt;P&gt;address of pI420SrcData[1] = 0x04074600&lt;/P&gt;&lt;P&gt;address of pI420SrcData[2] = 0x04089780&lt;/P&gt;&lt;P&gt;It crashes trying to access 0x0409f170 which according to me is exceeds the boundary of V planar buffer. Please let me know what could be wrong here.&lt;/P&gt;&lt;P&gt;I am using Intel IPP v6.1.2.041&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;PRE&gt;[bash]Ipp8u* ScalingYUV420Data(Ipp8u* pInputImage,unsigned int srcwidth,unsigned int srcheight,unsigned int dstwidth,unsigned int dstheight)

{

Ipp8u* pI420SrcData[3];

Ipp8u* pI420DestData[3];

IppiRect srcrect;

IppiRect destrect;

IppiSize srcsize;

IppiSize destsize;

pI420SrcData[0] = pInputImage;

pI420SrcData[1] = pI420SrcData[0] + (srcwidth * srcheight);

pI420SrcData[2] = pI420SrcData[1] + (srcwidth * srcheight) / 4 ;

// Calculate the resolution

srcsize.width = srcwidth;

srcsize.height = srcheight;

destsize.width = dstwidth;

destsize.height = dstheight;

int srcstep = srcwidth;

int dststep = dstwidth;

// Calculate the pointers for destination

pI420DestData[0] = m_pScaledDestData;

pI420DestData[1] = pI420DestData[0] + (dstwidth * dstheight);

pI420DestData[2] = pI420DestData[1] + (dstwidth * dstheight) / 4;

int bufsize = 0;

if(ippiSuperSamplingGetBufSize( srcsize, destsize, 3, &amp;amp;bufsize ) != ippStsNoErr)

{

return NULL;

}

 

if(bufsize &amp;lt;= 0)

{

return NULL;

}

Ipp8u* buf = ippsMalloc_8u( bufsize );

ippiSuperSampling_8u_P3R(pI420SrcData, srcstep, srcsize, pI420DestData, dststep, destsize, buf);

if( buf != NULL ) 

ippsFree( buf );

return m_pScaledDestData;

}
[/bash]&lt;/PRE&gt;</description>
    <pubDate>Thu, 25 Aug 2011 00:41:29 GMT</pubDate>
    <dc:creator>Sarun_Nandakumar</dc:creator>
    <dc:date>2011-08-25T00:41:29Z</dc:date>
    <item>
      <title>ippiSuperSampling_8u_P3R crashes</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/ippiSuperSampling-8u-P3R-crashes/m-p/765849#M187</link>
      <description>&lt;P&gt;Resizing of the YV12 (planar) data using ippiSuperSampling_8u_P3R crashes, with invalid access in reading memory location. Below is the code and the details of the buffer and parameters&lt;/P&gt;&lt;P&gt;Input buffer size(pInputImage) is 518400, srcwidth = 720, srcheight = 480, dstwidth = 400, dstheight = 300. It crashes trying to access memory outside the boundary for eg:&lt;/P&gt;&lt;P&gt;address of pI420SrcData[0] = 0x04020000&lt;/P&gt;&lt;P&gt;address of pI420SrcData[1] = 0x04074600&lt;/P&gt;&lt;P&gt;address of pI420SrcData[2] = 0x04089780&lt;/P&gt;&lt;P&gt;It crashes trying to access 0x0409f170 which according to me is exceeds the boundary of V planar buffer. Please let me know what could be wrong here.&lt;/P&gt;&lt;P&gt;I am using Intel IPP v6.1.2.041&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;PRE&gt;[bash]Ipp8u* ScalingYUV420Data(Ipp8u* pInputImage,unsigned int srcwidth,unsigned int srcheight,unsigned int dstwidth,unsigned int dstheight)

{

Ipp8u* pI420SrcData[3];

Ipp8u* pI420DestData[3];

IppiRect srcrect;

IppiRect destrect;

IppiSize srcsize;

IppiSize destsize;

pI420SrcData[0] = pInputImage;

pI420SrcData[1] = pI420SrcData[0] + (srcwidth * srcheight);

pI420SrcData[2] = pI420SrcData[1] + (srcwidth * srcheight) / 4 ;

// Calculate the resolution

srcsize.width = srcwidth;

srcsize.height = srcheight;

destsize.width = dstwidth;

destsize.height = dstheight;

int srcstep = srcwidth;

int dststep = dstwidth;

// Calculate the pointers for destination

pI420DestData[0] = m_pScaledDestData;

pI420DestData[1] = pI420DestData[0] + (dstwidth * dstheight);

pI420DestData[2] = pI420DestData[1] + (dstwidth * dstheight) / 4;

int bufsize = 0;

if(ippiSuperSamplingGetBufSize( srcsize, destsize, 3, &amp;amp;bufsize ) != ippStsNoErr)

{

return NULL;

}

 

if(bufsize &amp;lt;= 0)

{

return NULL;

}

Ipp8u* buf = ippsMalloc_8u( bufsize );

ippiSuperSampling_8u_P3R(pI420SrcData, srcstep, srcsize, pI420DestData, dststep, destsize, buf);

if( buf != NULL ) 

ippsFree( buf );

return m_pScaledDestData;

}
[/bash]&lt;/PRE&gt;</description>
      <pubDate>Thu, 25 Aug 2011 00:41:29 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/ippiSuperSampling-8u-P3R-crashes/m-p/765849#M187</guid>
      <dc:creator>Sarun_Nandakumar</dc:creator>
      <dc:date>2011-08-25T00:41:29Z</dc:date>
    </item>
  </channel>
</rss>

