Changing image hue with Python PIL

前端 未结 3 768
野趣味
野趣味 2020-11-27 04:40

Using Python PIL, I\'m trying to adjust the hue of a given image.

I\'m not very comfortable with the jargon of graphics, so what I mean by “adjusting hue” is doing t

3条回答
  •  臣服心动
    2020-11-27 05:27

    With a recent copy of Pillow, one should probably use Image.convert():

    def rgb2hsv(image: PIL.Image.Image):
        return image.convert('HSV')
    

提交回复
热议问题