https://github.com/ex-exe/windowsscreencapture
Capture window or monitor using 'Windows Graphics Capture' from the command line.
https://github.com/ex-exe/windowsscreencapture
capture windows
Last synced: about 1 year ago
JSON representation
Capture window or monitor using 'Windows Graphics Capture' from the command line.
- Host: GitHub
- URL: https://github.com/ex-exe/windowsscreencapture
- Owner: EX-EXE
- License: mit
- Created: 2024-03-16T09:13:24.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2024-03-17T00:46:15.000Z (over 2 years ago)
- Last Synced: 2025-04-15T05:46:45.531Z (about 1 year ago)
- Topics: capture, windows
- Language: C++
- Homepage:
- Size: 41 KB
- Stars: 4
- Watchers: 1
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# WindowsScreenCapture
Capture window or monitor using 'Windows Graphics Capture' from the command line.

## Arguments
|Argument|Description|Example|
|-|-|-|
| /Output: | Specify the destination for saving captured data. | /Output: "C://OutputDir/Output.png" |
| /Format: | Specifies the image format.(Default: png)[png/bmp/dds] | /Format: png |
| /ProcessId: | This is the Process ID (PID) of the target for capture. | /ProcessId: 10000 |
| /ProcessName: | This is the Process Name of the target for capture. | /ProcessName: Taskmgr.exe |
| /Monitor: | This is the Monitor Index of the target for capture. | /Monitor: 0 |
| /CaptureCursor: | This specifies whether to include the mouse cursor in the capture. (Default: Disable) | /CaptureCursor: Enable |
| /TimeoutSec: | This specifies the timeout duration for capturing (in seconds) | /TimeoutSec: 10.0 |
| /Licence: | Displays the license of the library being used. | /Licence: |
## Example
```
WindowsScreenCapture.exe /ProcessName: Taskmgr.exe /Output: ./output.png
```
```
WindowsScreenCapture.exe /Monitor: 0 /Output: ./output.png
```
## Packages
- [DirectXTK](https://github.com/microsoft/DirectXTK)