sh0dan // VoxPod

Monday, May 02, 2005

Colorspace and overall progess

I've been a bit away again. Mostly at work, but I finally got some time to make some progress. I've been focusing on colorspace aspects, as I noticed differences in output from RAW programs and my own engine. I experimented quite a bit, using various gamma corrections and applying a variety of colorspace transformation matrices.

I've almost settled on the steps each image should be able to go through. The pipeline should be something like this:
  • Open RAW. Transfer RAW data to graphic card memory.
  • Black level compensation. Preferable per line.
  • Denoising. Should optimally take place here, while sensor RGB is still linear.
  • Bayer Interpolation.
  • Apply Whitebalance & (sRGB) Gamma correction.
  • Apply Brightness, Contrast, Saturation, Hue, Levels, User Selectable Gamma. (Might be kept with former)
  • Read back quarter sized version for histogram.
  • Apply Chroma Abberation Correction, Rotation, Skew and Crop. Use Bicubic interpolation.
  • Render to screen.
  • Download from texture and save to file.
This will probably be the steps each image would have to go through. I should be able to do this using two buffers, and switching between them. This should keep graphic card memory usage at a minimum. Most (timeconsuming) algorithms will be made in a fast preview and a slow quality version.

I hope to be able to use information from the RAW as a base for denoising. Posterization is something I'm still concerned about, but I'll only be able to test how resistant the program will be when it is more complete.

I also tested uploading an R32F (32 bit float) texture instead of an L16 (16 bit integer) texture. Speed seems to be exactly the same, and the memory usage is doubled. Since 16 bit integer is enough for us, I use it by default, but I left R32F as a fallback option.

0 Comments:

Post a Comment

<< Home