fast screen capture musings

odd, but

may have some clues, as also

vdub is supposed to be able to do it.

Here’s some code that touts itself as super fast:

says “if you use getRenderTargetArea…”

says “use a Video Miniport driver, Mirror Driver”

actually contains some directshow screen capture code

that “one” downloadable is actually quite fast tho…hmm…

35 thoughts on “fast screen capture musings”

  1. it might vary dependent on graphics card, OS, app…hmm…
    also apparently there’s an opengl way to grab, to complement the directx way. Which is fast, dunno…

  2. faster than GetFrontBufferData()? Reply Quote
    read back from the GPU is not fast, nor is it every likely to be fast. Trying to round-trip the data like you are doing above is always going to be incrediably slow.

    WDDM-based APIs like Direct3D 10.x and Direct3D 11 are a bit faster than the XPDM …


    mentions the mirror again…might be good for catching changes, but maybe not so good for knowing when a new frame has finished…

    maybe upping the priority during the bitblt to make it avoid tearing?

    maybe warn if they don’t have 2 cores? 3 possibly even better? hmm…

    also maybe could use memcpy instead, or a tight loop? (someplace mentioned they do that…)

  4. maybe if you can figure out how to only grab the part of the screen that has changed…hmm…what if you do “teeny stripes” bit blt’ing is that as fast as one large one, that might be one way…hmm…or possibly leverage the tightvnc server to know which areas have changed…

  5. multi-thread so that “exactly every x fps, it already has one [just] ready to send down the chain” (or chained multi-thread, or what not, just pull the latest one)…

  6. maybe use “Flip” then hook into the “Present” method to ‘know’ when the thing occurs, instead of having to busy wait (or sleep loop wait? though sleeping 1ms might not hurt too bad 😛 especially since you can catch it “in the middle of” a scan refresh which should be a good time to grab ) waiting for the WaitForVerticalBlank method to return…hmm

  7. Pingback: Fastest method of screen capturing on Windows |

Leave a Reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload the CAPTCHA.