snwau/SWSnapshotStackView — Issue #7: Shadows render incorrectly on iOS <3.2
Author: snwau
Created: 2012-03-07 23:22:41+00:00
State: open
Labels: Bug

Testing on a device running iOS 3.1.3 I noticed shadows were not being rendered correctly.

It turns out Apple inverted the shadow offset (base translation) direction for the y-axis in iOS 3.2, hence the shadows are being drawn up instead of down on iOS version prior to 3.2.

Refer to:
https://developer.apple.com/library/ios/#documentation/2DDrawing/Conceptual/DrawingPrintingiOS/GraphicsDrawingOverview/GraphicsDrawingOverview.html

Paragraph:
> Note: Prior to iOS 3.2, Core Graphics and UIKit shared the same convention for shadow direction: positive offset values make the shadow go down and to the right of an object.