#!/bin/sh ## ## SCRIPT: 00_ffmpeg_mp4_CHG_AUDIO_VOLUME.sh ## ## PURPOSE: Change the audio volume of a '.mp4' movie file. ## ## METHOD OF USE: ## 1) Put this script in the directory of '.mp4' movie files ## that you want to clip. ## 2) Edit this script to set the input & output filenames and volume level. ## 3) Run the script in a terminal window positioned at the directory ## that holds this script and the movie files. ## ## REFERENCE: ## https://trac.ffmpeg.org/wiki/AudioVolume ## ## Examples: ## ## If we want our volume to be half of the input volume: ## ## ffmpeg -i input.wav -filter:a "volume=0.5" output.wav ## ## 150% of current volume: ## ## ffmpeg -i input.wav -filter:a "volume=1.5" output.wav ## ## You can also use decibel measures. To increase the volume by 10dB: ## ## ffmpeg -i input.wav -filter:a "volume=10dB" output.wav ## ## To reduce the volume, use a negative value: ## ## ffmpeg -i input.wav -filter:a "volume=-5dB" output.wav ## ## Script started: 2021jul16 ## ffmpeg \ -i input_40sec_640x480_LOWLOWvol_h264-aac.mp4 \ -filter:a "volume=15.5" \ output_40sec_640x480_h264-aac.mp4 ## 00_temp.mp4 # totem 00_temp.mp4 # ffplay 00_temp.mp4 exit