当前位置:网站首页>Cesium add light sweep
Cesium add light sweep
2022-07-28 01:21:00 【Yue Yan Shao Falcon】
var viewer=ysc.createNormalCesium("cesiumContainer",{
globalImagery:" Sky map "// Sky map image
});
var data={
circle:[0.003,117,35,30]// The first parameter 0.003 It's radius , The second and third respectively represent the coordinates of the base center , The fourth represents how many points are cut . How many faces are formed . The more you get, the more you get stuck Try not to affect the effect of the actual project , The less, the better. .
,observer:[117.01,35.01,500]// Observation points , That is, the light source
,positionList:[ // We won't increase the height here . Otherwise it would be too much trouble // Take the center of the circle as the reference to obtain the offset value , The coordinates of the center of the circle [117,35], Simply dot and draw a square If you draw a round picture , You can also get more
[117,35],// initial position
[117.01,35], // The next point
[117.01,35.01],
[117,35.01],
[117,35],// Come back
]
,material:Cesium.Color.RED.withAlpha(0.5)// The material of light
,number:100// The smaller the number, the faster
};
var entityCList= ysc.createLightScan(viewer,data); // Returns an array of all faces If you need to clear the painting , Clear through this
// eliminate
// for(var i=0;i< entityCList.length;i++){
// viewer.entities.remove(entityCList[i]);
// }
//**** Here are the extra Yes, but not ***//
// Cube column Indicates the platform
viewer.entities.add({
position : Cesium.Cartesian3.fromDegrees(data.observer[0],data.observer[1],data.observer[2]/2),
name:"",
box : {
dimensions : new Cesium.Cartesian3(100.0, 100.0,data.observer[2]),
outline : true,
outlineColor : Cesium.Color.WHITE,
outlineWidth : 2,
material : Cesium.Color.fromRandom({alpha : 0.5})
}
});
// A blue ray
var glowingLine = viewer.entities.add({
name : 'Glowing blue line on the surface',
polyline : {
positions : Cesium.Cartesian3.fromDegreesArray(
[
data.positionList[0][0],data.positionList[0][1],
data.positionList[1][0],data.positionList[1][1],
data.positionList[2][0],data.positionList[2][1],
data.positionList[3][0],data.positionList[3][1],
data.positionList[4][0],data.positionList[4][1],
]),
width : 10,
material : new Cesium.PolylineGlowMaterialProperty({ // Luminous line
glowPower : 0.2,
color : Cesium.Color.BLUE
})
}
});
viewer.zoomTo(viewer.entities)边栏推荐
- BYD semiconductor completed the a+ round financing of 800million yuan: 30 well-known investment institutions entered the market, with a valuation of 10.2 billion yuan!
- 深圳华强宣布拟不超2000万元入股比亚迪半导体
- 华米科技“黄山2号”发布:AI性能提升7倍,功耗降低50%!
- node-red与TDengine交互
- Matlab 绘制 - 点和向量:向量加减的方法和源码
- 容器网络硬核技术内幕 (7) 大海航行靠舵手
- Flutter--密码登录注册界面
- Redis sentinel mode
- [game] Nintendo Nintendo switch ultra detailed purchase / use guide and precautions (continuous update according to your own use...)
- How the test architects of bat factories interpret various disputes of the test platform
猜你喜欢
随机推荐
Basic learning of cesium
Swoole collaboration
Xinyi information technology, a domestic NB IOT chip manufacturer, received 200million yuan of a+ round financing
110. In depth introduction to sap ui5 fileuploader control - why do you need a hidden iframe
Demo: the test interface receives duplicate data and creates documents in a short time
20 bad habits of bad programmers
Insider of container network hard core technology (7) sailing on the sea depends on the helmsman
二维数组相关知识
The cooperation between starfish OS and metabell is just the beginning
Spool timer
Redis cache penetration breakdown and avalanche
Flutter 通话界面UI
Ford SUV "Mustang" officially went offline, safe and comfortable
Unknown database ‘xxxxx‘
Redis-哨兵模式
URDF integrated gazebo
[300 opencv routines] 241. Scale invariant feature transformation (SIFT)
uni-app进阶之样式框架/生产环境
BAT大厂测试架构师如何解读测试平台的各种争议
Oracle error: ora-01722 invalid number









