C语言中如何将RGB分量转换为百分比?
如何将 RGB 分量 (0-255) 转换为浮点数,其中 255 为 1.0f,0 为 0.0f?
How do I conver an RGB component (0-255) to a floating point number in which 255 would be 1.0f and 0 would be 0.0f?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
划分有什么问题吗?
What's wrong with dividing?
像这样:
Like this:
如果 int 中有完整的 rgb 值,则可以选择此选项。
输出
And if you have the entire rgb value in the int you have this option.
Output