I need to black out part of the image. to do so I tried this code:
img2[0:0, 640:150] = [0, 0, 0]
img2[0:490, 640:640] = [0, 0, 0]
but it does not seem to be working. The image is a numpy array.
So my questions are:
- why does my image img2 look the same before and after the execution of these rows?
- I need to black out everything except a rectangle. i wanted to do so by drawing 4 rectangles on the outside. can this also be done by saying one time what I do NOT want to blacken? so basically the inverse of the range?