我希望制作一个小型的Photoshop JavaScript程序。从技术上讲,我只需要知道如何比较像素的颜色值,就好像它们是一个包含三个整数值的数组一样,例如:(伪代码)
for all pixels x
for all pixels y
if left pixel's green channel is bigger than red channel:
set the blue channel to 25
else
if the blue channel is greater than 50
set the green channel to 0
在文档中,有很多类似过滤器、文本和图层的操作,但如何执行这样简单的操作呢?