CapSoftware / scap

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

feat: adds Target struct for Windows and Displays #78

Closed clearlysid closed 6 months ago

clearlysid commented 6 months ago

Changes:

  1. Split out util functions into a separate module from Display
  2. Add a Target enum wrapping Displays and Windows
  3. Adds windows as targets on macOS
  4. Adds displays and windows as targets on Windows 11
  5. Fetches correct human-readable names for monitors on macOS
clearlysid commented 6 months ago

@Pranav2612000 ready for merge from my side.

This PR mostly sets up the structure for Targets. However, scap still doesn't really "consume" these targets atm and only captures main display. Once this PR is merged, I'll make 2 separate ones to actually consume these targers in the capturer — one windows and one mac.