deck.gl - 是否可以增加点击半径?

deck.gl - is it possible to increase the on click radius?

我想在用户单击路径层中的对象时添加操作。我注意到我真的需要在每条路径的中间单击才能发生这种情况。是否有可能以某种方式增加该半径,以便当用户在该对象附近单击时甚至会触发单击操作?无法为任何层找到这样的 属性。

我认为您正在寻找 pickingRadiuscheck this out

您应该可以在 Deck 实例上应用它。

使用 React:

<DeckGL
  ...otherProps
  pickingRadius={10}
>

使用普通 JS:

const deckgl = new Deck({
  ...otherProps,
  pickingRadius: 10
});