ra1nty / DXcam

A Python high-performance screen capture library for Windows using Desktop Duplication API
MIT License
457 stars 67 forks source link

how to do the accurate sleep #66

Open dvdco opened 1 year ago

dvdco commented 1 year ago

how can i use the accurate sleep on my own?

AI-M-BOT commented 11 months ago

old topic

def psleep(num: int):
    windll.winmm.timeBeginPeriod(1)
    windll.kernel32.Sleep(int(num))
    windll.winmm.timeEndPeriod(1)