title: Algorithm to convert film negative RGB to positive RGB
body: <p>Assuming I have a photographic film negative scanned as an RGB image, I'm trying to find an algorithm that will convert the color values to an RGB positive.</p>
  
  <p>Due to the orange bias ( <a href="http://photo.net/learn/orange-negative-mask" rel="nofollow noreferrer">http://photo.net/learn/orange-negative-mask</a> ) if I simply say redPositive = 255 - redNegative I get a final image that has a strong cyan tint to it, and is very washed out.  That means the answers given here: <a href="https://stackoverflow.com/questions/8662349/convert-negative-image-to-positive">Convert negative image to positive</a> are <em>NOT</em> correct.</p>
  
  <p>So how would I craft the following routine:</p>
  
  <pre><code>struct RGB
  {
      unsigned byte red;
      unsigned byte green;
      unsigned byte blue;
  };
  
  void FilmNegativeToPositive(RGB const &amp;negative, RGB &amp;positive)
  {
      // What goes here?
  }
  </code></pre>