Panorama

From OLPC
Revision as of 07:02, 12 October 2008 by Nrp (talk | contribs)
Jump to navigation Jump to search
Activity-panorama.svg

Panorama is a panorama auto-stitching Activity with an upload to Flickr button. The vision is to allow children around the world to share their surroundings with each other.

This Activity will freeze and maybe also freeze Sugar after saving or uploading a panorama. You may not want to use it until this is fixed.

History

Created by Donald Cober and Nirav Patel in 24 hours during Yahoo's University Hack Day at CMU, where it won the Hack for Good award. The activity is based on an earlier work by Ben Schwartz.

Panorama Upload

The activity currently has an upload to Flickr button. The images show up instantly on a Flickr account.

Todo and Known Bugs

Improve image quality

The activity currently captures as RGB444 and stores the images as 16 bit SDL Surfaces, largely for performance reasons. However, image quality is far more important than speed of the live preview for our purposes. It may be useful to move to YUYV capture and storing as 24 bit Surfaces. This has the side benefit of being able to use pygame.surfarray.pixels3d instead of pygame.surfarray.array3d for much less RAM usage during stitching.

Improve stitching accuracy

Since it was a 24 hour hack, the stitching algorithm wasn't given much thought. It currently moves a 100px wide slice of the right image one pixel at a time across the left image, going from 100 pixels in to half way through the image. At each step, it subtracts one 100px of array from the other 100 px of array, squares that resulting array, and stores the sum of that. When it is done moving through the image, it finds the lowest sum and assumes that is the best stitch. This is commenly called a Sum of Squared Differences, or SSD. It may be better to look at more than a 100 px slice, or at least not the 100px closest to the edge, since the edge tends to be darker.

Shorten stitching time

It currently takes a few seconds per image in the panorama. The wait time isn't painfully long, and the progress is shown to keep the user entertained, but quicker would be better. Pyramidizing the stitch may be useful to shorten the time.

Fix FATAL PyGTK/OLPCGames interaction

The Activity currently has a bug that causes it to freeze after the user hits ok on the Save or Upload dialog box. The save or upload is performed successfully, but the dialog box does not close, and prevents the user from accessing the Activity or quitting it. It may be necessary to drop the PyGTK box entirely and hack together a text input function for Pygame.

Secure Image Uploading

The activity currently uploads all panoramas to a personal Flickr account. This is less than ideal for obvious reasons.

Panoramas

Here is an example exhibiting basically all of the current flaws in the activity. It was taken during the demo of the activity to the Hack Day judges. Notice that there is severe color noise, hugely visible borders from auto exposure, and a completely wrong stitch. These are all points that are being focused on for the first real release.

Test stitch.jpg

Activity Summary

Icon: Sugar icon::Activity-panorama.svg
Genre: Activity genre::Drawing, Media Creation
Activity group: ,|x|Activity group::x}}
Short description: Short description::An auto-stitching panorama activity that uploads to Flickr.
Description:
Maintainers: ,|x|Contact person::x}}
Repository URL:
Available languages: ,|x|Available languages::x}}
Available languages (codes): ,|x|Language code::x}}
Pootle URL:
Related projects: Related projects,|x|Related projects::x}}
Contributors: ,|x|Team member::x}}
URL from which to download the latest .xo bundle Activity bundle::http://eclecti.cc/files/Panorama-1.xo
Last tested version number: Activity version::1
The releases with which this version of the activity has been tested. ,|x|Software release::x}}
Development status: Devel status::2. Pre-Alpha
Ready for testing (development has progressed to the point where testers should try it out): ,|x|Ready for testing::x}}
smoke tested :
test plan available :
test plan executed :
developer response to testing :