回放视频拉取参数/配置调整
This commit is contained in:
parent
5d0dd68f22
commit
73a84c2f93
@ -14,6 +14,10 @@ public class DeviceProxyConfig {
|
||||
* 通过其他 代理 agent 拉取历史视频 的地址
|
||||
*/
|
||||
private String url;
|
||||
/**
|
||||
* 是否使用下载的方式 拉取历史回放
|
||||
*/
|
||||
private Boolean useDownloadToPlayback = true;
|
||||
/**
|
||||
* 是否只通过代理拉取指定时间范围内的视频查询请求
|
||||
*/
|
||||
|
@ -356,6 +356,7 @@ public class DeviceProxyService {
|
||||
LocalDateTime fixedBeginTime = LocalDateTimeUtil.of(startTime.toInstant(), ZoneId.of(GB28181Constant.TIME_ZONE)).minus(zlmHookConfig.getFixed());
|
||||
map.put("begin_time",DateUtil.format(fixedBeginTime, DatePattern.PURE_DATETIME_PATTERN) );
|
||||
map.put("end_time", DateUtil.format(LocalDateTimeUtil.of(endTime.toInstant(), ZoneId.of(GB28181Constant.TIME_ZONE)), DatePattern.PURE_DATETIME_PATTERN));
|
||||
map.put("useDownload", String.valueOf(proxyConfig.getUseDownloadToPlayback()));
|
||||
String query = URLUtil.buildQuery(map, StandardCharsets.UTF_8);
|
||||
fromUrl = StringUtils.joinWith("?", fromUrl, query);
|
||||
log.info("设备: {} 视频 url: {}", deviceCode, fromUrl);
|
||||
|
@ -96,10 +96,15 @@ ffmpeg-support:
|
||||
# output: false
|
||||
rtp:
|
||||
#input: -thread_queue_size 128 -re -i http://192.168.3.12:5081/live/test.live.flv
|
||||
input: -re -i
|
||||
#input: -re -i
|
||||
input: -i
|
||||
#output: -tune zerolatency -vcodec libx264 -acodec aac -preset ultrafast -vf scale=640:-1 -f flv #rtp_mpegts
|
||||
#output: -vcodec libx264 -acodec aac -vf scale=640:-1 -f rtp_mpegts # -rtsp_transport tcp
|
||||
output: -c:v copy -c:a copy -flvflags no_duration_filesize -f flv
|
||||
# 拉取4倍速流文件 还原速率
|
||||
#output: -filter:v "setpts=4.0*PTS" -tune zerolatency -vcodec libx264 -acodec aac -preset ultrafast -vf scale=640:-1 -f flv
|
||||
# 下载 正常速率
|
||||
#output: -r 30 -tune zerolatency -vcodec libx264 -acodec aac -preset ultrafast -vf scale=640:-1 -f flv
|
||||
output: -r 30 -vcodec libx264 -acodec aac -filter:v "setpts=1*PTS" -preset ultrafast -vf scale=640:-1 -flvflags no_duration_filesize -f flv
|
||||
#download: -i E:\Repository\other\happytime-gb28181-device-x64\666.mp4 -filter:v "setpts=4.0*PTS"
|
||||
download: -i
|
||||
download-speed: 4.0
|
||||
|
Loading…
Reference in New Issue
Block a user