修复导出单个模式的时长错误
This commit is contained in:
@@ -92,7 +92,7 @@ namespace SpineViewer.ViewModels.Exporters
|
|||||||
var output = Path.Combine(_outputDir!, filename);
|
var output = Path.Combine(_outputDir!, filename);
|
||||||
|
|
||||||
if (_autoResolution) SetAutoResolutionAnimated(exporter, spines);
|
if (_autoResolution) SetAutoResolutionAnimated(exporter, spines);
|
||||||
if (_duration < 0) exporter.Duration = spines.Select(sp => sp.GetAnimationMaxDuration()).DefaultIfEmpty(0).Max();
|
exporter.Duration = _duration >= 0 ? _duration : spines.Select(sp => sp.GetAnimationMaxDuration()).DefaultIfEmpty(0).Max();
|
||||||
|
|
||||||
exporter.ProgressReporter = (total, done, text) =>
|
exporter.ProgressReporter = (total, done, text) =>
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -83,7 +83,7 @@ namespace SpineViewer.ViewModels.Exporters
|
|||||||
var output = Path.Combine(_outputDir!, filename);
|
var output = Path.Combine(_outputDir!, filename);
|
||||||
|
|
||||||
if (_autoResolution) SetAutoResolutionAnimated(exporter, spines);
|
if (_autoResolution) SetAutoResolutionAnimated(exporter, spines);
|
||||||
if (_duration < 0) exporter.Duration = spines.Select(sp => sp.GetAnimationMaxDuration()).DefaultIfEmpty(0).Max();
|
exporter.Duration = _duration >= 0 ? _duration : spines.Select(sp => sp.GetAnimationMaxDuration()).DefaultIfEmpty(0).Max();
|
||||||
|
|
||||||
exporter.ProgressReporter = (total, done, text) =>
|
exporter.ProgressReporter = (total, done, text) =>
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -56,12 +56,12 @@ namespace SpineViewer.ViewModels.Exporters
|
|||||||
var output = Path.Combine(_outputDir!, folderName);
|
var output = Path.Combine(_outputDir!, folderName);
|
||||||
|
|
||||||
if (_autoResolution) SetAutoResolutionAnimated(exporter, spines);
|
if (_autoResolution) SetAutoResolutionAnimated(exporter, spines);
|
||||||
if (_duration < 0) exporter.Duration = spines.Select(sp => sp.GetAnimationMaxDuration()).DefaultIfEmpty(0).Max();
|
exporter.Duration = _duration >= 0 ? _duration : spines.Select(sp => sp.GetAnimationMaxDuration()).DefaultIfEmpty(0).Max();
|
||||||
|
|
||||||
exporter.ProgressReporter = (total, done, text) =>
|
exporter.ProgressReporter = (total, done, text) =>
|
||||||
{
|
{
|
||||||
pr.Total = total;
|
pr.Total = total;
|
||||||
pr.Done = done;
|
pr.Done = done;
|
||||||
pr.ProgressText = text;
|
pr.ProgressText = text;
|
||||||
_vmMain.ProgressValue = pr.Done / pr.Total;
|
_vmMain.ProgressValue = pr.Done / pr.Total;
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user