You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/api-reference/google-maps/google-maps-overlay.md
+94-34Lines changed: 94 additions & 34 deletions
Original file line number
Diff line number
Diff line change
@@ -2,40 +2,104 @@
2
2
3
3
This class implements the [OverlayView](https://developers.google.com/maps/documentation/javascript/reference/overlay-view#OverlayView)/[WebGLOverlayView](https://developers.google.com/maps/documentation/javascript/reference/webgl#WebGLOverlayView) (depending on map rendering type) interface and can be used as any other Google Maps overlay.
4
4
5
-
## Vector/Raster maps
6
-
7
5
As detailed in the [overview](./overview.md), the overlay supports both Vector and Raster Google map rendering. Depending on the Google Map configuration, the correct deck.gl overlay rendering method will be chosen at runtime.
`props` are forwarded to a `Deck` instance. The following [Deck](../core/deck.md) props are supported:
@@ -59,15 +123,15 @@ The constructor additionally accepts the following option:
59
123
60
124
#### `setMap` {#setmap}
61
125
62
-
```js
126
+
```ts
63
127
overlay.setMap(map);
64
128
```
65
129
66
130
Add/remove the overlay from a map. An overlay can be temporarily hidden from a map by calling `setMap(null)`. Removing an overlay does not destroy the WebGL2 context; use `finalize()` if the overlay should be permanently removed.
67
131
68
132
#### `setProps` {#setprops}
69
133
70
-
```js
134
+
```ts
71
135
overlay.setProps(props);
72
136
```
73
137
@@ -87,12 +151,8 @@ Equivalent of [deck.pickMultipleObjects](../core/deck.md).
87
151
88
152
#### `finalize` {#finalize}
89
153
90
-
```js
91
-
overlay.finalize();
92
-
```
93
-
94
154
Remove the overlay and release all underlying resources.
95
155
96
156
##### getCanvas
97
157
98
-
See [Deck.getCanvas](../core/deck.md#getcanvas). When using `interleaved: true`, returns the base map's `canvas`.
158
+
See [Deck.getCanvas](../core/deck.md#getcanvas). When using `interleaved: true`, returns the base map's `canvas`.
`MapboxOverlay` accepts the same props as the [Deck](../core/deck.md) class, with the following exceptions:
128
111
129
112
-`views` - multi-view support is limited. There is only one `MapView` that can synchronize with the base map. See the [using with multi-views](#multi-view-usage) section for details.
Copy file name to clipboardExpand all lines: docs/api-reference/mapbox/overview.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -81,6 +81,6 @@ If you're using deck.gl in a React or Scripting environment, you just want the b
81
81
82
82
* When using deck.gl's multi-view system, only one of the views can match the base map and receive interaction. See [using MapboxOverlay with multi-views](./mapbox-overlay.md#multi-view-usage) for details.
83
83
* When using deck.gl as Mapbox layers or controls, `Deck` only receives a subset of user inputs delegated by `Map`. Therefore, certain interactive callbacks like `onDrag`, `onInteractionStateChange` are not available.
84
-
* Mapbox/Maplibre's terrain features are partially supported. When a terrain is used, the camera of deck.gl and the base map should synchronize, however the deck.gl data with z=0 are rendered at the sea level and not aligned with the terrain surface.
84
+
* Mapbox/MapLibre's terrain features are partially supported. When a terrain is used, the camera of deck.gl and the base map should synchronize, however the deck.gl data with z=0 are rendered at the sea level and not aligned with the terrain surface.
85
85
* Only Mercator projection is supported. Mapbox adaptive projection is not supported as their API doesn't expose the projection used.
86
86
* The `position` property in `viewState` has no equivalent in mapbox-gl.
0 commit comments