OpenCV with a couple of tweaks