PSD layer co-ordinates may be negative by radarhere · Pull Request #7706 · python-pillow/Pillow

Resolves #7704

At the moment, Pillow reads the top left co-ordinates of a PSD layer as unsigned, meaning that they can't be negative.

# bounding box
y0 = i32(read(4))
x0 = i32(read(4))

However, the issue has found a PSD file where a layer does have a negative Y offset. This PR adjusts the reading of the co-ordinates to be signed, so that they can be negative.

I created a test file using GIMP.