[FFmpeg-user] Lipsync of a UDP stream
Moritz Barsnick
barsnick at gmx.net
Thu Mar 16 18:47:21 EET 2023
On Wed, Mar 01, 2023 at 17:35:29 +0100, Jan Ceuleers wrote:
> For the benefit of search engines: my incantation has become:
>
> /usr/bin/ffmpeg -hide_banner -nostats -loglevel panic \
> -i udp://192.168.1.60:17001 \
> -filter_complex "asetpts=PTS-0.3/TB" \
> -vcodec copy -codec:a aac -b:a 256k -f mpegts pipe:1
Thanks for documenting your success.
> It is audio that needed to be shifted, because one cannot combine a
> filter and the copy codec.
For the record, there does exist a "setts" bitstream filter, which
operates on the encoded bitstreams, and therefore allows both audio and
video to be "copied".
-bsf:a setts=pts=...
(or -bsf:v if you prefer).
I haven't actually tested this though. ;-)
Moritz
More information about the ffmpeg-user
mailing list