aboutsummaryrefslogtreecommitdiffstats
path: root/i.php
diff options
context:
space:
mode:
authorrvelices <rv-github@modusoptimus.com>2012-04-02 04:00:15 +0000
committerrvelices <rv-github@modusoptimus.com>2012-04-02 04:00:15 +0000
commitf318fe042e322f86ca2054aff614ef16daf7a20a (patch)
tree9e8773e0f57a73c1d56a9ed9ddace84af3a5cbb2 /i.php
parent8bce8f09637ba88dbd3d7872ab193143e605a787 (diff)
don't rotate several times derivatives
git-svn-id: http://piwigo.org/svn/trunk@13848 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'i.php')
-rw-r--r--i.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/i.php b/i.php
index 5ecf831a0..d2da5178a 100644
--- a/i.php
+++ b/i.php
@@ -321,6 +321,7 @@ function try_switch_source(DerivativeParams $params, $original_mtime)
$params->sharpen = min(1, $params->sharpen);
$page['src_path'] = $candidate_path;
$page['src_url'] = $page['root_path'] . substr($candidate_path, strlen(PHPWG_ROOT_PATH));
+ $page['rotation_angle'] = 0;
}
}
@@ -509,9 +510,11 @@ $timing['load'] = time_step($step);
$changes = 0;
// rotate
-if (0 != $page['rotation_angle'])
+if (0 != (int)$page['rotation_angle'])
{
$image->rotate($page['rotation_angle']);
+ $changes++;
+ $timing['rotate'] = time_step($step);
}
// Crop & scale