1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 10:47:35 +00:00

Utilities/aplay: Print format name under "Format"

This is not only nice to see, but it additionally tells developers that
the correct loader plugin was selected.
This commit is contained in:
kleines Filmröllchen 2022-01-14 12:44:41 +01:00 committed by Andreas Kling
parent 54ac4ba8cc
commit 8467327807

View file

@ -37,7 +37,8 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
auto loader = maybe_loader.release_value();
outln("\033[34;1m Playing\033[0m: {}", path);
outln("\033[34;1m Format\033[0m: {} Hz, {}-bit, {}",
outln("\033[34;1m Format\033[0m: {} {} Hz, {}-bit, {}",
loader->format_name(),
loader->sample_rate(),
loader->bits_per_sample(),
loader->num_channels() == 1 ? "Mono" : "Stereo");