How do I invert a grayscale image and convert it to a binary image?

前端 未结 5 1334
栀梦
栀梦 2021-01-14 07:40

I want to create an image like this: \"alt From an image like this:

5条回答
  •  清酒与你
    2021-01-14 08:04

    It looks like the 3rd plot is the reverse of the 2nd above.

    One thing to consider is what you are using for draw image image() imagesc() or imshow() imagesc() does auto scaling and imshow() will use a color map.

    Another thing to consider is the input image itself. Does it range from 0 - 255, 0 - 1.0 or RGB? Depending on what it is, the reverse would be different.

提交回复
热议问题