node-opencv icon indicating copy to clipboard operation
node-opencv copied to clipboard

inrange

Open btsimonh opened this issue 8 years ago • 0 comments

hi, I always seem to be getting black from inRange. Can't see anything wrong with the code; really confused;

code: var lower = [0,0,0]; var upper = [255,255,255]; img.inRange(lower, upper); var mask = img.copy();

I expect complete white from the above, or var lower = [0,250,0]; var upper = [0,255,0]; to pick out solid green.

both give a completely black image. If I comment out the inRange, I see the picture with my green parts (the ones I want).

any ideas?

btsimonh avatar Nov 03 '17 22:11 btsimonh