From 9dff0deb8e30d809abe1d7152175bd807c33d719 Mon Sep 17 00:00:00 2001 From: boyska Date: Fri, 13 Jan 2017 00:16:22 +0100 Subject: [PATCH] write image output --- lines.cpp | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/lines.cpp b/lines.cpp index e37fea1..b3e622f 100644 --- a/lines.cpp +++ b/lines.cpp @@ -28,7 +28,7 @@ int main(int argc, char *argv[]) char const *fname = "files/masckera.png"; if( 1 params; + params.push_back(CV_IMWRITE_PNG_COMPRESSION); + params.push_back(9); + Mat dst; + img.convertTo(dst, CV_8UC3); + cv::imwrite(argv[2], dst, params); + } return EXIT_SUCCESS; }