648540858
2022-12-19 fc90cd7951600ce5173f71c3e28d78e69b4db4ae
src/main/java/com/genersoft/iot/vmp/media/zlm/ZLMHttpHookListener.java
@@ -319,7 +319,7 @@
      });
      if ("rtsp".equals(param.getSchema())){
         logger.info("on_stream_changed:注册->{}, app->{}, stream->{}", param.isRegist(), param.getApp(), param.getStream());
         logger.info("流变化:注册->{}, app->{}, stream->{}", param.isRegist(), param.getApp(), param.getStream());
         if (param.isRegist()) {
            mediaServerService.addCount(param.getMediaServerId());
         }else {
@@ -399,7 +399,11 @@
                           }
                        }
                     }else {
                        logger.info("[语音对讲] 未找到通道:{}", channelId);
                     }
                  }else{
                     logger.info("[语音对讲] 未找到设备:{}", deviceId);
                  }
               }
            }
@@ -525,17 +529,22 @@
                        if (platform != null) {
                           commanderFroPlatform.streamByeCmd(platform, sendRtpItem);
                        }else {
                           if ("talk".equals(param.getApp()) && sendRtpItem.isOnlyAudio()) {
                           if (sendRtpItem.isOnlyAudio()) {
                              AudioBroadcastCatch audioBroadcastCatch = audioBroadcastManager.get(sendRtpItem.getDeviceId(), sendRtpItem.getChannelId());
                              if (device != null && audioBroadcastCatch != null) {
//                                 cmder.streamByeCmd(device, sendRtpItem.getChannelId(), audioBroadcastCatch.getSipTransactionInfo(), null);
                              if (audioBroadcastCatch != null) {
//                                 playService.stopAudioBroadcast(device.getDeviceId(), sendRtpItem.getChannelId());
                                 if ("talk".equals(param.getApp())) {
//                                    cmder.streamByeCmd(device, sendRtpItem.getChannelId(), audioBroadcastCatch.getSipTransactionInfo(), null);
                                 }else {
//                                    cmder.streamByeCmd(device, sendRtpItem.getChannelId(), audioBroadcastCatch.getSipTransactionInfo(), null);
                                 }
                              }
                           }else {
                              cmder.streamByeCmd(device, null, null, sendRtpItem.getCallId());
                           }
                        }
                     } catch (SipException | InvalidArgumentException | ParseException | SsrcTransactionNotFoundException e) {
                     } catch (SipException | InvalidArgumentException | ParseException e) {
                        logger.error("[命令发送失败] 国标级联 发送BYE: {}", e.getMessage());
                     }
                  }