diff --git a/README b/README index 3d09d94..a24409c 100644 --- a/README +++ b/README @@ -59,7 +59,7 @@ Examples ./prpa -f drunk -f sepia -o bar.avi -c MP42 foo.avi ./prpa -f blur=50 -f reverse -o bar.avi -c XVID foo.avi -./prpa -f inlay=1,0,0 -o bar.avi -c XVID foo.avi +./prpa -f inlay=1,0,0 -o bar.avi -c XVID foo.avi inlayed.avi ./prpa -f strictinlay=255,137,42 -o bar.avi -c XVID orig.avi inlayed.avi time ./prpa -f drunk -f sepia -o bar.avi -c MP42 foo.avi diff --git a/src/filterSample/rotate.cc b/src/filterSample/rotate.cc index b6385d9..a611fe0 100644 --- a/src/filterSample/rotate.cc +++ b/src/filterSample/rotate.cc @@ -9,7 +9,7 @@ void* Rotate::operator()(void* para) if (direction_ == 0) // rotate-h for (size_t i = 0; i < mat->rows; ++i) - for (size_t j = mat->cols / 2 + 1; j > 0; --j) + for (size_t j = 0; j < mat->cols / 2; ++j) { cv::Vec3b tmp = mat->at(i, j); mat->at(i, j) = mat->at(i, mat->cols - j - 1); @@ -17,7 +17,7 @@ void* Rotate::operator()(void* para) } else if (direction_ == 2 || direction_ == -2) // rotate-v - for (size_t i = mat->rows / 2 + 1; i > 0; --i) + for (size_t i = 0; i < mat->rows / 2; ++i) for (size_t j = 0; j < mat->cols; ++j) { cv::Vec3b tmp = mat->at(i, j); diff --git a/src/main.cc b/src/main.cc index a76029b..900edb9 100644 --- a/src/main.cc +++ b/src/main.cc @@ -20,7 +20,8 @@ bool parse_cli(Configuration& conf, int argc, char** argv) ("help,h", "produce help message") ("filter,f", po::value>(), "apply a filter; " "choose between grey, reverse, cartoon, drunk, count, color=B,G,R, sepia," - " blur[=X], merge, interlace, inlay=B,G,R, strictinlay=B,G,R") + " blur[=X], rotate-x, rotate-y, merge, interlace, inlay=B,G,R," + " strictinlay=B,G,R") ("input-file,i", po::value>(), "file to treat") ("output,o", po::value(), "output file") ("codec,c", po::value(), "output codec")