Crowley Code! 
 (Take 12)

Stop doing it yourself and use CPAN — curvr-0.2 2008/02/05

Just like the career of the average software engineer, Curvr has now grown up just a bit and started reusing other people's code.

Dopplr integration in curvrmail

Geotagging is awesome but a bit of a pain to automate with any kind of accuracy.  I'm making a compromise here by automatically tagging things using my location according to Dopplr.  I had this working with my original PHP curvrmail script but have since switched to using Flickr::Upload::Dopplr just to practice some Perl.

AutoManual image rotation

Since my N73 isn't friendly enough to rotate pictures for me, I've added a way to specify rotation in the email you send to Curvr.  Prefixing with "L " or "l " will rotate 90 degrees counterclockwise and prefixing with "R " or "r " will rotate 90 degrees clockwise.  Note in both cases that it is a letter followed by a space followed by the normal title/tags syntax.

It is a bit awkward to think about in terms of left and right, since I could either be talking about the direction you rotated the camera or the direction the photo should be rotated (which itself could be rather ambiguous, so we'll say that it is relative to the top).  So here's the official word: the rotate syntax wants to know which direction you rotated the camera to take the picture.

curvrconf for getting API tokens

Getting tokens for the Flickr and Dopplr API, while not something you need to do often, is quite a drag.  Enter curvrconf, the copy-and-paste simple way to get your tokens out.  All it needs is to be setup with the same API key as curvrmail and it'll guide you through grabbing tokens.  For the Flickr API, setup your key for web-based auth and give it a garbage URL to return to (I use http://localhost:81/).

As usual, the API key is up to you.  I accidentally committed my keys/secrets/tokens to Subversion but have expired all of them so don't even bother trying to steal my accounts.

Anti-blue C code

The main curvr program has for a long time introduced some strange blue artifacts into my photos.  I figured this was due to some underflow or overflow issues with my color maps.  I finally took the time to do some serious experimentation and it turns out that if I just favor a stronger red channel in these edge cases, the artifacts seem to go away.  Strange and beautiful indeed.  I can't fully explain the phenomenon but believe it's somehow related to my using the red channel as my indicator of color value (as many photographers do when converting to black & white).

So there it is, curvr-0.2.

Er, here it is: http://svn.rcrowley.org/svn/curvr/tags/curvr-0.2

Comments (0)

Richard Crowley?  Kentuckian engineer who cooks and eats in between bicycling and beering.

I blog mostly about programming and databases.  Browse by month or tag.

To blame for...


© 2009 Richard Crowley.  Managed by Bashpress.