转换颜色以模仿灰度打印 [英] Convert colors to imitate greyscale printing
问题描述
阅读此问题,我开始考虑是否可以转换颜色模拟平均灰度打印机(假设你的屏幕是校准的)?
When reading this question, I started to think whether it would be possible to convert colors to imitate an average greyscale printer (assuming that your screen is calibrated)? Finding an approvable approximation would save paper.
例如,如何转换这些颜色以查看浅蓝色和深蓝色和红色是否可以在纸上区分?
For example, how to convert these colors to see whether the light and dark blues and reds can be differentiated on paper?
temp <- rgb2hsv(239, 138, 98, maxColorValue=255)
Rl <- hsv(h = temp[1,], s = 0.5, v = 1)
Rd <- hsv(h = temp[1,], s = 0.5, v = 0.4)
temp <- rgb2hsv(103, 169, 207, maxColorValue=255)
Cl <- hsv(h = temp[1,], s = temp[2,], v = 1)
Cd <- hsv(h = temp[1,], s = temp[2,], v = 0.4)
plot(1:4, type = "p", col = c(Rl, Rd, Cl, Cd), pch = 19, cex = 8, xlim = c(0,5), ylim = c(0,5))
>
推荐答案
col2grey
(和/或 col2gray
)函数在TeachingDemos包中使用一个通用的方法来做到这一点。这个想法是看看当您以灰度而不是颜色打印或复制时,您的颜色会是什么样子。
The col2grey
(and/or col2gray
) function in the TeachingDemos package uses one common method for doing this. The idea is to see what your colors will look like when printed or copied in grayscale instead of color.
这篇关于转换颜色以模仿灰度打印的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!