Select to view content in your preferred language

is there a trick to getting KML layers to render correctly?

2716
9
08-25-2011 12:23 AM
by Anonymous User
Not applicable
Original User: coldfusionPaul

i have several KML files that don't even come close to rendering what i see in google maps/GE (see attached). i can live w/most of it but the big red Xs & the polygons that aren't symbolized at all don't cut it.

is there some trick to formatting/whatever the KML to get it to render "better"?

thanks.
0 Kudos
9 Replies
dcopple
Frequent Contributor
I think there may be bugs with how Flex enders the KML file, and icons from the kml file.  I have had this isssue as well.  I did post a kml widget on the code gallery (may have to search for it) that at least allows you to test your kml to see if it works, but I agree, the renderer of icons is not working correctly.  Hope that improves in later releases, but at least we can add kmls.....
0 Kudos
by Anonymous User
Not applicable
Original User: bjorn

i have several KML files that don't even come close to rendering what i see in google maps/GE


Paul, do you mind sharing some examples of KML files that doesn't render the symbols correctly?  Either a full KML or just a sample with one feature would be helpful 🙂


is there some trick to formatting/whatever the KML to get it to render "better"?

There is no trick on the Flex side. If you have control of the KML you could adjust the actual KML, but if you don't have access to that, your best option is to report the not-properly-rendered KML file.
0 Kudos
PaulHastings1
Deactivated User
let me ask the client if it's ok to send you the files.

in this instance, yes we have control over the exported KML but "adjust" them to what? is there a standard as to what arcGIS can render correctly? as far as "not-properly-rendered KML", they render dandy in GE & google maps.

btw i also think these were exported from arcMap (need to confirm).

thanks.
0 Kudos
by Anonymous User
Not applicable
Original User: coldfusionPaul

Paul, do you mind sharing some examples of KML files that doesn't render the symbols correctly?  Either a full KML or just a sample with one feature would be helpful 🙂


attached, still waiting to see what produced these files.

thanks.
0 Kudos
by Anonymous User
Not applicable
Original User: dcopple

Paul, do you mind sharing some examples of KML files that doesn't render the symbols correctly?  Either a full KML or just a sample with one feature would be helpful 🙂


Bjorn,
Here is a link to a publically posted kml from saved from a lightning data server and posted on my own website.  The Strike icons are tiny.  See screen shots below.  https://sites.google.com/site/firewhirld/don-s-fire-pages/622466_Lightning.kmz
There is no trick on the Flex side. If you have control of the KML you could adjust the actual KML, but if you don't have access to that, your best option is to report the not-properly-rendered KML file.
I don't have contro over this particular kml, I have noticed some simple ones render great, some not at all.  I think some of them may be showing up, but just not renering (some of those from NOAA that I have been trying to load for instance.)  Here is another KML that works, but comes up with a ? in the TOC (much like the others), but the points render fine.  So thought you could use this to check on that error as well.  Here's the link to that kml: http://www.osdpd.noaa.gov/ml/land/fire.kml

Thanks for your work on getting the kml functionality working, I think this is a huge step in the right direction for sharing geographic information accross platforms, on one more note, is there a way to get a popup to work on a kml that is generated by an ArcGIS web service, and notice those kml's produced by a server are not actual points, polygons, etc, but image overlays.  A big future enhancement to the ArcGIS server would be to actually render kml polys, points, etc.

Keep up the good work, and hope to get a reply on the current issues.
0 Kudos
PaulHastings1
Deactivated User
see kirk's post
0 Kudos
by Anonymous User
Not applicable
Original User: kmower

Just to clarify - those KML files were created with the XTools Pro extension for ArcMap
0 Kudos
BjornSvensson
Esri Regular Contributor
attached


Paul, are all of those failing for you?  When I try them, all except for one seem to work just fine.  The one that breaks have the icon specified to an image which when I try it on my machine, it can't find the images and thus shows the default icon.  Maybe even on your server, it cant find the image and thus displays the default missing-icon image?

For example, in the Rail_Construction_Camps_Points.kml it is referring a local icon:
<Icon><href>camp.png</href></Icon>
0 Kudos
by Anonymous User
Not applicable
Original User: coldfusionPaul

Paul, are all of those failing for you?  When I try them, all except for one seem to work just fine.  The one that breaks have the icon specified to an image which when I try it on my machine, it can't find the images and thus shows the default icon.  Maybe even on your server, it cant find the image and thus displays the default missing-icon image?

For example, in the Rail_Construction_Camps_Points.kml it is referring a local icon:
<Icon><href>camp.png</href></Icon>


can you post a screen capture & the code you used? do these KML look anything like the 2nd image i posted above?

sorry yes i forgot those icons, but just substitute any png file. i've tried "local" to the KML file & "local" to the flex app location. none worked & resulted in the 1st image i posted above.

thanks.
0 Kudos