Measure loudness (EBU R128)
measure_loudness_of_fileMeasures EBU R128/ITU-R BS.1770 loudness (LUFS, range, true peak) in a file to check mixes and exports against streaming, podcast, or broadcast targets.
Instructions
Measure the programme loudness of a file's audio the EBU R128 / ITU-R BS.1770 way: integrated loudness in LUFS, loudness range in LU and true peak in dBTP. Use it to check a mix or an export against a delivery target (-14 LUFS for streaming music, -16 for podcasts, -23 for EBU broadcast, -24 for ATSC). With target_lufs it also returns gain_to_target_db and the true peak after that gain (apply the gain with adjust_clip_volume, or use normalize_audio_file to write a corrected file). silent=true when the audio is too quiet to measure. For plain peak and average level use measure_volume_of_file. Works on the file on disk with ffmpeg, not on the timeline; Premiere Pro is not needed. ffmpeg and ffprobe must be installed (see check_ffmpeg), else FFMPEG_NOT_FOUND.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"path": "<path>"
},
"name": "measure_loudness_of_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| end | No | Analyse up to this file time, in seconds; clamped to the file's length. Must be greater than start. Default: the end of the file. | |
| path | Yes | Absolute path of the media file on this computer. | |
| start | No | Analyse from this file time (seconds from the start of the file). Default 0. | |
| target_lufs | No | Loudness target in LUFS, -70 to 0. When given, the result includes gain_to_target_db. Omit for the measurement only. | |
| audio_stream | No | Which audio stream to use, 0-based among the file's audio streams (see probe_media_file). Default 0. | |
| timeout_seconds | No | Stop ffmpeg and fail with TIMEOUT after this many seconds. Default 600. |