Open morya opened 3 months ago
Hmmm, that will need some debugging, but the fact that it failed before even reaching the error message "CreateCaptureSession is not supported on this version of Windows" means you might have a GPU problem, do you know what GPU you are using?
wincam
requires Windows 10 version 10.0.26100.0 or later, or Windows 11. And you must have a GPU that supports DirectX 11. Specifically we call D3D11CreateDevice asking for hardware support for D3D11_SDK_VERSION on D3D11_CREATE_DEVICE_BGRA_SUPPORT images.
I confirm
Failed to start capture, error code 7fffbffe
File "E:\Dev\Project\Python\ddd\main.py", line 213, in copy_backup_proc
frame, _ = camera.get_bgr_frame()
^^^^^^^^^^^^^^^^^^^^^^
File "E:\Dev\Project\Python\ddd\main.py", line 166, in copy_backup
self._modifyCallback(self._src_dir, loc_path)
File "E:\Dev\Project\Python\ddd\main.py", line 190, in <lambda>
threading.Timer(DELAY_BEFORE_BACKUP, lambda: self.copy_backup()).start()
^^^^^^^^^^^^^^^^^^
Exception: Failed to start capture, error code 7fffbffe
win10, dx12, rtx4080
Getting the same Error: Failed to start capture, error code 7fffbffe running one of the examples while meeting all requirements.
Try moving your VM to windows 11. I do have Azure VM's running Windows 11 where wincam is working perfectly.
sample code was copied from example folder of this repo.
examples/video.py