Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
e49ea39a
Commit
e49ea39a
authored
Apr 19, 2012
by
Alexey Spizhevoy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed parsing cmd args bug (videostab)
parent
f355f798
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
10 deletions
+10
-10
videostab.cpp
samples/cpp/videostab.cpp
+10
-10
No files found.
samples/cpp/videostab.cpp
View file @
e49ea39a
...
@@ -93,7 +93,7 @@ void printHelp()
...
@@ -93,7 +93,7 @@ void printHelp()
" --stdev=(<float_number>|auto)
\n
"
" --stdev=(<float_number>|auto)
\n
"
" Set smoothing weights standard deviation. The default is auto
\n
"
" Set smoothing weights standard deviation. The default is auto
\n
"
" (i.e. sqrt(radius)).
\n
"
" (i.e. sqrt(radius)).
\n
"
" -lp
, --lp
-stab=(yes|no)
\n
"
" -lp
s, --lin-prog
-stab=(yes|no)
\n
"
" Turn on/off linear programming based stabilization method.
\n
"
" Turn on/off linear programming based stabilization method.
\n
"
" --lp-trim-ratio=(<float_number>|auto)
\n
"
" --lp-trim-ratio=(<float_number>|auto)
\n
"
" Trimming ratio used in linear programming based method.
\n
"
" Trimming ratio used in linear programming based method.
\n
"
...
@@ -409,15 +409,15 @@ int main(int argc, const char **argv)
...
@@ -409,15 +409,15 @@ int main(int argc, const char **argv)
#if HAVE_OPENCV_GPU
#if HAVE_OPENCV_GPU
PyrLkRobustMotionEstimatorGpu
*
est
=
0
;
PyrLkRobustMotionEstimatorGpu
*
est
=
0
;
if
(
arg
(
"
ws-
model"
)
==
"transl"
)
if
(
arg
(
"model"
)
==
"transl"
)
est
=
new
PyrLkRobustMotionEstimatorGpu
(
MM_TRANSLATION
);
est
=
new
PyrLkRobustMotionEstimatorGpu
(
MM_TRANSLATION
);
else
if
(
arg
(
"
ws-
model"
)
==
"transl_and_scale"
)
else
if
(
arg
(
"model"
)
==
"transl_and_scale"
)
est
=
new
PyrLkRobustMotionEstimatorGpu
(
MM_TRANSLATION_AND_SCALE
);
est
=
new
PyrLkRobustMotionEstimatorGpu
(
MM_TRANSLATION_AND_SCALE
);
else
if
(
arg
(
"
ws-
model"
)
==
"similarity"
)
else
if
(
arg
(
"model"
)
==
"similarity"
)
est
=
new
PyrLkRobustMotionEstimatorGpu
(
MM_SIMILARITY
);
est
=
new
PyrLkRobustMotionEstimatorGpu
(
MM_SIMILARITY
);
else
if
(
arg
(
"
ws-
model"
)
==
"affine"
)
else
if
(
arg
(
"model"
)
==
"affine"
)
est
=
new
PyrLkRobustMotionEstimatorGpu
(
MM_AFFINE
);
est
=
new
PyrLkRobustMotionEstimatorGpu
(
MM_AFFINE
);
else
if
(
arg
(
"
ws-
model"
)
==
"homography"
)
else
if
(
arg
(
"model"
)
==
"homography"
)
est
=
new
PyrLkRobustMotionEstimatorGpu
(
MM_HOMOGRAPHY
);
est
=
new
PyrLkRobustMotionEstimatorGpu
(
MM_HOMOGRAPHY
);
else
else
{
{
...
@@ -426,12 +426,12 @@ int main(int argc, const char **argv)
...
@@ -426,12 +426,12 @@ int main(int argc, const char **argv)
}
}
RansacParams
ransac
=
est
->
ransacParams
();
RansacParams
ransac
=
est
->
ransacParams
();
if
(
arg
(
"
ws-subset"
)
!=
"auto"
)
ransac
.
size
=
argi
(
"ws-
subset"
);
if
(
arg
(
"
subset"
)
!=
"auto"
)
ransac
.
size
=
argi
(
"
subset"
);
if
(
arg
(
"
ws-thresh"
)
!=
"auto"
)
ransac
.
thresh
=
argi
(
"ws-
thresh"
);
if
(
arg
(
"
thresh"
)
!=
"auto"
)
ransac
.
thresh
=
argi
(
"
thresh"
);
ransac
.
eps
=
argf
(
"
ws-
outlier-ratio"
);
ransac
.
eps
=
argf
(
"outlier-ratio"
);
est
->
setRansacParams
(
ransac
);
est
->
setRansacParams
(
ransac
);
est
->
setMinInlierRatio
(
argf
(
"
ws-
min-inlier-ratio"
));
est
->
setMinInlierRatio
(
argf
(
"min-inlier-ratio"
));
stabilizer
->
setMotionEstimator
(
est
);
stabilizer
->
setMotionEstimator
(
est
);
#else
#else
throw
runtime_error
(
"OpenCV is built without GPU support"
);
throw
runtime_error
(
"OpenCV is built without GPU support"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment