fixed issue with cornerSubPix being executed even if no points were detected.