Browse Source
Merge pull request #3 from lawrencehj/master
修改jar包编译版本,修正播放获取流编码信息的代码
pull/1/head
648540858
4 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with
9 additions and
4 deletions
-
README.md
-
BIN
libs/jain-sip-ri-1.3.0-91.jar
-
src/main/java/com/genersoft/iot/vmp/vmanager/play/PlayController.java
|
|
@ -1,6 +1,6 @@ |
|
|
|
# wvp |
|
|
|
WEB VIDEO PLATFORM是一个基于GB28181-2016标准实现的网络视频平台,负责实现核心信令与设备管理后台部分,支持NAT穿透,支持海康、大华、宇视等品牌的IPC、NVR、DVR接入。 |
|
|
|
流媒体服务基于ZLMediaKit-https://github.com/xiongziliang/ZLMediaKit |
|
|
|
流媒体服务基于ZLMediaKit-https://github.com/xiongziliang/ZLMediaKit |
|
|
|
前段页面基于MediaServerUI进行修改. |
|
|
|
|
|
|
|
# 应用场景: |
|
|
@ -34,12 +34,13 @@ WEB VIDEO PLATFORM是一个基于GB28181-2016标准实现的网络视频平台 |
|
|
|
7. 支持通道子目录查询; |
|
|
|
8. 支持udp/tcp国标流传输模式; |
|
|
|
9. 支持直接输出RTSP、RTMP、HTTP-FLV、Websocket-FLV、HLS多种协议流地址 |
|
|
|
10. |
|
|
|
10. 支持国标网络校时 |
|
|
|
|
|
|
|
# 待实现: |
|
|
|
上级级联 |
|
|
|
推流列表 |
|
|
|
拉流列表 |
|
|
|
web界面系统设置 |
|
|
|
web界面系统设置 |
|
|
|
使用mysql作为数据库 |
|
|
|
|
|
|
|
# 项目部署 |
|
|
|
|
|
@ -66,19 +66,23 @@ public class PlayController { |
|
|
|
try { |
|
|
|
if (System.currentTimeMillis() - startTime > 30 * 1000) { |
|
|
|
storager.stopPlay(streamInfo); |
|
|
|
logger.info("播放等待超时"); |
|
|
|
return new ResponseEntity<String>("timeout",HttpStatus.OK); |
|
|
|
}else { |
|
|
|
streamInfo = storager.queryPlayByDevice(deviceId, channelId); |
|
|
|
JSONObject rtpInfo = zlmresTfulUtils.getRtpInfo(streamId); |
|
|
|
if (rtpInfo != null && rtpInfo.getBoolean("exist") && streamInfo != null && streamInfo.getFlv() != null){ |
|
|
|
logger.info("RTP已推流,查询编码信息:"+streamInfo.getFlv()); |
|
|
|
Thread.sleep(2000); |
|
|
|
JSONObject mediaInfo = zlmresTfulUtils.getMediaInfo("rtp", "rtmp", streamId); |
|
|
|
if (mediaInfo.getInteger("code") == 0 && mediaInfo.getBoolean("online")) { |
|
|
|
lockFlag = false; |
|
|
|
logger.info("媒体编码信息已获取"); |
|
|
|
JSONArray tracks = mediaInfo.getJSONArray("tracks"); |
|
|
|
streamInfo.setTracks(tracks); |
|
|
|
storager.startPlay(streamInfo); |
|
|
|
}else { |
|
|
|
|
|
|
|
logger.info("媒体编码信息未获取,2秒后重试..."); |
|
|
|
} |
|
|
|
}else { |
|
|
|
Thread.sleep(2000); |
|
|
|