Results 1 to 3 of 3

Thread: Need help loading saved layers

  1. #1

    Default Need help loading saved layers

    I'm loading two shape files;
    one has 40 polygons,
    one has 3000 polygons.

    I'm want to group them once loaded and save the groupings and would like to avoid the long processing times to convert the shape files to layers.

    My problem is my attempts to recall the saved layers keep blowing up world wind.

    Tried Serializable/ObjectOutputStream, got (PreRenderable) renderable cast fail (I think).
    Tried XStream, got JVM crash, EXCEPTION_ACCESS_VIOLATION

    Anyone have experience saving/loading layers?

  2. #2

    Default

    I was able to get an ArrayList<LatLon> from the layers created by the shape files. I store these Lists in a custom Class for organization purposes. My main thread has a variable customClasses of type ArrayList<CustomClass> which I can save to file with ObjectOutputStream.writeObject(customCla sses) and load back in with readObject().
    I had to make LatLon and Angle implement Serializable to pull it off which I'm not happy about but it hasn't given me any problems yet.

    The whole process takes longer and chews a lot more heap memory do to the complexity and number of my polygons.

    So if anyone knows how to save a Layer or a non Serializable Object I'd appreciate the help.

  3. #3
    Super Moderator
    Join Date
    Nov 2006
    Location
    Mojave & Oxnard California
    Posts
    2,783

    Default

    Maybe take some of the work off of the GPU and run the data into a buffer then just redraw the buffer.

    3000 polygons is pushing the limit to work efficiently.

    Do a search for optimize and you may find another way to try.
    To get something to work is fairly easy.
    Optimizing and error handling is a bit more of a challenge.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Rendering top WMS layers
    By jas511 in forum Development Help
    Replies: 17
    Last Post: 01-19-2012, 02:23 AM
  2. WW1.3.2-Plugin: Layer Edit
    By canosso in forum Add-ons & Scripts
    Replies: 21
    Last Post: 02-27-2010, 04:37 AM
  3. MODIS historical image layers plugin
    By withak in forum Add-ons & Scripts
    Replies: 12
    Last Post: 05-11-2009, 08:39 PM
  4. How to determine ordering of layers
    By naql in forum Development Help
    Replies: 1
    Last Post: 11-18-2008, 02:40 AM
  5. The New Zealand Layers: The LINZ Data as Layers
    By canosso in forum Add-ons & Scripts
    Replies: 8
    Last Post: 04-25-2005, 02:03 AM

Tags for this Thread

Posting Permissions

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