RGB to Grayscaler
2014-07-23 10:51
375 查看
1. The lightness method averages the most prominent and least prominent colors:
(max(R, G, B) + min(R, G, B)) / 2.
2. The average method simply averages the values: (R + G + B) / 3.
3. The luminosity method is a more sophisticated version of the average method. It also averages the values, but it forms a weighted average to account for human perception. We’re more sensitive to green than other colors,
so green is weighted most heavily. The formula for luminosity is 0.21 R + 0.72 G + 0.07 B.
根据不同需求,选择不同的转换方式!
原文地址
(max(R, G, B) + min(R, G, B)) / 2.
2. The average method simply averages the values: (R + G + B) / 3.
3. The luminosity method is a more sophisticated version of the average method. It also averages the values, but it forms a weighted average to account for human perception. We’re more sensitive to green than other colors,
so green is weighted most heavily. The formula for luminosity is 0.21 R + 0.72 G + 0.07 B.
根据不同需求,选择不同的转换方式!
原文地址
相关文章推荐
- RGB to Gray 高效算法
- RGB to Gray 流行算法
- 【详细内容】NCS8805 RGB/LVDS-to-eDP w/ Scaler芯片规格书
- RGB to Gray
- MATLAB RGB to Gray
- 彩色转灰度算法 RGB to Gray
- RGB to Gray 流行算法
- RGB to Gray 流行算法
- RGB to Gray
- RGB to gray
- Matlab 伪彩色 grayscale to rgb
- How to Convert Temperature (K) to RGB: Algorithm and Sample Code
- RGB TO ARGB
- Android OpenGL es GPUImage convert YUV to RGB
- Useful color equations: RGB to LAB converter
- OpenCV简单操作-RGB转gray
- 请编写一个JavaScript 函数toRGB,它的作用是转换CSS中常用的颜色编码
- VGA to RGB + composite sync -converter
- ITU709 Matrix to convert between YCbCr and RGB
- YUV to RGB Conversion