为什么 OpenCV 使用 BGR 色彩空间而不是 RGB [英] Why OpenCV Using BGR Colour Space Instead of RGB

查看:28
本文介绍了为什么 OpenCV 使用 BGR 色彩空间而不是 RGB的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

为什么 OpenCV 使用 BGR 颜色空间而不是 RGB.我们都知道RGB 是大多数计算机图形的便捷颜色模型,而且人类视觉系统的工作方式类似于RGB 颜色空间.OpenCV BGR 色彩空间背后有什么原因吗?.

Why OpenCV using BGR colour space instead of RGB. We all know that RGB is the convenient colour model for most of the computer graphics and also the human visual system works in a way that is similar to a RGB colour space. Is there any reason behind OpenCV BGR colour space?.

推荐答案

"OpenCV 的早期开发者之所以选择 BGR 颜色格式,可能是因为当时 BGR 颜色格式在相机制造商和软件提供商中很流行.例如在 Windows, 当使用 COLORREF 指定颜色值时,它们使用 BGR 格式 0x00bbggrr.

"The reason why the early developers at OpenCV chose BGR color format is probably that back then BGR color format was popular among camera manufacturers and software providers. E.g. in Windows, when specifying color value using COLORREF they use the BGR format 0x00bbggrr.

BGR 是出于历史原因做出的选择,现在我们必须接受它.换句话说,BGR 在 OpenCV 中就是马的屁股."

BGR was a choice made for historical reasons and now we have to live with it. In other words, BGR is the horse’s ass in OpenCV."

这篇关于为什么 OpenCV 使用 BGR 色彩空间而不是 RGB的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆