Commit Graph

24 Commits

Author SHA1 Message Date
Julien Savard 7b00eab8ad swaygrab: Fix memory leak when recording videos 2015-12-22 23:47:07 -05:00
Mikkel Oscar Lyderik c97555d9f0 swaygrab: add default output filename.
With this it's possible to run `swaygrab` without a filename argument.
With no filename supplied it will use a default name based on the
current time.

The default file will get the extension `png` for screenshots and `webm`
for video capture.
2015-12-17 18:37:09 +01:00
Mikkel Oscar Lyderik 64ccd63f13 swaygrab: update man page 2015-12-17 16:47:18 +01:00
Mikkel Oscar Lyderik d49282b2c3 swaygrab: make focused output default
This makes swaygrab use the currently focused output as source if no
other output is defined with the `-o, --output <output>` option.
2015-12-17 16:09:03 +01:00
Mikkel Oscar Lyderik 45b959f601 Move numlen(1) to sway/util.c 2015-12-14 17:07:52 +01:00
Christoph Gysin 99af7e7c9c move manpages to subfolders 2015-12-02 12:49:01 +02:00
Christoph Gysin cce9c338c0 cmake: build common code only once
This creates (static) libraries for protocols/, common/, and wayland/.
2015-12-02 12:15:57 +02:00
Christoph Gysin c9ce15aa18 cmake: remove subprojects 2015-12-01 22:47:22 +02:00
Christoph Gysin 2dedf206d7 cmake: use out-of-source build 2015-12-01 22:03:09 +02:00
Christoph Gysin f7ec3d00a0 cmake: use tabs instead of spaces 2015-12-01 22:03:09 +02:00
Christoph Gysin 905966bcae cmake: style consistency 2015-12-01 22:03:09 +02:00
Christoph Gysin 2429266e3e cmake: convert all cmake commands to lowercase 2015-12-01 22:03:09 +02:00
Christoph Gysin 923c3245ac Fix option parsing
Using 'flag' results in duplicate code paths for short and long options.

This broke the -q short option in swaymsg, because there was:

 {"quiet", no_argument, &quiet, 'q'}

Which will set quiet to 'q' and return 0, not 'q'.
2015-11-28 23:50:44 +02:00
Christoph Gysin 12c8cf5bf6 swaygrab: Add --help option that prints usage 2015-11-28 23:50:44 +02:00
Christoph Gysin b235ccd212 swaygrab: Print usage and exit on unknown options 2015-11-28 23:50:44 +02:00
Christoph Gysin 3ba33321de Use macros for exit values 2015-11-28 23:50:10 +02:00
Drew DeVault 4916e30378 Remove extraneous logging from swaygrab 2015-11-28 09:04:02 -05:00
Drew DeVault e0cb8284fb Rearrange logging headers
Ref #270
2015-11-28 08:49:02 -05:00
Drew DeVault 0bb872ab70 Fix uninitialized variable warning in swaygrab 2015-11-27 16:01:19 -05:00
Drew DeVault 2ef7cf9e97 Add ffmpeg capture to swaygrab (with limitations)
This needs to be multithreaded to have any sort of realistic expectation
of performance, due to issues with syncronous I/O.
2015-11-27 14:21:38 -05:00
Drew DeVault 04bd9386fe Fix swaygrab memory leak 2015-11-27 10:40:28 -05:00
Drew DeVault f05b6cd55c Implement swaygrab for still images 2015-11-27 10:39:18 -05:00
Drew DeVault 062c74b7d0 Add command line to swaygrab
Also modifies IPC client so that we can work with persistent
connections.
2015-11-27 10:10:29 -05:00
Drew DeVault 7c04cd4fc8 Add swaygrab subproject 2015-11-27 09:53:50 -05:00