[FFmpeg-devel] patch for XYZ color-conversions for DCP encoding, request/sponsorship for OpenColorIO for more power and flexibility

Michaël Cinquin mc at michaelcinquin.com
Fri Apr 5 13:01:42 CEST 2013


Hello FFmpeg developers

2 months ago, my request to add 12 bpc pixel formats was fulfilled, and my patch to encode DCI-compliant j2c was accepted (commit 60f06f986f81c5aa0497c4fa189f50a504896c81).

Now, there's one (big) thing that is missing from FFmpeg as for DCI encoding / playback : that is XYZ colorspace to HD encoding and decoding. If we added this to FFmpeg, ffplay would become able to play DCPs, and ffmpeg could take a video and make dci-compliant dci-colorspaced j2c ready to be wrapped into an mxf for a DCP.

I did a pull request on the 21st of January with two extra av_filters : rgb2xyz and xyz2rgb ; when I submitted it to the list, Paul B Mahol suggested it would be better to add it to libswscale. I understand we just can't add a filter for every functionality that everybody needs, but I don't have the skills to do that.
I still think those filters would be a great addition to FFmpeg (they could be removed when somebody puts their functionality in libswscale).
So here's a patch with the two filters – updated with to support the latest git trunk –. I've improved in c-formatting for ffmpeg, but there will probably still be formatting glitches – let me know and I'll correct –.
I hope that this time, it will make it to the trunk, I had a hard time updating the code to be compatible with latest trunk version. I might as well turn to hieroglyphs now.

Better still than 2 additional filters or added functionality to libswscale : how about putting all the power of OpenColorIO Library inside FFmpeg ? 
> from http://opencolorio.org : OpenColorIO (OCIO) is a complete color management solution geared towards motion picture production with an emphasis on visual effects and computer animation. OCIO provides a straightforward and consistent user experience across all supporting applications while allowing for sophisticated back-end configuration options suitable for high-end production usage. OCIO is compatible with the Academy Color Encoding Specification (ACES) and is LUT-format agnostic, supporting many popular formats.

XYZ to HD and HD to XYZ are just one type of color-conversion. There are lots of other color conversion that I would like to be able to do with FFmpeg, such as burning a 3D LUT inside a log image.
Could we add OpenColorIO library inside FFmpeg (http://opencolorio.org) ? 
This is a feature that I would be ready to sponsor, and help testing or provide sample luts and images, but that I can't develop myself, as I'm not a c-programmer.


cheers

Michael

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-add-rgb2xyz-and-xyz2rgb-av_filters.patch
Type: application/octet-stream
Size: 21558 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20130405/b995ba92/attachment.obj>


More information about the ffmpeg-devel mailing list