From 5f189a066d802129874dfded4804866d68dddd3b Mon Sep 17 00:00:00 2001 From: ww-rm Date: Sat, 14 Jun 2025 20:00:25 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E9=9D=99=E6=80=81=E7=94=BB?= =?UTF-8?q?=E9=9D=A2=E7=9A=84=E8=BE=B9=E7=95=8C=E6=A3=80=E6=B5=8B=E9=94=99?= =?UTF-8?q?=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ViewModels/Exporters/BaseExporterViewModel.cs | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/SpineViewer/ViewModels/Exporters/BaseExporterViewModel.cs b/SpineViewer/ViewModels/Exporters/BaseExporterViewModel.cs index a53c7e8..4baff6e 100644 --- a/SpineViewer/ViewModels/Exporters/BaseExporterViewModel.cs +++ b/SpineViewer/ViewModels/Exporters/BaseExporterViewModel.cs @@ -101,18 +101,19 @@ namespace SpineViewer.ViewModels.Exporters /// protected void SetAutoResolutionStatic(BaseExporter exporter, params SpineObject[] spines) { - var bounds = spines[0].GetAnimationBounds(); - foreach (var sp in spines.Skip(1)) bounds.Union(sp.GetAnimationBounds()); + var bounds = spines[0].GetCurrentBounds(); + foreach (var sp in spines.Skip(1)) bounds.Union(sp.GetCurrentBounds()); SetAutoResolution(exporter, bounds); } /// /// 使用提供的模型设置导出器的自动分辨率和视区参数, 动画画面 /// - protected void SetAutoResolutionAnimated(BaseExporter exporter, params SpineObject[] spines) + protected void SetAutoResolutionAnimated(VideoExporter exporter, params SpineObject[] spines) { - var bounds = spines[0].GetAnimationBounds(); - foreach (var sp in spines.Skip(1)) bounds.Union(sp.GetAnimationBounds()); + var fps = exporter.Fps; + var bounds = spines[0].GetAnimationBounds(fps); + foreach (var sp in spines.Skip(1)) bounds.Union(sp.GetAnimationBounds(fps)); SetAutoResolution(exporter, bounds); }