CapSoftware / scap

High-performance, cross-platform screen capture library in Rust.
https://crates.io/crates/scap
Other
231 stars 44 forks source link

feat: macos targets scale factor #86

Closed clearlysid closed 6 months ago

clearlysid commented 6 months ago

Previously scale_factor was only calculated on a Display level. This PR updates the function to also work on Window targets as well.

This is the macOS equivalent of PR #85 (for Windows OS)

It also adds a CGWindowID so people can get the underlying raw_window_handle from there.

clearlysid commented 6 months ago

Merging this since it's a small one. Have tested it on my machine ✅