hdr image viewer

update xcode project

use existing asset fetch

pinch zoom

fix xcode

debug scaling
This commit is contained in:
mertalev
2025-09-08 14:14:21 -04:00
parent 23fb2e0fae
commit 56caf6a133
7 changed files with 336 additions and 34 deletions
@@ -193,12 +193,12 @@ class ThumbnailApiImpl: ThumbnailApi {
}
}
private static func requestAsset(assetId: String) -> PHAsset? {
static func requestAsset(assetId: String) -> PHAsset? {
var asset: PHAsset?
assetQueue.sync { asset = assetCache.object(forKey: assetId as NSString) }
if asset != nil { return asset }
guard let asset = PHAsset.fetchAssets(withLocalIdentifiers: [assetId], options: Self.fetchOptions).firstObject
guard let asset = PHAsset.fetchAssets(withLocalIdentifiers: [assetId], options: fetchOptions).firstObject
else { return nil }
assetQueue.async { assetCache.setObject(asset, forKey: assetId as NSString) }
return asset