Git Product home page Git Product logo

Comments (7)

liberostelios avatar liberostelios commented on July 19, 2024

Fixed with dbdede9

from ninja.

pizzanapoli avatar pizzanapoli commented on July 19, 2024

Hi @liberostelios,

I am developing a small project for data conversion from a collection of GIS-formats to CityJSON (not really familiar with the web-viewer side, sorry for this) and trying to view a MultiLineString from a CityJSON file in the public online viewer, but until now without success.

I produced a minimum example to see a simple Polyline:

{
 "type": "CityJSON",
 "version": "1.1",
 "CityObjects": {
  "id-01": {
   "type": "+Generic",
   "geometry": [
    {
     "type": "MultiLineString",
     "lod": null,
     "boundaries": [
      [
       0,
       1,
       2,
       3
      ]
     ]
    }
   ]
  }
 },
 "vertices": [
  [
   0.0,
   0.0,
   0.0
  ],
  [
   10.0,
   0.0,
   0.0
  ],
  [
   10.0,
   30.0,
   0.0
  ],
  [
   0.0,
   0.0,
   40.0
  ]
 ],
 "metadata": {
  "geographicalExtent": [
   0.0,
   0.0,
   0.0,
   10.0,
   30.0,
   40.0
  ]
 }
}

Regarding the issue, this should probably work. I'm not sure, if the file maybe not meets the requirements for the renderer?

Thanks in advance for comments!

from ninja.

liberostelios avatar liberostelios commented on July 19, 2024

Hi @pizzanapoli

I am sorry to see that your file doesn't work. Indeed, it seems like the current public version of ninja is not working with your file. I am not entirely sure why that is, as the latest development version seems to be working fine for now.

I'll try to push the latest version as soon as possible so that you have a version that works for your. Since this might still take a little long, I'll try to figure out what's wrong with this example and why it breaks the public version of ninja so that you can probably bypass it.

For sure, though, setting the lod property to null isn't ideal. Not that this is the cause of the issue, though.

from ninja.

pizzanapoli avatar pizzanapoli commented on July 19, 2024

Thanks for considering the issue and for the advice with the lod. I was not aware that the commit which updates the cityjson-threejs-loader was not included in the main branch yet, sorry for that.

After building the version from the develop branch, I was getting the same error. The console output says, there is an undefined attribute c.material.uniforms.selectSurface in the ThreeJsViewer.vue in line 308 (updateScene()) from the submodule project cityjson-vue-components as this is not included to the line object after loading. Anyway, I'm not sure if I built everything right, just followed the instructions from the readme.

Hope that helps a little bit.

from ninja.

liberostelios avatar liberostelios commented on July 19, 2024

Good that you build the whole thing from develop! Sounds like your cityjson-vue-components git submodule isn't at the latest version. Have you made sure that you are at develop in the submodule itself?

Btw, I need to apologise for the mess regarding how I handle dependencies here (like cityjson-vue-components being a submodule and cityjson-threejs-loader being an npm dependency directly linking to GitHub). It's one of the things that have to be sanitized and cleaned up before ninja 1.0! 😬

PS: Super nice that you use links and stuff for your post! 👌

from ninja.

pizzanapoli avatar pizzanapoli commented on July 19, 2024

That suggestion was totally correct, the submodule was not on develop. After changing that, the line is rendered without any problems. So practically the issue could be closed again as the problem occurred only on the main but is clearly solved in the current working state.

Sorry for not being able to contribute as developer for a lack of javascript and vue skills on my side. Thanks for your quick support and the nice work with the viewer, this helps a lot 👍!!

Just for the interest: How is the planning approximately for merging the branches to main and be available on the public url?

from ninja.

liberostelios avatar liberostelios commented on July 19, 2024

Great to hear that it worked!

There is no concrete plan, time-wise, regarding the release of ninja 1.0. But the only thing missing is a slightly better interface to load textures. As I am currently focusing on my PhD thesis writing, the plan is to do it after I am done with the main draft. Probably somewhere between the end of June to end of July.

from ninja.

Related Issues (20)

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.