Tuesday, October 20, 2009

Goodbye KDE

After getting fed up with KDE, we switched to Gnome. While some things took some getting used to (again, mostly around dealing with digital photos), overall the experience is a lot more pleasant.

The UI doesn't get nearly as much into the way as KDE does. Gnome has less bells and whistles, but things mostly just work, and on top of that, it's much, much faster than KDE4.

F-Spot is ok, but also suffers from the "hey, you didn't do anything, so I won't write that photo to disk when you tell me to save it after I rotated it for you automatically". One day I'll write (or find) a simple shell script that'll go through a folder and correctly rotate the photos on disk based on EXIF information.


Steve Lacy said...

Use at your own risk, and sorry for the poor blogger formatting.

use strict;
use warnings;

my $jpeg = $ARGV[0];

open OUTPUT,"jhead \"$jpeg\" |";
my $tempfile = "/tmp/temp_$$.jpg";
while (<OUTPUT>) {
if ($_ =~ /^Orientation +: +(.*)$/) {
my $angle;
if ($1 eq "rotate 90") {
$angle = "90";
} elsif ($1 eq "rotate 180") {
$angle = "180";
} elsif ($1 eq "rotate 270") {
$angle = "270";
} else {
die "Unknown rotation: $1\n";
# print ("jpegtran -copy all -rotate $angle $jpeg > $tempfile");
print "Rotating $jpeg by $angle\n";
system ("jpegtran -copy all -rotate $angle \"$jpeg\" > $tempfile");
system ("mv $tempfile \"$jpeg\"");

Bernhard said...


Thank you :-)

Steve Lacy said...

BTW, my usage is usually like this:

$ find . -iname "*.jpg" | xargs -n1 -P4 ~/bin/jpegrot

Will run 4 versions of this in parallel, which is great on a quad-core machine. :)

Bernhard said...

bbeck@chef:~$ cat /proc/cpuinfo

processor : 0

vendor_id : CentaurHauls

cpu family : 6

model : 9

model name : VIA Nehemiah

stepping : 10

cpu MHz : 999.874


Quite slow, but also very low power requirements for a desktop system.

Bernhard said...

I ended up using

exiftran -a -i