| | |
| | | |
| | | |
| | | <script> |
| | | var video_id; |
| | | var stream_path; |
| | | |
| | | var hourTimestamp = 3600 * 1000; |
| | | var dayTimestamp = hourTimestamp * 24; |
| | | var currentTimer; |
| | |
| | | } |
| | | } |
| | | |
| | | function play_video(video_url) { |
| | | window.rtsp = video_url; |
| | | window.streamPath = ""; |
| | | //播放 |
| | | function play_video(video_id) { |
| | | window.video_id = video_id; |
| | | window.stream_path = ""; |
| | | $.ajax({ |
| | | type: "get", |
| | | url: "../../webapi/media/historical?param=" + video_url+"&startTime="+currentTimer, |
| | | timeout: 5000, |
| | | async: false, |
| | | success: function (result) { |
| | | //$("#iframeSon").attr("src", "../../data/video/public/test.html?url=" + result.jessica); |
| | | var container = document.getElementById("playerContainer"); |
| | | jessibuca = new Jessibuca({ |
| | | container, decoder: "../../data/video/public/ff.js", videoBuffer: 1, |
| | | isResize: false |
| | | }); |
| | | |
| | | jessibuca.onLoad = function () { |
| | | h5lc.onLoad = function () { |
| | | this.play(result.jessica); |
| | | } |
| | | $("#close_video").attr("onclick", "close_videoDiv(\"" + result.streamPath + "\")"); |
| | | window.streamPath = result.streamPath; |
| | | } |
| | | }); |
| | | } |
| | | |
| | | //关闭 |
| | | function close_video(streamPath) { |
| | | jessibuca.destroy(); |
| | | h5lc.destroy(); |
| | | if (streamPath) { |
| | | $.ajax({ |
| | | type: "get", |