itwinjs-core icon indicating copy to clipboard operation
itwinjs-core copied to clipboard

Support 3d markers (2.5D points)

Open pmconne opened this issue 2 years ago • 10 comments

Is your feature request related to a problem? Please describe. Implementing #6194.

Describe the solution you'd like #6194 requires the ability to draw a potentially large number of mostly static billboard images efficiently.

Describe alternatives you've considered Using decorators - not efficient (need to update + redraw constantly) Using 2d canvas markers - does not participate in depth test.

Additional context This type of marker is available in and used by one of our applications today, using custom tile server and custom extension to the display system. We want to eliminate both of those. Additionally, other servers also supply these markers, which we cannot currently display.

Requested by @alarkbentley and @mdastous-bentley.

pmconne avatar Nov 14 '23 14:11 pmconne

We already have:

  • Marker - a 2d canvas decoration that is visually very similar to what is being requested but does not render via WebGL so does not participate in depth test with 3d geometry; and
  • ParticleCollectionBuilder - an efficient way to draw many instances of a single billboard image.

We could probably enhance our particle systems to support a texture atlas instead of a single billboard. We'd need to produce a texture atlas from the collection of billboard images. It will be simpler if all of the images have the same dimensions - packing the atlas would be trivial and each instance could refer to its image by a single integer index - but need to determine if that's an acceptable constraint.

pmconne avatar Nov 14 '23 14:11 pmconne

@danieliborra

markschlosseratbentley avatar Nov 14 '23 14:11 markschlosseratbentley

fyi @Josh-Schifter , i recall your team asking about this last yr

aruniverse avatar Nov 14 '23 15:11 aruniverse

fyi @Josh-Schifter , i recall your team asking about this last yr

@Josh-Schifter if any details of your request are not captured in the issue description, please provide them.

pmconne avatar Nov 14 '23 15:11 pmconne

We had a customer request for markers that would be hidden behind model geometry. We created a sandbox that satisfied them at the time. https://www.itwinjs.org/sandboxes/ThomasDicarlo/World%20Decoration%20Markers

That code is still on 2.x which is no longer supported by the sandbox.

Josh-Schifter avatar Nov 14 '23 16:11 Josh-Schifter

There are other teams interested in this, e.g. @MarcBedard8's annotation service and IOT. We had some recent initial conversations about how to structure and render this type of data in an efficient way (100Ks of points), using standard (GIS) formats if possible.

I'd start by collecting a list of technical requirements from the different teams and develop a single solution that covers all use cases. I'd suggest to discuss this on the next Tiling Services meeting (all the ones involved in this are included in the meeting).

danieliborra avatar Nov 14 '23 17:11 danieliborra

@AJMigliore

markschlosseratbentley avatar Nov 17 '23 19:11 markschlosseratbentley

I added this to the iTwin Graphics Service Backlog.

I'd also check how Open City Planner and Cesium.js implemented this, to get some ideas.

danieliborra avatar Nov 21 '23 18:11 danieliborra

@danieliborra FYI

markschlosseratbentley avatar Jan 11 '24 19:01 markschlosseratbentley

Initial research work: https://github.com/iTwin/itwinjs-core/pull/6439

markschlosseratbentley avatar Feb 14 '24 12:02 markschlosseratbentley