I created a couple of patches for ZenPhoto to add some much requested functionality.
First of all, I created a patch that adds EXIF reading capabilities to ZenPhoto itself. It adds some simple functions that theme authors can use print formatted EXIF information. The rest is handled completely transparently. One important difference between other solutions for EXIF reading is that the data is filtered beforehand. This ensures that the output of the functions are actually useful to be displayed, and not the raw data that is stored in the JPEG file.
One of the area I payed some extra attention to is the support of Geotagging. If present, the EXIF patch reads the Geotagging information in JPEG files and transforms it to a format that is used by the various map APIs such as Yahoo Maps and Google Maps and Google Earth. An example of what can be done with the Geotagging information can be found on my own gallery. Just click on the ‘Toon locatie’ button in the bottom left of the page: http://nielsenwilma.nl/italy/DSC02083.JPG
I also added RSS and Atom output. The RSS output should be compatible with iTunes (not tested yet) and includes MediaRSS information which is compatible with Flickr. Reading the RSS output in FeedDemon for example shows thumbnails, descriptions and dates for every photo. The RSS output also includes the Geotagging information (if applicable) using the ICBM extension. Examples:
http://nielsenwilma.nl/trier.rss
http://nielsenwilma.nl/scotland.atom
Finally I also added KML export for use in Google Earth. For every geotagged picture it places a small thumbnail on the map, and if you click on the thumbnail it will open a larger version of the picture and the description and a link back to the ZenPhoto gallery. Example:
http://nielsenwilma.nl/scotland.kml
I’ve added the patches to the bugtracker, so perhaps these functions will be included in a future version of ZenPhoto.
Some of that stuff looks very good, it would be great if it could be added to the list of (2) patches on the "plugins" page (http://www.zenphoto.org:8080/confluence/display/PLUG/Home).
@mannkind-
I'm not sure. I haven't seen those in quite a while. I fiddled with them when they were released, but the problem is they require modifications to zenphoto core code in versions earlier than zenphoto v1.0.3, and I don't think they'll work right in the newer zenphoto versions. So even if you were to get the code for them, they may not work at all since zenphoto's core code has changed.
Tristan might have saved those somewhere before the old confluence pages went away, but I'm not sure.
There is no reason why the zenphoto EXIF implementation that is being worked on now can't be extended at some point to include geotagging, but the EXIF library would have to be set up to support it.
For now, you can use the latest SVN code (rev 438) to include EXIF viewing capability, and I hope to work with Tristan (the developer) to get more theme functions written for EXIF stuff shortly.
You can see an example here:
http://www.bushwoodworking.com/zenphoto/projects/bushwoodtools/markingknives/IMG_2901.JPG.php#
(click on the EXIF Data link below the image)
This uses the new Zenphoto EXIF implementation to display the EXIF tags in my images.
For the RSS piece, I have RSS working here:
http://www.bushwoodworking.com/zenphoto/index.php?p=latest
This is not using official zenphoto code yet though, this is a hack I built from things I found around the forums here. I'd be glad to share if you want.
@thinkdreams
Thanks for the information. I would be interested in seeing the code you wrote/collected for displaying the EXIF data -- that is, if you don't mind sharing it.
I really am interested in the geo-spatial data, displaying of maps w/photos, and Google Earth kml downloads. I figured that the code wouldn't be entirely compatible with the newest ZenPhoto but I'm not afraid of coding. Heck, for awhile there I was even writing my own photo album software all because I wanted support for 'tags'. I came up with the following demo of real working code after working on it for about 2 weeks (evenings, after work):
http://www.thenullpointer.net/wordpress/wp-content/uploads/2006/12/tnppg-project-video.mov
Seeing Rakaz's demo has me excited about ZP once more -- I'd really love to give it a try.
Well, hopefully someone still has the older EXIF stuff by rakaz laying around somewhere.
Which code would you like from me? Since I'm heavy into the new EXIF functionality work, I'm not using the older hacky EXIF stuff. If you would like a copy of the old stuff, I can send it to you (although it doesn't do anything more than the the newer integrated EXIF we're working on)
mannkind, the new EXIF library we're using should be able to get any metadata you want out of an image, so perhaps we can use it and integrate some of Rakaz's old code, because that stuff looks downright awesome.
I can't believe I missed it when it came up before... it's really good stuff! The future of online galleries IMHO... when all cameras will have little GPS recievers in them, every gallery could be like this!
Rakaz's stuff was pretty cool if I recall. I made an attempt early on to use it, but couldn't get it to work right. It required some modifications to your code Tris, and some htaccess changes as well.
Do you have any backup copies of it from the old confluence web stuff?
@thinkdreams
Oh, maybe I mis-understood what you were saying. I should just checkout the SVN repo to get the cool EXIF stuff.
@trisweb
I'm really happy to see that you're interested in integrating the visualization of the geo-spatial data into ZP. I would be more than happy to help out in the effort. I'll be checking out the SVN this weekend to see how the EXIF stuff is coming along.
Re: Cameras with GPS
One neat thing is there is software available for almost every platform that allows you to select a photo/photos and geocode them manually using Google/Yahoo Maps. While I use a GPS for my newest photos, being able to go back to older photos and say, "This group of photos was taken ::click:: there" is very neat.
@mannkind-
If you want, you can check out the library that is being used to do the EXIF stuff. It might be able to be extended to include the Geotags. It's located under the /zen/exif folder I believe.
What camera manufacturers and models support that sort of tagging now?
@thinkdreams
IIRC there is only 1 camera that actually has a GPS in it. For everyone else (like myself) the photos are geocoded with programs (either Automated or point-n-click on a map).
The EXIF specification has fields for GPS Information -- here is an example from one of my geocoded photos:
[list]
[]GPSVersionID: 2,2,0,0
[]GPSLatitudeRef: N
[]GPSLatitude: 47 4810.3752
[]GPSLongitudeRef: W
[]GPSLongitude: 122 2922.92
[]GPSAltitudeRef: Sea level
[]GPSAltitude: 75/1 meters
[]GPSMapDatum: WGS-84
[/list]
I'll be checking the library out in a couple hours. I'm hoping it can do the deed.
@thinkdreams, trisweb
I quickly found where ZP defines what EXIF data is being pulled, and added Lat/Long+Refs, Alt+Ref to the list.
I then found the theme function that dumps the data and edited the testing template to dump the data.
Hmmm...the EXIF library as is does formatting for some of the GPS fields, but not all of them. So I found myself thinking: What does Altitude Reference: 0 (or 1 -- only two possible values) mean? What does Altitude: 75 mean? Once I figured out what it stood for I added some extra formatting (following the same style the other formatting code uses) and now have 'Altitude Reference: Above|Below Sea Level' and 'Altitude: 75m'
I'm very happy that the EXIF library used has the ability read GPS Data. As an example I placed a few of my recently geocoded photos online-- my SVN ZenPhoto album:
http://mu.thenullpointer.net/Silverdale_Brewery_and_Geocaching_200704/IMG_0014.JPG.php
That's nifty mannkind!
Submit this to Tristan for his review. This would be perfect to add to the development code for EXIF.
Cool. Zenphoto is just getting better all the time.
Yes, Tris, I need to know the proper procedures as well. I have a couple diffs to submit to you as well with my minor tweaks (see other EXIF thread).
@thinkdreams
Your code for the displaying of the EXIF data in a nicer way... might I sneak a peak? I'd be glad to give you my diff file for the geocoding if you were interested.
(This is a sneaky way of bumping the thread -- I don't want it to get lost in the depths of time again)
sure thing mannkind. give me a bit to zip up the files. it uses a very thin version of lightbox to pop up a display box. that's about the only thing I will use lightbox for, as it fits well into the theme without taking up too much space for the EXIF parameters.