开发者

How to quantize image color from RGB 24 bit to RGB 6 bit (64 colors)?

I'm trying to deploy BIC algorithm (border/interior pixel classify) and using PIL (python imaging library) to process image . But i don't know how to quantize RGB color from 24bit (8b开发者_Python百科it per color) to 6 bit (2bit per color) by using PIL . Anyone can tell me how to do it by PIL or another python library such as Opencv , pythonmagick...?


the PIL ImageOps posterize (scroll down to posterize) function should do this for you.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜