File tree Expand file tree Collapse file tree
examples/official/multi-document-capture Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ https://github.com/user-attachments/assets/bdda16cb-335e-47a2-8eb6-8945f4fa5a3f
2020## Requirements
2121
2222- Python 3.9+
23- - Windows 10/11 (camera via OpenCV DShow)
23+ - Windows, Linux, or macOS
2424- USB camera or image files
2525
2626## Install
Original file line number Diff line number Diff line change @@ -1059,10 +1059,7 @@ def _init_sdk(self, key: str):
10591059 self .init_status .setText (str (e ))
10601060
10611061 def _init_camera (self ):
1062- self .cap = cv2 .VideoCapture (0 , cv2 .CAP_DSHOW )
1063- if not self .cap or not self .cap .isOpened ():
1064- # Try any backend
1065- self .cap = cv2 .VideoCapture (0 )
1062+ self .cap = cv2 .VideoCapture (0 )
10661063 if self .cap and self .cap .isOpened ():
10671064 self .cap .set (cv2 .CAP_PROP_FRAME_WIDTH , 1920 )
10681065 self .cap .set (cv2 .CAP_PROP_FRAME_HEIGHT , 1080 )
You can’t perform that action at this time.
0 commit comments