選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

RadarWaveMaterialProperty.js 986B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. /**
  2. * @Author: Caven
  3. * @Date: 2021-02-27 23:53:08
  4. */
  5. import { Cesium } from '@dc-modules/namespace'
  6. import MaterialProperty from '../../MaterialProperty'
  7. class RadarWaveMaterialProperty extends MaterialProperty {
  8. constructor(options = {}) {
  9. super(options)
  10. }
  11. getType(time) {
  12. return Cesium.Material.RadarWaveType
  13. }
  14. getValue(time, result) {
  15. result = Cesium.defaultValue(result, {})
  16. result.color = Cesium.Property.getValueOrUndefined(this._color, time)
  17. result.speed = this._speed
  18. return result
  19. }
  20. equals(other) {
  21. return (
  22. this === other ||
  23. (other instanceof RadarWaveMaterialProperty &&
  24. Cesium.Property.equals(this._color, other._color) &&
  25. Cesium.Property.equals(this._speed, other._speed))
  26. )
  27. }
  28. }
  29. Object.defineProperties(RadarWaveMaterialProperty.prototype, {
  30. color: Cesium.createPropertyDescriptor('color'),
  31. speed: Cesium.createPropertyDescriptor('speed')
  32. })
  33. export default RadarWaveMaterialProperty