Class: Field ¶
Table of contents ¶
Constructors ¶
Properties ¶
Methods ¶
- buildGrid
- release
- extent
- calculateRange
- contains
- getDecimalIndexes
- valueAt
- interpolatedValueAt
- hasValueAt
- valueAtIndexes
- lonLatAtIndexes
- randomize
- checkFields
Constructors ¶
constructor ¶
• new Field(params
): Field
Parameters ¶
Name | Type |
---|---|
params | IField |
Returns ¶
Defined in ¶
core/dist/index.d.ts:109
Properties ¶
grid ¶
• grid: (null
| Vector
)[][]
Defined in ¶
core/dist/index.d.ts:106
range ¶
• range: undefined
| (undefined
| number
)[]
Defined in ¶
core/dist/index.d.ts:107
Methods ¶
buildGrid ¶
▸ buildGrid(): (null
| Vector
)[][]
Returns ¶
(null
| Vector
)[][]
Defined in ¶
core/dist/index.d.ts:110
release ¶
▸ release(): void
release data
Returns ¶
void
Defined in ¶
core/dist/index.d.ts:114
extent ¶
▸ extent(): number
[]
grib data extent 格点数据范围
Returns ¶
number
[]
Defined in ¶
core/dist/index.d.ts:119
calculateRange ¶
▸ calculateRange(): undefined
| any
[]
calculate vector value range
Returns ¶
undefined
| any
[]
Defined in ¶
core/dist/index.d.ts:136
contains ¶
▸ contains(lon
, lat
): any
Parameters ¶
Name | Type |
---|---|
lon | number |
lat | number |
Returns ¶
any
Defined in ¶
core/dist/index.d.ts:144
getDecimalIndexes ¶
▸ getDecimalIndexes(lon
, lat
): number
[]
获取经纬度所在的位置索引
Parameters ¶
Name | Type |
---|---|
lon | number |
lat | number |
Returns ¶
number
[]
Defined in ¶
core/dist/index.d.ts:150
valueAt ¶
▸ valueAt(lon
, lat
): null
| Vector
Nearest value at lon-lat coordinates 线性插值
Parameters ¶
Name | Type |
---|---|
lon | number |
lat | number |
Returns ¶
null
| Vector
Defined in ¶
core/dist/index.d.ts:157
interpolatedValueAt ¶
▸ interpolatedValueAt(lon
, lat
): null
| Vector
Get interpolated grid value lon-lat coordinates 双线性插值
Parameters ¶
Name | Type |
---|---|
lon | number |
lat | number |
Returns ¶
null
| Vector
Defined in ¶
core/dist/index.d.ts:164
hasValueAt ¶
▸ hasValueAt(lon
, lat
): boolean
Parameters ¶
Name | Type |
---|---|
lon | number |
lat | number |
Returns ¶
boolean
Defined in ¶
core/dist/index.d.ts:165
valueAtIndexes ¶
▸ valueAtIndexes(i
, j
): null
| Vector
Value for grid indexes
Parameters ¶
Name | Type | Description |
---|---|---|
i | number | column index (integer) |
j | number | row index (integer) |
Returns ¶
null
| Vector
Defined in ¶
core/dist/index.d.ts:213
lonLatAtIndexes ¶
▸ lonLatAtIndexes(i
, j
): number
[]
Lon-Lat for grid indexes
Parameters ¶
Name | Type | Description |
---|---|---|
i | number | column index (integer) |
j | number | row index (integer) |
Returns ¶
number
[]
[lon, lat]
Defined in ¶
core/dist/index.d.ts:220
randomize ¶
▸ randomize(o
, width
, height
, unproject
): IPosition
生成粒子位置
Parameters ¶
Name | Type |
---|---|
o | undefined | IPosition |
width | number |
height | number |
unproject | (a : number []) => null | [number , number ] |
Returns ¶
IPosition
IPosition
Defined in ¶
core/dist/index.d.ts:241
checkFields ¶
▸ checkFields(): boolean
判断是否是 Field
的实例
Returns ¶
boolean
boolean
Defined in ¶
core/dist/index.d.ts:246