Skip to content

CollisionFilterExtension

lonboard.experimental.CollisionFilterExtension

Allows layers to hide overlapping objects.

collision_enabled class-attribute instance-attribute

collision_enabled = traitlets.Bool(True).tag(sync=True)

Enable/disable collisions. If collisions are disabled, all objects are rendered.

  • Type: bool, optional
  • Default: True

collision_group class-attribute instance-attribute

collision_group = traitlets.Unicode().tag(sync=True)

Collision group this layer belongs to. If it is not set, the 'default' collision group is used

  • Type: string, optional
  • Default: None

get_collision_priority class-attribute instance-attribute

get_collision_priority = FloatAccessor(allow_none=True)

Accessor for collision priority. Must return a number in the range -1000 -> 1000. Features with higher values are shown preferentially.

  • Type: FloatAccessor, optional
    • If a number is provided, it is used as the priority for all objects.
    • If an array is provided, each value in the array will be used as the priority for the object at the same row index.
  • Default: 0.