SaranshKejriwal/opencv — pull request #1 by SaranshKejriwal (2014-04-04 08:04:40+00:00)
Title: Testing cvtColor() for RGB-Gray vs BGR-Gray (related to  Bug #2267)

The color conversions performed by C++ function cvtColor() under color conversion codes CV_BGR2GRAY and CV_RGB2GRAY, yield slightly different results for some typically colored objects.

I tested this by performing both conversions on the same image, which gave me an image converted using RGB2Gray, and another using BGR2Gray. Then I used absdiff() function on the obtained frames. The results are as follows:

Original Image:
![original](https://cloud.githubusercontent.com/assets/6229349/2613017/134776a0-bbcf-11e3-8c22-f1e61d02f6fb.jpeg)

Converted using RGB2GRAY
![rgb-2-gray](https://cloud.githubusercontent.com/assets/6229349/2613023/2ad6aa2a-bbcf-11e3-8c1d-e1da2b15bc3a.jpeg)

Converted using BGR2GRAY
![bgr-2-gray](https://cloud.githubusercontent.com/assets/6229349/2613043/64307fda-bbcf-11e3-8a2d-a080f04a54df.jpeg)

Difference between BGR2GRAY and RGB2GRAY:
![difference](https://cloud.githubusercontent.com/assets/6229349/2613063/bfc5014a-bbcf-11e3-86f2-8f20176148ce.jpeg)