Advertisement

Cesium航天卫星开发教程之二:相控阵雷达探测

阅读量:

教程示例网站:https://thomaz529.github.io

一、效果图

二、代码

复制代码
  
    
     let r = new Cesium.HeadingPitchRoll(Cesium.Math.toRadians(90), Cesium.Math.toRadians(0), Cesium.Math.toRadians(0));
    
     let l = Cesium.Cartesian3.fromDegrees(117.224, 31.819, 128);
    
     let sensorEntity = viewer.entities.add({
    
         position: l,
    
         orientation: Cesium.Transforms.headingPitchRollQuaternion(l, r),
    
         rectangularSensor: new RectangularSensorGraphics({
    
             radius: 100000,//传感器的半径
    
             xHalfAngle: Cesium.Math.toRadians(45), // 传感器水平半角
    
             yHalfAngle: Cesium.Math.toRadians(45), // 传感器垂直半角
    
             material: Cesium.Color.AQUA.withAlpha(0.5),
    
             lineColor: Cesium.Color.AQUA.withAlpha(0.5), // 线的颜色
    
             showScanPlane: true, // 是否显示扇面的线
    
             scanPlaneColor: Cesium.Color.AQUA.withAlpha(0.8), // 扫描面颜色
    
             scanPlaneMode: "vertical", // 扫描面模式 垂直vertical/水平horizontal
    
             scanPlaneRate: 3, // 扫描速率
    
             showThroughEllipsoid: !1
    
             // slice: 32 // 切分程度
    
             // showSectorLines:true //是否显示扇面的线 
    
             // showSectorSegmentLines:true //是否显示扇面和圆顶面连接的线 
    
             // showLateralSurfaces:true //是否显示侧面 
    
             // showDomeSurfaces:true //是否显示圆顶表面 
    
             // showDomeLines:true //是否显示圆顶面线 
    
             // showIntersection:true //是否显示与地球相交的线 
    
             // intersectionColor:Color.WHITE //与地球相交的线的颜色 
    
             // intersectionWidth:5.0 //与地球相交的线的宽度(像素) 
    
         })
    
     })

全部评论 (0)

还没有任何评论哟~