Class: BaseLayer ¶
Table of contents ¶
Constructors ¶
Methods ¶
- initialize
- updateOptions
- resize
- setFillColor
- setOpacity
- setNumParticles
- setSpeedFactor
- setFadeOpacity
- setDropRate
- setDropRateBump
- setSymbolSpace
- setSymbolSize
- parseStyleSpec
- handleZoom
- buildColorRamp
- clearStencil
- stencilConfigForOverlap
- moveStart
- moveEnd
- update
- onTileLoaded
- setMask
- picker
- prerender
- render
- destroy
Constructors ¶
constructor ¶
• new BaseLayer(source
, rs
, options?
): BaseLayer
Parameters ¶
Name | Type |
---|---|
source | SourceType |
rs | Object |
rs.renderer | Renderer |
rs.scene | Scene |
options? | Partial <BaseLayerOptions > |
Returns ¶
Defined in ¶
gl-core/src/renderer/index.ts:200
Methods ¶
initialize ¶
▸ initialize(): void
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:265
updateOptions ¶
▸ updateOptions(options
): void
Parameters ¶
Name | Type |
---|---|
options | Partial <UserOptions > |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:417
resize ¶
▸ resize(width
, height
): void
Parameters ¶
Name | Type |
---|---|
width | number |
height | number |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:432
setFillColor ¶
▸ setFillColor(): void
设置填色色阶
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:441
setOpacity ¶
▸ setOpacity(opacity
): void
设置图层透明度
Parameters ¶
Name | Type |
---|---|
opacity | number |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:449
setNumParticles ¶
▸ setNumParticles(numParticles
): void
设置粒子图层的粒子数量
Parameters ¶
Name | Type |
---|---|
numParticles | number |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:457
setSpeedFactor ¶
▸ setSpeedFactor(speedFactor
): void
设置粒子图层的粒子数量
Parameters ¶
Name | Type |
---|---|
speedFactor | number |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:465
setFadeOpacity ¶
▸ setFadeOpacity(fadeOpacity
): void
设置粒子图层的粒子数量
Parameters ¶
Name | Type |
---|---|
fadeOpacity | number |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:473
setDropRate ¶
▸ setDropRate(dropRate
): void
设置粒子图层的粒子数量
Parameters ¶
Name | Type |
---|---|
dropRate | number |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:481
setDropRateBump ¶
▸ setDropRateBump(dropRateBump
): void
设置粒子图层的粒子数量
Parameters ¶
Name | Type |
---|---|
dropRateBump | number |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:489
setSymbolSpace ¶
▸ setSymbolSpace(space
): void
设置 symbol 的间距
Parameters ¶
Name | Type |
---|---|
space | any |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:497
setSymbolSize ¶
▸ setSymbolSize(size
): void
设置 symbol 的大小
Parameters ¶
Name | Type |
---|---|
size | any |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:505
parseStyleSpec ¶
▸ parseStyleSpec(clear
): void
解析样式配置
Parameters ¶
Name | Type |
---|---|
clear | any |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:513
handleZoom ¶
▸ handleZoom(): void
处理地图缩放事件
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:535
buildColorRamp ¶
▸ buildColorRamp(): void
构建渲染所需色带
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:542
clearStencil ¶
▸ clearStencil(): void
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:563
stencilConfigForOverlap ¶
▸ stencilConfigForOverlap(tiles
): [{ [_: number]
: any
; }, Tile
[]]
Parameters ¶
Name | Type |
---|---|
tiles | any [] |
Returns ¶
[{ [_: number]
: any
; }, Tile
[]]
Defined in ¶
gl-core/src/renderer/index.ts:567
moveStart ¶
▸ moveStart(): void
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:617
moveEnd ¶
▸ moveEnd(): void
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:636
update ¶
▸ update(): void
更新视野内的瓦片
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:661
onTileLoaded ¶
▸ onTileLoaded(): void
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:672
setMask ¶
▸ setMask(mask
): void
Parameters ¶
Name | Type |
---|---|
mask | undefined | { data : Attributes [] ; type : MaskType } |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:678
picker ¶
▸ picker(pixel?
): Promise
<any
>
Parameters ¶
Name | Type |
---|---|
pixel | number [] |
Returns ¶
Promise
<any
>
Defined in ¶
gl-core/src/renderer/index.ts:712
prerender ¶
▸ prerender(cameras
, renderTarget?
): void
Parameters ¶
Name | Type |
---|---|
cameras | any |
renderTarget? | any |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:719
render ¶
▸ render(cameras
, renderTarget?
): void
Parameters ¶
Name | Type |
---|---|
cameras | any |
renderTarget? | any |
Returns ¶
void
Defined in ¶
gl-core/src/renderer/index.ts:750
destroy ¶
▸ destroy(): void
销毁此 Renderer
Returns ¶
void