This commit is contained in:
shikong 2023-08-23 17:22:29 +08:00
parent 3dc59f2dfb
commit e8db3fb313
3 changed files with 9 additions and 0 deletions

View File

@ -3,6 +3,7 @@ package cn.skcks.docking.gb28181.service.play;
import cn.skcks.docking.gb28181.common.json.JsonResponse;
import cn.skcks.docking.gb28181.common.redis.RedisUtil;
import cn.skcks.docking.gb28181.core.sip.gb28181.cache.CacheUtil;
import cn.skcks.docking.gb28181.media.config.ZlmMediaConfig;
import cn.skcks.docking.gb28181.media.dto.rtp.GetRtpInfoResp;
import cn.skcks.docking.gb28181.media.dto.rtp.OpenRtpServer;
import cn.skcks.docking.gb28181.media.dto.rtp.OpenRtpServerResp;
@ -25,6 +26,7 @@ import java.util.concurrent.TimeUnit;
@RequiredArgsConstructor
public class PlayService {
private static final String PREFIX = "RealTimePlay";
private final ZlmMediaConfig mediaConfig;
private final DockingDeviceService deviceService;
private final ZlmMediaService zlmMediaService;
private final SsrcService ssrcService;
@ -68,6 +70,11 @@ public class PlayService {
return result;
}
String ip = mediaConfig.getIp();
StringBuilder sb = new StringBuilder();
sb.append("v=0\r\n");
sb.append("o=").append(channelId).append(" 0 0 IN IP4 ").append(ip).append("\r\n");
return result;
// zlmMediaService.getRtpInfo();
// GetMediaList getMediaList = new GetMediaList();

View File

@ -9,6 +9,7 @@ import org.springframework.context.annotation.Configuration;
@ConfigurationProperties(prefix = "media")
public class ZlmMediaConfig {
private String url;
private String ip;
private String id;
private String secret;
}

View File

@ -2,6 +2,7 @@ project:
version: @project.version@
media:
ip: 10.10.10.200
url: 'http://10.10.10.200:5080'
# url: 'http://10.10.10.200:12580/anything/'
id: amrWMKmbKqoBjRQ9