[OpenMap Users] Error: when DTED Layer deman CADRG/LLYY Projection

From: Eliecer Osorio <cursor_at_vtr.net>
Date: Tue, 17 May 2005 00:42:04 -0400

Hi,
I setting in my opnemap.properties the projection
com.bbn.openmap.proj.CADRG, but, when then BasicMapPanel try to load the
DTEDLayer MapHandler claim by Projection.

My temporary solution was change the code: swap order

Origonal Code

    ph.createComponents(getMapHandler());

        // At this point, check the MapHandler to see if a
        // ProjectionFactory has been added. If it hasn't, create one
        // with the default ProjectionLoaders. We might want to
        // remove this at some point, but not having it here will
        // catch some people by suprise when 4.6.1 comes out.
        Object obj = mh.get(com.bbn.openmap.proj.ProjectionFactory.class);
        if (obj == null) {
            Debug.message("basic",
                    "BasicMapPanel adding ProjectionFactory and
projections to MapHandler since there are none to be found.");
            mh.add(ProjectionFactory.loadDefaultProjections());
        }

        // Environment will only get loaded after the property file is
        // read.
        
mb.setProjection(ProjectionFactory.getDefaultProjectionFromEnvironment());
        mb.setBckgrnd(Environment.getCustomBackgroundColor());

My new Code
        // At this point, check the MapHandler to see if a
        // ProjectionFactory has been added. If it hasn't, create one
        // with the default ProjectionLoaders. We might want to
        // remove this at some point, but not having it here will
        // catch some people by suprise when 4.6.1 comes out.
        Object obj = mh.get(com.bbn.openmap.proj.ProjectionFactory.class);
        if (obj == null) {
            Debug.message("basic",
                    "BasicMapPanel adding ProjectionFactory and
projections to MapHandler since there are none to be found.");
            mh.add(ProjectionFactory.loadDefaultProjections());
        }

        // Environment will only get loaded after the property file is
        // read.
        
mb.setProjection(ProjectionFactory.getDefaultProjectionFromEnvironment());
        mb.setBckgrnd(Environment.getCustomBackgroundColor());
       
        ph.createComponents(getMapHandler());

This not claim, but not show DTED.


--
[To unsubscribe to this list send an email to "majdart_at_bbn.com"
with the following text in the BODY of the message "unsubscribe openmap-users"]
Received on Tue May 17 2005 - 00:54:23 EDT

This archive was generated by hypermail 2.3.0 : Tue Mar 28 2017 - 23:25:06 EDT