's'
This commit is contained in:
9
main.py
9
main.py
@@ -1673,7 +1673,7 @@ def start_record(url_data: tuple, count_variable: int = -1) -> None:
|
||||
# ========== 参数配置(保留你原始配置) ==========
|
||||
# YT_STREAM_KEY = "qxvb-r47b-r5ju-6ud3-6k7z"
|
||||
# youtube_rtmp = f"rtmp://a.rtmp.youtube.com/live2/x04z-564w-aks7-embw-30y4"
|
||||
youtube_rtmp="rtmp://127.0.0.1/live/douyin"
|
||||
srs_rtmp="rtmp://127.0.0.1/live/douyin"
|
||||
|
||||
# # ←←←← 在这块代码的上方先定义你要推的多个地址 ←←←←
|
||||
# rtmp_targets = [
|
||||
@@ -1760,6 +1760,9 @@ def start_record(url_data: tuple, count_variable: int = -1) -> None:
|
||||
ffmpeg_command = [
|
||||
"ffmpeg",
|
||||
"-loglevel", "info",
|
||||
|
||||
# ===== 所有「输入选项」必须放在 -i 之前!=====
|
||||
# "-re", # 必须在这!按真实帧率读
|
||||
"-err_detect", "ignore_err+explode",
|
||||
"-fflags", "+genpts+discardcorrupt+igndts",
|
||||
"-reconnect", "1",
|
||||
@@ -1771,8 +1774,12 @@ def start_record(url_data: tuple, count_variable: int = -1) -> None:
|
||||
|
||||
# ===== 输入源 =====
|
||||
"-i", real_url,
|
||||
|
||||
# ===== 输出选项(放在 -i 之后)=====
|
||||
"-c:v", "copy",
|
||||
"-c:a", "copy",
|
||||
# "-copyts",
|
||||
# "-avoid_negative_ts", "disabled",
|
||||
"-max_muxing_queue_size", "9999",
|
||||
"-f", "flv", srs_rtmp
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user