Announcement

Collapse
No announcement yet.

New OSM Buildings layer and how to deploy it

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    Hello sbodmer,
    Looks like we (I?) have crashed the osm buildings server because .org link does not show up buildings any more...From client side, i think there should be some calls to setMaxActiveAltitude () or so, in order not to load buildings from the moon...
    ​​Also i've seen a isLayerInView () that always return true, that means the building server is always triggered even if we are in the middle of the desert...
    Another problem is that even with the server down, the renderable should be created with the previous json dowloaded on disk, and it is not...right?
    Last edited by frenchy; 02-09-2017, 06:56 PM.

    Comment


    • #17
      Hi frenchy,

      Well, I've set the MaxActiveAltitude to 8000m by default (cf config/Earth/OSMBuildings.xml).
      For why the inLayerInView() always returning true, it's because there "could" always be buildings in the viewport,..
      My code loads the tiles via WW provided HTTPRetreiver, so the cache is used (I think...my implementation check on local storage first before starting the online request). I hard coded the max limit to 7 day to keep in local cache.

      If you create the OSMBuildings layer manually, check the config file for value to be set as default.
      Last edited by sbodmer; 02-13-2017, 07:16 PM.

      Comment


      • #18
        Hemm... normally if you use an .xml file (i didn't see it), you don't have to implement a .java Layer file... But as we say in French "Abondance de biens ne nuit pas" :-)
        BTW, i can't see buildings anymore, looks like I'm banned (Error HTTP 401 - Unauthorized access). I don't get the previously dowloaded buildings either, I'll check that.
        One kind of optimization could be the test of the central altitude (in case of <0, we're in the sea, so no buildings...:-)
        Cheers

        Comment


        • #19
          Hi frenchy,

          Can you explain a bit the part where you say if we use an .xml no .java layer is needed, what do you mean by that ?
          If I understand correctly the WW framework (which I'm not so sure... because "la doc n'est pas terriblement claire..."), if you use "default" WW layers (like WMS, or TileServer) you just need to define a .xml file with the needed settings (because the layer is already implemented by the framework), but I any other case (complete new layer) you have to implement your own AbstractLayer...

          Sorry for the banned IP, can you check your cache files (/WorldWindData/Earth/OSMBuildings) if there are some data in it ?

          I'v changed the expire date to 1 year, so the next time you can download the buildings, it should stay for a while

          Comment


          • #20
            Ohoh... There is something wrong here :
            Code:
            setExpiryTime(365 * 24 * 60 * 1000);
            There is a missing *60 for seconds... Furthermore, it should be long ints not to overflow, so it would be better like :
            Code:
            setExpiryTime(365L * 24L * 60L * 60L * 1000L);
            This caused within the date comparison the deletion of (some of) the tiles I dowloaded... No big deal, the problem is that i still can't see any tiles/buildings anyway...
            Would it be possible for you to debug by just unplug your internet connection ?
            About your first question, for example there is a 'BingImagery.xml' but no 'BingImageryLayer.java' in the source, because of internal mechanisms, like you said. I thought you were more in the 'from scratch layer' mechanism.

            Comment


            • #21
              Thanks frenchy, I fixed my code.

              I tried wthout online connection, the local buildings are indeed loaded correctly...

              Comment


              • #22
                Okay... Thanks, I'll debug more, as soon as I can, Maybe I missed something when I took your sources.
                "Bonne soirée" in Genova !

                Comment


                • #23
                  Okay I got it working, it was the xml i didn't use and contained the NetworkRetrieval parameter which was not set for me I guess.
                  I can now see tiles and buildings remaining above Paris and other cities. Thanks again !
                  BTW, there is sometimes a message (i had also before ) :
                  Code:
                  Exception in thread "Running World Wind Task 16597x11273@15" java.lang.IllegalArgumentException: Invalid event 2.345883
                      at gov.nasa.worldwind.formats.geojson.GeoJSONCoordinateParser.parseComplexArray(GeoJSONCoordinateParser.java:167)
                      at gov.nasa.worldwind.formats.geojson.GeoJSONCoordinateParser.parseArrayOfArrays(GeoJSONCoordinateParser.java:234)
                      at gov.nasa.worldwind.formats.geojson.GeoJSONCoordinateParser.parseComplexArray(GeoJSONCoordinateParser.java:176)
                      at gov.nasa.worldwind.formats.geojson.GeoJSONCoordinateParser.parseArray(GeoJSONCoordinateParser.java:49)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parse(BasicJSONEventParser.java:44)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parseComplexContent(BasicJSONEventParser.java:195)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parseObjectField(BasicJSONEventParser.java:112)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parseObject(BasicJSONEventParser.java:90)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parse(BasicJSONEventParser.java:41)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parseComplexContent(BasicJSONEventParser.java:195)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parseObjectField(BasicJSONEventParser.java:112)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parseObject(BasicJSONEventParser.java:90)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parse(BasicJSONEventParser.java:41)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parseComplexContent(BasicJSONEventParser.java:195)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parseArrayEntry(BasicJSONEventParser.java:164)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parseArray(BasicJSONEventParser.java:156)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parse(BasicJSONEventParser.java:44)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parseComplexContent(BasicJSONEventParser.java:195)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parseObjectField(BasicJSONEventParser.java:112)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parseObject(BasicJSONEventParser.java:90)
                      at gov.nasa.worldwind.formats.json.BasicJSONEventParser.parse(BasicJSONEventParser.java:41)
                      at gov.nasa.worldwind.formats.json.JSONDoc.parse(JSONDoc.java:79)
                      at gov.nasa.worldwind.layers.Earth.OSMBuildingsTile.run(OSMBuildingsTile.java:196)
                      at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
                      at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
                      at java.lang.Thread.run(Unknown Source)
                  It looks like a coordinate gets into an event name ?
                  Do you observe this also ?
                  Thanks

                  Comment


                  • #24
                    Hello, me again,
                    Just a few more colors added to the static block, (surfing above London) making it :
                    Code:
                    static {
                            COLORS.put("lightbrown", "#ac6b25");
                            COLORS.put("yellowbrown", "#bb9613");
                            COLORS.put("darkbrown", "#654321");
                            COLORS.put("redbrown", "#a52a2a");
                            COLORS.put("firered", "#825252");
                            COLORS.put("cream", "#ffffcc");
                            COLORS.put("brickred", "#cb4154");
                            COLORS.put("bluegreen", "#0d98ba");
                        }
                    http://www.colorhexa.com looks like a good website for getting hexa value from string name.
                    Cheers

                    Comment


                    • #25
                      Hi frenchy,

                      For the exception, sometimes I got some too (don't know if it's the same as yours), it seems that the data source (json) is sometimes wrong (wrong syntaxe, structures, corrupted...).
                      We have to check the datasource and NASA GeoJson implementation to understand what exactly is going on.
                      Last edited by sbodmer; 02-27-2017, 08:15 PM.

                      Comment


                      • #26
                        Hello everyone,

                        I'm happy to see your efforts and thank you for using OSM Buildings.
                        You could have been in touch earlier, frenchy just pointed me here.

                        In order to avoid rate limitations, you might want to use a dedicated api key. Just let me know.
                        Email preferred as I might not be able to follow here at all times.

                        I could also provide you with option to fetch per bounding box rather than map tiles.

                        Again, nice work!

                        Comment


                        • #27
                          Hello Jan,
                          Can you explain a few things to us, according to your knowledge in OSMBuildings :
                          1/ What are colors like "red;white" ? Is it for two-slopes roofs ?
                          2/ What are colors "multiple" ?
                          3/ Do you (or whoever) plan to achieve complex buildings (not cylindrical pieces), like Eiffel Tower, Liberty Tower... Big tower in Dubai is great!
                          Thanks
                          As you're registered you should have a mail alert
                          --frenchy

                          Comment


                          • #28
                            Hi OSMBuildings (Jan M. I suppose)

                            Sure, I'm interested to fetch data with bounding box instead of tile (so that I can match bing tiles border to use their aerial photo to texture the roofs ;^) ).
                            I'm also interested for an api key, but as I call your tile server directly (without javascript) I'm not sure how you will provide an api key...

                            My reference page for your project is actually the server side page
                            https://github.com/OSMBuildings/OSMB...docs/server.md
                            Can you complete this page with the documentation for calling your bounding box api, and how to get an api key for direct calls ?

                            BTW, in your doc, you specify that the server code is not public, do you have a plan to release it as open source in the (near) futur ?
                            (I'm also interested to host a new copy of your server).

                            For other questions about OSMBuildings, do you have a developers oriented forums ?

                            So, thanks for your service at OSMBuldings, I like it very much and is the easiest implementation that I've found

                            Keep going folks...
                            Last edited by sbodmer; 03-08-2017, 08:25 PM.

                            Comment


                            • #29
                              Originally posted by frenchy View Post
                              1/ What are colors like "red;white" ? Is it for two-slopes roofs ?
                              2/ What are colors "multiple" ?
                              3/ Do you (or whoever) plan to achieve complex buildings (not cylindrical pieces), like Eiffel Tower, Liberty Tower... Big tower in Dubai is great!
                              1. I really can't tell about intentions of the mapper.
                              2. Same here. Most likely something far beyond just a few enumerable colors.
                              3. Yes. In case you got some yourself you can add them already. We also intend to create an open 3d map object repository with support of German OSM community.
                              Any ideas are welcome!

                              Comment


                              • #30
                                Originally posted by sbodmer View Post
                                Hi OSMBuildings (Jan M. I suppose)

                                Sure, I'm interested to fetch data with bounding box instead of tile (so that I can match bing tiles border to use their aerial photo to texture the roofs ;^) ).
                                I'm also interested for an api key, but as I call your tile server directly (without javascript) I'm not sure how you will provide an api key...
                                Hi,

                                The key process is created for business customers at the moment. However, We're glad to support community projects.
                                Condition is a moderate and non-commercial usage of the API.
                                Please PM/email me for further details.

                                Originally posted by sbodmer View Post
                                BTW, in your doc, you specify that the server code is not public, do you have a plan to release it as open source in the (near) futur ?
                                (I'm also interested to host a new copy of your server).
                                It's not planned as of now. We are supporting community anyway and it turned out a donation based model will not keep the project running.

                                Originally posted by sbodmer View Post
                                For other questions about OSMBuildings, do you have a developers oriented forums ?
                                There is no forums but we are best reachable via Twitter OSMBuildings or GitHub issues https://github.com/OSMBuildings/OSMBuildings

                                Cheers,
                                Jan

                                Comment

                                Working...
                                X