itowns icon indicating copy to clipboard operation
itowns copied to clipboard

3D Tiles refactoring

Open jailln opened this issue 5 years ago • 4 comments

I started working on the refactoring of 3D Tiles here. Current proposed modifications are: (some of these points have been discussed with @gchoqueux offline).

  • [ ] Create a class for each object of the spec and put them in src/Core/3DTiles/ . I started working on some of these classes here.
  • [x] Create a 3DTilesLayer which extend GeometryLayer.
  • [ ] Harmonize the tileIndex and object3d hierarchies (see this issue) to have only one hierarchy of tiles; probably with a boolean attribute loaded and the content of the tile in a content attribute when it is loaded.
  • [x] Refactor the extensions management:
    • [x] Don't use a global object to register extension (namely $3dTilesExtensions). Use a property of the layer instead (currently with layer.defineLayerProperty, e.g. here but then it must become a property of the 3DTilesLayer class).
    • [x] Register extensions as objects and not parsers (so they can have other methods than parsing).
  • [ ] Implement cache at iTowns level (see issue #1170)

Open questions:

  • Regarding the parsers, we can either:
  • Keep the BatchTableParser and create a FeatureTableParser to be consistent (and maybe regroup these files in a folder).
  • Remove BatchTableParser, create a TileContentParser which groups the common parsing code of the different 3D Tiles format (b3dm, pnts, etc.), such as the parsing of the headers, of the batch table and features tables, etc.

Do you have any inputs on these propositions ?

jailln avatar Jul 01 '19 13:07 jailln

Hello, thank you for your contribution.

Create a class for each object of the spec and put them in src/Core/3DTiles/ . I started working on some of these classes here.

I think we need to get to the heart of the matter and open a PR on the new classes.

gchoqueux avatar Jul 10 '19 09:07 gchoqueux

Yep, I started this work here. I'll open a PR next week.

jailln avatar Jul 10 '19 10:07 jailln

Very good to start next week. I had seen your branch, the future PR will allow you to exchange on your code.

gchoqueux avatar Jul 10 '19 10:07 gchoqueux

The complete 3d-tiles support is planned in the short term road map. We are currently studying possibilities in terms of libraries to enhance support (as mentioned in https://github.com/iTowns/itowns/discussions/1917).

mgermerie avatar Oct 13 '22 12:10 mgermerie