Commit f737aab
Change type of VideoCaptureProperties to int32
This patch changes the type of `VideoCaptureProperties` to `int32`. It is currently set to `int`. This breaks `VideoCapture_OpenDeviceWithAPIParams` because it doesn't correclty unroll the slice into the `std::vector<int>` here:
```c++
bool VideoCapture_OpenDeviceWithAPIParams(VideoCapture v, int device, int apiPreference, int *paramsv, int paramsc) {
std::vector< int > params;
for( int i = 0; i< paramsc; i++) {
params.push_back(paramsv[i]);
}
return v->open(device, apiPreference, params);
}
```
With `int64` this for loop will create only zeros in the value parts of the array that OpenCV expects (`[p1, v1, ..., pn, vn]`).
Changing it to `int32` unpacks the slice correctly and OpenCV will pass the parameters correctly to the respective VideoCapture backends.1 parent fbf4c89 commit f737aab
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
119 | 119 | | |
120 | 120 | | |
121 | 121 | | |
122 | | - | |
| 122 | + | |
123 | 123 | | |
124 | 124 | | |
125 | 125 | | |
| |||
0 commit comments