<!DOCTYPE html> <html> <head> <meta charset='UTF-8'/> <meta name='viewport' content='initial-scale=1,maximum-scale=1,user-scalable=no'/> <link href='http://bigemap.com:9000/bigemap-gl.js/v1.1.0/Widgets/widgets.css' rel='stylesheet'/> <script src='http://bigemap.com:9000/bigemap-gl.js/v1.1.0/bigemap-gl.js'></script> <style> body { margin: 0; padding: 0; } #container { position: absolute; top: 0; bottom: 0; width: 100%; } .bmgl-widget-credits{display:none} </style> <title>part_test</title> </head> <body> <div id='container'></div> <video id="video" muted="" style="display: none;" autoplay="" loop="" crossorigin="" controls=""> <source src="/bmgl/video/intro.mp4" type="video/mp4"> </video> <script> bmgl.Config.HTTP_URL = 'http://bigemap.com:9000'; var viewer = new bmgl.Viewer('container', { mapId: 'bigemap.zhongkexingtu', requestRenderMode:false, }); var videoElement = document.getElementById('video'); videoElement.play(); var rect = viewer.entities.add({ wall:{ positions:bmgl.Cartesian3.fromDegreesArrayHeights([104.06515958335,30.657422854392873,50,104.06637958335,30.657422854392873,50]), material: videoElement, }, }); viewer.flyTo(rect); </script> </body> </html>
源码