当前位置:网站首页>cesium listens to map zoom or zoom to control whether the content added on the map is displayed
cesium listens to map zoom or zoom to control whether the content added on the map is displayed
2022-08-10 05:48:00 【Why can't I get enough to eat?】
Controlling the display and hiding of entities according to the height of the viewing angle, the specific effects are as follows:
The main code is as follows:
// Monitor map zoom or zoom to control whether the content added on the map is displayedcontrolVisible() {viewer.camera.changed.addEventListener(function() {//View change monitoringvar currentMagnitude = viewer.camera.getMagnitude();if (currentMagnitude > 13000000) {for (let i = 0; i < viewer.entities.values.length; i++) {viewer.entities.values[i].show = false;}} else {for (let i = 0; i < viewer.entities.values.length; i++) {viewer.entities.values[i].show = true;}}});},
边栏推荐
猜你喜欢
pytorch框架学习(3)torch.nn.functional模块和nn.Module模块
操作表 函数的使用
The latest and most complete digital collection sales calendar-07.27
tinymce富文本编辑器
Chained Picks: Starbucks looks at digital collectibles and better engages customers
图纸怎么折?(A0,A1,A2,A3の图纸如何折成A4大小)
速刷正则表达式一周目(上)
链读推荐:从瓷砖到生成式 NFT
基于Qiskit——《量子计算编程实战》读书笔记(二)
非会员更改有道云笔记背景
随机推荐
Chain Reading|The latest and most complete digital collection sales calendar-07.29
【el和template区别】
第二次实验
Notes 1
Pony语言学习(八):引用能力(Reference Capabilities)
链读精选:星巴克着眼于数字收藏品并更好地吸引客户
链读好文:Jeff Garzik 推出 Web3 制作公司
IDEA 项目中设置 Sources Resources 等文件夹
网络安全6
基本比例尺标准分幅编号流程
ZigBee 网络设备相关内容
链读|最新最全的数字藏品发售日历-08.02
pytorch框架学习(9)torchvision.transform
各个架构指令集对应的机型
自适应空间特征融合( adaptively spatial feature fusion)一种基于数据驱动的金字塔特征融合策略
最新最全的数字藏品发售日历-07.27
关于cfar检测的学习及仿真
转载fstream,ifstream的详细用法
先人一步,不再错过,链读APP即将上线!
网络安全之防火墙