Showing posts with label QTVR. Show all posts
Showing posts with label QTVR. Show all posts

Thursday, 20 September 2007

GE Object Movie Snapper

Update: The GEAirlines plugin and Vista don't seem to like eachother, so it looks like XP only.

I've uploaded the web page utility I use to make QTVR and Flash object movies from Google Earth. The GE Object Movie Snapper automates the process of grabbing a set of still images suitable for compiling into an object movie.

There are still a few enhancements I want to make to this, such as giving some feedback of progress. There also seems to be an issue with the eye altitude jumping about with terrain height on some movies. For a future version I want to include the ability to look outwards and grab images for 360° panoramas.

Before it can be used you will need:

Note: The page works with IE7 and FF2. Opera doesn't like the plugin and Safari doesn't like the javascript.

At the bottom of the page are a number of input boxes. You can set the parameters in any order, but I find the following sequence works well:

First set the root filename for the image set. Images are saved in the form 'filename_<row>_<col>.bmp', where <row> and <col> are the row and column numbers of the image, counting from zero.

Navigate to the desired location and click 'Get Position' to load the latitude, longitude and range. These parameters can be set manually if desired.

If a full azimuth object movie is needed leave the Minimum and Maximum Azimuth settings as they are, otherwise set them as desired. Buttons are provided for each to grab the current view.

Set the number of Azimuth steps. The default of 24 results in full azimuth object movie stills taken at 15° intervals.

Set the Top and Bottom Elevation angles. An elevation angle of 0° is looking straight down and one of 90° is a horizontal view. Usually it is best to set the Bottom Elevation angle to a couple of degrees less than 90 to avoid the viewpoint going underground.

Finally set the Altitude of the point at which the object movie will focus on. This value is in meters relative to the ground at the chosen latitude and longitude.

Note that using the "Get Position", "Get Latitude" and "Get Longitude" buttons after a non-zero altitude is set will result in their values changing to the point on the ground projected beyond the elevated focus point from the current view point!

Click the Preview button and the view will cycle through the image views you have defined. This has the added bonus of pre-loading the Google Earth cache.

Once you are happy with the settings make sure the browser window is large enough to show the entire plugin box and click the Snap Image Set button. The screen grab won't work properly if the whole image isn't visible! The instructions at the top of the page will disappear and the images will get saved to C:\Documents and Settings\USERNAME\Local Settings\Temp\GEAPlugin.

Hover over the bottom left of the image area until the navigation gadgets fade out before snapping the image set, otherwise it will appear on all the images. The snapped image size is 640x480 pixels, and is fixed in the "content" div size. The script does very little range and sanity checking on the input parameters. Crazy in, crazy out.

Saturday, 15 September 2007

Automated Object Movie Creation

Having made a couple of object movies from Google Earth by hand, I don't particularly want to repeat the experience! It is repetitive and takes ages: select a viewpoint; grab the screen; give it a filename; repeat 168 times. I had a look at the Google Earth COM API which allows scripting of view positions, but unfortunately its screen capture capabilities are limited to black and white images, with an automatic degradation in image quality every so often.

Fortunately, Luca Rocchi at Google Earth Airlines has come up with a nifty plug-in that allows GE to run in a browser, exposing its interface to javascript. The even nicer thing about it is that it supports proper screen grabs

After a bit of playing I now have a script that automatically generates the image set Pano2QTVR needs to create an object movie. Once its been tidied up and given it a more user friendly interface I'll post it up

For now, here's a preview:

(Drag on the image to stop that annoying autorotation)

Wednesday, 12 September 2007

Google Earth Quicktime Object Movie

This little experiment captures a tiny corner of Google Earth in a Quicktime object movie. I chose London's Battersea power station as the subject, though with hindsight that was probably not the most glamorous of places I could have picked. Nevertheless it is instantly recognisable (to the British and Pink Floyd fans at any rate ;) and there's a very good model of it in the 3D Warehouse.

It will need a few seconds to load, then, provided you have Quicktime installed, you will be able to change the view point by dragging on the image:

The object movie was created with Pano2QTVR, a utility that allows both QTVR panoramas and object movies to be constructed.

An extension to Pano2QTVR allows the object movie to be output in flash format:

The source images for the object movie have to be laboriously captured one at a time with Ctrl+Alt+S (or the mac equivalent) from Google Earth. View positioning is accomplished via the use of this kml file. This will allow easy positioning over most of a hemisphere in 24 azimuth steps at each of 7 elevations. It stops a couple of degrees short of ground level to avoid plunging the viewpoint underground. Note that the values of YOUR_LONGITUDE, YOUR_LATITUDE and YOUR_RANGE will need to altered to your chosen location before the file is any use!

If anyone knows a way to automate the image capture process, please drop me a line.