Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add extensions and extras to 3D Tiles #6490

Closed
lilleyse opened this issue Apr 24, 2018 · 5 comments · Fixed by #6974
Closed

Add extensions and extras to 3D Tiles #6490

lilleyse opened this issue Apr 24, 2018 · 5 comments · Fixed by #6974

Comments

@lilleyse
Copy link
Contributor

CesiumGS/3d-tiles#8 adds extras and extensions properties to the top-level tileset.json, individual tiles, feature table, batch table, and other misc json objects. How do we want to expose this from the API?

To start, we should atleast add an extras getter/setter to Cesium3DTileset and Cesium3DTile.

@pjcozzi
Copy link
Contributor

pjcozzi commented Apr 24, 2018

As discussed offline, let's push this until after spec work unless it is critical to getting the spec right...which I don't think it is in this case given this is just following glTF's lead.

@lilleyse
Copy link
Contributor Author

I agree, the implementation can wait.

@apopiak
Copy link
Contributor

apopiak commented Dec 13, 2018

I would be interested in using extensions. As extras seem to be equally powerful that would be my fallback, but not optimal for building something well-defined.
Use-case: including (just bare-bones) images in 3D-tiles data that are loaded based on the HLOD.

@lilleyse
Copy link
Contributor Author

@apopiak you can start using them now. The extras/extensions API looks like:

tile.extras
tileset.extras
tileset.hasExtension

There isn't a great way to get extension data from the API since it usually needs to be implemented internally. But for your use case you could start by storing image uris in each tile's extras and then listening to the tileset.tileLoad and tileset.tileVisible events where your app would handle the logic for loading and displaying the images.

@apopiak
Copy link
Contributor

apopiak commented Dec 13, 2018 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants