Needed: Automatic screenshots on window changes

I can’t find windows software anywhere that will attach to a window/process, and automatically take a screenshot of that window (or child windows) every x seconds or whenever a change is detected. If the attached-to app is running and a progress bar in it updates, or a confirmation popup appears, or the text in that …