From c17975b64ec847e43b69df226ddde273051c561c Mon Sep 17 00:00:00 2001 From: Nikolaj Olsson Date: Fri, 22 Mar 2024 19:06:50 +0100 Subject: [PATCH] Support some frame rates for export to DcinemaSmpte2014 - thx rimu :) --- src/ui/Forms/ExportPngXml.cs | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/src/ui/Forms/ExportPngXml.cs b/src/ui/Forms/ExportPngXml.cs index 727441194..e848d6570 100644 --- a/src/ui/Forms/ExportPngXml.cs +++ b/src/ui/Forms/ExportPngXml.cs @@ -993,8 +993,8 @@ namespace Nikse.SubtitleEdit.Forms " 2014-01-01T00:00:00.000-00:00" + Environment.NewLine + " 1" + Environment.NewLine + " en" + Environment.NewLine + - " 25 1" + Environment.NewLine + - " 25" + Environment.NewLine + + " [FRAMERATE] 1" + Environment.NewLine + + " [FRAMERATE]" + Environment.NewLine + " 00:00:00:00 " + Environment.NewLine + " urn:uuid:3dec6dc0-39d0-498d-97d0-928d2eb78391" + Environment.NewLine + " " + Environment.NewLine + @@ -1002,6 +1002,7 @@ namespace Nikse.SubtitleEdit.Forms " " + Environment.NewLine + ""; + xml = xml.Replace("[FRAMERATE]", ((int)FrameRate).ToString(CultureInfo.InvariantCulture)); doc.LoadXml(xml); var fName = saveFileDialog1.FileName; @@ -4549,6 +4550,20 @@ $DROP=[DROPVALUE]" + Environment.NewLine + Environment.NewLine + checkBoxFullFrameImage.Top = comboBoxFrameRate.Top + comboBoxFrameRate.Height + 5; panelFullFrameBackground.Top = checkBoxFullFrameImage.Top; } + else if (exportType == ExportFormats.DCinemaSmpte2014) + { + labelFrameRate.Visible = true; + comboBoxFrameRate.Visible = true; + + comboBoxFrameRate.Items.Add("24"); + comboBoxFrameRate.Items.Add("25"); + comboBoxFrameRate.Items.Add("30"); + comboBoxFrameRate.Items.Add("50"); + comboBoxFrameRate.Items.Add("60"); + comboBoxFrameRate.SelectedIndex = 2; + comboBoxFrameRate.DropDownStyle = ComboBoxStyle.DropDownList; + } + if (comboBoxFrameRate.Items.Count >= 2) { SetLastFrameRate(Configuration.Settings.Tools.ExportLastFrameRate);