From bc78a330b9d675953a0770bcd1d79fc29cab7e3e Mon Sep 17 00:00:00 2001 From: bluesea <307723040@qq.com> Date: Sun, 7 Apr 2024 16:51:02 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E7=BC=96=E7=A0=81=E4=B8=BA72?= =?UTF-8?q?0*640=E6=97=B6=E7=9A=84=E7=BC=96=E7=A0=81=E5=B4=A9=E6=BA=83?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../RecordingVideo/VRVideoTransformController.swift | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/SwiftProject/SwiftProject/Project/Controller/RecordingVideo/VRVideoTransformController.swift b/SwiftProject/SwiftProject/Project/Controller/RecordingVideo/VRVideoTransformController.swift index 5815013..afdf33d 100644 --- a/SwiftProject/SwiftProject/Project/Controller/RecordingVideo/VRVideoTransformController.swift +++ b/SwiftProject/SwiftProject/Project/Controller/RecordingVideo/VRVideoTransformController.swift @@ -791,7 +791,13 @@ extension VRVideoTransformController { videoSettings?[AVVideoHeightKey] = height //视频编码AVVideoCodecType // videoSettings?[AVVideoCodecKey] = codecType.rawValue - videoSettings?[AVVideoCodecKey] = AVVideoCodecType.hevc + if self.selectedPreset == .preset1280x720 { + videoSettings?[AVVideoCodecKey] = AVVideoCodecType.h264 + } + else { + videoSettings?[AVVideoCodecKey] = AVVideoCodecType.hevc + } + //设置视频缩放方式 videoSettings?[AVVideoScalingModeKey] = AVVideoScalingModeResizeAspectFill /*