Code Monkey home page Code Monkey logo

py3dtiles_merger's Introduction

py3dtiles_merger

Disclaimer:

This project is under active development and has been created to generate data as fast as possible at Jakarto (rush time). It doesn't cover either unit test, well-written documentation, or a sufficient level of abstraction to be used in different contexts. However, I will be more than happy to remove this disclaimer when improvements will be done. Feel free to open an issue to help the project.

A tool to merge independant 3dtiles to ease visualization of big 3d data on Cesium or Itowns.

The 3dtiles must have been generated in the same format than py3dtiles output (branch lasTo3dtiles until it's merged).

py3dtiles_merger generate a tileset.json file which points to some tileset.json children respecting the 3dtiles external tilesets referencing specification.

py3dtiles_merger schema

Installation

  • Local installation (recommended until the project support pypi integration)
git clone https://github.com/Tofull/py3dtiles_merger
cd py3dtiles_merger
pip install .

Usage

To merge <child_paths>/tileset.json into one global tileset.json, use:

# On windows
py3dtiles_merger.exe -v -r D:/data_py3dtiles/output_merged

What's next ? ############

Once you have generated the global tileset.json, you can expose it over the Internet with any http server, like :

# using https://www.npmjs.com/package/http-server
npm install http-server -g
http-server D:/data_py3dtiles/output_merged --cors -p 8080

Then, your tileset is available over the Internet, and you can visualize it using 3d viewer, for example Cesium sandcastle :

  1. Go to https://cesiumjs.org/Cesium/Build/Apps/Sandcastle/index.html
  2. Insert the following code on Javascript Code section :

    var viewer = new Cesium.Viewer('cesiumContainer');
    var tileset = viewer.scene.primitives.add(new Cesium.Cesium3DTileset({
        url : 'http://127.0.0.1:8080/tileset.json'
    }));
  3. Click Run (or F8) and enjoy.

    Example on cesium

Contribution

Contributions are welcome. Feel free to open an issue for a question, a remark, a typo, a bugfix or a wanted feature.

Licence

Copyright © 2018 Loïc Messal (@Tofull) and contributors

Distributed under the MIT Licence.

py3dtiles_merger's People

Contributors

tofull avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

py3dtiles_merger's Issues

Handle 3dtiles without optional transform attribute

This is a reported issue.

I am trying to merge 2 files:

image002
image004

And

image006

These 3D Tiles were created in FME.
When I try to run your code, there are errors:

image008

If you find the time to look at this, what am I doing wrong?

The issue after merging 3dtiles

Hello, I would like to ask how to solve the problem of merging two 3DTiles data and loading them in Cesium. However, there is clearly a gap in the merged 3DTiles. Have you ever encountered this problem?
image

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.