[FFmpeg-user] Unsupported codec pcm_s24be when RTP used

tech at rvoc.org tech at rvoc.org
Thu Nov 12 02:45:27 CET 2015


I need to send audio per the Livewire RTP specification: 48000Hz, 24-bit,
stereo, 200 packets/sec. 

The pcm_s24be codec works when saving to a file: 
[root at rdhost ~]# ffmpeg -vn -sn -f jack -ac 1 -i ffmpeg -ac 2 -acodec
pcm_s24be -ar 48000 -f s24be /root/test.pcm
ffmpeg version git-2015-11-06-daefd8a Copyright (c) 2000-2015 the FFmpeg
developers
  built with gcc 4.4.7 (GCC) 20120313 (Red Hat 4.4.7-16)
  configuration: --prefix=/root/ffmpeg_build
--extra-cflags=-I/root/ffmpeg_build/include
--extra-ldflags=-L/root/ffmpeg_build/lib --bindir=/root/bin
--pkg-config-flags=--static --enable-gpl --enable-nonfree
--enable-libfdk-aac --enable-libfreetype --enable-libmp3lame
  libavutil      55.  5.100 / 55.  5.100
  libavcodec     57. 15.100 / 57. 15.100
  libavformat    57. 14.100 / 57. 14.100
  libavdevice    57.  0.100 / 57.  0.100
  libavfilter     6. 14.101 /  6. 14.101
  libswscale      4.  0.100 /  4.  0.100
  libswresample   2.  0.100 /  2.  0.100
  libpostproc    54.  0.100 / 54.  0.100
[jack @ 0x2d684c0] JACK client registered and activated (rate=44100Hz,
buffer_size=1024 frames)
Guessed Channel Layout for  Input Stream #0.0 : mono
Input #0, jack, from 'ffmpeg':
  Duration: N/A, start: 1447285476.073389, bitrate: 1411 kb/s
    Stream #0:0: Audio: pcm_f32le, 44100 Hz, 1 channels, flt, 1411 kb/s
Output #0, s24be, to '/root/test.pcm':
  Metadata:
    encoder         : Lavf57.14.100
    Stream #0:0: Audio: pcm_s24be, 48000 Hz, stereo, s32, 2304 kb/s
    Metadata:
      encoder         : Lavc57.15.100 pcm_s24be
Stream mapping:
  Stream #0:0 -> #0:0 (pcm_f32le (native) -> pcm_s24be (native))
Press [q] to stop, [?] for help
size=   10142kB time=00:00:39.42 bitrate=2107.3kbits/s
video:0kB audio:10142kB subtitle:0kB other streams:0kB global headers:0kB
muxing overhead: 0.000000%
Exiting normally, received signal 2.

The pcm_s24be codec doesn't work when RTP muxer is used: 
[root at rdhost ~]# ffmpeg -vn -sn -f jack -ac 1 -i ffmpeg -ac 2 -acodec
pcm_s24be -ar 48000 -f rtp rtp://localhost:5004

ffmpeg version git-2015-11-06-daefd8a Copyright (c) 2000-2015 the FFmpeg
developers
  built with gcc 4.4.7 (GCC) 20120313 (Red Hat 4.4.7-16)
  configuration: --prefix=/root/ffmpeg_build
--extra-cflags=-I/root/ffmpeg_build/include
--extra-ldflags=-L/root/ffmpeg_build/lib --bindir=/root/bin
--pkg-config-flags=--static --enable-gpl --enable-nonfree
--enable-libfdk-aac --enable-libfreetype --enable-libmp3lame
  libavutil      55.  5.100 / 55.  5.100
  libavcodec     57. 15.100 / 57. 15.100
  libavformat    57. 14.100 / 57. 14.100
  libavdevice    57.  0.100 / 57.  0.100
  libavfilter     6. 14.101 /  6. 14.101
  libswscale      4.  0.100 /  4.  0.100
  libswresample   2.  0.100 /  2.  0.100
  libpostproc    54.  0.100 / 54.  0.100
[jack @ 0x3ccb4c0] JACK client registered and activated (rate=44100Hz,
buffer_size=1024 frames)
Guessed Channel Layout for  Input Stream #0.0 : mono
Input #0, jack, from 'ffmpeg':
  Duration: N/A, start: 1447292098.566968, bitrate: 1411 kb/s
    Stream #0:0: Audio: pcm_f32le, 44100 Hz, 1 channels, flt, 1411 kb/s
[rtp @ 0x3cee2c0] Unsupported codec pcm_s24be
Output #0, rtp, to 'rtp://localhost:5004':
  Metadata:
    encoder         : Lavf57.14.100
    Stream #0:0: Audio: pcm_s24be, 48000 Hz, stereo, s32, 2304 kb/s
    Metadata:
      encoder         : Lavc57.15.100 pcm_s24be
Stream mapping:
  Stream #0:0 -> #0:0 (pcm_f32le (native) -> pcm_s24be (native))
Could not write header for output file #0 (incorrect codec parameters ?):
Operation not permitted

Why am I getting the error message "Unsupported codec pcm_s24be" only when
using RTP? 



More information about the ffmpeg-user mailing list