AVPlayer Dynamic Volume control
问题 How can I change the volume of the AVPlayer Dynamically? I mean, I want to mute the volume every time a button is pressed. the given code seems to change it in compile time only. How to do it during runtime??? AVURLAsset *asset = [AVURLAsset URLAssetWithURL:[self myAssetURL] options:nil]; NSArray *audioTracks = [asset tracksWithMediaType:AVMediaTypeAudio]; NSMutableArray *allAudioParams = [NSMutableArray array]; for (AVAssetTrack *track in audioTracks) { AVMutableAudioMixInputParameters