Creates an action that changes an audio node’s playback rate to a new value.
SDKs
- iOS 9.0+
- macOS 10.11+
- Mac Catalyst 13.0+
- tvOS 9.0+
- watchOS 2.0+
Framework
- Sprite
Kit
Declaration
class func changePlaybackRate(to v: Float, duration: Time Interval) -> SKAction
Parameters
v
The new value for the playback rate. A playback rate of
1
represents normal speed..0 duration
The duration of the animation, in seconds.
Return Value
A new action object.
Discussion
When the action executes, the audio node’s playback rate animates from its current value to its new value. For more information, see AVAudio3DMixing
.
This action is not reversible.