问题
I need basic guidance on how to control Google Earth using Kinect Hand gestures instead of using mouse/keyboard navigation.
I have ran Kinect Developer toolkit sample, and there is one named interactive gallery in C# that allows panning world map (It's a static image). Here is the link to it's documentation, Kinect interactive gallery
I exactly want to create the same thing but allowing the world globe to be moved,zoom and rotate using hand gestures instead of a simple map image.
Currently I ran Google Earth in WPF application using a google earth plugin and using it via web browser component. here is the code,
public partial class MainWindow : Window
{
public MainWindow()
{
InitializeComponent();
this.Loaded += new RoutedEventHandler(MainWindow_Loaded);
}
void MainWindow_Loaded(object sender, RoutedEventArgs e)
{
string PLUGIN_URL = @"http://earth-api-samples.googlecode.com/svn/trunk/demos/desktop-embedded/pluginhost.html";
Uri url = new Uri(PLUGIN_URL);
this.browser.Navigate(url);
// this.browser.ObjectForScripting = this;
}
}
I have also tried controlling it by controlling mouse cursor using Kinect but it is not providing good user experience.
I would like to add grip gesture to pan the globe. I went through the kinect samples code, the documentation is not very good and I don't know where the grip gesture is being handled and corresponding event is fired.
Here is WorldMap.xaml code that displays world map image:
`<PannableContentModel xmlns="clr-namespace:Microsoft.Samples.Kinect.InteractionGallery.Models;assembly=InteractionGallery-WPF" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<PannableContentModel.ImageUri>
<x:Uri>pack://application:,,,/Content/PannableContentScreen/PannableMapImage.jpg</x:Uri>
</PannableContentModel.ImageUri>
` I would like to display a Google earth globe instead.
Any help will be appreciated!
来源:https://stackoverflow.com/questions/26023232/replace-pannable-world-map-image-by-google-earth-globe-in-kinect-sample