<?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 uic_image.cpp ImageDataRange::SetAsRangeInt bug in Intel® Integrated Performance Primitives</title>
    <link>https://community.intel.com/t5/Intel-Integrated-Performance/uic-image-cpp-ImageDataRange-SetAsRangeInt-bug/m-p/771278#M725</link>
    <description>&lt;PRE&gt;shouldnt that funciton look like this&lt;/PRE&gt;&lt;PRE&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;PRE&gt;voidImageDataRange::SetAsRangeInt(Ipp64smin,Ipp64smax)
{
m_min.v64s=min;
m_max.v64s=max;
 
if(min&amp;lt;0)
{
m_isSigned=true;
m_bitDepth=::BitDepth64(::Max(-min+1,max)); // was ::Max(-(min+1),max)
}
else
{
m_isSigned=false;
m_bitDepth=::BitDepth64(::Max(min,max));
}
}&lt;/PRE&gt;&lt;PRE&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;PRE&gt;checking with 8 bit signed range&lt;/PRE&gt;&lt;PRE&gt;-128, 127&lt;/PRE&gt;&lt;PRE&gt;with previous code it would do ::BitDepth64(127) = 7 (and it needs to be 8)&lt;/PRE&gt;&lt;PRE&gt;Max(127,127)&lt;/PRE&gt;&lt;PRE&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;PRE&gt;with modified code Max(129,127) -&amp;gt; BitDepth64(129) = 8&lt;/PRE&gt;&lt;PRE&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;PRE&gt;Edit:&lt;/PRE&gt;&lt;PRE&gt;there is similar "Bug" in SetAsRange32f  and SetAsRange64f when caclulating absMax&lt;/PRE&gt;</description>
    <pubDate>Tue, 17 Apr 2012 14:16:10 GMT</pubDate>
    <dc:creator>Aris_Basic</dc:creator>
    <dc:date>2012-04-17T14:16:10Z</dc:date>
    <item>
      <title>uic_image.cpp ImageDataRange::SetAsRangeInt bug</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/uic-image-cpp-ImageDataRange-SetAsRangeInt-bug/m-p/771278#M725</link>
      <description>&lt;PRE&gt;shouldnt that funciton look like this&lt;/PRE&gt;&lt;PRE&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;PRE&gt;voidImageDataRange::SetAsRangeInt(Ipp64smin,Ipp64smax)
{
m_min.v64s=min;
m_max.v64s=max;
 
if(min&amp;lt;0)
{
m_isSigned=true;
m_bitDepth=::BitDepth64(::Max(-min+1,max)); // was ::Max(-(min+1),max)
}
else
{
m_isSigned=false;
m_bitDepth=::BitDepth64(::Max(min,max));
}
}&lt;/PRE&gt;&lt;PRE&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;PRE&gt;checking with 8 bit signed range&lt;/PRE&gt;&lt;PRE&gt;-128, 127&lt;/PRE&gt;&lt;PRE&gt;with previous code it would do ::BitDepth64(127) = 7 (and it needs to be 8)&lt;/PRE&gt;&lt;PRE&gt;Max(127,127)&lt;/PRE&gt;&lt;PRE&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;PRE&gt;with modified code Max(129,127) -&amp;gt; BitDepth64(129) = 8&lt;/PRE&gt;&lt;PRE&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;PRE&gt;Edit:&lt;/PRE&gt;&lt;PRE&gt;there is similar "Bug" in SetAsRange32f  and SetAsRange64f when caclulating absMax&lt;/PRE&gt;</description>
      <pubDate>Tue, 17 Apr 2012 14:16:10 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/uic-image-cpp-ImageDataRange-SetAsRangeInt-bug/m-p/771278#M725</guid>
      <dc:creator>Aris_Basic</dc:creator>
      <dc:date>2012-04-17T14:16:10Z</dc:date>
    </item>
  </channel>
</rss>

