You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
453 B
23 lines
453 B
//
|
|
// NSURL+NSURL_Asset.m
|
|
// Snapchat
|
|
//
|
|
// Created by Michel Loenngren on 4/30/17.
|
|
// Copyright © 2017 Snapchat, Inc. All rights reserved.
|
|
//
|
|
|
|
#import "NSURL+Asset.h"
|
|
|
|
#import <SCBase/SCMacros.h>
|
|
|
|
@import AVFoundation;
|
|
|
|
@implementation NSURL (Asset)
|
|
|
|
- (void)reloadAssetKeys
|
|
{
|
|
AVAsset *videoAsset = [AVAsset assetWithURL:self];
|
|
[videoAsset loadValuesAsynchronouslyForKeys:@[ @keypath(videoAsset.duration) ] completionHandler:nil];
|
|
}
|
|
|
|
@end
|