November 2013
Intermediate to advanced
576 pages
19h 3m
English
Springs (shown in Figure 1.3) are an extension of the behavior of attachments. UIKitDynamics allows for additional properties to be set on UIAttachmentBehavior, frequency and damping.
Figure 1.3 A spring effect attaching the dragon image to the frog, which demonstrates using the effects of gravity as well as UIAttachmentBehavior damping and frequency.
The following section of the sample app adds three new properties after creating the UIAttachmentBehavior. The first, setFrequency, sets the oscillation or swing for the object. Next, setDamping evens out the animation peaks. The length is also adjusted for this example from its initial ...
Read now
Unlock full access