| Name | Type | Default | Description |
|---|---|---|---|
x |
number |
0.0
|
optional X组件. |
y |
number |
0.0
|
optional |
z |
number |
0.0
|
optional Z组分. |
See:
Members
X组件.
-
Default Value:
0.0
Y组件.
-
Default Value:
0.0
Z组件.
-
Default Value:
0.0
static constant Cesium.Cartesian3.ONE : Cartesian3
不可改变的 Cartesian3 实例初始化为(1.0,1.0,1.0).
用于将对象组合成数组的元素数量.
static constant Cesium.Cartesian3.UNIT_X : Cartesian3
不可改变的 Cartesian3 实例初始化为 (1.0, 0.0, 0.0).
static constant Cesium.Cartesian3.UNIT_Y : Cartesian3
不可改变的 Cartesian3 实例初始化为(0.0,1.0,0.0).
static constant Cesium.Cartesian3.UNIT_Z : Cartesian3
不可改变的 NT% 0 实例初始化为 (0.0, 0.0, 1. 0) .
static constant Cesium.Cartesian3.ZERO : Cartesian3
不可改变的 Cartesian3 实例初始化为(0.0,0.0,0.0).
Methods
clone(result) → Cartesian3
重复这个 NT+0+ 实例 .
| Name | Type | Description |
|---|---|---|
result |
Cartesian3 | optional 存储结果的对象 . |
Returns:
未提供修改的结果参数或新的 NT% 0 实例 .
将这个笛卡尔与提供的笛卡尔组件进行比较并返回
-NT+0+Treal NT+1+,如果两者是相等的, NT+2+false NT+3+否则.
| Name | Type | Description |
|---|---|---|
right |
Cartesian3 | optional 右手侧笛卡尔琴. |
Returns:
-NT+0+Treal NT+1+,如果两者是相等的, NT+2+false NT+3+否则.
将这个笛卡尔与提供的笛卡尔组件进行比较并返回
如果通过绝对或相对耐性测试,
-NT+0+false NT+1+否则.
| Name | Type | Default | Description |
|---|---|---|---|
right |
Cartesian3 | optional 右手侧笛卡尔琴. | |
relativeEpsilon |
number |
0
|
optional The relative epsilon tolerance to use for equality testing. |
absoluteEpsilon |
number |
相对Epsilon
|
optional 绝对的埃皮西隆耐受性用于平等测试. |
Returns:
NT##############################################################################################################################################################################################################################################################.
在格式“ (x, y, z) ” 中创建代表此笛卡尔的字符串.
Returns:
在格式“ (x, y, z) ” 中代表此笛卡尔的字符串 .
static Cesium.Cartesian3.abs(cartesian, result) → Cartesian3
计算所提供的笛卡尔的绝对值.
| Name | Type | Description |
|---|---|---|
cartesian |
Cartesian3 | 要计算绝对值的笛卡尔. |
result |
Cartesian3 | 存储结果的对象 . |
Returns:
修改的结果参数 .
static Cesium.Cartesian3.add(left, right, result) → Cartesian3
计算两个笛卡尔的组件和.
| Name | Type | Description |
|---|---|---|
left |
Cartesian3 | 第一笛卡尔人. |
right |
Cartesian3 | 第二笛卡尔人. |
result |
Cartesian3 | 存储结果的对象 . |
Returns:
修改的结果参数 .
返回弧度角度,在提供的笛卡尔之间.
| Name | Type | Description |
|---|---|---|
left |
Cartesian3 | 第一笛卡尔人. |
right |
Cartesian3 | 第二笛卡尔人. |
Returns:
笛卡尔人之间的角度.
static Cesium.Cartesian3.clamp(value, min, max, result) → Cartesian3
限定两个值之间的值.
| Name | Type | Description |
|---|---|---|
value |
Cartesian3 | 夹的值. |
min |
Cartesian3 | 最小范围. |
max |
Cartesian3 | 最大范围. |
result |
Cartesian3 | 存储结果的对象. |
Returns:
被夹住的值如此小 QQ 值最大 .
static Cesium.Cartesian3.clone(cartesian, result) → Cartesian3
Duplicates a Cartesian3 instance.
| Name | Type | Description |
|---|---|---|
cartesian |
Cartesian3 | 笛卡尔复制. |
result |
Cartesian3 | optional 存储结果的对象 . |
Returns:
The modified result parameter or a new Cartesian3 instance if one was not provided. (Returns undefined if cartesian is undefined)
static Cesium.Cartesian3.cross(left, right, result) → Cartesian3
计算两个笛卡尔的十字(outer)产品.
| Name | Type | Description |
|---|---|---|
left |
Cartesian3 | 第一笛卡尔人. |
right |
Cartesian3 | 第二笛卡尔人. |
result |
Cartesian3 | 存储结果的对象 . |
Returns:
交叉产品.
计算两点之间的距离.
| Name | Type | Description |
|---|---|---|
left |
Cartesian3 | 计算距离的第一点. |
right |
Cartesian3 | 计算距离的第二点. |
Returns:
两点之间的距离.
Example:
// Returns 1.0
const d = Cesium.Cartesian3.distance(new Cesium.Cartesian3(1.0, 0.0, 0.0), new Cesium.Cartesian3(2.0, 0.0, 0.0));
计算两点之间的平方距离。 比较平方距离
using this function is more efficient than comparing distances using
Cartesian3#distance.
| Name | Type | Description |
|---|---|---|
left |
Cartesian3 | 计算距离的第一点. |
right |
Cartesian3 | 计算距离的第二点. |
Returns:
两点之间的距离.
Example:
// Returns 4.0, not 2.0
const d = Cesium.Cartesian3.distanceSquared(new Cesium.Cartesian3(1.0, 0.0, 0.0), new Cesium.Cartesian3(3.0, 0.0, 0.0));
static Cesium.Cartesian3.divideByScalar(cartesian, scalar, result) → Cartesian3
将提供的笛卡尔元件除以所提供的斯卡尔.
| Name | Type | Description |
|---|---|---|
cartesian |
Cartesian3 | 笛卡尔人将被分割. |
scalar |
number | 师拟分之. |
result |
Cartesian3 | 存储结果的对象 . |
Returns:
修改的结果参数 .
static Cesium.Cartesian3.divideComponents(left, right, result) → Cartesian3
计算两个笛卡尔的组件商号.
| Name | Type | Description |
|---|---|---|
left |
Cartesian3 | 第一笛卡尔人. |
right |
Cartesian3 | 第二笛卡尔人. |
result |
Cartesian3 | 存储结果的对象 . |
Returns:
修改的结果参数 .
计算两个笛卡尔的点(scalar)产品.
| Name | Type | Description |
|---|---|---|
left |
Cartesian3 | 第一笛卡尔人. |
right |
Cartesian3 | 第二笛卡尔人. |
Returns:
点产品.
比较提供的笛卡尔组件并返回
-NT+0+Treal NT+1+,如果两者是相等的, NT+2+false NT+3+否则.
| Name | Type | Description |
|---|---|---|
left |
Cartesian3 | optional 第一笛卡尔人. |
right |
Cartesian3 | optional 第二笛卡尔人. |
Returns:
如果左右对等, 则使用 NT 0 true NT 1 , 否则使用 NT 2 false NT 3 .
比较提供的笛卡尔组件并返回
如果通过绝对或相对耐性测试,
-NT+0+false NT+1+否则.
| Name | Type | Default | Description |
|---|---|---|---|
left |
Cartesian3 | optional 第一笛卡尔人. | |
right |
Cartesian3 | optional 第二笛卡尔人. | |
relativeEpsilon |
number |
0
|
optional The relative epsilon tolerance to use for equality testing. |
absoluteEpsilon |
number |
相对Epsilon
|
optional 绝对的埃皮西隆耐受性用于平等测试. |
Returns:
NT################################################################### ##########################################################################################################################################################################################.
static Cesium.Cartesian3.fromArray(array, startingIndex, result) → Cartesian3
在数组中从三个连续的元素中创建 Cartesian3 .
| Name | Type | Default | Description |
|---|---|---|---|
array |
Array.<number> | 其三个连续元素分别对应x、y和z组件的数组. | |
startingIndex |
number |
0
|
optional The offset into the array of the first element, which corresponds to the x component. |
result |
Cartesian3 | optional 存储结果的对象 . |
Returns:
未提供修改的结果参数或新的 NT% 0 实例 .
Example:
// Create a Cartesian3 with (1.0, 2.0, 3.0)
const v = [1.0, 2.0, 3.0];
const p = Cesium.Cartesian3.fromArray(v);
// Create a Cartesian3 with (1.0, 2.0, 3.0) using an offset into an array
const v2 = [0.0, 0.0, 1.0, 2.0, 3.0];
const p2 = Cesium.Cartesian3.fromArray(v2, 2);
static Cesium.Cartesian3.fromCartesian4(cartesian, result) → Cartesian3
Creates a Cartesian3 instance from an existing Cartesian4. This simply takes the
x, y, and z properties of the Cartesian4 and drops w.
| Name | Type | Description |
|---|---|---|
cartesian |
Cartesian4 | The Cartesian4 instance to create a Cartesian3 instance from. |
result |
Cartesian3 | optional 存储结果的对象 . |
Returns:
未提供修改的结果参数或新的 NT% 0 实例 .
static Cesium.Cartesian3.fromDegrees(longitude, latitude, height, ellipsoid, result) → Cartesian3
从经度和纬度值中返回 NT++0 位置.
| Name | Type | Default | Description |
|---|---|---|---|
longitude |
number | 以度计的经度 | |
latitude |
number | 纬度,以度计 | |
height |
number |
0.0
|
optional 高度,以米计,高于椭圆形. |
ellipsoid |
Ellipsoid |
Ellipsoid.default
|
optional The ellipsoid on which the position lies. |
result |
Cartesian3 | optional 存储结果的对象 . |
Returns:
The position
Example:
const position = Cesium.Cartesian3.fromDegrees(-115.0, 37.0);
static Cesium.Cartesian3.fromDegreesArray(coordinates, ellipsoid, result) → Array.<Cartesian3>
返回以度数给出的经度和纬度值阵列的 Cartesian3 位置.
| Name | Type | Default | Description |
|---|---|---|---|
coordinates |
Array.<number> | A list of longitude and latitude values. Values alternate [longitude, latitude, longitude, latitude...]. | |
ellipsoid |
Ellipsoid |
Ellipsoid.default
|
optional The ellipsoid on which the coordinates lie. |
result |
Array.<Cartesian3> | optional An array of Cartesian3 objects to store the result. |
Returns:
位置阵列.
Example:
const positions = Cesium.Cartesian3.fromDegreesArray([-115.0, 37.0, -107.0, 33.0]);
static Cesium.Cartesian3.fromDegreesArrayHeights(coordinates, ellipsoid, result) → Array.<Cartesian3>
返回经纬度、纬度和高度值以度表示的 NT 0 位置数组.
| Name | Type | Default | Description |
|---|---|---|---|
coordinates |
Array.<number> | 经纬度,纬度和高度值列表. 值交替[经,纬,高,经,纬,高. ]. | |
ellipsoid |
Ellipsoid |
Ellipsoid.default
|
optional The ellipsoid on which the position lies. |
result |
Array.<Cartesian3> | optional An array of Cartesian3 objects to store the result. |
Returns:
位置阵列.
Example:
const positions = Cesium.Cartesian3.fromDegreesArrayHeights([-115.0, 37.0, 100000.0, -107.0, 33.0, 150000.0]);
static Cesium.Cartesian3.fromElements(x, y, z, result) → Cartesian3
Creates a Cartesian3 instance from x, y and z coordinates.
| Name | Type | Description |
|---|---|---|
x |
number | X坐标. |
y |
number | Y坐标. |
z |
number | Z坐标. |
result |
Cartesian3 | optional 存储结果的对象 . |
Returns:
未提供修改的结果参数或新的 NT% 0 实例 .
static Cesium.Cartesian3.fromRadians(longitude, latitude, height, ellipsoid, result) → Cartesian3
Returns a Cartesian3 position from longitude and latitude values given in radians.
| Name | Type | Default | Description |
|---|---|---|---|
longitude |
number | 经度,以弧度表示 | |
latitude |
number | 纬度,以弧度计 | |
height |
number |
0.0
|
optional 高度,以米计,高于椭圆形. |
ellipsoid |
Ellipsoid |
Ellipsoid.default
|
optional The ellipsoid on which the position lies. |
result |
Cartesian3 | optional 存储结果的对象 . |
Returns:
The position
Example:
const position = Cesium.Cartesian3.fromRadians(-2.007, 0.645);
static Cesium.Cartesian3.fromRadiansArray(coordinates, ellipsoid, result) → Array.<Cartesian3>
返回以弧度表示的经度和纬度值阵列的 Cartesian3 位置.
| Name | Type | Default | Description |
|---|---|---|---|
coordinates |
Array.<number> | A list of longitude and latitude values. Values alternate [longitude, latitude, longitude, latitude...]. | |
ellipsoid |
Ellipsoid |
Ellipsoid.default
|
optional The ellipsoid on which the coordinates lie. |
result |
Array.<Cartesian3> | optional An array of Cartesian3 objects to store the result. |
Returns:
位置阵列.
Example:
const positions = Cesium.Cartesian3.fromRadiansArray([-2.007, 0.645, -1.867, .575]);
static Cesium.Cartesian3.fromRadiansArrayHeights(coordinates, ellipsoid, result) → Array.<Cartesian3>
返回以弧度表示经度、经度和纬度的经度、纬度和高度值的 NT% 0 位置数组.
| Name | Type | Default | Description |
|---|---|---|---|
coordinates |
Array.<number> | 经纬度,纬度和高度值列表. 值交替[经,纬,高,经,纬,高. ]. | |
ellipsoid |
Ellipsoid |
Ellipsoid.default
|
optional The ellipsoid on which the position lies. |
result |
Array.<Cartesian3> | optional An array of Cartesian3 objects to store the result. |
Returns:
位置阵列.
Example:
const positions = Cesium.Cartesian3.fromRadiansArrayHeights([-2.007, 0.645, 100000.0, -1.867, .575, 150000.0]);
static Cesium.Cartesian3.fromSpherical(spherical, result) → Cartesian3
将所提供的球形转换为 NT 0 坐标.
| Name | Type | Description |
|---|---|---|
spherical |
Spherical | 将转换为 NT 0 的球形. |
result |
Cartesian3 | optional 存储结果的对象 . |
Returns:
未提供修改的结果参数或新的 NT% 0 实例 .
static Cesium.Cartesian3.lerp(start, end, t, result) → Cartesian3
使用提供的笛卡尔计算 t 的线性插值或外推值.
| Name | Type | Description |
|---|---|---|
start |
Cartesian3 | T 对应的值为 0.0. |
end |
Cartesian3 | 与 t 对应的数值为1.0. |
t |
number | 沿着T的点 插入. |
result |
Cartesian3 | 存储结果的对象 . |
Returns:
修改的结果参数 .
计算笛卡尔的大小(长度).
| Name | Type | Description |
|---|---|---|
cartesian |
Cartesian3 | 将计算大小的笛卡尔实例. |
Returns:
The magnitude.
计算提供的笛卡尔平方大小.
| Name | Type | Description |
|---|---|---|
cartesian |
Cartesian3 | 将计算平方级的笛卡尔实例. |
Returns:
平方的量级.
static Cesium.Cartesian3.maximumByComponent(first, second, result) → Cartesian3
比较两个笛卡尔,计算一个含有所供应笛卡尔最大组件的笛卡尔.
| Name | Type | Description |
|---|---|---|
first |
Cartesian3 | 一个笛卡尔比较. |
second |
Cartesian3 | 一个笛卡尔比较. |
result |
Cartesian3 | 存储结果的对象. |
Returns:
一个拥有最大组件的笛卡尔.
计算所提供的笛卡尔最大组件的值.
| Name | Type | Description |
|---|---|---|
cartesian |
Cartesian3 | 笛卡尔人使用. |
Returns:
最大组件的值 .
static Cesium.Cartesian3.midpoint(left, right, result) → Cartesian3
计算左右笛卡尔的中点.
| Name | Type | Description |
|---|---|---|
left |
Cartesian3 | 第一笛卡尔人. |
right |
Cartesian3 | 第二笛卡尔人. |
result |
Cartesian3 | 存储结果的对象 . |
Returns:
The midpoint.
static Cesium.Cartesian3.minimumByComponent(first, second, result) → Cartesian3
比较两个笛卡尔并计算一个含有所供应笛卡尔最小组件的笛卡尔.
| Name | Type | Description |
|---|---|---|
first |
Cartesian3 | 一个笛卡尔比较. |
second |
Cartesian3 | 一个笛卡尔比较. |
result |
Cartesian3 | 存储结果的对象. |
Returns:
最小组件的笛卡尔.
计算提供的笛卡尔最小组件的值.
| Name | Type | Description |
|---|---|---|
cartesian |
Cartesian3 | 笛卡尔人使用. |
Returns:
最小组件的值 .
static Cesium.Cartesian3.mostOrthogonalAxis(cartesian, result) → Cartesian3
返回给定的笛卡尔最正弦的轴 .
| Name | Type | Description |
|---|---|---|
cartesian |
Cartesian3 | 找到最正弦轴的笛卡尔. |
result |
Cartesian3 | 存储结果的对象 . |
Returns:
最正统轴.
static Cesium.Cartesian3.multiplyByScalar(cartesian, scalar, result) → Cartesian3
将提供的笛卡尔元件以提供的scalar乘以.
| Name | Type | Description |
|---|---|---|
cartesian |
Cartesian3 | 笛卡尔人要缩放. |
scalar |
number | 须cal以乘. |
result |
Cartesian3 | 存储结果的对象 . |
Returns:
修改的结果参数 .
static Cesium.Cartesian3.multiplyComponents(left, right, result) → Cartesian3
计算两个笛卡尔的组件产品.
| Name | Type | Description |
|---|---|---|
left |
Cartesian3 | 第一笛卡尔人. |
right |
Cartesian3 | 第二笛卡尔人. |
result |
Cartesian3 | 存储结果的对象 . |
Returns:
修改的结果参数 .
static Cesium.Cartesian3.negate(cartesian, result) → Cartesian3
忽略了提供的笛卡尔.
| Name | Type | Description |
|---|---|---|
cartesian |
Cartesian3 | 笛卡尔人将被否定. |
result |
Cartesian3 | 存储结果的对象 . |
Returns:
修改的结果参数 .
static Cesium.Cartesian3.normalize(cartesian, result) → Cartesian3
计算所供应的笛卡尔的普通形式.
| Name | Type | Description |
|---|---|---|
cartesian |
Cartesian3 | 笛卡尔人将实现正常化. |
result |
Cartesian3 | 存储结果的对象 . |
Returns:
修改的结果参数 .
static Cesium.Cartesian3.pack(value, array, startingIndex) → Array.<number>|TypedArray
将所提供的实例存储到所提供的数组中.
| Name | Type | Default | Description |
|---|---|---|---|
value |
Cartesian3 | 包装的价值. | |
array |
Array.<number> | TypedArray | 装入的阵列. | |
startingIndex |
number |
0
|
optional The index into the array at which to start packing the elements. |
Returns:
装入的阵列
static Cesium.Cartesian3.packArray(array, result) → Array.<number>|TypedArray
将笛卡尔3的阵列平整成组件阵列.
| Name | Type | Description |
|---|---|---|
array |
Array.<Cartesian3> | 要装填的笛卡尔阵列. |
result |
Array.<number> | TypedArray |
optional
The array onto which to store the result. If this is a typed array, it must have array.length * 3 components, else a DeveloperError will be thrown. If it is a regular array, it will be resized to have (array.length * 3) elements. |
Returns:
装填的阵列.
static Cesium.Cartesian3.projectVector(a, b, result) → Cartesian3
项目向量 a 到 向量 b
| Name | Type | Description |
|---|---|---|
a |
Cartesian3 | 需要投影的矢量 |
b |
Cartesian3 | 投影的向量 |
result |
Cartesian3 | 结果的笛卡尔 |
Returns:
修改的结果参数
static Cesium.Cartesian3.subtract(left, right, result) → Cartesian3
计算两个笛卡尔的组件差异.
| Name | Type | Description |
|---|---|---|
left |
Cartesian3 | 第一笛卡尔人. |
right |
Cartesian3 | 第二笛卡尔人. |
result |
Cartesian3 | 存储结果的对象 . |
Returns:
修改的结果参数 .
static Cesium.Cartesian3.unpack(array, startingIndex, result) → Cartesian3
从组合的数组中获取实例 .
| Name | Type | Default | Description |
|---|---|---|---|
array |
Array.<number> | TypedArray | 装填的阵列. | |
startingIndex |
number |
0
|
optional The starting index of the element to be unpacked. |
result |
Cartesian3 | optional 存储结果的对象. |
Returns:
未提供修改的结果参数或新的 NT% 0 实例 .
static Cesium.Cartesian3.unpackArray(array, result) → Array.<Cartesian3>
将一系列的笛卡尔元件拆卸成一系列的笛卡尔3.
| Name | Type | Description |
|---|---|---|
array |
Array.<number> | TypedArray | 要解开的组件阵列 . |
result |
Array.<Cartesian3> | optional 存储结果的数组 . |
Returns:
无包装的阵列.