sub _exif_info {
my $exifTool = new Image::ExifTool;
$exifTool->Options(Group0 => ['IPTC', 'EXIF', 'XMP', 'MakerNotes', 'Composite']);
- my $info = $exifTool->ImageInfo(shift->path);
+ my $info = $exifTool->ImageInfo(shift->path(0,0,1));
my $hash = {};
foreach my $tag ($exifTool->GetFoundTags('Group0')) {
next if $banned_tags{$tag};
}
sub path {
- my ($self, $is_url, $scale) = @_;
+ my ($self, $is_url, $scale, $raw) = @_;
my $path =
Memories->config->{$is_url eq "url" ? "data_store_external" : "data_store" };
if ($scale) { $path .= "$scale/" }
# Make dir if it doesn't exist, save trouble later
use File::Path;
if ($is_url ne "url" and ! -d $path) {mkpath($path) or die "Couldn't make path $path: $!";}
- if ($scale or $is_url ne "url") {
+ if ($scale or ($is_url ne "url" and !$raw)) {
$path .= $self->id.".jpg";
} else {
$path .= $self->id.".".($self->format||"jpg");