react-native-transparent-video/ios/AVAsset+VideoSize.swift
Brian Sztamfater 6640e69a81 feat: implement component iOS bridge and demo app example
Signed-off-by: Brian Sztamfater <brian@status.im>
2023-05-04 16:11:57 -03:00

14 lines
305 B
Swift

//
// AVAsset+VideoSize.swift
// MyTransparentVideoExample
//
// Created by Quentin Fasquel on 22/03/2020.
// Copyright © 2020 Quentin Fasquel. All rights reserved.
//
import AVFoundation
extension AVAsset {
var videoSize: CGSize { tracks(withMediaType: .video).first?.naturalSize ?? .zero }
}