0

I'm trying to find a way of creating regions for 3D models. It seems simple enough but there doesn't appear to be any examples of KML anywhere. The closest I've found is in the Keyhole Markup Language Guide where there is an example of 'Region for a 3D Model' which is perfect for displaying one 3D model. As you zoom in on it and as view criteria are met, the model displays in Google Earth. This is it here:

https://developers.google.com/kml/documentation/regions#example-2-region-for-a-3d-model

I've got this kml to work perfectly on one of my 3D models. But I need to group dozens of them in one region so they all 'appear' in the same manner as the single model.

The models are arranged in folders so it's simply a matter of finding a script or a program that will read all the coordinates of the different models in a folder and then display them like the single model.

My biggest problem is that I'm by no means a kml expert, programmer or anything else vaguely qualified to write a script to automate the process across many 3D models. I'm a copy and paste, trial and error kind of person. That's why I've been trying to find a sample kml somewhere on the web that I can adapt.

I'm creating this Google Earth map as a volunteer for a new museum project underway in Vanuatu. We can't afford to get people to do this for us so I offer to help in any way I can. So if you know of of any scripts I can modify or adapt, or a program that could do this for me, I'd be most grateful if you would pass the details on.

0

If you want them all to appear/disappear together, then it's easiest to group them all (or their folders) into a single top-level folder, and apply one Region to that. You'll want to pick a region bounding box that includes all of your models, and choose the minLod & maxLod so that they appear/disappear when you want. If you try this and need more help, maybe share your KML or a sample we can look at.

If, on the other hand, you want the models to appear separately, then you will need to apply a unique Region to each model or its folder.

  • Thanks for answering my issue. That's exactly what I did. They were all put into one folder. I then ran GE Regionate on the folder. The output came back with minLod & maxLod settings that are all the same for every building. But when you open the kml in GE they open in a staggered way adding maybe 20 buildings at a time when you zoom in further. It just doesn't make sense. If they've all got the same minLod & maxLod settings they should appear at the same time. I must be missing something here. – Broken Wings May 15 at 0:30
  • By the way, as much as I would love to share my kml with you, I've just discovered that when I share a kml/kmz file that i export out of GE, they either fail to load at all or crash the program on other computers. Shared Placemarks and overlays work fine, but kml's containing these 3D buildings will not load. This is driving me nuts. – Broken Wings May 15 at 0:34
  • Another update. If I share the entire My Places kml and open that on another computer everything opens - slowly mind you as there are so many 3D files to open. But at least GE doesn't crash. – Broken Wings May 15 at 1:21
0

Since we last spoke I've been trying all sorts of things. In the end I deleted all the Regionated files that I created as they just weren't working and I think they were crashing GE. I then manually created all the regions and for a while there, everything was working fine - it was great in fact. I still had issues with the area called 'Hospital No 6' and I think that was why it was crashing. I still don't know what was causing it. So I recreated those 3D files and as of last night they were working perfectly. Then today for some inexplicable reason, none of the 3D models would load. I've tried moving them from the server they were originally on to my Google Drive with no luck. I tried linking some of them directly from my desktop and still they wouldn't open. I just checked one area to open and again nothing. Which says to me that there's something about the files generated by SketchUp that Google Earth doesn't like? But why work for a week or two then suddenly stop? What's even more annoying is that you can't contact anyone at Google for assistance. But taking on your suggestion, below is a link to the entire project. If you open it, you'll see everything loads except the 3D files. And you can turn off the roads layer, it's only there to help people with directions.

https://drive.google.com/file/d/16kc3VXenClzy6bM9DCBCbHB3GZie0Vpy/view?usp=sharing

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.