push @mmlist, [ $mmwidth, $mmheight ];
}
-
+
# Ensure that all of them are OK
my $last_good_mmlocation;
for my $i (0..$#mmlist) {
}
}
+ if (!defined($img)) {
+ $img = read_original_image($r, $id, $dbwidth, $dbheight);
+ }
return $img;
}
$info->{'ExposureProgram'} =~ /aperture\b.*\bpriority/i);
my @classic_fields = ();
- if (defined($info->{'FocalLength'}) && $info->{'FocalLength'} =~ /^(\d+)(?:\.\d+)?(?:mm)?$/) {
+ if (defined($info->{'FocalLength'}) && $info->{'FocalLength'} =~ /^(\d+)(?:\.\d+)?\s*(?:mm)?$/) {
push @classic_fields, [ $1 . "mm", 0 ];
} elsif (defined($info->{'FocalLength'}) && $info->{'FocalLength'} =~ /^(\d+)\/(\d+)$/) {
push @classic_fields, [ (sprintf "%.1fmm", ($1/$2)), 0 ];