3

For one of my script I need to read out the bit depth of a wav file.

ffprobe -v error -show_entries format=bits_per_sample -of default=noprint_wrappers=1 test.wav

there is no output at all - I use this in the same way for the duration (format=duration) and it works fine.

Matt
  • 1,803
  • 3
  • 16
  • 17

1 Answers1

3

Found the solution - the stream needs to be defined:

ffprobe -v error -select_streams a:0 -show_entries stream=bits_per_raw_sample -of default=noprint_wrappers=1:nokey=1
Matt
  • 1,803
  • 3
  • 16
  • 17
  • `ffprobe -v error -select_streams a:0 -show_entries stream=bits_per_sample -of default=noprint_wrappers=1:nokey=1` seems more consistent – SgtPooki Feb 15 '21 at 04:46
  • `ffprobe -v error -select_streams a:0 -show_entries stream` will display all of the possible streams – SgtPooki Feb 15 '21 at 05:15