我在webbvcu_demo.html 的打开视频处同时打开了三路视频 浏览器就崩溃了 代码如下:
<input type="button" value="打开视频" />
<script type="text/javascript">
function openvide() {
for (var i = 0; i < 6; i++) {
if (i == 0) { bv_open_video("PU_4C1F",1); }
if (i == 1) { bv_open_video("PU_21025151",0); }
if (i == 2) { bv_open_video("PU_21121131",2); }
}
}
</script>
//以下JS方法基本没动, 只是传入了我需要打开的设备
var play_panel_index = 0;
function bv_open_video(puid, channel) {
/**创建播放div*/
var div = document.createElement("div");
div.id = div.name = "div_play_panel" + play_panel_index;
document.body.appendChild(div); /**添加到body中*/
/**创建播放object*/
var obj = document.createElement('object');
obj.id = ("WebPlayPanelWnd" + play_panel_index); /**播放窗口,注意*/
obj.classid = "clsid:CDE6C639-4BA8-4A09-81EB-DCE76A61FE98";
obj.width = '400px';
obj.height = '300px';
div.appendChild(obj);/**添加到div中*/