From b02d9ef8d628829c984cc4771080d10ac7fc1876 Mon Sep 17 00:00:00 2001 From: n00mkrad <61149547+n00mkrad@users.noreply.github.com> Date: Thu, 14 May 2026 01:40:56 +0200 Subject: [PATCH] Option to start realtime player in fullscreen --- CodeLegacy/Forms/Main/Form1.Designer.cs | 23 +++++++++++++++++++---- CodeLegacy/Forms/Main/Form1.cs | 3 +++ CodeLegacy/Main/Export.cs | 9 ++++----- CodeLegacy/Os/AiProcess.cs | 2 +- 4 files changed, 27 insertions(+), 10 deletions(-) diff --git a/CodeLegacy/Forms/Main/Form1.Designer.cs b/CodeLegacy/Forms/Main/Form1.Designer.cs index f2e3906..c32e2bc 100644 --- a/CodeLegacy/Forms/Main/Form1.Designer.cs +++ b/CodeLegacy/Forms/Main/Form1.Designer.cs @@ -143,6 +143,7 @@ this.cancelBtn = new System.Windows.Forms.Button(); this.menuStripQueue = new System.Windows.Forms.ContextMenuStrip(this.components); this.addCurrentConfigurationToQueueToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.checkRealtimeFs = new System.Windows.Forms.CheckBox(); this.panel1.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.pictureBox4)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.pictureBox3)).BeginInit(); @@ -946,6 +947,7 @@ // flowLayoutPanel1 // this.flowLayoutPanel1.Controls.Add(this.comboxOutputFormat); + this.flowLayoutPanel1.Controls.Add(this.checkRealtimeFs); this.flowLayoutPanel1.Controls.Add(this.comboxOutputEncoder); this.flowLayoutPanel1.Controls.Add(this.comboxOutputQuality); this.flowLayoutPanel1.Controls.Add(this.textboxOutputQualityCust); @@ -976,7 +978,7 @@ this.comboxOutputEncoder.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.comboxOutputEncoder.ForeColor = System.Drawing.Color.White; this.comboxOutputEncoder.FormattingEnabled = true; - this.comboxOutputEncoder.Location = new System.Drawing.Point(81, 0); + this.comboxOutputEncoder.Location = new System.Drawing.Point(204, 0); this.comboxOutputEncoder.Margin = new System.Windows.Forms.Padding(0, 0, 6, 0); this.comboxOutputEncoder.Name = "comboxOutputEncoder"; this.comboxOutputEncoder.Size = new System.Drawing.Size(90, 23); @@ -990,7 +992,7 @@ this.comboxOutputQuality.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.comboxOutputQuality.ForeColor = System.Drawing.Color.White; this.comboxOutputQuality.FormattingEnabled = true; - this.comboxOutputQuality.Location = new System.Drawing.Point(177, 0); + this.comboxOutputQuality.Location = new System.Drawing.Point(300, 0); this.comboxOutputQuality.Margin = new System.Windows.Forms.Padding(0, 0, 6, 0); this.comboxOutputQuality.Name = "comboxOutputQuality"; this.comboxOutputQuality.Size = new System.Drawing.Size(100, 23); @@ -1002,7 +1004,7 @@ this.textboxOutputQualityCust.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64))))); this.textboxOutputQualityCust.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.textboxOutputQualityCust.ForeColor = System.Drawing.Color.White; - this.textboxOutputQualityCust.Location = new System.Drawing.Point(283, 0); + this.textboxOutputQualityCust.Location = new System.Drawing.Point(406, 0); this.textboxOutputQualityCust.Margin = new System.Windows.Forms.Padding(0, 0, 6, 0); this.textboxOutputQualityCust.MaxLength = 3; this.textboxOutputQualityCust.MinimumSize = new System.Drawing.Size(4, 21); @@ -1019,7 +1021,7 @@ this.comboxOutputColors.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.comboxOutputColors.ForeColor = System.Drawing.Color.White; this.comboxOutputColors.FormattingEnabled = true; - this.comboxOutputColors.Location = new System.Drawing.Point(319, 0); + this.comboxOutputColors.Location = new System.Drawing.Point(442, 0); this.comboxOutputColors.Margin = new System.Windows.Forms.Padding(0); this.comboxOutputColors.Name = "comboxOutputColors"; this.comboxOutputColors.Size = new System.Drawing.Size(117, 23); @@ -1694,6 +1696,18 @@ this.addCurrentConfigurationToQueueToolStripMenuItem.Text = "Add Current Configuration to Queue"; this.addCurrentConfigurationToQueueToolStripMenuItem.Click += new System.EventHandler(this.addCurrentConfigurationToQueueToolStripMenuItem_Click); // + // checkRealtimeFs + // + this.checkRealtimeFs.AutoSize = true; + this.checkRealtimeFs.ForeColor = System.Drawing.Color.White; + this.checkRealtimeFs.Location = new System.Drawing.Point(84, 3); + this.checkRealtimeFs.Name = "checkRealtimeFs"; + this.checkRealtimeFs.Size = new System.Drawing.Size(117, 19); + this.checkRealtimeFs.TabIndex = 48; + this.checkRealtimeFs.Text = "Play in Fullscreen"; + this.checkRealtimeFs.UseVisualStyleBackColor = true; + this.checkRealtimeFs.Visible = false; + // // Form1 // this.AllowDrop = true; @@ -1884,6 +1898,7 @@ public System.Windows.Forms.TabPage welcomeTab; private System.Windows.Forms.Label label5; private System.Windows.Forms.ComboBox vfrHandling; + public System.Windows.Forms.CheckBox checkRealtimeFs; } } diff --git a/CodeLegacy/Forms/Main/Form1.cs b/CodeLegacy/Forms/Main/Form1.cs index 8e7a563..368a28d 100644 --- a/CodeLegacy/Forms/Main/Form1.cs +++ b/CodeLegacy/Forms/Main/Form1.cs @@ -141,6 +141,7 @@ namespace Flowframes.Forms.Main var outMode = ParseUtils.GetEnum(comboxOutputFormat.Text, true, Strings.OutputFormat); comboxOutputEncoder.FillFromEnum(OutputUtils.GetAvailableEncoders(outMode), Strings.Encoder, 0); comboxOutputEncoder.Visible = comboxOutputEncoder.Items.Count > 0; + checkRealtimeFs.Visible = outMode == Enums.Output.Format.Realtime; UpdateOutputEncodingUi(); } @@ -523,10 +524,12 @@ namespace Flowframes.Forms.Main if (comboxOutputQuality.Visible) strings.Add(comboxOutputQuality.Text); if (comboxOutputColors.Visible) strings.Add(comboxOutputColors.Text); Config.Set(Config.Key.lastOutputSettings, string.Join(",", strings)); + ConfigParser.SaveGuiElement(checkRealtimeFs); } private void LoadOutputSettings() { + ConfigParser.LoadGuiElement(checkRealtimeFs); string[] strings = Config.Get(Config.Key.lastOutputSettings).Split(','); if (strings.Length < 4) diff --git a/CodeLegacy/Main/Export.cs b/CodeLegacy/Main/Export.cs index 1e218bd..74f2c2e 100644 --- a/CodeLegacy/Main/Export.cs +++ b/CodeLegacy/Main/Export.cs @@ -108,11 +108,10 @@ namespace Flowframes.Main { encArgs = _useNutPipe ? "-c:v rawvideo -pix_fmt rgba" : $"-pix_fmt yuv444p16"; string format = _useNutPipe ? "nut" : "yuv4mpegpipe"; - - return - $"{extraArgsIn} -i - {encArgs} {""} -f {format} - | ffplay - " + - $"-autoexit -seek_interval {VapourSynthUtils.GetSeekSeconds(Program.mainForm.currInDuration)} " + - $"-window_title \"Flowframes Realtime Interpolation ({s.inFps.GetString()} FPS x{s.interpFactor} = {s.outFps.GetString()} FPS) ({s.model.Name})\" "; + string seek = $"-seek_interval {VapourSynthUtils.GetSeekSeconds(Program.mainForm.currInDuration)}"; + string title = $"\"Flowframes Realtime Interpolation ({s.inFps.GetString()} FPS x{s.interpFactor} = {s.outFps.GetString()} FPS) ({s.model.Name})\""; + string fs = Program.mainForm.checkRealtimeFs.Checked ? "-fs " : ""; + return $"{extraArgsIn} -i - {encArgs} {""} -f {format} - | ffplay - -autoexit {seek} {fs} -window_title {title} "; } else { diff --git a/CodeLegacy/Os/AiProcess.cs b/CodeLegacy/Os/AiProcess.cs index 908c41d..ae5ee03 100644 --- a/CodeLegacy/Os/AiProcess.cs +++ b/CodeLegacy/Os/AiProcess.cs @@ -379,7 +379,7 @@ namespace Flowframes.Os if (rt) { Logger.ClearLogBox(); - Logger.Log($"Starting. Use Space to pause, Left Arrow and Right Arrow to seek, though seeking can be slow."); + Logger.Log($"Starting. Use Space to pause, Left Arrow and Right Arrow to seek (can be slow), Q to exit."); AiStartedRt(rifeNcnnVs, inPath); } else