Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 24

Thread: Yet another Cache Builder for Google Earth (Linux/Win/Mac)

  1. #11
    Raw Wave shotgunefx's Avatar
    Join Date
    Apr 2005
    Location
    Boston, MA
    Posts
    1,800
    Quote Originally Posted by Ruffy View Post
    new error. Got both modules installed
    Sorry I didn't see this reply before now, your not passing the command line options as stated in the first post.

    It barks
    Missing or invalid latitude
    because lat is checked first, if you supplied lat and not lon, it would bark about lon. It stops checking errors after the first.

  2. #12
    Low Bitrate eurocarpc's Avatar
    Join Date
    Jun 2006
    Location
    Madrid, Spain
    Posts
    71
    Hi! I'm trying to make it work by setting the variables by hand in the perl file. Besides, I (being a bit stupid) would appreciate if you could explain what exactly means:

    -lon (Northwest in decimal degrees) ex: -72.983889 ?

    -range (Range in meters) ex: 600 ?

    -sleep (Int number of seconds to sleep before moving), default 3 ?

    -hres (Int horiztonal block to resume at) ?

    -vres (Int horiztonal block to resume at) ?

  3. #13
    Raw Wave shotgunefx's Avatar
    Join Date
    Apr 2005
    Location
    Boston, MA
    Posts
    1,800
    Quote Originally Posted by eurocarpc View Post
    Hi! I'm trying to make it work by setting the variables by hand in the perl file. Besides, I (being a bit stupid) would appreciate if you could explain what exactly means:

    -lon (Northwest in decimal degrees) ex: -72.983889 ?

    -range (Range in meters) ex: 600 ?

    -sleep (Int number of seconds to sleep before moving), default 3 ?

    -hres (Int horiztonal block to resume at) ?

    -vres (Int horiztonal block to resume at) ?
    -lon is the longitude, The -lat/-lon pair you specify is the northwest corner of where scanning starts.

    -range is the distance from the ground in meters of the viewpoint (what it's called in GE), the higher up you are, the more you should be able to fit into the cache.

    -sleep is just how long to pause between scanning. If it's too fast for your internet connection, it may move from an area before you've downloaded the map data.

    (-hres,-vres) are for if you get interrupted and want to resume where you left off. As the program is scanning along, it spits out the current lat/lon and (hres,vres) parameters. If you need to stop the program for any reason (it can take a long time to scan larger areas), just jot these two numbers down. Then when you start it up again, specify them on the command line via -hres and -vres and it will pick up from where it left off. Do not specify them at all unless you are resuming.

    Maybe a more detailed explanation of how it works would be helpful.

    The lat/lon specified on the command line indicate the Northwest corner of the area we would like to scan. How large an area to scan is determined by hkm (how far horizontally/East), vkm (how far vertically/South). The reason I set it up so that you only specified the NW coordinate and the area as offsets, was it just easier to handle them that way and I didn't have to worry about people entering them backwards, etc.

    An example run from the command line
    Code:
    ge_cachbuild.pl -lat 42.832778 -lon -72.983889 -range 600 -hkm 15 -vkm 10 -sleep 2
    This is going to start at 42.832778,-72.983889 (Just North of the NW border of Massachusetts) and scan East 15 kilometers and south 10 kilometers, at a range of 600 meters.

    When the program starts, it calculates the Southeast corner by adding hkm and vkm to the Northwest coordinate.

    It then divides that area into a grid of MxN blocks (horizontal distance/range)x(vertical distance/range),

    When scanning starts, it starts off the viewpoint in the KML file in the NE corner, moves horizontal -range meters, then sleeps for -sleep seconds, and keeps repeating this until it has reached the East side.

    Once it does, it resets back to the West side and moves South -range meters and repeats so on and so forth until the entire area is scanned.

    Also, instead of hard-coding the values in the script, you would probably be better off making a batch file that runs the script with the appropriate values.

    Is this helpful?

  4. #14
    Low Bitrate eurocarpc's Avatar
    Join Date
    Jun 2006
    Location
    Madrid, Spain
    Posts
    71
    It was helpful indeed, but:

    I uncompressed the file again, and used it with this parameters:

    ./ge_cachebuild.pl -lat 40.294747 -lon -3.433333 -range 600 -hkm 100 -vkm 100

    Which intends to be a 100x100km area around Madrid.

    And the grid does not overlay on top of the area I intented... It goes SE by a few dozen kms... =(

    Am I doing something wrong?

  5. #15
    Raw Wave shotgunefx's Avatar
    Join Date
    Apr 2005
    Location
    Boston, MA
    Posts
    1,800
    Quote Originally Posted by eurocarpc View Post
    It was helpful indeed, but:

    I uncompressed the file again, and used it with this parameters:

    ./ge_cachebuild.pl -lat 40.294747 -lon -3.433333 -range 600 -hkm 100 -vkm 100

    Which intends to be a 100x100km area around Madrid.

    And the grid does not overlay on top of the area I intented... It goes SE by a few dozen kms... =(

    Am I doing something wrong?
    Is 40.294747,-3.433333 the center of the area you want or the NW corner? It sounds like you are entering the center. If you entered the center instead of the corner, it would put it SE of where you would expect, and with a 100x100km range, a few dozen sounds like 50km off where you would expect.

    An easy way to get the NW position is to go into GE and get it from there or go to google maps and pick it, then click the "Link to this page", the url will then give you the lat/lon.

    Maybe I'll rewrite the options to specify the coordinates by the center (or as a pair NW,SE) as it seems like that will be more intuitive for most.

  6. #16
    Low Bitrate eurocarpc's Avatar
    Join Date
    Jun 2006
    Location
    Madrid, Spain
    Posts
    71
    Quote Originally Posted by shotgunefx View Post
    An easy way to get the NW position is to go into GE and get it from there or go to google maps and pick it, then click the "Link to this page", the url will then give you the lat/lon.
    That worked out OK! =)

    Thanks!

  7. #17
    Low Bitrate eurocarpc's Avatar
    Join Date
    Jun 2006
    Location
    Madrid, Spain
    Posts
    71
    BTW... It would be quite useful if there was some way to calculate how much can you actually store in that 2000MB.

    By thus we could always know how much area can we cache or with how much detail/layers.

  8. #18
    Low Bitrate eurocarpc's Avatar
    Join Date
    Jun 2006
    Location
    Madrid, Spain
    Posts
    71
    Heyaaa!! I've just come to an idea: how about a 'watch -n 1 du -hs .googleearth/' until it gets to 2000MB and stopping/doing something else then?

    I'm doing it right now to monitor how fast it works (about 1MB every ten/twenty seconds, under not very populated areas) =)

    On the other hand, it sometimes gives an unclosed token error if the refresh rate is too high -below 5 secs- specially if under places not even partially cached and with a lot of information to display.

    Is there any way to handle that?

    Oh! And... does it make any difference in terms of caching speed if GE is minimized or not? (Given that my cpu never reaches 100% load, that I've got 2GB RAM and a X1400 Graphics card)

    Well... thanks again!

  9. #19
    Raw Wave shotgunefx's Avatar
    Join Date
    Apr 2005
    Location
    Boston, MA
    Posts
    1,800
    Quote Originally Posted by eurocarpc View Post
    Heyaaa!! I've just come to an idea: how about a 'watch -n 1 du -hs .googleearth/' until it gets to 2000MB and stopping/doing something else then?

    I'm doing it right now to monitor how fast it works (about 1MB every ten/twenty seconds, under not very populated areas) =)

    On the other hand, it sometimes gives an unclosed token error if the refresh rate is too high -below 5 secs- specially if under places not even partially cached and with a lot of information to display.

    Is there any way to handle that?

    Oh! And... does it make any difference in terms of caching speed if GE is minimized or not? (Given that my cpu never reaches 100% load, that I've got 2GB RAM and a X1400 Graphics card)

    Well... thanks again!
    No problem, glad it's working. Good idea on watching the cache.

    Usually, hitting "ignore" will stop prompting after an error. I've tried a few ways around this (but haven't followed up in awhile), but basically what is happening is that it's reading the KML file while it's being written to. Apparently GE doesn't pay attention to file locking.

    This is also a problem with my GE GPS gpsd tracker. One solution I tried was instead of using a file, using a network resource, having the program fork a mini http server, but even then it sometimes glitches, as sometimes it doesn't wait for the response, which is weird as the time we are talking about is a fraction of a second.

    I'll take another look at it soon when I have a bit more time.

  10. #20
    ATF
    ATF is offline
    Newbie ATF's Avatar
    Join Date
    Nov 2006
    Location
    Stamford, CT <-> Boston, MA
    Posts
    11
    Hey guys, I'm running into an issue on Ubuntu 7.10 where it keeps going to 1000 meters (give or take a few meters) when caching. If i stop caching and view the KML, range is set to whatever value I want. It's like Google Earth keeps forcing it to 1 KM, any ideas?

Page 2 of 3 FirstFirst 123 LastLast

Similar Threads

  1. Google Earth Cache Builder
    By njwashor in forum Other Cool Stuff
    Replies: 54
    Last Post: 07-27-2007, 10:54 AM
  2. Drop-down menus don't work? Read this!
    By gnomad in forum Announcements
    Replies: 0
    Last Post: 10-14-2005, 01:15 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •