Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to capture window-content only? #74

Closed
Frixs opened this issue Nov 15, 2020 · 3 comments
Closed

How to capture window-content only? #74

Frixs opened this issue Nov 15, 2020 · 3 comments

Comments

@Frixs
Copy link

Frixs commented Nov 15, 2020

Hello,

how is it possible to capture only user content of selected window in ScreenCapture project?

I want to achieve to capture window without Window's control bar on the top and capture just the user content area.
Similar approach is presented here using GetDC() instead of GetWindowDC() from User32

Thank you for your assistance!

@robmikh
Copy link
Member

robmikh commented Nov 16, 2020

Unfortunately, capturing only the client area is not available at this time. You'll need to calculate the window's client area rect and copy that out of the buffer we provide.

You'll likely need to use a mix of ClientToScreen, DwmGetWindowAttribute, and DWMWA_EXTENDED_FRAME_BOUNDS.

@robmikh robmikh closed this as completed Jan 22, 2021
@BenShapira
Copy link

Hey Rob,
Wanted to check in if this is something that might have been added since your last comment?

@robmikh
Copy link
Member

robmikh commented Apr 8, 2023

Unfortunately not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants