Skip to content

Commit 426b687

Browse files
authored
Example rename (visgl#1182)
* Update picking docs. * Rename and add docs for viewport transition examples.
1 parent 1cc0e6a commit 426b687

33 files changed

Lines changed: 33 additions & 248 deletions

File tree

docs/advanced/picking.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,3 +69,16 @@ calculatePickingColors(attribute) {
6969
[`layer.decodePickingColor()`](/docs/api-reference/base-layer.md#-decodepickingcolor-) is likely sufficient, but you may need to implement your own pair.
7070
- By default, the `object` field of the picking `info` object is indexed from the layer's `data` prop. Custom layers often need to define on their own terms what constitutes meaningful information to the user's callbacks. A layer can achieve this by overriding [`layer.getPickingInfo()`](/docs/api-reference/base-layer.md#-getpickinginfo-) to add or modify fields to the `info` object.
7171
- For more information about how to implement picking in shaders see: [`renderPickingBuffer`](/docswriting-shaders.md#-float-renderpickingbuffer-)
72+
73+
74+
## Custom Shaders
75+
76+
Deck.gl layers use luma.gl's [`Picking Module`](http://uber.github.io/luma.gl/#/documentation/api-reference/shader-module). If you are writing custom shaders for your layers, please refer to above luma.gl documentation on how to add picking logic to your shaders. Also make sure to create `Model` object with `picking` module. ()
77+
78+
```
79+
const model = new Model(gl, {
80+
fs: CUSTOM_FS,
81+
vs: CUSTOM_VS,
82+
modules: ['picking', ...],
83+
});
84+
```

docs/get-started/interactivity.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ The picking engine returns "picking info" objects which contains a variety of fi
3131
3232
## Calling the Picking Engine Directly
3333

34-
The picking engine is exposed through the [`DeckGL.queryObject`]((/docs/api-reference/deckgl.md) and [`DeckGL.queryVisibleObject`]((/docs/api-reference/deckgl.md) methods. These methods allow you to query what layers and objects within those layers are under a specific point or within a specified rectangle. They return `Picking Info` objects as described below.
34+
The picking engine is exposed through the [`DeckGL.pickObject`]((/docs/api-reference/deckgl.md) and [`DeckGL.pickObjects`]((/docs/api-reference/deckgl.md) methods. These methods allow you to query what layers and objects within those layers are under a specific point or within a specified rectangle. They return `Picking Info` objects as described below.
3535

3636
`pickObject` allows an application to define its own event handling. When it comes to how to actually do event handling in a browser, there are many options. In a React application, perhaps the simplest is to just use React's "synthetic" event handling together with `pickObject`:
3737

examples/wip/viewport-animation-first-person-map/app.js renamed to examples/experimental/multi-viewport-transitions/app.js

File renamed without changes.
File renamed without changes.
File renamed without changes.

examples/wip/first-person-map/webpack.config.js renamed to examples/experimental/multi-viewport-transitions/webpack.config.js

File renamed without changes.
File renamed without changes.
File renamed without changes.

examples/wip/viewport-animation-first-person-map/package.json renamed to examples/experimental/multi-viewport/package.json

File renamed without changes.

examples/wip/viewport-animation-3d-heatmap/webpack.config.js renamed to examples/experimental/multi-viewport/webpack.config.js

File renamed without changes.

0 commit comments

Comments
 (0)