style: lint style

This commit is contained in:
shihui 2021-10-25 20:29:14 +08:00
parent d0c8f6ae59
commit 6bbc9dc5b2
3 changed files with 13 additions and 13 deletions

View File

@ -42,7 +42,7 @@ scene.on('loaded', () => {
// 根据 GeoJSON 数据放置模型
layer.getSource().data.dataArray.forEach(({ coordinates }) => {
const gltfScene = gltf.scene;
setDouble(gltfScene)
setDouble(gltfScene);
layer.adjustMeshToMap(gltfScene);
// gltfScene.scale.set(1000, 1000, 1000)
layer.setMeshScale(gltfScene, 1000, 1000, 1000);
@ -103,7 +103,7 @@ scene.on('loaded', () => {
function setDouble(object) {
if (object.children && object.children.length && object.children.length > 0) {
object.children.map(child => setDouble(child))
object.children.map(child => setDouble(child));
} else if (object.material) {
object.material.side = THREE.DoubleSide;
}

View File

@ -162,7 +162,7 @@ scene.on('loaded', () => {
gltf => {
// 根据 GeoJSON 数据放置模型
const gltfScene = gltf.scene.clone();
setDouble(gltfScene)
setDouble(gltfScene);
layer.getSource().data.dataArray.forEach(() => {
layer.adjustMeshToMap(gltfScene);
gltfScene.scale.set(500000, 500000, 500000);
@ -219,7 +219,7 @@ scene.on('loaded', () => {
function setDouble(object) {
if (object.children && object.children.length && object.children.length > 0) {
object.children.map(child => setDouble(child))
object.children.map(child => setDouble(child));
} else if (object.material) {
object.material.side = THREE.DoubleSide;
}

View File

@ -157,7 +157,7 @@ scene.on('loaded', () => {
'https://gw.alipayobjects.com/os/bmw-prod/3ca0a546-92d8-4ba0-a89c-017c218d5bea.gltf',
gltf => {
const antModel = gltf.scene;
setDouble(antModel)
setDouble(antModel);
// antModel.children[0].material.side = THREE.DoubleSide
layer.adjustMeshToMap(antModel);
layer.setMeshScale(antModel, 20, 20, 20);
@ -429,7 +429,7 @@ scene.on('loaded', () => {
function setDouble(object) {
if (object.children && object.children.length && object.children.length > 0) {
object.children.map(child => setDouble(child))
object.children.map(child => setDouble(child));
} else if (object.material) {
object.material.side = THREE.DoubleSide;
}