Skip to content
This repository was archived by the owner on Oct 7, 2024. It is now read-only.
This repository was archived by the owner on Oct 7, 2024. It is now read-only.

How to use "add_frame_arrived" ? #36

@tfluan0606

Description

@tfluan0606

I'm trying to implement window capture on specific window and send it to opencv.
I get a frame by keep calling try_get_next_frame(), send it to opencv and successfully show it.
But it can only got 1 frame, what i want to do is like obs window capture, keep listen window ,so that opencv can do some object detection.
I have read "screen-capture" and "screen-capture-video" by Microsoft build, I notice that both of these use FrameArrived to handle framepool. I think the equivalent one is add_frame_arrived, but how do I use it ?
https://learn.microsoft.com/en-us/windows/uwp/audio-video-camera/screen-capture#acquire-capture-frames
https://learn.microsoft.com/en-us/windows/uwp/audio-video-camera/screen-capture-video#start-capturing

The reson I want to use WGC is that the window I want to capture is hardware acceleration rendering.

Thank you for reading.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions