This thread is ancient, but my solution to display large images from a gallery2 installation fits here perfectly.
I had the (apparently not uncommon) problem that my gallery2 images were too large. By default the gallery2 widget attempts to load the full-sized images, which if you've uploaded anything straight out-of-cam is too much for the chumby.
My solution to this problem is using the ImageUrl Widget instead and adding a small php file to the gallery2 directory that fetches, resizes and outputs a random jpeg file from the gallery2 database.
Here is the php file, I called in randomimage.php and placed it directly in my gallery2 directory.
<?php
/****************************************************
* Get and resize random gallery2 image *
* Intended for use with small screen estate devices *
* Written by Loibisch *
*****************************************************/
### Configuration ###
$g2_url='http://www.yourgallery2.com/path'; // your public gallery2 url
$g2_rel_path=''; // relative path from this script to the g2 installation
$target_size = 320; // target image size
$quality = 90; // target jpeg quality
### Get random picture from gallery2 ###
require_once(dirname(__FILE__) . $g2_rel_path . '/embed.php');
$ret = GalleryEmbed::init(array('embedUri' => '/', 'relativeG2Path' => $g2_rel_path .'', 'activeUserId' => '', 'fullInit' => true ) );
list ($ret, $g2data) = GalleryEmbed::getImageBlock(array ('blocks' => 'randomImage', 'show' => 'none', 'activeUserId' => '', 'exactSize' => $target_size, 'link' => 'none'));
preg_match('/\?g2_view[^"]*/',$g2data,$imgurl);
$filename = $g2_url . '/main.php'. html_entity_decode($imgurl[0]);
$source = imagecreatefromjpeg($filename);
### Calculate new image size ###
$width = imagesx($source);
$height = imagesy($source);
if ($width > $height) {
$ratio = ($target_size / $width);
} else {
$ratio = ($target_size / $height);
}
$twidth = round($width * $ratio);
$theight = round($height * $ratio);
### Resize ###
$thumb = imagecreatetruecolor($twidth, $theight);
imagecopyresized($thumb, $source, 0, 0, 0, 0, $twidth, $theight, $width, $height);
### Display ###
header('Content-type: image/jpeg');
imagejpeg($thumb,NULL,$quality);
?>
Then set the URL of the ImageURL widget to the php file you created on the server and voila, the Chumby will now display your gallery2 files perfectly.
Caveat: This completely bombs out with anything but jpeg files in your gallery2 database. If you're using different filetypes or even video you will have to adjust the script accordingly. Worst case scenario however is that the ImageURL widget displays a blank screen whenever the php script encounters anything but a jpeg file.
Oh yeah, and I got my Chumby One yesterday, love the device so far.