forked from shadowfacts/Tusker
parent
3d15759fb9
commit
cb3fd43dbd
|
@ -40,6 +40,7 @@ class AttachmentThumbnailController: ViewController {
|
||||||
case .video, .gifv:
|
case .video, .gifv:
|
||||||
let asset = AVURLAsset(url: url)
|
let asset = AVURLAsset(url: url)
|
||||||
let imageGenerator = AVAssetImageGenerator(asset: asset)
|
let imageGenerator = AVAssetImageGenerator(asset: asset)
|
||||||
|
imageGenerator.appliesPreferredTrackTransform = true
|
||||||
#if os(visionOS)
|
#if os(visionOS)
|
||||||
#warning("Use async AVAssetImageGenerator.image(at:)")
|
#warning("Use async AVAssetImageGenerator.image(at:)")
|
||||||
#else
|
#else
|
||||||
|
@ -91,6 +92,7 @@ class AttachmentThumbnailController: ViewController {
|
||||||
if type.conforms(to: .movie) {
|
if type.conforms(to: .movie) {
|
||||||
let asset = AVURLAsset(url: url)
|
let asset = AVURLAsset(url: url)
|
||||||
let imageGenerator = AVAssetImageGenerator(asset: asset)
|
let imageGenerator = AVAssetImageGenerator(asset: asset)
|
||||||
|
imageGenerator.appliesPreferredTrackTransform = true
|
||||||
#if os(visionOS)
|
#if os(visionOS)
|
||||||
#warning("Use async AVAssetImageGenerator.image(at:)")
|
#warning("Use async AVAssetImageGenerator.image(at:)")
|
||||||
#else
|
#else
|
||||||
|
|
Loading…
Reference in New Issue