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
d6a32120
Commit
d6a32120
authored
Jun 10, 2010
by
Vadim Pisarevsky
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
can now select the camera for calibration
parent
023e2b28
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
2 deletions
+9
-2
calibration.cpp
samples/c/calibration.cpp
+9
-2
No files found.
samples/c/calibration.cpp
View file @
d6a32120
...
...
@@ -226,6 +226,8 @@ int main( int argc, char** argv )
int
mode
=
DETECTION
;
int
undistort_image
=
0
;
CvSize
img_size
=
{
0
,
0
};
int
cameraId
=
0
;
const
char
*
live_capture_help
=
"When the live video from camera is used as input, the following hot-keys may be used:
\n
"
" <ESC>, 'q' - quit the program
\n
"
...
...
@@ -318,7 +320,12 @@ int main( int argc, char** argv )
out_filename
=
argv
[
++
i
];
}
else
if
(
s
[
0
]
!=
'-'
)
input_filename
=
s
;
{
if
(
isdigit
(
s
[
0
])
)
sscanf
(
s
,
"%d"
,
&
cameraId
);
else
input_filename
=
s
;
}
else
return
fprintf
(
stderr
,
"Unknown option %s"
,
s
),
-
1
;
}
...
...
@@ -336,7 +343,7 @@ int main( int argc, char** argv )
mode
=
CAPTURING
;
}
else
capture
=
cvCreateCameraCapture
(
0
);
capture
=
cvCreateCameraCapture
(
cameraId
);
if
(
!
capture
&&
!
f
)
return
fprintf
(
stderr
,
"Could not initialize video capture
\n
"
),
-
2
;
...
...
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