Opened 5 years ago
Closed 2 months ago
#8683 closed defect (fixed)
publish srt stream with special streamid
Reported by: | xiaozhihong | Owned by: | |
---|---|---|---|
Priority: | normal | Component: | avformat |
Version: | unspecified | Keywords: | libsrt |
Cc: | Blocked By: | ||
Blocking: | Reproduced by developer: | no | |
Analyzed by developer: | no |
Description
My FFmpeg version and built message:
ffmpeg version 4.2.1 Copyright (c) 2000-2019 the FFmpeg developers
built with gcc 5.4.0 (Ubuntu 5.4.0-6ubuntu1~16.04.12) 20160609
configuration: --prefix=/root/git/xiaozhihong/shell/ff/FFmpeg/build --pkg-config-flags=--static --extra-cflags=-I/root/git/xiaozhihong/shell/ff/FFmpeg/build/include --extra-ldflags=-L/root/git/xiaozhihong/shell/ff/FFmpeg/build/lib --extra-libs='-lpthread -lm' --bindir=/root/git/xiaozhihong/shell/ff/FFmpeg/build/bin --enable-static --enable-libsrt --disable-libxcb --disable-libxcb --disable-libxcb-shm --disable-libxcb-xfixes --disable-libxcb-shape --disable-vdpau --disable-libass --enable-gpl --enable-libfdk-aac --enable-libopus --enable-libx264 --enable-nonfree
=================================================
My FFmpeg command line:
ffmpeg -re -stream_loop -1 -i input.flv -c copy -f flv "srt://localhost:9000?streamid=test_stream?key1=value1&key2=value2"
My problem:
I have a sepcial streamid like "test_stream?key1=value1&key2=value2", when I publish stream with SRT by using this special streamid, ffmpeg will truncate it to "test_stream?key1=value1", I lost "&key2=value2"
I see the source code in libavformat/libsrt.c, FFmpeg will try to find the special argement in srt url.
Can I use "srt://localhost:9000?streamid="test_stream?key1=value1&key2=value2"" instead of "srt://localhost:9000?streamid=test_stream?key1=value1&key2=value2" or any other solution?
Thanks.
Change History (3)
follow-up: 2 comment:1 by , 5 years ago
Keywords: | libsrt added; SRT removed |
---|---|
Version: | 4.2 → unspecified |
comment:2 by , 5 years ago
Replying to cehoyos:
If you want to report a bug, please test current FFmpeg git head and provide the command line together with the complete, uncut console output to make this a valid ticket.
I had test the curent FFmpeg git head version, it have the same problem.
My command line:
ffmpeg -re -stream_loop -1 -i input.flv -c copy -f mpegts "srt://localhost:9000?streamid=test_stream?key1=value1&key2=value2"
comment:3 by , 2 months ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
This is likely fixed in 86128bd07a8634fb4a19c1bab616bc16ce0567d3, after that commit you should be able to use any streamid by urlencoding it properly.
Reopen if it still does not work.
If you want to report a bug, please test current FFmpeg git head and provide the command line together with the complete, uncut console output to make this a valid ticket.