47 lines
939 B
HTML
47 lines
939 B
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<title>Title</title>
|
|
<script src="../sdk/YJEarth.min.js"></script>
|
|
<script src="vue.js"></script>
|
|
<style>
|
|
body {
|
|
width: 100%;
|
|
height: 100%;
|
|
}
|
|
</style>
|
|
</head>
|
|
|
|
<body>
|
|
<div id="app" class="fullSize">
|
|
|
|
</div>
|
|
</body>
|
|
|
|
</html>
|
|
|
|
<script>
|
|
new Vue({
|
|
el: "#app",
|
|
data: {
|
|
sdk: null,
|
|
},
|
|
async mounted() {
|
|
await YJ.on()
|
|
this.createEarth()
|
|
},
|
|
methods: {
|
|
createEarth() {
|
|
this.sdk = new YJ.YJEarth("app")
|
|
let Draw = new YJ.Draw.DrawPolyline(this.sdk)
|
|
Draw.start((a,positions)=>{
|
|
let WallStereoscopic = new YJ.Obj.WallStereoscopic(this.sdk, { color: "#00d9ff", width: 10000, height: 100000, extrudedHeight: 0, cornerType: "ROUNDED", positions: positions })
|
|
WallStereoscopic.edit(true)
|
|
WallStereoscopic.flyTo()
|
|
})
|
|
}
|
|
}
|
|
})
|
|
</script> |