Appearance
KBE3D / KBCore / Cesium / VelocityVectorProperty
类: VelocityVectorProperty
A Property which evaluates to a Cartesian3 vector based on the velocity of the provided PositionProperty.
示例
ts
//Create an entity with a billboard rotated to match its velocity.
const position = new Cesium.SampledProperty();
position.addSamples(...);
const entity = viewer.entities.add({
position : position,
billboard : {
image : 'image.png',
alignedAxis : new Cesium.VelocityVectorProperty(position, true) // alignedAxis must be a unit vector
}
}));参数
The position property used to compute the velocity.
参数
Whether to normalize the computed velocity vector.
属性
isConstant
readonlyisConstant:boolean
Gets a value indicating if this property is constant.
definitionChanged
readonlydefinitionChanged:Event
Gets the event that is raised whenever the definition of this property changes.
position
position:
Property|undefined
Gets or sets the position property used to compute the velocity vector.
normalize
normalize:
boolean
Gets or sets whether the vector produced by this property will be normalized or not.
方法
getValue()
getValue(
time?:JulianDate,result?:Cartesian3):Cartesian3
Gets the value of the property at the provided time.
参数
time?
The time for which to retrieve the value. If omitted, the current system time is used.
result?
The object to store the value into, if omitted, a new instance is created and returned.
返回
The modified result parameter or a new instance if the result parameter was not supplied.
equals()
equals(
other?:Property):boolean
Compares this property to the provided property and returns <code>true</code> if they are equal, <code>false</code> otherwise.
参数
other?
The other property.
返回
boolean
true if left and right are equal, false otherwise.
构造函数
构造函数
new VelocityVectorProperty(
position?:PositionProperty,normalize?:boolean):VelocityVectorProperty
参数
position?
normalize?
boolean
返回
VelocityVectorProperty
