custom google earth application

118 views
Skip to first unread message

Laoballer

unread,
Aug 7, 2008, 12:45:58 PM8/7/08
to KML Developer Support - Google Earth Browser Plugin
I have the task of creating a stand alone application that uses google
earth as the viewer for displaying properties that will be represented
by points and lines. Eventually I would like to move the lines to 3d
objects. Has anyone created a custom application that does something
similar and if there's a tutorial out there? I'm using visual studio
2005, and will code in C#. I've been in the third party applications
section but from what I'm getting from the discussions, the COM API
isn't supported by google and there are features missing. Frankly I'm
clueless at this point on how to start.

Thanks,

fraser

unread,
Aug 7, 2008, 2:11:08 PM8/7/08
to KML Developer Support - Google Earth Browser Plugin
Hi Laovaller,

Firstly a caveat, I have not tried this and so don't know if it will
work...
Secondly, the application will never be "stand alone" as it will
allways need to connect to Google's servers for the data.

OK, that said you could possibly use the existing webBrowser control
to load the plug-in in to your "stand-alone" application.
In vs2005 it is located in "Common Controls" in the tool box.

The webBrowser control would allow you to point to a local/remote HTML
file that contains the plug-in.
You could then play around with the browser control, and the plug-in,
however you want in your c# app.

This is a good article on working with the webBrowser control in
Visual Studio 2005.
http://www.codeproject.com/KB/recipes/IE7_Clone_VS2005_Browser.aspx

Anyway, as I say, none of this is tested but it may at least give you
a start!

Regards,

Fraser.

p.s. I might have a play with this myself, I will post back here
should I come up with anything...

fraser

unread,
Aug 9, 2008, 6:41:51 PM8/9/08
to KML Developer Support - Google Earth Browser Plugin
Hi,

Ok, I put together 'geApp' a quick proof-of-concept application based
on the points outlined in my last post.
geApp is just a simple application that shows the basics of two-way
communication between the plug-in's DHTML Code and the Client
Application Code

The application allows you to toggle Layers, options and controls in
the plug-in by invoking javascript functions from managed code.
You can also Load KML and KMZ files into the plug-in using the the GUI
in the winForm application.
Finally, the application allows you to view a log of ge 'mousedown'
events.

Rather than going into the c# code here you can read more and download
the complete solution here:
http://fraserchapman.blogspot.com/2008/08/google-earth-plug-in-and-c.html

Hope that gives you some ideas, it's certainly something that has
excited me!

Regards,

Fraser.

On Aug 7, 7:11 pm, fraser wrote:
> Hi Laovaller,
>
> Firstly a caveat, I have not tried this and so don't know if it will
> work...
> Secondly, the application will never be "stand alone" as it will
> allways need to connect to Google's servers for the data.
>
> OK, that said you could possibly use the existing webBrowser control
> to load the plug-in in to your "stand-alone" application.
> In vs2005 it is located in "Common Controls" in the tool box.
>
> The webBrowser control would allow you to point to a local/remote HTML
> file that contains the plug-in.
> You could then play around with the browser control, and the plug-in,
> however you want in your c# app.
>
> This is a good article on working with the webBrowser control in
> Visual Studio 2005.http://www.codeproject.com/KB/recipes/IE7_Clone_VS2005_Browser.aspx
>
> Anyway, as I say, none of this is tested but it may at least give you
> a start!
>
> Regards,
>
> Fraser.
>
> p.s. I might have a play with this myself, I will post back here
> should I come up with anything...
>
> On Aug 7, 5:45 pm, Laoballer wrote:
>
>
>
> > I have the task of creating a stand alone application that uses google
> > earth as the viewer for displaying properties that will be represented
> > by points and lines.  Eventually I would like to move the lines to 3d
> > objects.  Has anyone created a custom application that does something
> > similar and if there's a tutorial out there?  I'm using visual studio
> > 2005, and will code in C#.   I've been in the third party applications
> > section but from what I'm getting from the discussions, the COM API
> > isn't supported by google and there are features missing.  Frankly I'm
> > clueless at this point on how to start.
>
> > Thanks,- Hide quoted text -
>
> - Show quoted text -

Roman N

unread,
Aug 11, 2008, 3:49:01 PM8/11/08
to KML Developer Support - Google Earth Browser Plugin
Fraser,

Great article! This could really help developers seeking more control
over the Earth experience than the COM API can offer.

- Roman

On Aug 9, 3:41 pm, fraser wrote:
> Hi,
>
> Ok, I put together 'geApp' a quick proof-of-concept application based
> on the points outlined in my last post.
> geApp is just a simple application that shows the basics of two-way
> communication between the plug-in's DHTML Code and the Client
> Application Code
>
> The application allows you to toggle Layers, options and controls in
> the plug-in by invoking javascript functions from managed code.
> You can also Load KML and KMZ files into the plug-in using the the GUI
> in the winForm application.
> Finally, the application allows you to view a log of ge 'mousedown'
> events.
>
> Rather than going into the c# code here you can read more and download
> the complete solution here:http://fraserchapman.blogspot.com/2008/08/google-earth-plug-in-and-c....

Laoballer

unread,
Aug 12, 2008, 9:53:34 PM8/12/08
to KML Developer Support - Google Earth Browser Plugin
Wow, thanks for the post, this is a great starting point for me.

Thanks,

On Aug 9, 3:41 pm, fraser wrote:
> Hi,
>
> Ok, I put together 'geApp' a quick proof-of-concept application based
> on the points outlined in my last post.
> geApp is just a simple application that shows the basics of two-way
> communication between the plug-in's DHTML Code and the Client
> Application Code
>
> The application allows you to toggle Layers, options and controls in
> the plug-in by invoking javascript functions from managed code.
> You can also Load KML and KMZ files into the plug-in using the the GUI
> in the winForm application.
> Finally, the application allows you to view a log of ge 'mousedown'
> events.
>
> Rather than going into the c# code here you can read more and download
> the complete solution here:http://fraserchapman.blogspot.com/2008/08/google-earth-plug-in-and-c....

TinyGrasshopper

unread,
Aug 13, 2008, 2:06:52 AM8/13/08
to KML Developer Support - Google Earth Browser Plugin
I hope this isn't going to spoil anyone's party but what's the deal
with licensing for standalone apps like this?

My understanding of the licensing for Maps API keys is that they're
only free if you're page is freely accessible on the web. Does
embedding your page in an application mean that you have to pay for an
enterprise license? or only if your application will not be available
for free on a website? or only if your application is not open source?
or...

Is there a separate license available for application developers that
entitles you to embed it for less than the (quite considerable i
understand) cost of entry for a full Enterprise license?

Cheers,
Chris

TinyGrasshopper

unread,
Aug 13, 2008, 2:09:53 AM8/13/08
to KML Developer Support - Google Earth Browser Plugin
Mmm I guess another way is to allow the user to enter their Enterprise
key into your application so that, as a developer, you pay nothing but
customers must pay for an enterprise key?

TinyGrasshopper

unread,
Aug 13, 2008, 2:22:01 AM8/13/08
to KML Developer Support - Google Earth Browser Plugin
heh what about if your app loads a freely accessible web page but more
functionality is available when the page is displayed in your
application? (hehe bit of devils advocate playing here :) )

fraser

unread,
Aug 13, 2008, 5:52:13 AM8/13/08
to KML Developer Support - Google Earth Browser Plugin
Hi TinyGrasshopper,

I was very careful in going through the terms of service before I set
out putting the example together.
The bit in Google Maps API Terms of Service which is most relevant to
the points you make is section.

1.4 Appropriate Conduct and Prohibited Uses
See: http://code.google.com/apis/maps/terms.html

As the example application connects to a HTML page which is freely
accessible there is no issue.
Also, the solution itself is freely available for anyone for any use.

If you think about it, the sample application I put together is really
just a simple, customised, web browser.

Regards,

Fraser.
> > > > > > - Show quoted text -- Hide quoted text -

TinyGrasshopper

unread,
Aug 13, 2008, 8:48:35 PM8/13/08
to KML Developer Support - Google Earth Browser Plugin
Hi Fraser,

Cheers for the reply - sorry, if it sounded like i was implying that
your sample would breach the license, I was more wondering what the
implications were for the original poster/other people wishing to
embed the plugin in their applications if those applications were sold
commercially.

I guess it seems like there are a lot of ways that a commercial
organisation can have a site which both makes money and complies with
the free license (ads etc) but not a lot of ways that a company could
sell software that includes a page embedding the plugin where the
whole service they offer would be "generally accessible to consumers
without charge".

I can see your point with the customised web browser, but presumably
if you add functions that only work if the page is viewed within your
custom browser and you charge for the browser then that would be
outside the license?

Eg: say ESRI (http://www.esri.com/ ) were to add a button to ArcGIS
that opened a new window (inside their application) that displayed a
view of the current ArcGIS view in Google Earth and then loaded their
data in over the top. Even though the actual page that was displayed
might be available to everyone from their website, you'd only get the
extra data if it was viewed in the embedded browser in ArcGIS. Since
they're charging for at least part of the service they provide then I
guess they would be required to pay for a license?

I would imagine that ESRI can afford to pay for whatever license they
require :) but smaller developers might consider that paying for a
full enterprise license would be prohibitively expensive.

Cheers,
Chris

TinyGrasshopper

unread,
Aug 13, 2008, 9:01:39 PM8/13/08
to KML Developer Support - Google Earth Browser Plugin
Or to give a different (more-ambiguous :) ) example, say you work for
a local town planning office. It might be useful to write a little
drafting tool that let you sketch out, against the satellite backdrop,
areas where trees should be planted and then save them into your GIS
or something. You could put the page on an external website but saving
things to your GIS might only work when the page was viewed via a
custom browser. Would that require a license? Not all of the service
you provide is generally accessible.

On Aug 14, 10:48 am, TinyGrasshopper wrote:
> Hi Fraser,
>
> Cheers for the reply - sorry, if it sounded like i was implying that
> your sample would breach the license, I was more wondering what the
> implications were for the original poster/other people wishing to
> embed the plugin in their applications if those applications were sold
> commercially.
>
> I guess it seems like there are a lot of ways that a commercial
> organisation can have a site which both makes money and complies with
> the free license (ads etc) but not a lot of ways that a company could
> sell software that includes a page embedding the plugin where the
> whole service they offer would be "generally accessible to consumers
> without charge".
>
> I can see your point with the customised web browser, but presumably
> if you add functions that only work if the page is viewed within your
> custom browser and you charge for the browser then that would be
> outside the license?
>
> Eg: say ESRI (http://www.esri.com/) were to add a button to ArcGIS

TinyGrasshopper

unread,
Aug 13, 2008, 9:08:35 PM8/13/08
to KML Developer Support - Google Earth Browser Plugin
Oops, meant to say:

local *government* town planning office

ie: i was going for an organisation that is not profiting from use of
google but never-the-less, by embedding the plugin in an application,
restricts some of the features from general availability.

Laoballer

unread,
Aug 15, 2008, 6:09:00 PM8/15/08
to KML Developer Support - Google Earth Browser Plugin
here's a question, are you breaching the contract if you use the free
google earth version in a professional environment? What about using
the free google earth in a customized application like the one Fraser
put together in a professional environment?

thanks
Reply all
Reply to author
Forward
0 new messages