9c579c65aa
* perf: Automatically determine Pixel Format depending on active format. (More efficient video recording 🚀)
* perf: Skip `AVAssetWriter` transform by directly correctly orienting the Video Output connection
* feat: Support camera flipping while recording
* feat: Run frame processor on separate queue, avoids stutters in video recordigns
* feat: Automatically drop late frame processor frames
21 lines
437 B
Swift
21 lines
437 B
Swift
//
|
|
// AVCapturePhotoOutput+mirror.swift
|
|
// Cuvent
|
|
//
|
|
// Created by Marc Rousavy on 18.01.21.
|
|
// Copyright © 2021 mrousavy. All rights reserved.
|
|
//
|
|
|
|
import AVFoundation
|
|
|
|
extension AVCapturePhotoOutput {
|
|
func mirror() {
|
|
connections.forEach { connection in
|
|
if connection.isVideoMirroringSupported {
|
|
connection.automaticallyAdjustsVideoMirroring = false
|
|
connection.isVideoMirrored = true
|
|
}
|
|
}
|
|
}
|
|
}
|