Closed
Description
I would like to cache AVURLAsset.
However, in order to play cached AVURLAsset, file extensions (mp4, etc ...) are necessary... The current filePath is ".../XXX", but in order to actually play it needs to be ".../XXX.mp4"...
static func video(forKey key: String) -> AVURLAsset? {
do {
let entry = try storage.transformData().entry(forKey: key)
guard let filePath = EntryMeta(entry.meta)?.filePath else {
return nil
}
return AVURLAsset(url: URL(fileURLWithPath: filePath)) // <= Can't play this AVURLAsset
} catch let error {
log.error(error)
return nil
}
}
Are there any good ideas?
Metadata
Metadata
Assignees
Labels
No labels
Activity