russelltg / wl-screenrec

High performance wlroots screen recording, featuring hardware encoding
Apache License 2.0
266 stars 10 forks source link

Question / README expansion: how to scale down output #37

Closed hholst80 closed 7 months ago

hholst80 commented 7 months ago

I am recording a 4K display but I only need the output to be in 1080p is there a way to make the output directly into 1080p without having to transcode the output from wl-screenrec as a post-processing operation?

Update: With the variable frame-rate I think I will not need this feature after all. The output files even though they are in 4K are comparable in size to the 1080p downscaled video. It could perhaps be a good thing to have anyway to make it explicit to newbies like me that are not familiar with ffmpeg workflows.

russelltg commented 7 months ago

The suggested way to control the output file size is by changing the bitrate. However, adding options to scale would be trivial and efficient (we can do it in the same step as pixel format conversion).

Yeah, VFR helps (can be turned off btw, with --no-damage) quite a bit.

russelltg commented 7 months ago

Just added a --encode-resolution flag that should do this.