Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
#! /bin/bash
for file in toconvert/*
do
filename=`pwd`/$file
basename=`echo $filename | sed 's/.*toconvert\/\(.*\)\.[^\.]*$/\1/'`
targetname=`pwd`/converted/$basename'.mp4'
ffmpeg -vaapi_device /dev/dri/renderD128 -hwaccel vaapi -hwaccel_output_format vaapi -i $filename -loglevel error -c:v h264_vaapi $targetname -y
done
echo 'done'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment