[FFmpeg-devel] Color Calculations

wm4 nfxjfg at googlemail.com
Wed Apr 20 18:38:35 CEST 2016


On Sun, 17 Apr 2016 04:05:07 -0400
Chris <c319chris at aol.com> wrote:

> About a year ago I posted some concerns about color accuracy and received this response:
> 
> > The specific code I'm referring to is at the end of colorspace.h
> > 
> > #define RGB_TO_Y(r1, g1, b1, shift)
> > #define RGB_TO_U(r1, g1, b1, shift)
> > #define RGB_TO_V(r1, g1, b1, shift)  
> 
> >A quick search over the ffmpeg codebase tells me that these functions
> >are not used anywhere, so if you are trying to fix some inaccuracy,
> >those macros are most certainly not where it comes from.  
> 
> If not in those macros, could someone please tell me where in the source code the actual color encoding takes place?
> 
> Thank you.

These macros are used only for some things. Most color conversions are
done by libswscale.


More information about the ffmpeg-devel mailing list