sketchucation logo sketchucation
    • 登入
    ℹ️ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info

    [Plugin] KML Tools (2.0.0-beta) — updated 31.05.2013

    已排程 已置頂 已鎖定 已移動 Plugins
    137 貼文 49 Posters 124.4k 瀏覽 49 Watching
    正在載入更多貼文
    • 從舊到新
    • 從新到舊
    • 最多點贊
    回覆
    • 在新貼文中回覆
    登入後回覆
    此主題已被刪除。只有擁有主題管理權限的使用者可以查看。
    • M 離線
      marktonium
      最後由 編輯

      Looks like that part of the script is working now (I re-downloaded the files, maybe they were/are corrupted for me).

      I am getting the following error now, though:

      no JSON returned (which I'm expecting)
      Error: #<NoMethodError: undefined method []' for nil:NilClass> ...kmlTools/kmlImport.rb:737:in points_to_plane'
      ...kmlTools/kmlImport.rb:737:in each' ...kmlTools/kmlImport.rb:737:in points_to_plane'
      ...kmlTools/kmlImport.rb:320:in polygon' ...kmlTools/kmlImport.rb:205:in run2'
      ...kmlTools/kmlImport.rb:205:in eachp' ...kmlTools/kmlImport.rb:632:in each_with_index'
      ...kmlTools/kmlImport.rb:632:in each' ...kmlTools/kmlImport.rb:632:in each_with_index'
      ...kmlTools/kmlImport.rb:632:in each' ...kmlTools/kmlImport.rb:205:in run2'
      ...kmlTools/kmlImport.rb:176:in each' ...kmlTools/kmlImport.rb:176:in run2'
      ...kmlTools/kmlImport.rb:114:in fetch_alt' ...kmlTools/kmlImport.rb:109:in call'

      Thanks again.

      Mark

      1 條回覆 最後回覆 回覆 引用 0
      • A 離線
        Aerilius
        最後由 編輯

        @marktonium said:

        I am getting the following error now, though:

        Hi Mark,
        I have fixed something that could have caused this error in line 737. After reading the kml file, the plugin could have come across some unexpected (empty) elements. Can you check if it works now?

        1 條回覆 最後回覆 回覆 引用 0
        • A 離線
          Aerilius
          最後由 編輯

          @3dworks said:

          is this working with SU version 8 on mac or is there another solution in the meantime?

          Hi 3dworks,
          It is not yet tested on mac, but it shouldn't contain anything specific that doesn't work on both platforms.

          @3dworks said:

          [...] the ability to batch capture a sequence of aligned terrains.

          That's probably not in the scope of this plugin, but it's a question that many people ask. Technically it is not possible to do the batch part automatically (because one had to interfere with the Add location tool in a way that is impossible), but one could imagine a tool that helps to perfectly align the selection rectangle to the previous terrain.

          1 條回覆 最後回覆 回覆 引用 0
          • C 離線
            ccreynol
            最後由 編輯

            It is hanging up on the "importing styles" when I try to import a Google Earth made .kml file, any thoughts? Your previous tool worked fine to import a simple ground tracing from a Google Earth .kmz file, is this new tool any improvement for this simple function? Thanks!

            1 條回覆 最後回覆 回覆 引用 0
            • A 離線
              Aerilius
              最後由 編輯

              Hi,
              the importing will probably be the problematic part of KML Tools because there is no simple and clean way in ruby to parse xml files and because kml files can occur in many different kinds.
              If you open the ruby console before starting the import, can you send me the error message (first lines of the error)? Or you can pm me the kml file so that it's easier to find the cause of the problem.

              If you refer to the KML linestring importer, this tool here is not limited to only "linestrings" but it's also ways more complex. So the simple tool is not a bad choice if it does the job sufficiently.

              1 條回覆 最後回覆 回覆 引用 0
              • C 離線
                ccreynol
                最後由 編輯

                Why does this not work on international locations? My shapes are imported at strange sizes, occasionally with angles changed as well. Thoughts?

                1 條回覆 最後回覆 回覆 引用 0
                • GaieusG 離線
                  Gaieus
                  最後由 編輯

                  What do you mean by "internationallocations"? (Are there "nationallocations"? 😕 )

                  Gai...

                  1 條回覆 最後回覆 回覆 引用 0
                  • thomthomT 離線
                    thomthom
                    最後由 編輯

                    I've been looking around at the various ruby based importers for SketchUp and I see that no one uses the Importer class. If this class is used the importer can be found in the native import list which would be very nice.
                    http://code.google.com/apis/sketchup/docs/ourdoc/importer.html

                    Thomas Thomassen — SketchUp Monkey & Coding addict
                    List of my plugins and link to the CookieWare fund

                    1 條回覆 最後回覆 回覆 引用 0
                    • A 離線
                      Aerilius
                      最後由 編輯

                      @ccreynol said:

                      My shapes are imported at strange sizes, occasionally with angles changed as well. Thoughts?

                      If you can tell me more details and send me an example file that does not work as expected, I can have a look at it. SketchUp documents can only cover an area of some kilometers, so one shouldn't import too distant places, otherwise SketchUp behaves very weird (navigation won't work properly, clipping occurs and shapes can look strange).

                      1 條回覆 最後回覆 回覆 引用 0
                      • A 離線
                        Aerilius
                        最後由 編輯

                        @thomthom said:

                        Importer class

                        I had looked at it, but since no other plugin used it I had thought users would expect to find the importer in the Plugins menu. In general I like the idea of using existing standards, so I will add this in the next update. Especially that the Importer class also allows options dialogs ( Importer.do_options) sounds promissing.

                        1 條回覆 最後回覆 回覆 引用 0
                        • thomthomT 離線
                          thomthom
                          最後由 編輯

                          I think the reason why no-one else has used it is because it's simply over-looked. Which is a pity as it'd help clean up the menus and integrates the ruby importers with the native ones.

                          (I kind of spammed the forum of the importers I could find... 😳 😄 .. in an attempt to bring focus to this unused class. )

                          Thomas Thomassen — SketchUp Monkey & Coding addict
                          List of my plugins and link to the CookieWare fund

                          1 條回覆 最後回覆 回覆 引用 0
                          • J 離線
                            Jim
                            最後由 編輯

                            But there isn't a corresponding exporter class. So if you did use the Importer class, the exporter would still need to go in the standard menus which would make the UI inconsistent.

                            Hi

                            1 條回覆 最後回覆 回覆 引用 0
                            • thomthomT 離線
                              thomthom
                              最後由 編輯

                              @jim said:

                              But there isn't a corresponding exporter class. So if you did use the Importer class, the exporter would still need to go in the standard menus which would make the UI inconsistent.

                              True, this would do well as a feature request.

                              Thomas Thomassen — SketchUp Monkey & Coding addict
                              List of my plugins and link to the CookieWare fund

                              1 條回覆 最後回覆 回覆 引用 0
                              • L 離線
                                lbatt3
                                最後由 編輯

                                I'm new to SU, and this is completely awesome, exactly what I've been looking for.

                                BUT, installed it, and it worked great once to bring in a KML line (GPS "track" from Garmin opened in Google Earth and saved as KML). Also brings in KML points (GPS waypoints) no problem. But then I go to download another line KML and no luck at all. I tried removing and re-downloading/unzipping, still no luck.

                                I'm on Windows XP using FireFox, if that matters.

                                1 條回覆 最後回覆 回覆 引用 0
                                • A 離線
                                  Aerilius
                                  最後由 編輯

                                  Hi,
                                  can you give me a link to that file?

                                  A possibility is that the lines are in a "network link" in the KML file. Then Google Earth loads them from the internet (so the lines are not in the file). The importer plugin cannot download network links.

                                  1 條回覆 最後回覆 回覆 引用 0
                                  • L 離線
                                    lbatt3
                                    最後由 編輯

                                    @aerilius said:

                                    Hi,
                                    can you give me a link to that file?

                                    A possibility is that the lines are in a "network link" in the KML file. Then Google Earth loads them from the internet (so the lines are not in the file). The importer plugin cannot download network links.

                                    Here is a link to one of the KML files I had trouble with:

                                    Link Preview Image
                                    Dropbox - 404

                                    favicon

                                    (dl.dropbox.com)

                                    I did find a fix - tracing the track as a regular line in GE, then exporting. These imported just fine. So I guess it's the original track files from GPS that the plugin has trouble with. GE is loading them from the MapSource software I have which holds the Garmin/GPS data. Would they still be a network link? just odd that it worked for the first one, then not after that.

                                    Thanks again for your time creating this plugin. Can't tell you how valuable it will be in creating site layouts (we do horse farm planning).

                                    1 條回覆 最後回覆 回覆 引用 0
                                    • B 離線
                                      burgemj
                                      最後由 編輯

                                      @pixero said:

                                      I have the same problem as lexmonteiro (above).
                                      IE 8 Windows 7 64bit. SketchUp 8 Pro.

                                      I also have the same problem as lexmonteiro with regards to the fetching elevation data and am running the same setup as Pixero. I believe lexmonteiro was running an older version of IE that solved his problem. Pixero and I are not, however. Has this issue been resolved and I'm just missing it somewhere?

                                      1 條回覆 最後回覆 回覆 引用 0
                                      • A 離線
                                        asteinberger
                                        最後由 編輯

                                        I'm having an issue which I don't think anyone else has mentioned yet. I'm trying to import extruded building footprints into Sketchup. The terrain on which they are supposed to sit is quite hilly, and what I've noticed is that when the kml files are imported, they seem to pitch in such a way that they are perpendicular to whatever slope they sit on.

                                        http://i.imgur.com/Z6VO4.jpg

                                        The kml files themselves look fine, it's when they get imported into sketchup that the problem occurs. Any ideas???


                                        Source KML

                                        1 條回覆 最後回覆 回覆 引用 0
                                        • A 離線
                                          Aerilius
                                          最後由 編輯

                                          I found the reason and solved it. There was something not clear in the kml documentation. While not-extruded polygons relative to ground follow the terrain, extruded polygons don't.

                                          1 條回覆 最後回覆 回覆 引用 0
                                          • A 離線
                                            asteinberger
                                            最後由 編輯

                                            @aerilius said:

                                            I found the reason and solved it. There was something not clear in the kml documentation. While not-extruded polygons relative to ground follow the terrain, extruded polygons don't.

                                            awesome! works perfectly now! I owe you a beer.

                                            1 條回覆 最後回覆 回覆 引用 0
                                            • 1
                                            • 2
                                            • 3
                                            • 4
                                            • 5
                                            • 6
                                            • 7
                                            • 5 / 7
                                            • 第一個貼文
                                              最後的貼文
                                            Buy SketchPlus
                                            Buy SUbD
                                            Buy WrapR
                                            Buy eBook
                                            Buy Modelur
                                            Buy Vertex Tools
                                            Buy SketchCuisine
                                            Buy FormFonts

                                            Advertisement