<?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 bug in WarpAffineQuad in Intel® Integrated Performance Primitives</title>
    <link>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873276#M9231</link>
    <description>Hi Yuri,&lt;BR /&gt;&lt;BR /&gt;I understand that this is happening but if there is a ippStsAffineQuadChanged due to slight imprecision in the shape of the parallelogram then the position of the fourth corner is corrected. There is no reason why this should cause some pixels to be lost in the drawing. The transform should be calculated and the drawing take place in the overlap of the two roi specified.&lt;BR /&gt;&lt;BR /&gt;The calculation of the transform from the two quads ought to have no effect on calculation of the area drawn to as this is defined in the documentation thus:&lt;BR /&gt;&lt;BR /&gt; transform the rectangular ROI of the source image to quadrangle in the destination image;&lt;BR /&gt; find the intersection of this quadrangle and the rectangular ROI of the destination image;&lt;BR /&gt; update the destination image in the intersection area.&lt;BR /&gt;&lt;BR /&gt;Pixels fully within this intersection after the transform should be drawn to.&lt;BR /&gt;&lt;BR /&gt;It sounds like the very slight correction to the dst quad is also being applied to the dst roi with the effect being magnified by float rounding. There is no reason to adjust the dst roi at all.&lt;BR /&gt;&lt;BR /&gt;This is a bug and still needs fixing.&lt;BR /&gt;&lt;BR /&gt;Also GetAffineTransform is limited in its use as the src area is specified by an int based roi rather than a double based quad. I will check again but I think I am currently getting a 0.5 pixel error in the src which I cannot correct for with int values.&lt;BR /&gt;&lt;BR /&gt;Could you make available a two quad based version of GetAffineTransform?&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;BR /&gt;&lt;BR /&gt;Paul&lt;BR /&gt;&lt;BR /&gt;</description>
    <pubDate>Tue, 23 Mar 2010 15:59:12 GMT</pubDate>
    <dc:creator>paullumidium_com</dc:creator>
    <dc:date>2010-03-23T15:59:12Z</dc:date>
    <item>
      <title>bug in WarpAffineQuad</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873271#M9226</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;
&lt;P&gt;I think there is a bug in WarpAffineQuad.&lt;/P&gt;
&lt;P&gt;If one or more corner of the source quad lies outside the source roi and there is an ippStsAffineQuadChanged error (which seems sensitive enough to occur fairly regularly) then sometimes the destination roi is recalculated causing a one pixel wide strip on the left and/or bottom not to be drawn.&lt;/P&gt;
&lt;P&gt;I can work round it ok using GetAffineTransform to calculate the transform and WarpAffineBack to draw it, so this is not critical to me but it would still be nice to have WarpAffineQuad.&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;P&gt;Paul&lt;/P&gt;</description>
      <pubDate>Thu, 11 Mar 2010 11:58:46 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873271#M9226</guid>
      <dc:creator>paullumidium_com</dc:creator>
      <dc:date>2010-03-11T11:58:46Z</dc:date>
    </item>
    <item>
      <title>bug in WarpAffineQuad</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873272#M9227</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;
&lt;P&gt;I'm afraid my workround does not work. I have been running some tests and there seems to be problem with the GetAffineTransform.&lt;/P&gt;
&lt;P&gt;If I use two quads with WarpAffineQuad the correct transformation is calculated, but there is the problem of undrawn pixels. BUT if I use the same quads with GetAffineTransform and WarpAffineBack I get quite different results. The problem seems to be in GetAffineTransform mixing geometrical rectangles and roi. The net effect seems to be that all the quad values would need to be adjusted by -0.5 and the roi needs to be 0.5 pixel bigger all round.&lt;/P&gt;
&lt;P&gt;If GetAffineTransform took two quads I could at correct for this error but the int values of the srcroi mean I cannot.&lt;/P&gt;
&lt;P&gt;I am stuck. If you cannot easily either fix WarpAffineQuad or GetAffineTransform could you let me have the source for GetAffineTransform so that I can patch it?&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;P&gt;Paul&lt;/P&gt;</description>
      <pubDate>Thu, 11 Mar 2010 14:47:34 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873272#M9227</guid>
      <dc:creator>paullumidium_com</dc:creator>
      <dc:date>2010-03-11T14:47:34Z</dc:date>
    </item>
    <item>
      <title>bug in WarpAffineQuad</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873273#M9228</link>
      <description>&lt;P&gt;Hi Paul,&lt;/P&gt;
&lt;P&gt;Please send us a test case with the problem in ippiWarpAffineQuad function. We will look at it and fix it.&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt; Beg&lt;/P&gt;</description>
      <pubDate>Fri, 12 Mar 2010 08:35:11 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873273#M9228</guid>
      <dc:creator>Yuri_Tikhomirov__Int</dc:creator>
      <dc:date>2010-03-12T08:35:11Z</dc:date>
    </item>
    <item>
      <title>bug in WarpAffineQuad</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873274#M9229</link>
      <description>&lt;P&gt;Hi Yuri,&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;That would be great. I have written up a test which shows the first row and column of the destination image failing to be written. Interestingly if the source quad is defined as doubles it works ok but if (as I am doing) they are cast from floats the function fails.&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;Thanks for your prompt and helpful reply.&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;Paul&lt;/P&gt;</description>
      <pubDate>Tue, 16 Mar 2010 12:13:08 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873274#M9229</guid>
      <dc:creator>paullumidium_com</dc:creator>
      <dc:date>2010-03-16T12:13:08Z</dc:date>
    </item>
    <item>
      <title>bug in WarpAffineQuad</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873275#M9230</link>
      <description>&lt;P&gt;Hi Paul,&lt;BR /&gt;&lt;BR /&gt;The function ippiWarpAffineQuad checks correspondence between src and dst quadrangles in the following way:&lt;BR /&gt;The function computes transform coefficients, based on the mapping of the source quadrangle to the quadrangle dstQuad.Then it computes the coordinates of the 4th vertex of the destination quadrangle that uniquely depends on the three other vertices. Then the function compares these coordinates with the coordinates specified in dstQuad using the special macro fcmp&lt;BR /&gt;&lt;BR /&gt;#define fcmp(x, y) ((fabs(x) &amp;lt;= 1.e-200) ? (fabs(y) &amp;lt;= 1.e-10) : (fabs(((x) - (y)) / (x)) &amp;lt;= 1.e-10))&lt;/P&gt;
&lt;P&gt;If the coordinates are not equal, the function returns the warning message &lt;SPAN style="text-decoration: underline;"&gt;ippStsAffineQuadChanged&lt;/SPAN&gt; and continues operation with the computed values. In this case some pixels may be lost. If you use float constants (in your example), the precision is degraded, and srcQuad became not pure parallelogram,&lt;BR /&gt; srcQuad[0][0] = 602.795898f;&lt;BR /&gt; srcQuad[0][1] = 873.016785f;&lt;BR /&gt; srcQuad[1][0] = 1116.818848f;&lt;BR /&gt; srcQuad[1][1] = 601.846130f;&lt;BR /&gt; srcQuad[2][0] = 964.285339f;&lt;BR /&gt; srcQuad[2][1] = 312.708221f;&lt;BR /&gt; srcQuad[3][0] = 450.262421f;&lt;BR /&gt; srcQuad[3][1] = 583.878906f;&lt;BR /&gt;although with double all work correctly.&lt;BR /&gt;This function is very sensitive to the precision of the vertices coordinates.&lt;/P&gt;
&lt;P&gt;When you use ippiWarpAffineBack, the result will be the same only if the dstQuad is specified as&lt;BR /&gt; dstQuad[0][0] = 0;&lt;BR /&gt; dstQuad[0][1] = 0;&lt;BR /&gt; dstQuad[1][0] = dstWidth - 1;&lt;BR /&gt; dstQuad[1][1] = 0;&lt;BR /&gt; dstQuad[2][0] = dstWidth - 1;&lt;BR /&gt; dstQuad[2][1] = dstHeight - 1;&lt;BR /&gt; dstQuad[3][0] = 0;&lt;BR /&gt; dstQuad[3][1] = dstHeight - 1;&lt;BR /&gt;You can use the function ippiGetAffineTransform, because in this case dstQuad is a rectangle.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt; Yuri&lt;/P&gt;</description>
      <pubDate>Tue, 23 Mar 2010 12:08:28 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873275#M9230</guid>
      <dc:creator>Yuri_Tikhomirov__Int</dc:creator>
      <dc:date>2010-03-23T12:08:28Z</dc:date>
    </item>
    <item>
      <title>bug in WarpAffineQuad</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873276#M9231</link>
      <description>Hi Yuri,&lt;BR /&gt;&lt;BR /&gt;I understand that this is happening but if there is a ippStsAffineQuadChanged due to slight imprecision in the shape of the parallelogram then the position of the fourth corner is corrected. There is no reason why this should cause some pixels to be lost in the drawing. The transform should be calculated and the drawing take place in the overlap of the two roi specified.&lt;BR /&gt;&lt;BR /&gt;The calculation of the transform from the two quads ought to have no effect on calculation of the area drawn to as this is defined in the documentation thus:&lt;BR /&gt;&lt;BR /&gt; transform the rectangular ROI of the source image to quadrangle in the destination image;&lt;BR /&gt; find the intersection of this quadrangle and the rectangular ROI of the destination image;&lt;BR /&gt; update the destination image in the intersection area.&lt;BR /&gt;&lt;BR /&gt;Pixels fully within this intersection after the transform should be drawn to.&lt;BR /&gt;&lt;BR /&gt;It sounds like the very slight correction to the dst quad is also being applied to the dst roi with the effect being magnified by float rounding. There is no reason to adjust the dst roi at all.&lt;BR /&gt;&lt;BR /&gt;This is a bug and still needs fixing.&lt;BR /&gt;&lt;BR /&gt;Also GetAffineTransform is limited in its use as the src area is specified by an int based roi rather than a double based quad. I will check again but I think I am currently getting a 0.5 pixel error in the src which I cannot correct for with int values.&lt;BR /&gt;&lt;BR /&gt;Could you make available a two quad based version of GetAffineTransform?&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;BR /&gt;&lt;BR /&gt;Paul&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 23 Mar 2010 15:59:12 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873276#M9231</guid>
      <dc:creator>paullumidium_com</dc:creator>
      <dc:date>2010-03-23T15:59:12Z</dc:date>
    </item>
    <item>
      <title>bug in WarpAffineQuad</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873277#M9232</link>
      <description>Hi Yuri&lt;DIV&gt;&lt;SPAN style="font-family: Verdana, Arial, Helvetica, sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-family: Verdana, Arial, Helvetica, sans-serif;"&gt;Do you have an update about this bug?&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-family: Verdana, Arial, Helvetica, sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-family: Verdana, Arial, Helvetica, sans-serif;"&gt;I have submitted a detailed bug report with supporting test and would hope that you would fix it.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-family: Verdana, Arial, Helvetica, sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-family: Verdana, Arial, Helvetica, sans-serif;"&gt;If you are unwilling to fix it could you let me have the source toGetAffineTransform so that I can try and patch it myself?&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-family: Verdana, Arial, Helvetica, sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-family: Verdana, Arial, Helvetica, sans-serif;"&gt;ALSO&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-family: Verdana, Arial, Helvetica, sans-serif;"&gt;&lt;/SPAN&gt;I have another outstanding issue. In ipp 6 you have removed support for resizing using super sampling and square pixels from the library. This this by design or an oversight?&lt;BR /&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;META charset="utf-8" /&gt;&lt;A href="http://software.intel.com/en-us/forums/showthread.php?t=72606&amp;amp;o=d&amp;amp;s=lr"&gt;http://software.intel.com/en-us/forums/showthread.php?t=72606&amp;amp;o=d&amp;amp;s=lr&lt;/A&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;It would be nice to have an answer.&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;Thanks&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;Paul&lt;/DIV&gt;</description>
      <pubDate>Tue, 27 Apr 2010 20:03:44 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873277#M9232</guid>
      <dc:creator>paullumidium_com</dc:creator>
      <dc:date>2010-04-27T20:03:44Z</dc:date>
    </item>
    <item>
      <title>bug in WarpAffineQuad</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873278#M9233</link>
      <description>&lt;P&gt;Hi Paul,&lt;/P&gt;&lt;P&gt;Idon't think this is a bug, because whenthe function returns the warning ippStsAffineQuadChanged some pixels may be lost.&lt;BR /&gt;Please look at the function GetAffineTransformQ calculating transformation matrix for case quad to quad.&lt;BR /&gt;&lt;BR /&gt;void GetAffineTransformQ(const double srcQuad[4][2], const double dstQuad[4][2], double coeffs[2][3])&lt;BR /&gt;{&lt;BR /&gt; double det, dx1, dx2, dy1, dy2, sx1, sx2, sy1, sy2;&lt;BR /&gt; dx1 = dstQuad[1][0] - dstQuad[0][0]; dx2 = dstQuad[2][0] - dstQuad[1][0];&lt;BR /&gt; dy1 = dstQuad[1][1] - dstQuad[0][1]; dy2 = dstQuad[2][1] - dstQuad[1][1];&lt;BR /&gt; det = 1.0 / (dx1 * dy2 - dx2 * dy1);&lt;BR /&gt; sx1 = srcQuad[1][0] - srcQuad[0][0]; sx2 = srcQuad[2][0] - srcQuad[1][0];&lt;BR /&gt; sy1 = srcQuad[1][1] - srcQuad[0][1]; sy2 = srcQuad[2][1] - srcQuad[1][1];&lt;BR /&gt; coeffs[0][0] = (sx1 * dy2 - sx2 * dy1) * det;&lt;BR /&gt; coeffs[0][1] = (sx2 * dx1 - sx1 * dx2) * det;&lt;BR /&gt; coeffs[0][2] = srcQuad[2][0] - coeffs[0][0] * dstQuad[2][0] - coeffs[0][1] * dstQuad[2][1];&lt;BR /&gt; coeffs[1][0] = (sy1 * dy2 - sy2 * dy1) * det;&lt;BR /&gt; coeffs[1][1] = (sy2 * dx1 - sy1 * dx2) * det;&lt;BR /&gt; coeffs[1][2] = srcQuad[2][1] - coeffs[1][0] * dstQuad[2][0] - coeffs[1][1] * dstQuad[2][1];&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;About your second question...&lt;BR /&gt;The function ippiResizeSqrPixel support Super Sampling method for shrinking images.&lt;BR /&gt;It was a misprint in the documentation.&lt;BR /&gt;Please set interpolation parameter as IPPI_INTER_SUPER&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt; Yuri&lt;/P&gt;</description>
      <pubDate>Wed, 28 Apr 2010 09:54:27 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/bug-in-WarpAffineQuad/m-p/873278#M9233</guid>
      <dc:creator>Yuri_Tikhomirov__Int</dc:creator>
      <dc:date>2010-04-28T09:54:27Z</dc:date>
    </item>
  </channel>
</rss>

