|
From: sfeam <sf...@us...> - 2017-10-25 02:57:07
|
I propose to drop YIQ colorspace from 5.3 When color palette support was merged into gnuplot in 2001, it included support for RGB HSV CMY YIQ XYZ color spaces. It may well be that in the intervening 16 years no one has ever tried to use YIQ. Bug #1981 points out that it never worked 1) the YIQ_2_RGB() color conversion routine uses incorrect coefficients 2) the permitted range of I is [-.5957:.5957], for Q it is [-.5226:.5226] but the "set palette" code and the grayscale conversion code truncate all color components to [0:1] so it is not possible to enter general YIQ triples 3) the "set palette defined (gray1 R G B, gray2 R G B, ...) syntax cannot handle negative numbers because the leading - sign would be parsed as an operator. E.g. set palette defined (0 0.5 -0.5 -0.5) is parse as two numbers rather than four. That isn't necessarily a fatal flaw since there are other ways to define a palette, but "defined" does not and can not work for the full range of YIQ values. Furthermore the transform provided goes in the wrong direction. It might make sense to accept YIQ values and produce a grayscale. That's what black & white television did. But what use case is there for providing a grayscale value and converting it to a YIQ triple that cannot be displayed without subsequenting re-converting it to RGB? (1) and (2) are fixable. (3) is not. Given that this never worked and as noted it has no obvious use anyhow, is it OK to simply remove all mention of YIQ support rather than trying to repair it? Ethan |