gpu-screen-recorder: specified audio input & output, audio codec and video codec for better compatibility

master
tiyn 1 year ago
parent 69f05f6c96
commit 928f9c7c27

@ -2,10 +2,13 @@
window=$(xdotool getwindowfocus) window=$(xdotool getwindowfocus)
fps=60 fps=60
audio="$(pactl get-default-sink).monitor" audio_1="easyeffects_sink.monitor"
audio_2="easyeffects_source"
format="mp4" format="mp4"
v_codec="h264"
a_codec="opus"
lenght=20 lenght=20
output="$HOME/downloads" output="$HOME/downloads"
gpu-screen-recorder -w $window -f $fps -a $audio -c $format -r $lenght -o $output & gpu-screen-recorder -w $window -f $fps -a $audio_1 -a $audio_2 -c $format -k $v_codec -ac $a_codec -r $lenght -o $output &
notify-send 'Screen record' 'Replay started' notify-send 'Screen record' 'Replay started'

@ -2,9 +2,12 @@
window=$(xdotool getwindowfocus) window=$(xdotool getwindowfocus)
fps=30 fps=30
audio="$(pactl get-default-sink).monitor" audio_1="easyeffects_sink.monitor"
audio_2="easyeffects_source"
format="mp4" format="mp4"
v_codec="h264"
a_codec="opus"
output="$HOME/downloads/recording-$(date '+%Y-%m-%d_%H-%M-%S').$format" output="$HOME/downloads/recording-$(date '+%Y-%m-%d_%H-%M-%S').$format"
gpu-screen-recorder -w $window -c "mp4" -f $fps -a $audio -o $output & gpu-screen-recorder -w $window -c $format -k $v_codec -ac $a_codec -f $fps -a $audio_1 -a $audio_2 -o $output &
notify-send 'Screen record' 'Recording started' notify-send 'Screen record' 'Recording started'

Loading…
Cancel
Save