Skip to content

Ahistogram

Audio Video Single output Transform

Convert input audio to histogram video output.

FFmpeg filter: ahistogram — the official reference.

Add it to a graph. The explicit form works for every filter — bind it to its input and read the result from outputs():

$node = $video->addFilter(new Ahistogram());
$result = $node->outputs()[0];

Shorthand. Single-output filters can skip the node — apply() returns the result stream directly:

$result = $video->apply(new Ahistogram());

TODO — when this filter shines: what it’s the right tool for, what to reach for instead when it isn’t, and how it composes with neighbouring filters.

TODO — prose: how the filter actually works and what its key parameters mean (the explanation FFmpeg’s terse option help omits).

TODO — runnable PHP, with the equivalent ffmpeg CLI alongside.

TODO

TODO

ParameterTypeDefaultRange / valuesDescription
dmodeAhistogramDmodesinglesingle, separateset method to display channels
ratestring25set video rate
sizestringhd720set video size
scaleAhistogramScaleloglog, sqrt, cbrt, lin, rlogset display scale
ascaleAhistogramAscaleloglog, linset amplitude scale
acountint1-1100how much frames to accumulate
rheightfloat0.101set histogram ratio of window height
slideAhistogramSlidereplacereplace, scrollset sonogram sliding
hmodeAhistogramHmodeabsabs, signset histograms mode

FFmpeg also names these options (use the parameter shown above): rrate, ssize.


Maps to FFmpeg’s ahistogram filter. Verified against ffmpeg n7.1.1.

An Artisan Build project.

Built on FFmpeg — an independent binding, not affiliated with or endorsed by the FFmpeg project. Support FFmpeg.