Binary threshold on saturation instead of luminescence value #1539
-
In a biological monitoring project we analyse belly patterns of yellow bellied toads (bombina variegata). We need to find patterns of yellow and black colors. Unfortunately the black parts can range from very dark to light grey with luminescence values higher than the yellow parts. Here you can see the raw image of a toad: We use a rectangular field between cloak and snout, shown in the left part of the following image: The center image shows the BinaryThreshold processor applied with a threshold value of 0.5. I modified the processor to use the saturation value instead of the luminescence value for comparison with the threshold. This gives the right image, which discriminates between the yellow and the "black" parts. Extending the processor and the corresponding constructors and extension methods I get the wanted results. The patch containing my extensions is here: ImageSharp_saturation_threshold.txt If you think this solution makes sense for ImageSharp, I would be happy to find it integrated sometime. BTW: Congratulations to this extremely elegant image processing library! Cheers Franz |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 5 replies
-
This sound like a good addition to me. Would you mind creating a PR for that? |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
This sound like a good addition to me. Would you mind creating a PR for that?