[FFmpeg-user] udp multicast video stream frame loss
Andrey Utkin
andrey.krieger.utkin at gmail.com
Tue Nov 13 09:27:25 CET 2012
2012/11/11 Jacobs <jacobhameiri at gmail.com>:
> I need to stream video files over a wifi lan from an android tablet to other
> tablets using ffmpeg.
> when I stream directly to one device with udp unicast the stream is fine.
> but if I stream over multicast I get a lot of frame loss in the output
> video. the player is android mxplayer ( android player based on ffmpeg )
>
> any idea how I can reduce the frame loss. this is the best command I have so
> far:
> ffmpeg -i /sdcard/m -vcodec mpeg4 -ab 32k -ar 22050 -tune film -b 600k -r 13
> -async 1 -f mpegts udp://224.1.1.1:1234
>
> ffmpeg version N-46525-gbc17a6f Copyright (c) 2000-2012 the FFmpeg
> developers
> built on Nov 8 2012 12:27:23 with gcc 4.6.x-google (GCC) 20120106
> (prerelease)
> configuration: --arch=arm --cpu=cortex-a8 --target-os=linux
> --enable-runtime-cpudetect --prefix=/data/ --enable-pic --disable-shared
> --enable-static
> --cross-prefix=/home/oz/android-ndk-r8b//toolchains/arm-linux-androideabi-4.6/prebuilt/linux-x86/bin/arm-linux-androideabi-
> --sysroot=/home/oz/android-ndk-r8b//platforms/android-8/arch-arm
> --extra-cflags='-I../x264 -mfloat-abi=softfp -mfpu=neon -mfpu=vfpv3-d16'
> --extra-ldflags=-L../x264 --enable-version3 --enable-gpl --disable-doc
> --enable-decoders --enable-encoders --enable-muxers --enable-demuxers
> --enable-parsers --enable-protocols --enable-avresample --enable-libfreetype
> --enable-indevs --disable-indev=lavfi --enable-indev=fbdev --enable-outdevs
> --enable-hwaccels --enable-ffmpeg --enable-ffplay --disable-ffprobe
> --disable-ffserver --enable-network --enable-pthreads --enable-libx264
> --enable-zlib --enable-postproc --disable-libxvid --enable-avcodec
> --enable-avformat --enable-swresample --enable-swscale --enable-postproc
> --enable-avfilter --enable-avresample libavutil 52. 5.100 / 52.
> 5.100
> libavcodec 54. 71.100 / 54. 71.100
> libavformat 54. 36.100 / 54. 36.100
> libavdevice 54. 3.100 / 54. 3.100
> libavfilter 3. 21.106 / 3. 21.106
> libswscale 2. 1.102 / 2. 1.102
> libswresample 0. 16.100 / 0. 16.100
> libpostproc 52. 1.100 / 52. 1.100
> Input #0, avi, from '/sdcard/m':
> Metadata:
> encoder : transcode-1.0.6
> Duration: 00:21:22.87, start: 0.000000, bitrate: 1144 kb/s
> Stream #0:0: Video: mpeg4 (Advanced Simple Profile) (XVID / 0x44495658),
> yuv420p, 624x352 [SAR 1:1 DAR 39:22], 23.98 tbr, 23.98 tbn, 23.98 tbc
> Stream #0:1: Audio: mp3 (U[0][0][0] / 0x0055), 48000 Hz, stereo, s16,
> 128 kb/s
> Please use -b:a or -b:v, -b is ambiguous
> -async is forwarded to lavfi similarly to -af
> aresample=min_comp=0.001:min_hard_comp=0.100000.
> Output #0, mpegts, to 'udp://225.1.1.1:3333':
> Metadata:
> encoder : Lavf54.36.100
> Stream #0:0: Video: mpeg4, yuv420p, 624x352 [SAR 1:1 DAR 39:22], q=2-31,
> 600 kb/s, 90k tbn, 13 tbc
> Stream #0:1: Audio: mp2, 22050 Hz, stereo, s16, 32 kb/s
> Stream mapping:
> Stream #0:0 -> #0:0 (mpeg4 -> mpeg4)
> Stream #0:1 -> #0:1 (mp3 -> mp2)
> Press [q] to stop, [?] for help
> frame= 28 fps=0.0 q=2.1 size= 263kB time=00:00:02.15 bitrate=
> 999.2kbits/s dup=1 drop=19
"drop" here has nothing to do with UDP data loss. That count is of
omitted video frames due to transcoding logics AFAIK.
--
Andrey Utkin
More information about the ffmpeg-user
mailing list