Hi Mike,
thanks for your answer. Meanwhile I found a good solution by myself.
I'm now using the Google Earth extensions library for this, which
meanwile has some very nice functions.
For those, who will need that in future, here is a sample: Suppose,
"beacons" is an array of placemarkers, holding a point each. Then the
following does the job:
1) Get the extension library and instantiate it
<script type="text/javascript" src="extensions-0.2.1.pack.js"></
script>
2) Create an object of the extension (ge is your GE instance)
var gex = new GEarthExtensions(ge);
3) Here is the "best fitting view" procedure
var bounds = new geo.Bounds();
for (var i = 0; i < beacons.length; i++) {
var p = beacons[i].getGeometry();
bounds.extend(new geo.Point(p.getLatitude(), p.getLongitude()));
}
var view = gex.view.createBoundsView(bounds, { aspectRatio: 1.0 });
view.setTilt(60);
ge.getView().setAbstractView(view)
HTH
Regards
On 10 Aug., 12:14, Mike Williams <[email protected]> wrote:
> The method described athttp://econym.org.uk/gmap/basic14.htmshould
> work just as well for the Earth maptype.
>
> --
> Mike Williams
--
You received this message because you are subscribed to the Google Groups
"Google Maps API" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-maps-api?hl=en.