Fix #32603: Multi-Layer EXR files can't be color managed
authorSergey Sharybin <sergey.vfx@gmail.com>
Thu, 20 Sep 2012 10:07:49 +0000 (10:07 +0000)
committerSergey Sharybin <sergey.vfx@gmail.com>
Thu, 20 Sep 2012 10:07:49 +0000 (10:07 +0000)
commitddcc3f612a33de6cc1ed7ecb2b2fd66290952a31
treec6fef0892fa237abc08627dec80995fa23878e28
parentbe2454dc551779aaa7bf5fd39f27b65a9201bcc6
Fix #32603: Multi-Layer EXR files can't be color managed

Issue was caused by completely different way how multi-layer EXRs are loading,
they're bypassing general image buffer loading functions.

Solved by running color space transformation on render result construction
from multi-layer EXR image.

Also fixed issue with wrong display buffer computing for buffers with less
than 4 channels. Issues were:

- Display buffer is always expected to be RGBA
- OpenColorIO can not apply color space transformations on non-{RGB, RGBA}
  pixels.
source/blender/blenkernel/intern/image.c
source/blender/imbuf/intern/colormanagement.c
source/blender/render/extern/include/RE_pipeline.h
source/blender/render/intern/include/render_result.h
source/blender/render/intern/source/pipeline.c
source/blender/render/intern/source/render_result.c