[go: up one dir, main page]

Feature request: draped feature collection

Summary

The current FeatureCollection entity was designed with 2D algorithms in mind (2D tiles, no handling of 3D volumes, min/max zoom levels not very intuitive).

It makes it very difficult to use on terrain that is not near zero elevation, because all bounding boxes are initialized with elevation of zero, making unlikely that the tile passes the frustum culling test when the camera is oblique/far from the zero level.

On possible alternative is to listen to creation of map tiles (or any other similar interface), then create the feature in those tiles. The benefit would be that we automatically know the 3D volume of tiles, as well and when they become invisible or visible.

Something like a DrapedFeatureCollection or ClampedFeatureCollection ?

Possible use cases

Describe possible use cases to help understand the benefits of this new feature.

  1. Load 2D or 2.5D features on the surface of the terrain without relying on complicated elevation callbacks.

Implementation suggestions

We would mostly be reusing a lot of logic from FeatureCollection, such as style API, the use of GeometryConverter, etc, but instead of having a 2D grid, we would just hook into an existing tile system such as map (hidden behind an interface for abstraction purposes), and then load/unload features when tiles are added/removed.

Edited by Sébastien Guimmara