av dump: support resizing everything to a single resolution. sorry about all the crap gumming up MainForm...

This commit is contained in:
goyuken 2012-11-26 02:25:23 +00:00
parent 0eea66c54b
commit fa388ed149
7 changed files with 260 additions and 111 deletions

View File

@ -56,6 +56,10 @@ namespace BizHawk
public string TraceHeader = "Instructions";
// size hint to a/v out resizer. this probably belongs in VideoProvider? but it's somewhat different than VirtualWidth...
public int NominalWidth = 640;
public int NominalHeight = 480;
public bool DriveLED = false;
public bool UsesDriveLed = false;
}

View File

@ -9,7 +9,7 @@ namespace BizHawk.MultiClient.AVOut
/// <summary>
/// an IVideoProivder wrapping a Bitmap
/// </summary>
public class BmpVideoProvder : IVideoProvider
public class BmpVideoProvder : IVideoProvider, IDisposable
{
Bitmap bmp;
public BmpVideoProvder(Bitmap bmp)
@ -17,6 +17,15 @@ namespace BizHawk.MultiClient.AVOut
this.bmp = bmp;
}
public void Dispose()
{
if (bmp != null)
{
bmp.Dispose();
bmp = null;
}
}
public int[] GetVideoBuffer()
{
// is there a faster way to do this?

View File

@ -29,138 +29,186 @@
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(VideoWriterChooserForm));
this.checkBoxResize = new System.Windows.Forms.CheckBox();
this.listBox1 = new System.Windows.Forms.ListBox();
this.button1 = new System.Windows.Forms.Button();
this.button2 = new System.Windows.Forms.Button();
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
this.label1 = new System.Windows.Forms.Label();
this.buttonOK = new System.Windows.Forms.Button();
this.buttonCancel = new System.Windows.Forms.Button();
this.tableLayoutPanel4 = new System.Windows.Forms.TableLayoutPanel();
this.label2 = new System.Windows.Forms.Label();
this.tableLayoutPanel1.SuspendLayout();
this.tableLayoutPanel2.SuspendLayout();
this.labelDescription = new System.Windows.Forms.Label();
this.labelDescriptionBody = new System.Windows.Forms.Label();
this.numericTextBoxW = new BizHawk.MultiClient.AVOut.NumericTextBox();
this.numericTextBoxH = new BizHawk.MultiClient.AVOut.NumericTextBox();
this.label3 = new System.Windows.Forms.Label();
this.label4 = new System.Windows.Forms.Label();
this.buttonAuto = new System.Windows.Forms.Button();
this.panelSizeSelect = new System.Windows.Forms.Panel();
this.tableLayoutPanel4.SuspendLayout();
this.panelSizeSelect.SuspendLayout();
this.SuspendLayout();
//
// checkBoxResize
//
this.checkBoxResize.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.checkBoxResize.AutoSize = true;
this.checkBoxResize.Location = new System.Drawing.Point(347, 12);
this.checkBoxResize.Name = "checkBoxResize";
this.checkBoxResize.Size = new System.Drawing.Size(88, 17);
this.checkBoxResize.TabIndex = 9;
this.checkBoxResize.Text = "Resize Video";
this.checkBoxResize.UseVisualStyleBackColor = true;
this.checkBoxResize.CheckedChanged += new System.EventHandler(this.checkBoxResize_CheckedChanged);
//
// listBox1
//
this.tableLayoutPanel1.SetColumnSpan(this.listBox1, 2);
this.listBox1.Dock = System.Windows.Forms.DockStyle.Fill;
this.listBox1.FormattingEnabled = true;
this.listBox1.IntegralHeight = false;
this.listBox1.Location = new System.Drawing.Point(3, 3);
this.listBox1.Location = new System.Drawing.Point(12, 12);
this.listBox1.Margin = new System.Windows.Forms.Padding(3, 3, 3, 0);
this.listBox1.Name = "listBox1";
this.listBox1.Size = new System.Drawing.Size(668, 283);
this.listBox1.Size = new System.Drawing.Size(329, 202);
this.listBox1.TabIndex = 0;
this.listBox1.SelectedIndexChanged += new System.EventHandler(this.listBox1_SelectedIndexChanged);
//
// button1
// buttonOK
//
this.button1.DialogResult = System.Windows.Forms.DialogResult.OK;
this.button1.Location = new System.Drawing.Point(3, 3);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(96, 32);
this.button1.TabIndex = 1;
this.button1.Text = "OK";
this.button1.UseVisualStyleBackColor = true;
this.buttonOK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.buttonOK.DialogResult = System.Windows.Forms.DialogResult.OK;
this.buttonOK.Location = new System.Drawing.Point(373, 405);
this.buttonOK.Name = "buttonOK";
this.buttonOK.Size = new System.Drawing.Size(65, 23);
this.buttonOK.TabIndex = 1;
this.buttonOK.Text = "OK";
this.buttonOK.UseVisualStyleBackColor = true;
this.buttonOK.Click += new System.EventHandler(this.buttonOK_Click);
//
// button2
// buttonCancel
//
this.button2.DialogResult = System.Windows.Forms.DialogResult.Cancel;
this.button2.Location = new System.Drawing.Point(105, 3);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(96, 32);
this.button2.TabIndex = 2;
this.button2.Text = "Cancel";
this.button2.UseVisualStyleBackColor = true;
//
// tableLayoutPanel1
//
this.tableLayoutPanel1.AutoSize = true;
this.tableLayoutPanel1.ColumnCount = 2;
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
this.tableLayoutPanel1.Controls.Add(this.tableLayoutPanel4, 0, 1);
this.tableLayoutPanel1.Controls.Add(this.tableLayoutPanel2, 1, 1);
this.tableLayoutPanel1.Controls.Add(this.listBox1, 0, 0);
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
this.tableLayoutPanel1.RowCount = 2;
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle());
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 20F));
this.tableLayoutPanel1.Size = new System.Drawing.Size(674, 392);
this.tableLayoutPanel1.TabIndex = 5;
//
// tableLayoutPanel2
//
this.tableLayoutPanel2.AutoSize = true;
this.tableLayoutPanel2.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
this.tableLayoutPanel2.ColumnCount = 2;
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel2.Controls.Add(this.button2, 1, 0);
this.tableLayoutPanel2.Controls.Add(this.button1, 0, 0);
this.tableLayoutPanel2.Dock = System.Windows.Forms.DockStyle.Bottom;
this.tableLayoutPanel2.Location = new System.Drawing.Point(467, 351);
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
this.tableLayoutPanel2.RowCount = 1;
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel2.Size = new System.Drawing.Size(204, 38);
this.tableLayoutPanel2.TabIndex = 6;
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(5, 2);
this.label1.Name = "label1";
this.label1.Padding = new System.Windows.Forms.Padding(0, 3, 0, 3);
this.label1.Size = new System.Drawing.Size(63, 19);
this.label1.TabIndex = 3;
this.label1.Text = "Description:";
this.buttonCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.buttonCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
this.buttonCancel.Location = new System.Drawing.Point(444, 405);
this.buttonCancel.Name = "buttonCancel";
this.buttonCancel.Size = new System.Drawing.Size(65, 23);
this.buttonCancel.TabIndex = 2;
this.buttonCancel.Text = "Cancel";
this.buttonCancel.UseVisualStyleBackColor = true;
//
// tableLayoutPanel4
//
this.tableLayoutPanel4.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.tableLayoutPanel4.CellBorderStyle = System.Windows.Forms.TableLayoutPanelCellBorderStyle.Inset;
this.tableLayoutPanel4.ColumnCount = 1;
this.tableLayoutPanel4.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tableLayoutPanel4.Controls.Add(this.label2, 0, 1);
this.tableLayoutPanel4.Controls.Add(this.label1, 0, 0);
this.tableLayoutPanel4.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel4.Location = new System.Drawing.Point(3, 289);
this.tableLayoutPanel4.Controls.Add(this.labelDescription, 0, 0);
this.tableLayoutPanel4.Controls.Add(this.labelDescriptionBody, 0, 1);
this.tableLayoutPanel4.Location = new System.Drawing.Point(12, 220);
this.tableLayoutPanel4.Name = "tableLayoutPanel4";
this.tableLayoutPanel4.RowCount = 2;
this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle());
this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tableLayoutPanel4.Size = new System.Drawing.Size(458, 100);
this.tableLayoutPanel4.Size = new System.Drawing.Size(329, 208);
this.tableLayoutPanel4.TabIndex = 8;
//
// label2
// labelDescription
//
this.label2.Location = new System.Drawing.Point(5, 23);
this.label2.Name = "label2";
this.label2.Padding = new System.Windows.Forms.Padding(0, 3, 0, 3);
this.label2.Size = new System.Drawing.Size(448, 75);
this.label2.TabIndex = 6;
this.label2.Text = resources.GetString("label2.Text");
this.labelDescription.AutoSize = true;
this.labelDescription.Dock = System.Windows.Forms.DockStyle.Fill;
this.labelDescription.Location = new System.Drawing.Point(5, 2);
this.labelDescription.Name = "labelDescription";
this.labelDescription.Padding = new System.Windows.Forms.Padding(0, 3, 0, 3);
this.labelDescription.Size = new System.Drawing.Size(319, 19);
this.labelDescription.TabIndex = 3;
this.labelDescription.Text = "Description:";
//
// labelDescriptionBody
//
this.labelDescriptionBody.Dock = System.Windows.Forms.DockStyle.Fill;
this.labelDescriptionBody.Location = new System.Drawing.Point(5, 23);
this.labelDescriptionBody.Name = "labelDescriptionBody";
this.labelDescriptionBody.Padding = new System.Windows.Forms.Padding(0, 3, 0, 3);
this.labelDescriptionBody.Size = new System.Drawing.Size(319, 183);
this.labelDescriptionBody.TabIndex = 6;
this.labelDescriptionBody.Text = resources.GetString("labelDescriptionBody.Text");
//
// numericTextBoxW
//
this.numericTextBoxW.AllowDecimal = false;
this.numericTextBoxW.AllowNegative = false;
this.numericTextBoxW.AllowSpace = false;
this.numericTextBoxW.Location = new System.Drawing.Point(0, 16);
this.numericTextBoxW.Name = "numericTextBoxW";
this.numericTextBoxW.Size = new System.Drawing.Size(70, 20);
this.numericTextBoxW.TabIndex = 10;
//
// numericTextBoxH
//
this.numericTextBoxH.AllowDecimal = false;
this.numericTextBoxH.AllowNegative = false;
this.numericTextBoxH.AllowSpace = false;
this.numericTextBoxH.Location = new System.Drawing.Point(92, 16);
this.numericTextBoxH.Name = "numericTextBoxH";
this.numericTextBoxH.Size = new System.Drawing.Size(70, 20);
this.numericTextBoxH.TabIndex = 11;
//
// label3
//
this.label3.AutoSize = true;
this.label3.Location = new System.Drawing.Point(74, 23);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(14, 13);
this.label3.TabIndex = 12;
this.label3.Text = "X";
//
// label4
//
this.label4.AutoSize = true;
this.label4.Location = new System.Drawing.Point(3, 0);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(30, 13);
this.label4.TabIndex = 13;
this.label4.Text = "Size:";
//
// buttonAuto
//
this.buttonAuto.Location = new System.Drawing.Point(0, 42);
this.buttonAuto.Name = "buttonAuto";
this.buttonAuto.Size = new System.Drawing.Size(162, 23);
this.buttonAuto.TabIndex = 14;
this.buttonAuto.Text = "Autodetect Size";
this.buttonAuto.UseVisualStyleBackColor = true;
this.buttonAuto.Click += new System.EventHandler(this.buttonAuto_Click);
//
// panelSizeSelect
//
this.panelSizeSelect.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
this.panelSizeSelect.Controls.Add(this.label4);
this.panelSizeSelect.Controls.Add(this.buttonAuto);
this.panelSizeSelect.Controls.Add(this.numericTextBoxW);
this.panelSizeSelect.Controls.Add(this.numericTextBoxH);
this.panelSizeSelect.Controls.Add(this.label3);
this.panelSizeSelect.Location = new System.Drawing.Point(347, 35);
this.panelSizeSelect.Name = "panelSizeSelect";
this.panelSizeSelect.Size = new System.Drawing.Size(162, 83);
this.panelSizeSelect.TabIndex = 15;
//
// VideoWriterChooserForm
//
this.AcceptButton = this.button1;
this.AcceptButton = this.buttonOK;
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.CancelButton = this.button2;
this.ClientSize = new System.Drawing.Size(674, 392);
this.Controls.Add(this.tableLayoutPanel1);
this.CancelButton = this.buttonCancel;
this.ClientSize = new System.Drawing.Size(521, 440);
this.Controls.Add(this.panelSizeSelect);
this.Controls.Add(this.tableLayoutPanel4);
this.Controls.Add(this.listBox1);
this.Controls.Add(this.buttonOK);
this.Controls.Add(this.buttonCancel);
this.Controls.Add(this.checkBoxResize);
this.Name = "VideoWriterChooserForm";
this.Text = "Choose A\\V Writer";
this.tableLayoutPanel1.ResumeLayout(false);
this.tableLayoutPanel1.PerformLayout();
this.tableLayoutPanel2.ResumeLayout(false);
this.tableLayoutPanel4.ResumeLayout(false);
this.tableLayoutPanel4.PerformLayout();
this.panelSizeSelect.ResumeLayout(false);
this.panelSizeSelect.PerformLayout();
this.ResumeLayout(false);
this.PerformLayout();
@ -168,13 +216,19 @@
#endregion
private System.Windows.Forms.CheckBox checkBoxResize;
private System.Windows.Forms.ListBox listBox1;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.Button button2;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Button buttonOK;
private System.Windows.Forms.Button buttonCancel;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel4;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Label labelDescription;
private System.Windows.Forms.Label labelDescriptionBody;
private AVOut.NumericTextBox numericTextBoxW;
private AVOut.NumericTextBox numericTextBoxH;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.Button buttonAuto;
private System.Windows.Forms.Panel panelSizeSelect;
}
}

View File

@ -14,7 +14,7 @@ namespace BizHawk.MultiClient
/// </summary>
public partial class VideoWriterChooserForm : Form
{
public VideoWriterChooserForm()
VideoWriterChooserForm()
{
InitializeComponent();
}
@ -25,11 +25,11 @@ namespace BizHawk.MultiClient
/// <param name="list">list of IVideoWriters to choose from</param>
/// <param name="owner">parent window</param>
/// <returns>user choice, or null on Cancel\Close\invalid</returns>
public static IVideoWriter DoVideoWriterChoserDlg(IEnumerable<IVideoWriter> list, IWin32Window owner)
public static IVideoWriter DoVideoWriterChoserDlg(IEnumerable<IVideoWriter> list, IWin32Window owner, out int resizew, out int resizeh)
{
VideoWriterChooserForm dlg = new VideoWriterChooserForm();
dlg.label2.Text = "";
dlg.labelDescriptionBody.Text = "";
dlg.listBox1.BeginUpdate();
foreach (var vw in list)
@ -40,6 +40,9 @@ namespace BizHawk.MultiClient
if (i != ListBox.NoMatches)
dlg.listBox1.SelectedIndex = i;
foreach (Control c in dlg.panelSizeSelect.Controls)
c.Enabled = false;
DialogResult result = dlg.ShowDialog(owner);
IVideoWriter ret;
@ -52,6 +55,16 @@ namespace BizHawk.MultiClient
else
ret = null;
if (ret != null && dlg.checkBoxResize.Checked)
{
resizew = dlg.numericTextBoxW.IntValue;
resizeh = dlg.numericTextBoxH.IntValue;
}
else
{
resizew = -1;
resizeh = -1;
}
dlg.Dispose();
return ret;
}
@ -59,9 +72,43 @@ namespace BizHawk.MultiClient
private void listBox1_SelectedIndexChanged(object sender, EventArgs e)
{
if (listBox1.SelectedIndex != -1)
label2.Text = ((IVideoWriter)listBox1.SelectedItem).WriterDescription();
labelDescriptionBody.Text = ((IVideoWriter)listBox1.SelectedItem).WriterDescription();
else
label2.Text = "";
labelDescriptionBody.Text = "";
}
private void checkBoxResize_CheckedChanged(object sender, EventArgs e)
{
foreach (Control c in panelSizeSelect.Controls)
c.Enabled = checkBoxResize.Checked;
}
private void buttonAuto_Click(object sender, EventArgs e)
{
numericTextBoxW.Text = Global.Emulator.CoreOutputComm.NominalWidth.ToString();
numericTextBoxH.Text = Global.Emulator.CoreOutputComm.NominalHeight.ToString();
}
private void buttonOK_Click(object sender, EventArgs e)
{
if (checkBoxResize.Checked)
{
try
{
if (numericTextBoxW.IntValue < 1 || numericTextBoxH.IntValue < 1)
{
MessageBox.Show(this, "Size must be positive!");
DialogResult = DialogResult.None;
return;
}
}
catch (FormatException)
{
MessageBox.Show(this, "Size must be numeric!");
DialogResult = DialogResult.None;
return;
}
}
}
}
}

View File

@ -117,7 +117,7 @@
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="label2.Text" xml:space="preserve">
<data name="labelDescriptionBody.Text" xml:space="preserve">
<value>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean tempor congue imperdiet. Etiam aliquam lobortis magna hendrerit euismod. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Vivamus interdum nibh a sem tincidunt ac vehicula mi tempus. Morbi eu felis elit. </value>
</data>
</root>

View File

@ -140,6 +140,9 @@
<DependentUpon>JMDForm.cs</DependentUpon>
</Compile>
<Compile Include="AVOut\JMDWriter.cs" />
<Compile Include="AVOut\NumericTextBox.cs">
<SubType>Component</SubType>
</Compile>
<Compile Include="AVOut\NutMuxer.cs" />
<Compile Include="AVOut\NutWriter.cs" />
<Compile Include="AVOut\VideoWriterChooserForm.cs">

View File

@ -49,6 +49,8 @@ namespace BizHawk.MultiClient
Emulation.Sound.MetaspuSoundProvider DumpProxy = null;
/// <summary>audio timekeeping for video dumping</summary>
long SoundRemainder = 0;
int avwriter_resizew;
int avwriter_resizeh;
//runloop control
bool exit;
@ -2649,10 +2651,37 @@ namespace BizHawk.MultiClient
try
{
if (Global.Config.AVI_CaptureOSD)
CurrAviWriter.AddFrame(new AVOut.BmpVideoProvder(CaptureOSD()));
IVideoProvider output;
if (avwriter_resizew > 0 && avwriter_resizeh > 0)
{
Bitmap bmpin;
if (Global.Config.AVI_CaptureOSD)
bmpin = CaptureOSD();
else
{
bmpin = new Bitmap(Global.Emulator.VideoProvider.BufferWidth, Global.Emulator.VideoProvider.BufferHeight, PixelFormat.Format32bppArgb);
var lockdata = bmpin.LockBits(new Rectangle(0, 0, bmpin.Width, bmpin.Height), ImageLockMode.WriteOnly, PixelFormat.Format32bppArgb);
System.Runtime.InteropServices.Marshal.Copy(Global.Emulator.VideoProvider.GetVideoBuffer(), 0, lockdata.Scan0, bmpin.Width * bmpin.Height);
bmpin.UnlockBits(lockdata);
}
Bitmap bmpout = new Bitmap(avwriter_resizew, avwriter_resizeh, PixelFormat.Format32bppArgb);
using (Graphics g = Graphics.FromImage(bmpout))
g.DrawImage(bmpin, new Rectangle(0, 0, bmpout.Width, bmpout.Height));
bmpin.Dispose();
output = new AVOut.BmpVideoProvder(bmpout);
}
else
CurrAviWriter.AddFrame(Global.Emulator.VideoProvider);
{
if (Global.Config.AVI_CaptureOSD)
output = new AVOut.BmpVideoProvder(CaptureOSD());
else
output = Global.Emulator.VideoProvider;
}
CurrAviWriter.AddFrame(output);
if (output is AVOut.BmpVideoProvder)
(output as AVOut.BmpVideoProvder).Dispose();
CurrAviWriter.AddSamples(temp);
}
catch (Exception e)
@ -3725,7 +3754,7 @@ namespace BizHawk.MultiClient
}
else
{
aw = VideoWriterChooserForm.DoVideoWriterChoserDlg(writers, Global.MainForm);
aw = VideoWriterChooserForm.DoVideoWriterChoserDlg(writers, Global.MainForm, out avwriter_resizew, out avwriter_resizeh);
}
foreach (var w in writers)
@ -3746,7 +3775,10 @@ namespace BizHawk.MultiClient
try
{
aw.SetMovieParameters(Global.Emulator.CoreOutputComm.VsyncNum, Global.Emulator.CoreOutputComm.VsyncDen);
aw.SetVideoParameters(Global.Emulator.VideoProvider.BufferWidth, Global.Emulator.VideoProvider.BufferHeight);
if (avwriter_resizew > 0 && avwriter_resizeh > 0)
aw.SetVideoParameters(avwriter_resizew, avwriter_resizeh);
else
aw.SetVideoParameters(Global.Emulator.VideoProvider.BufferWidth, Global.Emulator.VideoProvider.BufferHeight);
aw.SetAudioParameters(44100, 2, 16);
// select codec token