rain
2024-07-02 82a90f791678dddbc6e1b98ee9e8028b61a38dfe
src/main/java/com/dji/sample/manage/service/impl/LiveStreamServiceImpl.java
@@ -125,15 +125,15 @@
        //相机已经在直播中,请勿重复开启直播
        if(receiveReply.getResult() == 513003) {
            LiveDTO live = new LiveDTO();
//            live.setUrl(liveParam.getUrl().replace("rtmp", "https").replace("735","700") + ".flv");
            LiveUrlGB28181DTO gb28181 = urlToGB28181(liveParam.getUrl());
            live.setUrl(new StringBuilder()
                    .append("https://wrj.shuixiongit.com/zb/rtp/")
                    .append(gb28181.getAgentID())
                    .append("_")
                    .append(gb28181.getChannel())
                    .append(".live.flv")
                    .toString());
            live.setUrl(liveParam.getUrl().replace("rtmp", "https").replace("735","700") + ".flv");
//            LiveUrlGB28181DTO gb28181 = urlToGB28181(liveParam.getUrl());
//            live.setUrl(new StringBuilder()
//                    .append("https://wrj.shuixiongit.com/zb/rtp/")
//                    .append(gb28181.getAgentID())
//                    .append("_")
//                    .append(gb28181.getChannel())
//                    .append(".live.flv")
//                    .toString());
            return ResponseResult.success(live);
        }
@@ -150,27 +150,27 @@
//                live.setUrl(liveParam.getUrl().replace("rtmp", "webrtc"));
                live.setUrl(liveParam.getUrl().replace("rtmp", "https").replace("735","700") + ".flv");
                break;
//            case GB28181:
//                LiveUrlGB28181DTO gb28181 = urlToGB28181(liveParam.getUrl());
//                live.setUrl(new StringBuilder()
//                        .append("webrtc://")
//                        .append(gb28181.getServerIP())
//                        .append("/live/")
//                        .append(gb28181.getAgentID())
//                        .append("@")
//                        .append(gb28181.getChannel())
//                        .toString());
//                break;
            case GB28181:
                LiveUrlGB28181DTO gb28181 = urlToGB28181(liveParam.getUrl());
                live.setUrl(new StringBuilder()
                        .append("https://wrj.shuixiongit.com/zb/rtp/")
                        .append("webrtc://")
                        .append(gb28181.getServerIP())
                        .append("/live/")
                        .append(gb28181.getAgentID())
                        .append("_")
                        .append("@")
                        .append(gb28181.getChannel())
                        .append(".live.flv")
                        .toString());
                break;
//            case GB28181:
//                LiveUrlGB28181DTO gb28181 = urlToGB28181(liveParam.getUrl());
//                live.setUrl(new StringBuilder()
//                        .append("https://wrj.shuixiongit.com/zb/rtp/")
//                        .append(gb28181.getAgentID())
//                        .append("_")
//                        .append(gb28181.getChannel())
//                        .append(".live.flv")
//                        .toString());
//                break;
            case RTSP:
                String url = receiveReply.getOutput().toString();
                this.resolveUrlUser(url, live);