mirror of
https://github.com/lovell/sharp.git
synced 2025-12-19 07:15:08 +01:00
Allow for negative top/left offsets in composite overlays
A top or left offset value of -1 will no longer mean that the value is not set, but will now be an actual offset of -1. INT_MIN for left & top will mean that the values are not set. Co-authored-by: Christian Flintrup <chr@gigahost.dk>
This commit is contained in:
committed by
Lovell Fuller
parent
182beaa4a1
commit
02676140e8
@@ -40,6 +40,7 @@ struct Composite {
|
||||
int gravity;
|
||||
int left;
|
||||
int top;
|
||||
bool hasOffset;
|
||||
bool tile;
|
||||
bool premultiplied;
|
||||
|
||||
@@ -47,8 +48,9 @@ struct Composite {
|
||||
input(nullptr),
|
||||
mode(VIPS_BLEND_MODE_OVER),
|
||||
gravity(0),
|
||||
left(-1),
|
||||
top(-1),
|
||||
left(0),
|
||||
top(0),
|
||||
hasOffset(false),
|
||||
tile(false),
|
||||
premultiplied(false) {}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user