Be more explicit about type conversion for OpenCV