<?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 Re: Problem with ippiLabToBGR in Intel® Integrated Performance Primitives</title>
    <link>https://community.intel.com/t5/Intel-Integrated-Performance/Problem-with-ippiLabToBGR/m-p/863347#M8038</link>
    <description>&lt;DIV style="margin:0px;"&gt;
&lt;DIV id="quote_reply" style="margin-top: 5px; width: 100%;"&gt;
&lt;DIV style="margin-left:2px;margin-right:2px;"&gt;Quoting - &lt;A href="https://community.intel.com/en-us/profile/431134"&gt;gsoucy&lt;/A&gt;&lt;/DIV&gt;
&lt;DIV style="background-color:#E5E5E5; padding:5px;border: 1px; border-style: inset;margin-left:2px;margin-right:2px;"&gt;&lt;EM&gt;Hello, &lt;BR /&gt;&lt;BR /&gt;I am trying to convert a LAB image into a BGR image. I am not getting the expected values when I compare with conversions done with other software (Photoshop). More specifically, I am using this routine:&lt;BR /&gt;&lt;BR /&gt;&lt;EM&gt;IppStatus ippiLabToBGR_16u8u_C3R(const Ipp16u* pSrc, int srcStep, Ipp8u* pDst, int dstStep, IppiSize roiSize);&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/EM&gt;According to the doc, the 16U lab dataarefirst converted to original/unscaled LAB value asfollows:&lt;BR /&gt;&lt;BR /&gt; L = L * 100./65535.&lt;BR /&gt; a = (a/255. - 128.)&lt;BR /&gt; b = (b/255.) - 128.)&lt;BR /&gt;&lt;BR /&gt;When I try simple values, the conversion seems wrong. Here are a few examples:&lt;BR /&gt;&lt;BR /&gt;LAB values 16U values passes toIPP 8u values returned by ippiLabToBGR&lt;BR /&gt;------------- --------------------------- -------------------------------------&lt;BR /&gt;L= 50 32767 R=46&lt;BR /&gt;A= 0 32640 G=47&lt;BR /&gt;B= 0 32640 B=48&lt;BR /&gt;&lt;BR /&gt;For a L of 50, we should get a much higher intensity then RGB~=46 as returned now by the routine (it should be close to 128 IMHO)&lt;BR /&gt;&lt;BR /&gt;Here is another example:&lt;BR /&gt;&lt;BR /&gt;LAB values 16U values passes to IPP 8u values returned by ippiLabToBGR Conversion with Photoshop&lt;BR /&gt;------------- --------------------------- ------------------------------------- ---------------------------&lt;BR /&gt;L= 60 39321 R= 26 R=90&lt;BR /&gt;A= -20 27540G= 81 G=154 &lt;BR /&gt;B= +30 40290B= 55 B=123&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;The IPP conversion is not even close to the value obtained with Photoshop (which I trust for that).&lt;BR /&gt;&lt;BR /&gt;I suspect that this might be related to gamma-correction but I am not sure. Is there a way to disable gamma-correction?&lt;BR /&gt;&lt;BR /&gt;Am I missing something else? Any help would be appreciated. &lt;BR /&gt;&lt;BR /&gt;Thanks you!&lt;BR /&gt;&lt;BR /&gt;Gilbert&lt;/EM&gt;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;BR /&gt;Hi,&lt;BR /&gt;
&lt;P dir="ltr"&gt;To get result like Photoshop you should work with gamma corrected RGB.&lt;/P&gt;
&lt;P dir="ltr"&gt;Use ippi functions:&lt;/P&gt;
&lt;P dir="ltr"&gt;- ippiGammaFwd which performs gamma-correction of the source image with RGB data.&lt;/P&gt;
&lt;P dir="ltr"&gt;- ippiGammaInv which converts a gamma-corrected RGB image back to the original RGB image.&lt;/P&gt;</description>
    <pubDate>Wed, 08 Jul 2009 08:43:19 GMT</pubDate>
    <dc:creator>Sergey_P_Intel1</dc:creator>
    <dc:date>2009-07-08T08:43:19Z</dc:date>
    <item>
      <title>Problem with ippiLabToBGR</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Problem-with-ippiLabToBGR/m-p/863346#M8037</link>
      <description>Hello, &lt;BR /&gt;&lt;BR /&gt;I am trying to convert a LAB image into a BGR image. I am not getting the expected values when I compare with conversions done with other software (Photoshop). More specifically, I am using this routine:&lt;BR /&gt;&lt;BR /&gt;&lt;EM&gt;IppStatus ippiLabToBGR_16u8u_C3R(const Ipp16u* pSrc, int srcStep, Ipp8u* pDst, int dstStep, IppiSize roiSize);&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/EM&gt;According to the doc, the 16U lab dataarefirst converted to original/unscaled LAB value asfollows:&lt;BR /&gt;&lt;BR /&gt; L = L * 100./65535.&lt;BR /&gt; a = (a/255. - 128.)&lt;BR /&gt; b = (b/255.) - 128.)&lt;BR /&gt;&lt;BR /&gt;When I try simple values, the conversion seems wrong. Here are a few examples:&lt;BR /&gt;&lt;BR /&gt;LAB values 16U values passes toIPP 8u values returned by ippiLabToBGR&lt;BR /&gt;------------- --------------------------- -------------------------------------&lt;BR /&gt;L= 50 32767 R=46&lt;BR /&gt;A= 0 32640 G=47&lt;BR /&gt;B= 0 32640 B=48&lt;BR /&gt;&lt;BR /&gt;For a L of 50, we should get a much higher intensity then RGB~=46 as returned now by the routine (it should be close to 128 IMHO)&lt;BR /&gt;&lt;BR /&gt;Here is another example:&lt;BR /&gt;&lt;BR /&gt;LAB values 16U values passes to IPP 8u values returned by ippiLabToBGR Conversion with Photoshop&lt;BR /&gt;------------- --------------------------- ------------------------------------- ---------------------------&lt;BR /&gt;L= 60 39321 R= 26 R=90&lt;BR /&gt;A= -20 27540G= 81 G=154 &lt;BR /&gt;B= +30 40290B= 55 B=123&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;The IPP conversion is not even close to the value obtained with Photoshop (which I trust for that).&lt;BR /&gt;&lt;BR /&gt;I suspect that this might be related to gamma-correction but I am not sure. Is there a way to disable gamma-correction?&lt;BR /&gt;&lt;BR /&gt;Am I missing something else? Any help would be appreciated. &lt;BR /&gt;&lt;BR /&gt;Thanks you!&lt;BR /&gt;&lt;BR /&gt;Gilbert</description>
      <pubDate>Mon, 06 Jul 2009 22:32:17 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Problem-with-ippiLabToBGR/m-p/863346#M8037</guid>
      <dc:creator>gsoucy</dc:creator>
      <dc:date>2009-07-06T22:32:17Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with ippiLabToBGR</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Problem-with-ippiLabToBGR/m-p/863347#M8038</link>
      <description>&lt;DIV style="margin:0px;"&gt;
&lt;DIV id="quote_reply" style="margin-top: 5px; width: 100%;"&gt;
&lt;DIV style="margin-left:2px;margin-right:2px;"&gt;Quoting - &lt;A href="https://community.intel.com/en-us/profile/431134"&gt;gsoucy&lt;/A&gt;&lt;/DIV&gt;
&lt;DIV style="background-color:#E5E5E5; padding:5px;border: 1px; border-style: inset;margin-left:2px;margin-right:2px;"&gt;&lt;EM&gt;Hello, &lt;BR /&gt;&lt;BR /&gt;I am trying to convert a LAB image into a BGR image. I am not getting the expected values when I compare with conversions done with other software (Photoshop). More specifically, I am using this routine:&lt;BR /&gt;&lt;BR /&gt;&lt;EM&gt;IppStatus ippiLabToBGR_16u8u_C3R(const Ipp16u* pSrc, int srcStep, Ipp8u* pDst, int dstStep, IppiSize roiSize);&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/EM&gt;According to the doc, the 16U lab dataarefirst converted to original/unscaled LAB value asfollows:&lt;BR /&gt;&lt;BR /&gt; L = L * 100./65535.&lt;BR /&gt; a = (a/255. - 128.)&lt;BR /&gt; b = (b/255.) - 128.)&lt;BR /&gt;&lt;BR /&gt;When I try simple values, the conversion seems wrong. Here are a few examples:&lt;BR /&gt;&lt;BR /&gt;LAB values 16U values passes toIPP 8u values returned by ippiLabToBGR&lt;BR /&gt;------------- --------------------------- -------------------------------------&lt;BR /&gt;L= 50 32767 R=46&lt;BR /&gt;A= 0 32640 G=47&lt;BR /&gt;B= 0 32640 B=48&lt;BR /&gt;&lt;BR /&gt;For a L of 50, we should get a much higher intensity then RGB~=46 as returned now by the routine (it should be close to 128 IMHO)&lt;BR /&gt;&lt;BR /&gt;Here is another example:&lt;BR /&gt;&lt;BR /&gt;LAB values 16U values passes to IPP 8u values returned by ippiLabToBGR Conversion with Photoshop&lt;BR /&gt;------------- --------------------------- ------------------------------------- ---------------------------&lt;BR /&gt;L= 60 39321 R= 26 R=90&lt;BR /&gt;A= -20 27540G= 81 G=154 &lt;BR /&gt;B= +30 40290B= 55 B=123&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;The IPP conversion is not even close to the value obtained with Photoshop (which I trust for that).&lt;BR /&gt;&lt;BR /&gt;I suspect that this might be related to gamma-correction but I am not sure. Is there a way to disable gamma-correction?&lt;BR /&gt;&lt;BR /&gt;Am I missing something else? Any help would be appreciated. &lt;BR /&gt;&lt;BR /&gt;Thanks you!&lt;BR /&gt;&lt;BR /&gt;Gilbert&lt;/EM&gt;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;BR /&gt;Hi,&lt;BR /&gt;
&lt;P dir="ltr"&gt;To get result like Photoshop you should work with gamma corrected RGB.&lt;/P&gt;
&lt;P dir="ltr"&gt;Use ippi functions:&lt;/P&gt;
&lt;P dir="ltr"&gt;- ippiGammaFwd which performs gamma-correction of the source image with RGB data.&lt;/P&gt;
&lt;P dir="ltr"&gt;- ippiGammaInv which converts a gamma-corrected RGB image back to the original RGB image.&lt;/P&gt;</description>
      <pubDate>Wed, 08 Jul 2009 08:43:19 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Problem-with-ippiLabToBGR/m-p/863347#M8038</guid>
      <dc:creator>Sergey_P_Intel1</dc:creator>
      <dc:date>2009-07-08T08:43:19Z</dc:date>
    </item>
  </channel>
</rss>

