You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 23, 2022. It is now read-only.
import d3dshot
import time
d = d3dshot.create(capture_output="numpy")
d.capture(region=(100,100,300,300), target_fps=30)
time.sleep(20)
d.stop()
d.frame_buffer_to_disk()
dumping frame buffer to disk always yields following error: File "C:\ProgramData\Anaconda3\envs\testing_env\lib\site-packages\d3dshot\d3dshot.py", line 119, in frame_buffer_to_disk for i, frame in enumerate(self.frame_buffer): RuntimeError: deque mutated during iteration
The text was updated successfully, but these errors were encountered:
Runs fine here on 3.8.3. It's hard to tell why you are getting this but going by the error message: d.stop() might not be done running or getting ignored. d.frame_buffer_to_disk() iterates over what's in the frame buffer to save the individual images but if it receives new data while it does that, Python is not going to like it.
I'll look into why that could be happening at all and to see if there is more reliable way to stop the capture. I could also just copy the frame buffer to a separate iterable only for the duration of the image saving on disk.
dumping frame buffer to disk always yields following error:
File "C:\ProgramData\Anaconda3\envs\testing_env\lib\site-packages\d3dshot\d3dshot.py", line 119, in frame_buffer_to_disk for i, frame in enumerate(self.frame_buffer): RuntimeError: deque mutated during iteration
The text was updated successfully, but these errors were encountered: