[Home]
Film 2010
101 War
101 Sci-Fi
101 Horror
101 Gangster
Films on TV
Film Charts
IMDb Top 250
EIFF
Film 2009
Flickr
89 Years
1001 Upcoming
1001 Movies
Film 2008
Trip Advisor
80 Countries
Google Photo Map
Microsoft Map
Film 2007
Film 2006
100 Andys
Last.fm
World Wide Wilkie
Blog
Reviews
200 Films
My DVDs
My Games|
Exif Woes
I have a local web script I use when uploading photos to Flickr so that all the information I add (e.g. title, description, tags etc.) is stored in the Exif of the photo, meaning if I ever move away from Flickr I still have all the extra meta-data I've added for each photo. One of the things I wanted to do was tag which lens the photo was taken with, I had just been trying to work it out based on the focal length and aperature (e.g. if it's less than f/5.6 at certain focal lengths I know it's my Tamron 17-50mm f/2.8 rather than the Sony kit lens and anything over 70mm has to be the Tamron 55-200mm). This works to a point, but e.g. anything taken between 17mm and 50mm at f/5.6 or higher could be either the kit lens or the Tamron. Neil had claimed that the lens information was stored in the Exif, but I wasn't convinced as I hadn't seen it for any of my photos, I wondered if maybe only the newer Sonys contained this information, but after checking on Flickr, sure enough there it is "Lens Type: Tamron Lens (255)". I'd assumed I'd just missed this, so yesterday when I came to upload another photo I thought I'd give it a try and update my process. The thing is, that the "Lens Type" field isn't one of the standard fields returned by PHP's exif_read_data() function. It's actually buried inside the "MakerNote" field which exif_read_data() returns as a big block of binary data. As well as exif_read_data, I'm also using the PHP Exif Library (PEL) to write Exif info back into the files. It's pretty powerful, but Exif is a bit of a crazy format, so finding the exact bits you need to extract the data proved problematic. In the end, I could get hold of the binary data for the MakerNote field, but couldn't find a way to parse this as another TIFF container to get at the underlying information. There's some good information about the layout of this data here, and I did contemplate trying to parse it myself. I found another PHP library (PHP JPEG Metadata Toolkit) which claims to be able to parse Sony MakerNote information, but I didn't have much luck with getting it to run. In the end, I stumbled across a Perl library for reading Exif data (Exif Tool), this handles the Sony MakerNote field flawlessly and comes with a sample script which can parse the Exif for a photo and return it in a variety of formats. In the end, I just wrote a wrapper round this script which executes the script from within PHP, getting the results in JSON format and then converting that to a PHP object and returning it. Seems to work flawlessly and the information returned is even better than Flickr, giving the complete name of the lens rather than just "Tamron Lens (255)". If I get time, I plan to try and work out how Exif Tool decodes the MakerNote and see if I can replicate this in PHP (probably using PEL) but in the meantime, the hack seems to work and now my photos have the lens automatically tagged on upload. Hopefully, someone trying to do something similar finds this information useful, at least in terms of where to start looking.
Flickr Stats API
I guess, this is what Twitter's for, but anyway. Interesting development from Flickr; (Stats API). Now I can add more useless graphs to my website!
Band of Brothers
I got Band of Brothers on Blu-Ray for my Christmas, I had never seen it before but had heard good things and after recently finishing the series, I'm pleased to say it lived up to expectations. The 10 1 hour episodes follow a paratroop regiment during the Second World War from their landing behind enemy lines on D-Day through to the end of the War. It plays out much like a 10 hour Saving Private Ryan, with movie quality production values, sets and action sequences. The Blu-Ray presentation is pretty good, a lot of the scenes shot in lower light are visibly grainy, but some of the action sequences looks stunning in Hi-Def. Overall, well worth watching on either DVD or Blu-Ray. 5/5
Ice Factor - Kinloch Leven
Just back from a weekend away, we were staying in Fort Augustus, but seemed to spend most of our time driving between Ballachulish and there and back. On Sunday we had a 2.5 hour ice climbing lesson booked with Ice Factor in Kinloch Leven. Kinloch Leven is in the middle of nowhere, 7 miles down the side of Loch Leven from Glencoe village. There used to be a large aluminum factory there but that has since shut down, now there is the Atlas brewery and the Ice Factor which boasts indoor climbing walls and a high wire course. Perhaps most interestingly though, they also have a large indoor ice climbing room. Basically a huge freezer where the walls are covered in ice, so for £48 each we got to spend 2.5 hours in the freezer hanging onto the ice with ice axes and crampons. It's great fun and our instructor was very friendly and helpful. All the equipment is provided and if you're into climbing, this is a great introduction to ice climbing, I want to go do it outside now!
Broken Chain(s)
OK, so it seems my short lived ability to maintain my own bike has come to an end. Yesterday I got about 10m away from my work when the chain snapped due to my poor maintenance at the weekend. No problem though, after walking half way home and getting Rosie to pick me up, I set about fitting the new chain that had arrived in the post. Managed to bend one of the links trying to fit that. Then this morning, it broke on the way to work. To make matters worse, the back brakes keep getting jammed as well, so this time, I'm taking it to a bike shop to get properly repaired by someone who knows what they are doing. |
Insomnium – Where the Last Wave Broke
Warbringer – Jackal High on Fire – Frost Hammer High on Fire – Snakes For The Divine Rammstein – Klavier Rammstein – Spiel Mit Mir Rammstein – Bück Dich Rammstein – Du Hast Rammstein – Bestrafe Mich Rammstein – Tier
|