Skip to content

Commit

Permalink
fixed coordinate clipping calc
Browse files Browse the repository at this point in the history
  • Loading branch information
michelegonella committed Nov 22, 2012
1 parent 28218fc commit 9604953
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -132,7 +132,7 @@ protected int[] clipCalc(int sw, int sh, int dw, @Nullable Integer dh,
return new int[] { 0 + margin, 0, sw - margin, sh, dw, sh };
} else if (dw > sw) {
int margin = approx((double) (sh - dh) / 2);
return new int[] { 0 + margin, 0, sw, dh - margin, sw, dh };
return new int[] { 0, 0 + margin, sw, sh - margin, sw, dh };
} else {
double xRatio = (double) sw / (double) dw;
double yRatio = (double) sh / (double) dh;
Expand Down

0 comments on commit 9604953

Please sign in to comment.