Serhiy Storchaka added the comment:

> Can you add a reference for the coefficients?

I have only link to Wikipedia which refers to Code of Federal Regulations 
ยง73.682. This link (http://en.wikipedia.org/wiki/YIQ) already mentioned at the 
top of the file.

> (You claim about the current rounding is not exactly correct. While .28*g 
> rounds .277 rather than .274, the current .52*g rounds the non-FCC .523 
> rather than the FCC .5251. So I avoided making the claim in the suggested 
> entry. It is not important.)

A sum of coefficients in this line should be 0 (Q=0 for R=G=B).

Patch updated. I added a What's New entry and update to use of unittest.main(), 
rewrite rgb_to_yiq() in the form as in Wikipedia (it uses less multiplications) 
and write coefficients in yiq_to_rgb() with maximal precision (as calculated 
with Python).

----------
Added file: http://bugs.python.org/file31163/colorsys_yiq_fcc_2.patch

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue14323>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to