Small script to detect AAC audio in video files and transcode the audio stream to LPCM (pcm_s16le) while copying the video stream. Useful for editing in tools that don't support AAC audio (e.g. DaVinci Resolve on some Linux setups).
convert.sh— main script. Run with-hto see usage.converter_gui.py— GUI wrapper for the converter script using tkinter.
Simply run the GUI application:
python3 converter_gui.pyThe graphical interface allows you to:
- Browse and select input/output directories
- Choose audio codec and output format from dropdowns
- Configure parallel jobs
- Enable options like dry-run, keep originals, and force conversion
- View real-time conversion progress and output
- Start, stop, and monitor conversions
Basic usage from the project root:
chmod +x convert.sh./convert.sh -i /path/to/videos -o /path/to/outputKey options:
-i INPUT_DIR— directory to search for.mp4files (default: current directory)-o OUTPUT_DIR— where converted files are written (defaults to input dir)-a AUDIO_CODEC— audio codec for ffmpeg (default:pcm_s16le; acceptslpcmshorthand)-f FORMAT— container format/extension for output files (default:mov)-n— dry-run (prints actions, does not runffmpegor delete originals)-k— keep originals (don't delete source.mp4after successful conversion)-F— force conversion even if audio codec isn'taac
Run ./convert.sh -h for the full help text.
Notes:
- Make sure
convert.shis executable before running:chmod +x convert.sh. - The script depends on
ffmpeg/ffprobebeing installed and available in PATH. - The GUI requires Python 3 with tkinter (usually included with Python installations).
- If a video file has multiple audio tracks, all tracks will be preserved without transcoding.