0

I have an image with 4 channels BGRA. I want to check my image if there is value in the 4th channel. Then I want to get values from the area that have value in the 4th channel. I want to get the same image within values from the area that have value in the 4th channel. I want to ignore and make other areas zero.

It's like that: There is a image. some part of image fully transparant. And I want to make zero in transparant area. Because I'll use this image for cv:add method.

I hope you understood.

how can I do like that?

hede
  • 1
  • 2
  • 1
    Welcome to Stack Overflow. Please consider [taking the tour](https://stackoverflow.com/tour). Users are much more likely to help if you show some [research effort](https://meta.stackoverflow.com/questions/261592) on your own. Please provide a [mre] to your _specific_ problem. Show any code you tried so far, and provide some clean sample input, and the expected output (even manually drawn). – HansHirse Sep 20 '19 at 05:59
  • use the inRange function to find all pixels as a mask and then use setTo function to set them to (0,0,0,0) – Micka Sep 20 '19 at 06:18

0 Answers0