mirror of https://github.com/davisking/dlib.git
Added an error message if a camera isn't available.
This commit is contained in:
parent
617ffba652
commit
0cd76f899b
|
@ -42,6 +42,12 @@ int main()
|
|||
try
|
||||
{
|
||||
cv::VideoCapture cap(0);
|
||||
if (!cap.isOpened())
|
||||
{
|
||||
cerr << "Unable to connect to camera" << endl;
|
||||
return 1;
|
||||
}
|
||||
|
||||
image_window win;
|
||||
|
||||
// Load face detection and pose estimation models.
|
||||
|
|
Loading…
Reference in New Issue