We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1972340 commit 319e837Copy full SHA for 319e837
modules/CameraCapture/CameraCapture.cpp
@@ -13,6 +13,13 @@ CameraCapture::CameraCapture()
13
{
14
}
15
16
+CameraCapture::~CameraCapture()
17
+{
18
+ if(cap.isOpened()) {
19
+ cap.release();
20
+ }
21
+}
22
+
23
int CameraCapture::findAvailableCameraID(int maxTested)
24
25
for(int i = 0; i < maxTested; ++i) {
modules/CameraCapture/CameraCapture.h
@@ -17,6 +17,7 @@
class CameraCapture {
public:
CameraCapture();
+ ~CameraCapture();
/**
* @brief 利用可能なカメラIDを探索する
0 commit comments