diff --git a/OGL/FormJSCalCurve.Designer.cs b/OGL/FormJSCalCurve.Designer.cs index 869580f..bb279d8 100644 --- a/OGL/FormJSCalCurve.Designer.cs +++ b/OGL/FormJSCalCurve.Designer.cs @@ -26,1826 +26,1878 @@ /// private void InitializeComponent( ) { - System.Windows.Forms.DataVisualization.Charting.ChartArea chartArea1 = new System.Windows.Forms.DataVisualization.Charting.ChartArea(); - System.Windows.Forms.DataVisualization.Charting.Series series1 = new System.Windows.Forms.DataVisualization.Charting.Series(); - System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FormJSCalCurve)); - this.glControl1 = new OpenTK.GLControl(); - this.tlp = new System.Windows.Forms.TableLayoutPanel(); - this.tlpData = new System.Windows.Forms.TableLayoutPanel(); - this.panel2 = new System.Windows.Forms.Panel(); - this.pnlYaw = new System.Windows.Forms.Panel(); - this.lblYnt = new System.Windows.Forms.Label(); - this.cbxYinvert = new System.Windows.Forms.CheckBox(); - this.cbxYpts = new System.Windows.Forms.CheckBox(); - this.cbxYexpo = new System.Windows.Forms.CheckBox(); - this.cbxYsat = new System.Windows.Forms.CheckBox(); - this.cbxYdeadzone = new System.Windows.Forms.CheckBox(); - this.label25 = new System.Windows.Forms.Label(); - this.label24 = new System.Windows.Forms.Label(); - this.label23 = new System.Windows.Forms.Label(); - this.lblYout3 = new System.Windows.Forms.Label(); - this.lblYin3 = new System.Windows.Forms.Label(); - this.lblYout2 = new System.Windows.Forms.Label(); - this.lblYin2 = new System.Windows.Forms.Label(); - this.lblYout1 = new System.Windows.Forms.Label(); - this.lblYin1 = new System.Windows.Forms.Label(); - this.lblYsat = new System.Windows.Forms.Label(); - this.lblYexponent = new System.Windows.Forms.Label(); - this.lblYdeadzone = new System.Windows.Forms.Label(); - this.lblYCmd = new System.Windows.Forms.Label(); - this.lblYaw = new System.Windows.Forms.Label(); - this.pnlPitch = new System.Windows.Forms.Panel(); - this.lblPnt = new System.Windows.Forms.Label(); - this.cbxPinvert = new System.Windows.Forms.CheckBox(); - this.cbxPpts = new System.Windows.Forms.CheckBox(); - this.cbxPexpo = new System.Windows.Forms.CheckBox(); - this.cbxPsat = new System.Windows.Forms.CheckBox(); - this.cbxPdeadzone = new System.Windows.Forms.CheckBox(); - this.label26 = new System.Windows.Forms.Label(); - this.label27 = new System.Windows.Forms.Label(); - this.label28 = new System.Windows.Forms.Label(); - this.lblPout3 = new System.Windows.Forms.Label(); - this.lblPin3 = new System.Windows.Forms.Label(); - this.lblPout2 = new System.Windows.Forms.Label(); - this.lblPin2 = new System.Windows.Forms.Label(); - this.lblPout1 = new System.Windows.Forms.Label(); - this.lblPin1 = new System.Windows.Forms.Label(); - this.lblPsat = new System.Windows.Forms.Label(); - this.lblPexponent = new System.Windows.Forms.Label(); - this.lblPdeadzone = new System.Windows.Forms.Label(); - this.lblPCmd = new System.Windows.Forms.Label(); - this.lblPitch = new System.Windows.Forms.Label(); - this.pnlRoll = new System.Windows.Forms.Panel(); - this.lblRnt = new System.Windows.Forms.Label(); - this.cbxRinvert = new System.Windows.Forms.CheckBox(); - this.cbxRpts = new System.Windows.Forms.CheckBox(); - this.cbxRexpo = new System.Windows.Forms.CheckBox(); - this.cbxRsat = new System.Windows.Forms.CheckBox(); - this.cbxRdeadzone = new System.Windows.Forms.CheckBox(); - this.label35 = new System.Windows.Forms.Label(); - this.label36 = new System.Windows.Forms.Label(); - this.label37 = new System.Windows.Forms.Label(); - this.lblRout3 = new System.Windows.Forms.Label(); - this.lblRin3 = new System.Windows.Forms.Label(); - this.lblRout2 = new System.Windows.Forms.Label(); - this.lblRin2 = new System.Windows.Forms.Label(); - this.lblRout1 = new System.Windows.Forms.Label(); - this.lblRin1 = new System.Windows.Forms.Label(); - this.lblRsat = new System.Windows.Forms.Label(); - this.lblRexponent = new System.Windows.Forms.Label(); - this.lblRdeadzone = new System.Windows.Forms.Label(); - this.lblRCmd = new System.Windows.Forms.Label(); - this.lblRoll = new System.Windows.Forms.Label(); - this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); - this.panel9 = new System.Windows.Forms.Panel(); - this.label6 = new System.Windows.Forms.Label(); - this.lblDamping = new System.Windows.Forms.Label(); - this.slDamping = new System.Windows.Forms.TrackBar(); - this.panel1 = new System.Windows.Forms.Panel(); - this.label16 = new System.Windows.Forms.Label(); - this.lblTurnspeed = new System.Windows.Forms.Label(); - this.slTurnSpeed = new System.Windows.Forms.TrackBar(); - this.panel6 = new System.Windows.Forms.Panel(); - this.rbPtDeadzone = new System.Windows.Forms.RadioButton(); - this.lblGraphSaturation = new System.Windows.Forms.Label(); - this.lblGraphDeadzone = new System.Windows.Forms.Label(); - this.lblNodetext = new System.Windows.Forms.Label(); - this.label12 = new System.Windows.Forms.Label(); - this.cbRuse = new System.Windows.Forms.CheckBox(); - this.cbPuse = new System.Windows.Forms.CheckBox(); - this.cbYuse = new System.Windows.Forms.CheckBox(); - this.label11 = new System.Windows.Forms.Label(); - this.label10 = new System.Windows.Forms.Label(); - this.lblROutput = new System.Windows.Forms.Label(); - this.lblRInput = new System.Windows.Forms.Label(); - this.lblPOutput = new System.Windows.Forms.Label(); - this.lblPInput = new System.Windows.Forms.Label(); - this.lblLiveRoll = new System.Windows.Forms.Label(); - this.lblLivePitch = new System.Windows.Forms.Label(); - this.btCopyToAllAxis = new System.Windows.Forms.Button(); - this.lblLiveYaw = new System.Windows.Forms.Label(); - this.label4 = new System.Windows.Forms.Label(); - this.lblYOutput = new System.Windows.Forms.Label(); - this.lblYInput = new System.Windows.Forms.Label(); - this.rbPtExponent = new System.Windows.Forms.RadioButton(); - this.rbPtSaturation = new System.Windows.Forms.RadioButton(); - this.rbPt3 = new System.Windows.Forms.RadioButton(); - this.rbPt2 = new System.Windows.Forms.RadioButton(); - this.rbPt1 = new System.Windows.Forms.RadioButton(); - this.label33 = new System.Windows.Forms.Label(); - this.label32 = new System.Windows.Forms.Label(); - this.lblOut3 = new System.Windows.Forms.Label(); - this.lblIn3 = new System.Windows.Forms.Label(); - this.lblOut2 = new System.Windows.Forms.Label(); - this.lblIn2 = new System.Windows.Forms.Label(); - this.lblOut1 = new System.Windows.Forms.Label(); - this.lblIn1 = new System.Windows.Forms.Label(); - this.chart1 = new System.Windows.Forms.DataVisualization.Charting.Chart(); - this.lblOutSlider = new System.Windows.Forms.Label(); - this.lblOutExponent = new System.Windows.Forms.Label(); - this.tbSlider = new System.Windows.Forms.TrackBar(); - this.flowLayoutPanel1 = new System.Windows.Forms.FlowLayoutPanel(); - this.rb300 = new System.Windows.Forms.RadioButton(); - this.rbHornet = new System.Windows.Forms.RadioButton(); - this.rbAurora = new System.Windows.Forms.RadioButton(); - this.tableLayoutPanel3 = new System.Windows.Forms.TableLayoutPanel(); - this.btDone = new System.Windows.Forms.Button(); - this.panel8 = new System.Windows.Forms.Panel(); - this.rbSunset = new System.Windows.Forms.RadioButton(); - this.rbOutThere3 = new System.Windows.Forms.RadioButton(); - this.rbSkybox = new System.Windows.Forms.RadioButton(); - this.rbOutThere1 = new System.Windows.Forms.RadioButton(); - this.rbBigSight = new System.Windows.Forms.RadioButton(); - this.rbHighway = new System.Windows.Forms.RadioButton(); - this.rbHelipad = new System.Windows.Forms.RadioButton(); - this.rbShiodome = new System.Windows.Forms.RadioButton(); - this.rbCanyon = new System.Windows.Forms.RadioButton(); - this.flowLayoutPanel2 = new System.Windows.Forms.FlowLayoutPanel(); - this.pnlAxisSelector = new System.Windows.Forms.Panel(); - this.rbP = new System.Windows.Forms.RadioButton(); - this.rbY = new System.Windows.Forms.RadioButton(); - this.rbR = new System.Windows.Forms.RadioButton(); - this.panel10 = new System.Windows.Forms.Panel(); - this.rbTuneStrafe = new System.Windows.Forms.RadioButton(); - this.rbTuneYPR = new System.Windows.Forms.RadioButton(); - this.tlp.SuspendLayout(); - this.tlpData.SuspendLayout(); - this.pnlYaw.SuspendLayout(); - this.pnlPitch.SuspendLayout(); - this.pnlRoll.SuspendLayout(); - this.tableLayoutPanel1.SuspendLayout(); - this.panel9.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.slDamping)).BeginInit(); - this.panel1.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.slTurnSpeed)).BeginInit(); - this.panel6.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.chart1)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.tbSlider)).BeginInit(); - this.flowLayoutPanel1.SuspendLayout(); - this.tableLayoutPanel3.SuspendLayout(); - this.panel8.SuspendLayout(); - this.flowLayoutPanel2.SuspendLayout(); - this.pnlAxisSelector.SuspendLayout(); - this.panel10.SuspendLayout(); - this.SuspendLayout(); - // - // glControl1 - // - this.glControl1.BackColor = System.Drawing.Color.Black; - this.glControl1.Dock = System.Windows.Forms.DockStyle.Fill; - this.glControl1.Location = new System.Drawing.Point(153, 3); - this.glControl1.Name = "glControl1"; - this.glControl1.Size = new System.Drawing.Size(1028, 610); - this.glControl1.TabIndex = 0; - this.glControl1.VSync = false; - this.glControl1.Load += new System.EventHandler(this.glControl1_Load); - this.glControl1.Paint += new System.Windows.Forms.PaintEventHandler(this.glControl1_Paint); - this.glControl1.Resize += new System.EventHandler(this.glControl1_Resize); - // - // tlp - // - this.tlp.ColumnCount = 2; - this.tlp.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 150F)); - this.tlp.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tlp.Controls.Add(this.tlpData, 0, 0); - this.tlp.Controls.Add(this.tableLayoutPanel1, 1, 1); - this.tlp.Controls.Add(this.glControl1, 1, 0); - this.tlp.Controls.Add(this.flowLayoutPanel2, 0, 1); - this.tlp.Dock = System.Windows.Forms.DockStyle.Fill; - this.tlp.GrowStyle = System.Windows.Forms.TableLayoutPanelGrowStyle.FixedSize; - this.tlp.Location = new System.Drawing.Point(0, 0); - this.tlp.Name = "tlp"; - this.tlp.RowCount = 2; - this.tlp.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tlp.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 300F)); - this.tlp.Size = new System.Drawing.Size(1184, 916); - this.tlp.TabIndex = 1; - // - // tlpData - // - this.tlpData.BackColor = System.Drawing.Color.Gold; - this.tlpData.ColumnCount = 1; - this.tlpData.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tlpData.Controls.Add(this.panel2, 0, 0); - this.tlpData.Controls.Add(this.pnlYaw, 0, 1); - this.tlpData.Controls.Add(this.pnlPitch, 0, 3); - this.tlpData.Controls.Add(this.pnlRoll, 0, 5); - this.tlpData.Dock = System.Windows.Forms.DockStyle.Top; - this.tlpData.GrowStyle = System.Windows.Forms.TableLayoutPanelGrowStyle.FixedSize; - this.tlpData.Location = new System.Drawing.Point(3, 3); - this.tlpData.Name = "tlpData"; - this.tlpData.RowCount = 8; - this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 120F)); - this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 155F)); - this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 6F)); - this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 155F)); - this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 6F)); - this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 155F)); - this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 6F)); - this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle()); - this.tlpData.Size = new System.Drawing.Size(144, 610); - this.tlpData.TabIndex = 2; - // - // panel2 - // - this.panel2.BackgroundImage = global::SCJMapper_V2.Properties.Resources.YPR; - this.panel2.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.panel2.Dock = System.Windows.Forms.DockStyle.Fill; - this.panel2.Location = new System.Drawing.Point(3, 3); - this.panel2.Name = "panel2"; - this.panel2.Size = new System.Drawing.Size(138, 114); - this.panel2.TabIndex = 0; - // - // pnlYaw - // - this.pnlYaw.BackColor = System.Drawing.Color.PowderBlue; - this.pnlYaw.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; - this.pnlYaw.Controls.Add(this.lblYnt); - this.pnlYaw.Controls.Add(this.cbxYinvert); - this.pnlYaw.Controls.Add(this.cbxYpts); - this.pnlYaw.Controls.Add(this.cbxYexpo); - this.pnlYaw.Controls.Add(this.cbxYsat); - this.pnlYaw.Controls.Add(this.cbxYdeadzone); - this.pnlYaw.Controls.Add(this.label25); - this.pnlYaw.Controls.Add(this.label24); - this.pnlYaw.Controls.Add(this.label23); - this.pnlYaw.Controls.Add(this.lblYout3); - this.pnlYaw.Controls.Add(this.lblYin3); - this.pnlYaw.Controls.Add(this.lblYout2); - this.pnlYaw.Controls.Add(this.lblYin2); - this.pnlYaw.Controls.Add(this.lblYout1); - this.pnlYaw.Controls.Add(this.lblYin1); - this.pnlYaw.Controls.Add(this.lblYsat); - this.pnlYaw.Controls.Add(this.lblYexponent); - this.pnlYaw.Controls.Add(this.lblYdeadzone); - this.pnlYaw.Controls.Add(this.lblYCmd); - this.pnlYaw.Controls.Add(this.lblYaw); - this.pnlYaw.Dock = System.Windows.Forms.DockStyle.Fill; - this.pnlYaw.Location = new System.Drawing.Point(3, 123); - this.pnlYaw.Name = "pnlYaw"; - this.pnlYaw.Size = new System.Drawing.Size(138, 149); - this.pnlYaw.TabIndex = 2; - this.pnlYaw.MouseUp += new System.Windows.Forms.MouseEventHandler(this.pnlYaw_MouseUp); - // - // lblYnt - // - this.lblYnt.AutoSize = true; - this.lblYnt.Location = new System.Drawing.Point(107, 17); - this.lblYnt.Name = "lblYnt"; - this.lblYnt.Size = new System.Drawing.Size(20, 13); - this.lblYnt.TabIndex = 23; - this.lblYnt.Text = "NT"; - this.lblYnt.Visible = false; - // - // cbxYinvert - // - this.cbxYinvert.AutoSize = true; - this.cbxYinvert.Location = new System.Drawing.Point(6, 17); - this.cbxYinvert.Name = "cbxYinvert"; - this.cbxYinvert.Size = new System.Drawing.Size(55, 17); - this.cbxYinvert.TabIndex = 22; - this.cbxYinvert.Text = "Invert"; - this.cbxYinvert.UseVisualStyleBackColor = true; - this.cbxYinvert.CheckedChanged += new System.EventHandler(this.cbxYinvert_CheckedChanged); - // - // cbxYpts - // - this.cbxYpts.AutoSize = true; - this.cbxYpts.Location = new System.Drawing.Point(6, 91); - this.cbxYpts.Name = "cbxYpts"; - this.cbxYpts.Size = new System.Drawing.Size(15, 14); - this.cbxYpts.TabIndex = 21; - this.cbxYpts.UseVisualStyleBackColor = true; - this.cbxYpts.CheckedChanged += new System.EventHandler(this.cbxYpts_CheckedChanged); - // - // cbxYexpo - // - this.cbxYexpo.AutoSize = true; - this.cbxYexpo.Location = new System.Drawing.Point(6, 71); - this.cbxYexpo.Name = "cbxYexpo"; - this.cbxYexpo.Size = new System.Drawing.Size(75, 17); - this.cbxYexpo.TabIndex = 20; - this.cbxYexpo.Text = "Exponent"; - this.cbxYexpo.UseVisualStyleBackColor = true; - this.cbxYexpo.CheckedChanged += new System.EventHandler(this.cbxYexpo_CheckedChanged); - // - // cbxYsat - // - this.cbxYsat.AutoSize = true; - this.cbxYsat.Location = new System.Drawing.Point(6, 53); - this.cbxYsat.Name = "cbxYsat"; - this.cbxYsat.Size = new System.Drawing.Size(80, 17); - this.cbxYsat.TabIndex = 19; - this.cbxYsat.Text = "Saturation"; - this.cbxYsat.UseVisualStyleBackColor = true; - this.cbxYsat.CheckedChanged += new System.EventHandler(this.cbxYsense_CheckedChanged); - // - // cbxYdeadzone - // - this.cbxYdeadzone.AutoSize = true; - this.cbxYdeadzone.Location = new System.Drawing.Point(6, 35); - this.cbxYdeadzone.Name = "cbxYdeadzone"; - this.cbxYdeadzone.Size = new System.Drawing.Size(78, 17); - this.cbxYdeadzone.TabIndex = 18; - this.cbxYdeadzone.Text = "Deadzone"; - this.cbxYdeadzone.UseVisualStyleBackColor = true; - this.cbxYdeadzone.CheckedChanged += new System.EventHandler(this.cbxYdeadzone_CheckedChanged); - // - // label25 - // - this.label25.AutoSize = true; - this.label25.Location = new System.Drawing.Point(37, 127); - this.label25.Name = "label25"; - this.label25.Size = new System.Drawing.Size(23, 13); - this.label25.TabIndex = 17; - this.label25.Text = "Pt3"; - // - // label24 - // - this.label24.AutoSize = true; - this.label24.Location = new System.Drawing.Point(37, 109); - this.label24.Name = "label24"; - this.label24.Size = new System.Drawing.Size(23, 13); - this.label24.TabIndex = 16; - this.label24.Text = "Pt2"; - // - // label23 - // - this.label23.AutoSize = true; - this.label23.Location = new System.Drawing.Point(37, 91); - this.label23.Name = "label23"; - this.label23.Size = new System.Drawing.Size(23, 13); - this.label23.TabIndex = 15; - this.label23.Text = "Pt1"; - // - // lblYout3 - // - this.lblYout3.AutoSize = true; - this.lblYout3.Location = new System.Drawing.Point(99, 127); - this.lblYout3.Name = "lblYout3"; - this.lblYout3.Size = new System.Drawing.Size(28, 13); - this.lblYout3.TabIndex = 14; - this.lblYout3.Text = "0.75"; - // - // lblYin3 - // - this.lblYin3.AutoSize = true; - this.lblYin3.Location = new System.Drawing.Point(59, 127); - this.lblYin3.Name = "lblYin3"; - this.lblYin3.Size = new System.Drawing.Size(28, 13); - this.lblYin3.TabIndex = 13; - this.lblYin3.Text = "0.75"; - // - // lblYout2 - // - this.lblYout2.AutoSize = true; - this.lblYout2.Location = new System.Drawing.Point(99, 109); - this.lblYout2.Name = "lblYout2"; - this.lblYout2.Size = new System.Drawing.Size(22, 13); - this.lblYout2.TabIndex = 12; - this.lblYout2.Text = "0.5"; - // - // lblYin2 - // - this.lblYin2.AutoSize = true; - this.lblYin2.Location = new System.Drawing.Point(59, 109); - this.lblYin2.Name = "lblYin2"; - this.lblYin2.Size = new System.Drawing.Size(22, 13); - this.lblYin2.TabIndex = 11; - this.lblYin2.Text = "0.5"; - // - // lblYout1 - // - this.lblYout1.AutoSize = true; - this.lblYout1.Location = new System.Drawing.Point(99, 91); - this.lblYout1.Name = "lblYout1"; - this.lblYout1.Size = new System.Drawing.Size(28, 13); - this.lblYout1.TabIndex = 10; - this.lblYout1.Text = "0.25"; - // - // lblYin1 - // - this.lblYin1.AutoSize = true; - this.lblYin1.Location = new System.Drawing.Point(59, 91); - this.lblYin1.Name = "lblYin1"; - this.lblYin1.Size = new System.Drawing.Size(28, 13); - this.lblYin1.TabIndex = 9; - this.lblYin1.Text = "0.25"; - // - // lblYsat - // - this.lblYsat.AutoSize = true; - this.lblYsat.Location = new System.Drawing.Point(99, 54); - this.lblYsat.Name = "lblYsat"; - this.lblYsat.Size = new System.Drawing.Size(34, 13); - this.lblYsat.TabIndex = 8; - this.lblYsat.Text = "1.000"; - // - // lblYexponent - // - this.lblYexponent.AutoSize = true; - this.lblYexponent.Location = new System.Drawing.Point(99, 72); - this.lblYexponent.Name = "lblYexponent"; - this.lblYexponent.Size = new System.Drawing.Size(34, 13); - this.lblYexponent.TabIndex = 6; - this.lblYexponent.Text = "1.000"; - // - // lblYdeadzone - // - this.lblYdeadzone.AutoSize = true; - this.lblYdeadzone.Location = new System.Drawing.Point(99, 36); - this.lblYdeadzone.Name = "lblYdeadzone"; - this.lblYdeadzone.Size = new System.Drawing.Size(34, 13); - this.lblYdeadzone.TabIndex = 4; - this.lblYdeadzone.Text = "0.000"; - // - // lblYCmd - // - this.lblYCmd.AutoSize = true; - this.lblYCmd.Font = new System.Drawing.Font("Segoe UI", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblYCmd.Location = new System.Drawing.Point(37, 1); - this.lblYCmd.Name = "lblYCmd"; - this.lblYCmd.Size = new System.Drawing.Size(47, 12); - this.lblYCmd.TabIndex = 2; - this.lblYCmd.Text = "Command"; - // - // lblYaw - // - this.lblYaw.AutoSize = true; - this.lblYaw.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblYaw.Location = new System.Drawing.Point(2, 0); - this.lblYaw.Name = "lblYaw"; - this.lblYaw.Size = new System.Drawing.Size(29, 13); - this.lblYaw.TabIndex = 1; - this.lblYaw.Text = "Yaw"; - // - // pnlPitch - // - this.pnlPitch.BackColor = System.Drawing.Color.Salmon; - this.pnlPitch.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; - this.pnlPitch.Controls.Add(this.lblPnt); - this.pnlPitch.Controls.Add(this.cbxPinvert); - this.pnlPitch.Controls.Add(this.cbxPpts); - this.pnlPitch.Controls.Add(this.cbxPexpo); - this.pnlPitch.Controls.Add(this.cbxPsat); - this.pnlPitch.Controls.Add(this.cbxPdeadzone); - this.pnlPitch.Controls.Add(this.label26); - this.pnlPitch.Controls.Add(this.label27); - this.pnlPitch.Controls.Add(this.label28); - this.pnlPitch.Controls.Add(this.lblPout3); - this.pnlPitch.Controls.Add(this.lblPin3); - this.pnlPitch.Controls.Add(this.lblPout2); - this.pnlPitch.Controls.Add(this.lblPin2); - this.pnlPitch.Controls.Add(this.lblPout1); - this.pnlPitch.Controls.Add(this.lblPin1); - this.pnlPitch.Controls.Add(this.lblPsat); - this.pnlPitch.Controls.Add(this.lblPexponent); - this.pnlPitch.Controls.Add(this.lblPdeadzone); - this.pnlPitch.Controls.Add(this.lblPCmd); - this.pnlPitch.Controls.Add(this.lblPitch); - this.pnlPitch.Dock = System.Windows.Forms.DockStyle.Fill; - this.pnlPitch.Location = new System.Drawing.Point(3, 284); - this.pnlPitch.Name = "pnlPitch"; - this.pnlPitch.Size = new System.Drawing.Size(138, 149); - this.pnlPitch.TabIndex = 3; - this.pnlPitch.MouseUp += new System.Windows.Forms.MouseEventHandler(this.pnlPitch_MouseUp); - // - // lblPnt - // - this.lblPnt.AutoSize = true; - this.lblPnt.Location = new System.Drawing.Point(107, 17); - this.lblPnt.Name = "lblPnt"; - this.lblPnt.Size = new System.Drawing.Size(20, 13); - this.lblPnt.TabIndex = 34; - this.lblPnt.Text = "NT"; - this.lblPnt.Visible = false; - // - // cbxPinvert - // - this.cbxPinvert.AutoSize = true; - this.cbxPinvert.Location = new System.Drawing.Point(6, 17); - this.cbxPinvert.Name = "cbxPinvert"; - this.cbxPinvert.Size = new System.Drawing.Size(55, 17); - this.cbxPinvert.TabIndex = 33; - this.cbxPinvert.Text = "Invert"; - this.cbxPinvert.UseVisualStyleBackColor = true; - this.cbxPinvert.CheckedChanged += new System.EventHandler(this.cbxPinvert_CheckedChanged); - // - // cbxPpts - // - this.cbxPpts.AutoSize = true; - this.cbxPpts.Location = new System.Drawing.Point(6, 91); - this.cbxPpts.Name = "cbxPpts"; - this.cbxPpts.Size = new System.Drawing.Size(15, 14); - this.cbxPpts.TabIndex = 32; - this.cbxPpts.UseVisualStyleBackColor = true; - this.cbxPpts.CheckedChanged += new System.EventHandler(this.cbxPpts_CheckedChanged); - // - // cbxPexpo - // - this.cbxPexpo.AutoSize = true; - this.cbxPexpo.Location = new System.Drawing.Point(6, 71); - this.cbxPexpo.Name = "cbxPexpo"; - this.cbxPexpo.Size = new System.Drawing.Size(75, 17); - this.cbxPexpo.TabIndex = 31; - this.cbxPexpo.Text = "Exponent"; - this.cbxPexpo.UseVisualStyleBackColor = true; - this.cbxPexpo.CheckedChanged += new System.EventHandler(this.cbxPexpo_CheckedChanged); - // - // cbxPsat - // - this.cbxPsat.AutoSize = true; - this.cbxPsat.Location = new System.Drawing.Point(6, 53); - this.cbxPsat.Name = "cbxPsat"; - this.cbxPsat.Size = new System.Drawing.Size(80, 17); - this.cbxPsat.TabIndex = 30; - this.cbxPsat.Text = "Saturation"; - this.cbxPsat.UseVisualStyleBackColor = true; - this.cbxPsat.CheckedChanged += new System.EventHandler(this.cbxPsense_CheckedChanged); - // - // cbxPdeadzone - // - this.cbxPdeadzone.AutoSize = true; - this.cbxPdeadzone.Location = new System.Drawing.Point(6, 35); - this.cbxPdeadzone.Name = "cbxPdeadzone"; - this.cbxPdeadzone.Size = new System.Drawing.Size(78, 17); - this.cbxPdeadzone.TabIndex = 29; - this.cbxPdeadzone.Text = "Deadzone"; - this.cbxPdeadzone.UseVisualStyleBackColor = true; - this.cbxPdeadzone.CheckedChanged += new System.EventHandler(this.cbxPdeadzone_CheckedChanged); - // - // label26 - // - this.label26.AutoSize = true; - this.label26.Location = new System.Drawing.Point(37, 126); - this.label26.Name = "label26"; - this.label26.Size = new System.Drawing.Size(23, 13); - this.label26.TabIndex = 28; - this.label26.Text = "Pt3"; - // - // label27 - // - this.label27.AutoSize = true; - this.label27.Location = new System.Drawing.Point(37, 108); - this.label27.Name = "label27"; - this.label27.Size = new System.Drawing.Size(23, 13); - this.label27.TabIndex = 27; - this.label27.Text = "Pt2"; - // - // label28 - // - this.label28.AutoSize = true; - this.label28.Location = new System.Drawing.Point(37, 90); - this.label28.Name = "label28"; - this.label28.Size = new System.Drawing.Size(23, 13); - this.label28.TabIndex = 26; - this.label28.Text = "Pt1"; - // - // lblPout3 - // - this.lblPout3.AutoSize = true; - this.lblPout3.Location = new System.Drawing.Point(99, 126); - this.lblPout3.Name = "lblPout3"; - this.lblPout3.Size = new System.Drawing.Size(28, 13); - this.lblPout3.TabIndex = 25; - this.lblPout3.Text = "0.75"; - // - // lblPin3 - // - this.lblPin3.AutoSize = true; - this.lblPin3.Location = new System.Drawing.Point(59, 126); - this.lblPin3.Name = "lblPin3"; - this.lblPin3.Size = new System.Drawing.Size(28, 13); - this.lblPin3.TabIndex = 24; - this.lblPin3.Text = "0.75"; - // - // lblPout2 - // - this.lblPout2.AutoSize = true; - this.lblPout2.Location = new System.Drawing.Point(99, 108); - this.lblPout2.Name = "lblPout2"; - this.lblPout2.Size = new System.Drawing.Size(22, 13); - this.lblPout2.TabIndex = 23; - this.lblPout2.Text = "0.5"; - // - // lblPin2 - // - this.lblPin2.AutoSize = true; - this.lblPin2.Location = new System.Drawing.Point(59, 108); - this.lblPin2.Name = "lblPin2"; - this.lblPin2.Size = new System.Drawing.Size(22, 13); - this.lblPin2.TabIndex = 22; - this.lblPin2.Text = "0.5"; - // - // lblPout1 - // - this.lblPout1.AutoSize = true; - this.lblPout1.Location = new System.Drawing.Point(99, 90); - this.lblPout1.Name = "lblPout1"; - this.lblPout1.Size = new System.Drawing.Size(28, 13); - this.lblPout1.TabIndex = 21; - this.lblPout1.Text = "0.25"; - // - // lblPin1 - // - this.lblPin1.AutoSize = true; - this.lblPin1.Location = new System.Drawing.Point(59, 90); - this.lblPin1.Name = "lblPin1"; - this.lblPin1.Size = new System.Drawing.Size(28, 13); - this.lblPin1.TabIndex = 20; - this.lblPin1.Text = "0.25"; - // - // lblPsat - // - this.lblPsat.AutoSize = true; - this.lblPsat.Location = new System.Drawing.Point(99, 54); - this.lblPsat.Name = "lblPsat"; - this.lblPsat.Size = new System.Drawing.Size(34, 13); - this.lblPsat.TabIndex = 10; - this.lblPsat.Text = "1.000"; - // - // lblPexponent - // - this.lblPexponent.AutoSize = true; - this.lblPexponent.Location = new System.Drawing.Point(99, 72); - this.lblPexponent.Name = "lblPexponent"; - this.lblPexponent.Size = new System.Drawing.Size(34, 13); - this.lblPexponent.TabIndex = 8; - this.lblPexponent.Text = "1.000"; - // - // lblPdeadzone - // - this.lblPdeadzone.AutoSize = true; - this.lblPdeadzone.Location = new System.Drawing.Point(99, 36); - this.lblPdeadzone.Name = "lblPdeadzone"; - this.lblPdeadzone.Size = new System.Drawing.Size(34, 13); - this.lblPdeadzone.TabIndex = 5; - this.lblPdeadzone.Text = "0.000"; - // - // lblPCmd - // - this.lblPCmd.AutoSize = true; - this.lblPCmd.Font = new System.Drawing.Font("Segoe UI", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblPCmd.Location = new System.Drawing.Point(37, 1); - this.lblPCmd.Name = "lblPCmd"; - this.lblPCmd.Size = new System.Drawing.Size(47, 12); - this.lblPCmd.TabIndex = 3; - this.lblPCmd.Text = "Command"; - // - // lblPitch - // - this.lblPitch.AutoSize = true; - this.lblPitch.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblPitch.Location = new System.Drawing.Point(2, 0); - this.lblPitch.Name = "lblPitch"; - this.lblPitch.Size = new System.Drawing.Size(33, 13); - this.lblPitch.TabIndex = 2; - this.lblPitch.Text = "Pitch"; - // - // pnlRoll - // - this.pnlRoll.BackColor = System.Drawing.Color.LightGreen; - this.pnlRoll.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; - this.pnlRoll.Controls.Add(this.lblRnt); - this.pnlRoll.Controls.Add(this.cbxRinvert); - this.pnlRoll.Controls.Add(this.cbxRpts); - this.pnlRoll.Controls.Add(this.cbxRexpo); - this.pnlRoll.Controls.Add(this.cbxRsat); - this.pnlRoll.Controls.Add(this.cbxRdeadzone); - this.pnlRoll.Controls.Add(this.label35); - this.pnlRoll.Controls.Add(this.label36); - this.pnlRoll.Controls.Add(this.label37); - this.pnlRoll.Controls.Add(this.lblRout3); - this.pnlRoll.Controls.Add(this.lblRin3); - this.pnlRoll.Controls.Add(this.lblRout2); - this.pnlRoll.Controls.Add(this.lblRin2); - this.pnlRoll.Controls.Add(this.lblRout1); - this.pnlRoll.Controls.Add(this.lblRin1); - this.pnlRoll.Controls.Add(this.lblRsat); - this.pnlRoll.Controls.Add(this.lblRexponent); - this.pnlRoll.Controls.Add(this.lblRdeadzone); - this.pnlRoll.Controls.Add(this.lblRCmd); - this.pnlRoll.Controls.Add(this.lblRoll); - this.pnlRoll.Dock = System.Windows.Forms.DockStyle.Fill; - this.pnlRoll.Location = new System.Drawing.Point(3, 445); - this.pnlRoll.Name = "pnlRoll"; - this.pnlRoll.Size = new System.Drawing.Size(138, 149); - this.pnlRoll.TabIndex = 4; - this.pnlRoll.MouseUp += new System.Windows.Forms.MouseEventHandler(this.pnlRoll_MouseUp); - // - // lblRnt - // - this.lblRnt.AutoSize = true; - this.lblRnt.Location = new System.Drawing.Point(107, 17); - this.lblRnt.Name = "lblRnt"; - this.lblRnt.Size = new System.Drawing.Size(20, 13); - this.lblRnt.TabIndex = 38; - this.lblRnt.Text = "NT"; - this.lblRnt.Visible = false; - // - // cbxRinvert - // - this.cbxRinvert.AutoSize = true; - this.cbxRinvert.Location = new System.Drawing.Point(6, 17); - this.cbxRinvert.Name = "cbxRinvert"; - this.cbxRinvert.Size = new System.Drawing.Size(55, 17); - this.cbxRinvert.TabIndex = 37; - this.cbxRinvert.Text = "Invert"; - this.cbxRinvert.UseVisualStyleBackColor = true; - this.cbxRinvert.CheckedChanged += new System.EventHandler(this.cbxRinvert_CheckedChanged); - // - // cbxRpts - // - this.cbxRpts.AutoSize = true; - this.cbxRpts.Location = new System.Drawing.Point(6, 91); - this.cbxRpts.Name = "cbxRpts"; - this.cbxRpts.Size = new System.Drawing.Size(15, 14); - this.cbxRpts.TabIndex = 36; - this.cbxRpts.UseVisualStyleBackColor = true; - this.cbxRpts.CheckedChanged += new System.EventHandler(this.cbxRpts_CheckedChanged); - // - // cbxRexpo - // - this.cbxRexpo.AutoSize = true; - this.cbxRexpo.Location = new System.Drawing.Point(6, 71); - this.cbxRexpo.Name = "cbxRexpo"; - this.cbxRexpo.Size = new System.Drawing.Size(75, 17); - this.cbxRexpo.TabIndex = 35; - this.cbxRexpo.Text = "Exponent"; - this.cbxRexpo.UseVisualStyleBackColor = true; - this.cbxRexpo.CheckedChanged += new System.EventHandler(this.cbxRexpo_CheckedChanged); - // - // cbxRsat - // - this.cbxRsat.AutoSize = true; - this.cbxRsat.Location = new System.Drawing.Point(6, 53); - this.cbxRsat.Name = "cbxRsat"; - this.cbxRsat.Size = new System.Drawing.Size(80, 17); - this.cbxRsat.TabIndex = 34; - this.cbxRsat.Text = "Saturation"; - this.cbxRsat.UseVisualStyleBackColor = true; - this.cbxRsat.CheckedChanged += new System.EventHandler(this.cbxRsense_CheckedChanged); - // - // cbxRdeadzone - // - this.cbxRdeadzone.AutoSize = true; - this.cbxRdeadzone.Location = new System.Drawing.Point(6, 35); - this.cbxRdeadzone.Name = "cbxRdeadzone"; - this.cbxRdeadzone.Size = new System.Drawing.Size(78, 17); - this.cbxRdeadzone.TabIndex = 33; - this.cbxRdeadzone.Text = "Deadzone"; - this.cbxRdeadzone.UseVisualStyleBackColor = true; - this.cbxRdeadzone.CheckedChanged += new System.EventHandler(this.cbxRdeadzone_CheckedChanged); - // - // label35 - // - this.label35.AutoSize = true; - this.label35.Location = new System.Drawing.Point(37, 126); - this.label35.Name = "label35"; - this.label35.Size = new System.Drawing.Size(23, 13); - this.label35.TabIndex = 28; - this.label35.Text = "Pt3"; - // - // label36 - // - this.label36.AutoSize = true; - this.label36.Location = new System.Drawing.Point(37, 108); - this.label36.Name = "label36"; - this.label36.Size = new System.Drawing.Size(23, 13); - this.label36.TabIndex = 27; - this.label36.Text = "Pt2"; - // - // label37 - // - this.label37.AutoSize = true; - this.label37.Location = new System.Drawing.Point(37, 90); - this.label37.Name = "label37"; - this.label37.Size = new System.Drawing.Size(23, 13); - this.label37.TabIndex = 26; - this.label37.Text = "Pt1"; - // - // lblRout3 - // - this.lblRout3.AutoSize = true; - this.lblRout3.Location = new System.Drawing.Point(99, 126); - this.lblRout3.Name = "lblRout3"; - this.lblRout3.Size = new System.Drawing.Size(28, 13); - this.lblRout3.TabIndex = 25; - this.lblRout3.Text = "0.75"; - // - // lblRin3 - // - this.lblRin3.AutoSize = true; - this.lblRin3.Location = new System.Drawing.Point(59, 126); - this.lblRin3.Name = "lblRin3"; - this.lblRin3.Size = new System.Drawing.Size(28, 13); - this.lblRin3.TabIndex = 24; - this.lblRin3.Text = "0.75"; - // - // lblRout2 - // - this.lblRout2.AutoSize = true; - this.lblRout2.Location = new System.Drawing.Point(99, 108); - this.lblRout2.Name = "lblRout2"; - this.lblRout2.Size = new System.Drawing.Size(22, 13); - this.lblRout2.TabIndex = 23; - this.lblRout2.Text = "0.5"; - // - // lblRin2 - // - this.lblRin2.AutoSize = true; - this.lblRin2.Location = new System.Drawing.Point(59, 108); - this.lblRin2.Name = "lblRin2"; - this.lblRin2.Size = new System.Drawing.Size(22, 13); - this.lblRin2.TabIndex = 22; - this.lblRin2.Text = "0.5"; - // - // lblRout1 - // - this.lblRout1.AutoSize = true; - this.lblRout1.Location = new System.Drawing.Point(99, 90); - this.lblRout1.Name = "lblRout1"; - this.lblRout1.Size = new System.Drawing.Size(28, 13); - this.lblRout1.TabIndex = 21; - this.lblRout1.Text = "0.25"; - // - // lblRin1 - // - this.lblRin1.AutoSize = true; - this.lblRin1.Location = new System.Drawing.Point(59, 90); - this.lblRin1.Name = "lblRin1"; - this.lblRin1.Size = new System.Drawing.Size(28, 13); - this.lblRin1.TabIndex = 20; - this.lblRin1.Text = "0.25"; - // - // lblRsat - // - this.lblRsat.AutoSize = true; - this.lblRsat.Location = new System.Drawing.Point(99, 54); - this.lblRsat.Name = "lblRsat"; - this.lblRsat.Size = new System.Drawing.Size(34, 13); - this.lblRsat.TabIndex = 10; - this.lblRsat.Text = "1.000"; - // - // lblRexponent - // - this.lblRexponent.AutoSize = true; - this.lblRexponent.Location = new System.Drawing.Point(99, 72); - this.lblRexponent.Name = "lblRexponent"; - this.lblRexponent.Size = new System.Drawing.Size(34, 13); - this.lblRexponent.TabIndex = 8; - this.lblRexponent.Text = "1.000"; - // - // lblRdeadzone - // - this.lblRdeadzone.AutoSize = true; - this.lblRdeadzone.Location = new System.Drawing.Point(99, 36); - this.lblRdeadzone.Name = "lblRdeadzone"; - this.lblRdeadzone.Size = new System.Drawing.Size(34, 13); - this.lblRdeadzone.TabIndex = 6; - this.lblRdeadzone.Text = "0.000"; - // - // lblRCmd - // - this.lblRCmd.AutoSize = true; - this.lblRCmd.Font = new System.Drawing.Font("Segoe UI", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblRCmd.Location = new System.Drawing.Point(37, 1); - this.lblRCmd.Name = "lblRCmd"; - this.lblRCmd.Size = new System.Drawing.Size(47, 12); - this.lblRCmd.TabIndex = 4; - this.lblRCmd.Text = "Command"; - // - // lblRoll - // - this.lblRoll.AutoSize = true; - this.lblRoll.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblRoll.Location = new System.Drawing.Point(2, 0); - this.lblRoll.Name = "lblRoll"; - this.lblRoll.Size = new System.Drawing.Size(27, 13); - this.lblRoll.TabIndex = 2; - this.lblRoll.Text = "Roll"; - // - // tableLayoutPanel1 - // - this.tableLayoutPanel1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left) + System.Windows.Forms.DataVisualization.Charting.ChartArea chartArea1 = new System.Windows.Forms.DataVisualization.Charting.ChartArea(); + System.Windows.Forms.DataVisualization.Charting.Series series1 = new System.Windows.Forms.DataVisualization.Charting.Series(); + System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FormJSCalCurve)); + this.glControl1 = new OpenTK.GLControl(); + this.tlp = new System.Windows.Forms.TableLayoutPanel(); + this.tlpData = new System.Windows.Forms.TableLayoutPanel(); + this.panel2 = new System.Windows.Forms.Panel(); + this.pnlYaw = new System.Windows.Forms.Panel(); + this.lblYnt = new System.Windows.Forms.Label(); + this.cbxYinvert = new System.Windows.Forms.CheckBox(); + this.cbxYpts = new System.Windows.Forms.CheckBox(); + this.cbxYexpo = new System.Windows.Forms.CheckBox(); + this.cbxYsat = new System.Windows.Forms.CheckBox(); + this.cbxYdeadzone = new System.Windows.Forms.CheckBox(); + this.label25 = new System.Windows.Forms.Label(); + this.label24 = new System.Windows.Forms.Label(); + this.label23 = new System.Windows.Forms.Label(); + this.lblYout3 = new System.Windows.Forms.Label(); + this.lblYin3 = new System.Windows.Forms.Label(); + this.lblYout2 = new System.Windows.Forms.Label(); + this.lblYin2 = new System.Windows.Forms.Label(); + this.lblYout1 = new System.Windows.Forms.Label(); + this.lblYin1 = new System.Windows.Forms.Label(); + this.lblYsat = new System.Windows.Forms.Label(); + this.lblYexponent = new System.Windows.Forms.Label(); + this.lblYdeadzone = new System.Windows.Forms.Label(); + this.lblYCmd = new System.Windows.Forms.Label(); + this.lblYaw = new System.Windows.Forms.Label(); + this.pnlPitch = new System.Windows.Forms.Panel(); + this.lblPnt = new System.Windows.Forms.Label(); + this.cbxPinvert = new System.Windows.Forms.CheckBox(); + this.cbxPpts = new System.Windows.Forms.CheckBox(); + this.cbxPexpo = new System.Windows.Forms.CheckBox(); + this.cbxPsat = new System.Windows.Forms.CheckBox(); + this.cbxPdeadzone = new System.Windows.Forms.CheckBox(); + this.label26 = new System.Windows.Forms.Label(); + this.label27 = new System.Windows.Forms.Label(); + this.label28 = new System.Windows.Forms.Label(); + this.lblPout3 = new System.Windows.Forms.Label(); + this.lblPin3 = new System.Windows.Forms.Label(); + this.lblPout2 = new System.Windows.Forms.Label(); + this.lblPin2 = new System.Windows.Forms.Label(); + this.lblPout1 = new System.Windows.Forms.Label(); + this.lblPin1 = new System.Windows.Forms.Label(); + this.lblPsat = new System.Windows.Forms.Label(); + this.lblPexponent = new System.Windows.Forms.Label(); + this.lblPdeadzone = new System.Windows.Forms.Label(); + this.lblPCmd = new System.Windows.Forms.Label(); + this.lblPitch = new System.Windows.Forms.Label(); + this.pnlRoll = new System.Windows.Forms.Panel(); + this.lblRnt = new System.Windows.Forms.Label(); + this.cbxRinvert = new System.Windows.Forms.CheckBox(); + this.cbxRpts = new System.Windows.Forms.CheckBox(); + this.cbxRexpo = new System.Windows.Forms.CheckBox(); + this.cbxRsat = new System.Windows.Forms.CheckBox(); + this.cbxRdeadzone = new System.Windows.Forms.CheckBox(); + this.label35 = new System.Windows.Forms.Label(); + this.label36 = new System.Windows.Forms.Label(); + this.label37 = new System.Windows.Forms.Label(); + this.lblRout3 = new System.Windows.Forms.Label(); + this.lblRin3 = new System.Windows.Forms.Label(); + this.lblRout2 = new System.Windows.Forms.Label(); + this.lblRin2 = new System.Windows.Forms.Label(); + this.lblRout1 = new System.Windows.Forms.Label(); + this.lblRin1 = new System.Windows.Forms.Label(); + this.lblRsat = new System.Windows.Forms.Label(); + this.lblRexponent = new System.Windows.Forms.Label(); + this.lblRdeadzone = new System.Windows.Forms.Label(); + this.lblRCmd = new System.Windows.Forms.Label(); + this.lblRoll = new System.Windows.Forms.Label(); + this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); + this.panel9 = new System.Windows.Forms.Panel(); + this.label6 = new System.Windows.Forms.Label(); + this.lblDamping = new System.Windows.Forms.Label(); + this.slDamping = new System.Windows.Forms.TrackBar(); + this.panel1 = new System.Windows.Forms.Panel(); + this.label16 = new System.Windows.Forms.Label(); + this.lblTurnspeed = new System.Windows.Forms.Label(); + this.slTurnSpeed = new System.Windows.Forms.TrackBar(); + this.panel6 = new System.Windows.Forms.Panel(); + this.rbPtDeadzone = new System.Windows.Forms.RadioButton(); + this.lblGraphSaturation = new System.Windows.Forms.Label(); + this.lblGraphDeadzone = new System.Windows.Forms.Label(); + this.lblNodetext = new System.Windows.Forms.Label(); + this.label12 = new System.Windows.Forms.Label(); + this.cbRuse = new System.Windows.Forms.CheckBox(); + this.cbPuse = new System.Windows.Forms.CheckBox(); + this.cbYuse = new System.Windows.Forms.CheckBox(); + this.label11 = new System.Windows.Forms.Label(); + this.label10 = new System.Windows.Forms.Label(); + this.lblROutput = new System.Windows.Forms.Label(); + this.lblRInput = new System.Windows.Forms.Label(); + this.lblPOutput = new System.Windows.Forms.Label(); + this.lblPInput = new System.Windows.Forms.Label(); + this.lblLiveRoll = new System.Windows.Forms.Label(); + this.lblLivePitch = new System.Windows.Forms.Label(); + this.btCopyToAllAxis = new System.Windows.Forms.Button(); + this.lblLiveYaw = new System.Windows.Forms.Label(); + this.label4 = new System.Windows.Forms.Label(); + this.lblYOutput = new System.Windows.Forms.Label(); + this.lblYInput = new System.Windows.Forms.Label(); + this.rbPtExponent = new System.Windows.Forms.RadioButton(); + this.rbPtSaturation = new System.Windows.Forms.RadioButton(); + this.rbPt3 = new System.Windows.Forms.RadioButton(); + this.rbPt2 = new System.Windows.Forms.RadioButton(); + this.rbPt1 = new System.Windows.Forms.RadioButton(); + this.label33 = new System.Windows.Forms.Label(); + this.label32 = new System.Windows.Forms.Label(); + this.lblOut3 = new System.Windows.Forms.Label(); + this.lblIn3 = new System.Windows.Forms.Label(); + this.lblOut2 = new System.Windows.Forms.Label(); + this.lblIn2 = new System.Windows.Forms.Label(); + this.lblOut1 = new System.Windows.Forms.Label(); + this.lblIn1 = new System.Windows.Forms.Label(); + this.chart1 = new System.Windows.Forms.DataVisualization.Charting.Chart(); + this.lblOutSlider = new System.Windows.Forms.Label(); + this.lblOutExponent = new System.Windows.Forms.Label(); + this.tbSlider = new System.Windows.Forms.TrackBar(); + this.flowLayoutPanel1 = new System.Windows.Forms.FlowLayoutPanel(); + this.rb300 = new System.Windows.Forms.RadioButton(); + this.rbHornet = new System.Windows.Forms.RadioButton(); + this.rbAurora = new System.Windows.Forms.RadioButton(); + this.tableLayoutPanel3 = new System.Windows.Forms.TableLayoutPanel(); + this.btDone = new System.Windows.Forms.Button(); + this.panel8 = new System.Windows.Forms.Panel(); + this.rbArea18 = new System.Windows.Forms.RadioButton(); + this.rbDemien = new System.Windows.Forms.RadioButton(); + this.rbBrokenMoon = new System.Windows.Forms.RadioButton(); + this.rbDyingStar = new System.Windows.Forms.RadioButton(); + this.rbSunset = new System.Windows.Forms.RadioButton(); + this.rbOutThere3 = new System.Windows.Forms.RadioButton(); + this.rbSkybox = new System.Windows.Forms.RadioButton(); + this.rbOutThere1 = new System.Windows.Forms.RadioButton(); + this.rbBigSight = new System.Windows.Forms.RadioButton(); + this.rbHighway = new System.Windows.Forms.RadioButton(); + this.rbHelipad = new System.Windows.Forms.RadioButton(); + this.rbShiodome = new System.Windows.Forms.RadioButton(); + this.rbCanyon = new System.Windows.Forms.RadioButton(); + this.flowLayoutPanel2 = new System.Windows.Forms.FlowLayoutPanel(); + this.pnlAxisSelector = new System.Windows.Forms.Panel(); + this.rbP = new System.Windows.Forms.RadioButton(); + this.rbY = new System.Windows.Forms.RadioButton(); + this.rbR = new System.Windows.Forms.RadioButton(); + this.panel10 = new System.Windows.Forms.Panel(); + this.rbTuneStrafe = new System.Windows.Forms.RadioButton(); + this.rbTuneYPR = new System.Windows.Forms.RadioButton(); + this.tlp.SuspendLayout(); + this.tlpData.SuspendLayout(); + this.pnlYaw.SuspendLayout(); + this.pnlPitch.SuspendLayout(); + this.pnlRoll.SuspendLayout(); + this.tableLayoutPanel1.SuspendLayout(); + this.panel9.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.slDamping)).BeginInit(); + this.panel1.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.slTurnSpeed)).BeginInit(); + this.panel6.SuspendLayout(); + ((System.ComponentModel.ISupportInitialize)(this.chart1)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.tbSlider)).BeginInit(); + this.flowLayoutPanel1.SuspendLayout(); + this.tableLayoutPanel3.SuspendLayout(); + this.panel8.SuspendLayout(); + this.flowLayoutPanel2.SuspendLayout(); + this.pnlAxisSelector.SuspendLayout(); + this.panel10.SuspendLayout(); + this.SuspendLayout(); + // + // glControl1 + // + this.glControl1.BackColor = System.Drawing.Color.Black; + this.glControl1.Dock = System.Windows.Forms.DockStyle.Fill; + this.glControl1.Location = new System.Drawing.Point(153, 3); + this.glControl1.Name = "glControl1"; + this.glControl1.Size = new System.Drawing.Size(1028, 610); + this.glControl1.TabIndex = 0; + this.glControl1.VSync = false; + this.glControl1.Load += new System.EventHandler(this.glControl1_Load); + this.glControl1.Paint += new System.Windows.Forms.PaintEventHandler(this.glControl1_Paint); + this.glControl1.Resize += new System.EventHandler(this.glControl1_Resize); + // + // tlp + // + this.tlp.ColumnCount = 2; + this.tlp.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 150F)); + this.tlp.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F)); + this.tlp.Controls.Add(this.tlpData, 0, 0); + this.tlp.Controls.Add(this.tableLayoutPanel1, 1, 1); + this.tlp.Controls.Add(this.glControl1, 1, 0); + this.tlp.Controls.Add(this.flowLayoutPanel2, 0, 1); + this.tlp.Dock = System.Windows.Forms.DockStyle.Fill; + this.tlp.GrowStyle = System.Windows.Forms.TableLayoutPanelGrowStyle.FixedSize; + this.tlp.Location = new System.Drawing.Point(0, 0); + this.tlp.Name = "tlp"; + this.tlp.RowCount = 2; + this.tlp.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); + this.tlp.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 300F)); + this.tlp.Size = new System.Drawing.Size(1184, 916); + this.tlp.TabIndex = 1; + // + // tlpData + // + this.tlpData.BackColor = System.Drawing.Color.Gold; + this.tlpData.ColumnCount = 1; + this.tlpData.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F)); + this.tlpData.Controls.Add(this.panel2, 0, 0); + this.tlpData.Controls.Add(this.pnlYaw, 0, 1); + this.tlpData.Controls.Add(this.pnlPitch, 0, 3); + this.tlpData.Controls.Add(this.pnlRoll, 0, 5); + this.tlpData.Dock = System.Windows.Forms.DockStyle.Top; + this.tlpData.GrowStyle = System.Windows.Forms.TableLayoutPanelGrowStyle.FixedSize; + this.tlpData.Location = new System.Drawing.Point(3, 3); + this.tlpData.Name = "tlpData"; + this.tlpData.RowCount = 8; + this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 120F)); + this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 155F)); + this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 6F)); + this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 155F)); + this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 6F)); + this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 155F)); + this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 6F)); + this.tlpData.RowStyles.Add(new System.Windows.Forms.RowStyle()); + this.tlpData.Size = new System.Drawing.Size(144, 610); + this.tlpData.TabIndex = 2; + // + // panel2 + // + this.panel2.BackgroundImage = global::SCJMapper_V2.Properties.Resources.YPR; + this.panel2.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.panel2.Dock = System.Windows.Forms.DockStyle.Fill; + this.panel2.Location = new System.Drawing.Point(3, 3); + this.panel2.Name = "panel2"; + this.panel2.Size = new System.Drawing.Size(138, 114); + this.panel2.TabIndex = 0; + // + // pnlYaw + // + this.pnlYaw.BackColor = System.Drawing.Color.PowderBlue; + this.pnlYaw.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; + this.pnlYaw.Controls.Add(this.lblYnt); + this.pnlYaw.Controls.Add(this.cbxYinvert); + this.pnlYaw.Controls.Add(this.cbxYpts); + this.pnlYaw.Controls.Add(this.cbxYexpo); + this.pnlYaw.Controls.Add(this.cbxYsat); + this.pnlYaw.Controls.Add(this.cbxYdeadzone); + this.pnlYaw.Controls.Add(this.label25); + this.pnlYaw.Controls.Add(this.label24); + this.pnlYaw.Controls.Add(this.label23); + this.pnlYaw.Controls.Add(this.lblYout3); + this.pnlYaw.Controls.Add(this.lblYin3); + this.pnlYaw.Controls.Add(this.lblYout2); + this.pnlYaw.Controls.Add(this.lblYin2); + this.pnlYaw.Controls.Add(this.lblYout1); + this.pnlYaw.Controls.Add(this.lblYin1); + this.pnlYaw.Controls.Add(this.lblYsat); + this.pnlYaw.Controls.Add(this.lblYexponent); + this.pnlYaw.Controls.Add(this.lblYdeadzone); + this.pnlYaw.Controls.Add(this.lblYCmd); + this.pnlYaw.Controls.Add(this.lblYaw); + this.pnlYaw.Dock = System.Windows.Forms.DockStyle.Fill; + this.pnlYaw.Location = new System.Drawing.Point(3, 123); + this.pnlYaw.Name = "pnlYaw"; + this.pnlYaw.Size = new System.Drawing.Size(138, 149); + this.pnlYaw.TabIndex = 2; + this.pnlYaw.MouseUp += new System.Windows.Forms.MouseEventHandler(this.pnlYaw_MouseUp); + // + // lblYnt + // + this.lblYnt.AutoSize = true; + this.lblYnt.Location = new System.Drawing.Point(107, 17); + this.lblYnt.Name = "lblYnt"; + this.lblYnt.Size = new System.Drawing.Size(20, 13); + this.lblYnt.TabIndex = 23; + this.lblYnt.Text = "NT"; + this.lblYnt.Visible = false; + // + // cbxYinvert + // + this.cbxYinvert.AutoSize = true; + this.cbxYinvert.Location = new System.Drawing.Point(6, 17); + this.cbxYinvert.Name = "cbxYinvert"; + this.cbxYinvert.Size = new System.Drawing.Size(55, 17); + this.cbxYinvert.TabIndex = 22; + this.cbxYinvert.Text = "Invert"; + this.cbxYinvert.UseVisualStyleBackColor = true; + this.cbxYinvert.CheckedChanged += new System.EventHandler(this.cbxYinvert_CheckedChanged); + // + // cbxYpts + // + this.cbxYpts.AutoSize = true; + this.cbxYpts.Location = new System.Drawing.Point(6, 91); + this.cbxYpts.Name = "cbxYpts"; + this.cbxYpts.Size = new System.Drawing.Size(15, 14); + this.cbxYpts.TabIndex = 21; + this.cbxYpts.UseVisualStyleBackColor = true; + this.cbxYpts.CheckedChanged += new System.EventHandler(this.cbxYpts_CheckedChanged); + // + // cbxYexpo + // + this.cbxYexpo.AutoSize = true; + this.cbxYexpo.Location = new System.Drawing.Point(6, 71); + this.cbxYexpo.Name = "cbxYexpo"; + this.cbxYexpo.Size = new System.Drawing.Size(75, 17); + this.cbxYexpo.TabIndex = 20; + this.cbxYexpo.Text = "Exponent"; + this.cbxYexpo.UseVisualStyleBackColor = true; + this.cbxYexpo.CheckedChanged += new System.EventHandler(this.cbxYexpo_CheckedChanged); + // + // cbxYsat + // + this.cbxYsat.AutoSize = true; + this.cbxYsat.Location = new System.Drawing.Point(6, 53); + this.cbxYsat.Name = "cbxYsat"; + this.cbxYsat.Size = new System.Drawing.Size(80, 17); + this.cbxYsat.TabIndex = 19; + this.cbxYsat.Text = "Saturation"; + this.cbxYsat.UseVisualStyleBackColor = true; + this.cbxYsat.CheckedChanged += new System.EventHandler(this.cbxYsense_CheckedChanged); + // + // cbxYdeadzone + // + this.cbxYdeadzone.AutoSize = true; + this.cbxYdeadzone.Location = new System.Drawing.Point(6, 35); + this.cbxYdeadzone.Name = "cbxYdeadzone"; + this.cbxYdeadzone.Size = new System.Drawing.Size(78, 17); + this.cbxYdeadzone.TabIndex = 18; + this.cbxYdeadzone.Text = "Deadzone"; + this.cbxYdeadzone.UseVisualStyleBackColor = true; + this.cbxYdeadzone.CheckedChanged += new System.EventHandler(this.cbxYdeadzone_CheckedChanged); + // + // label25 + // + this.label25.AutoSize = true; + this.label25.Location = new System.Drawing.Point(37, 127); + this.label25.Name = "label25"; + this.label25.Size = new System.Drawing.Size(23, 13); + this.label25.TabIndex = 17; + this.label25.Text = "Pt3"; + // + // label24 + // + this.label24.AutoSize = true; + this.label24.Location = new System.Drawing.Point(37, 109); + this.label24.Name = "label24"; + this.label24.Size = new System.Drawing.Size(23, 13); + this.label24.TabIndex = 16; + this.label24.Text = "Pt2"; + // + // label23 + // + this.label23.AutoSize = true; + this.label23.Location = new System.Drawing.Point(37, 91); + this.label23.Name = "label23"; + this.label23.Size = new System.Drawing.Size(23, 13); + this.label23.TabIndex = 15; + this.label23.Text = "Pt1"; + // + // lblYout3 + // + this.lblYout3.AutoSize = true; + this.lblYout3.Location = new System.Drawing.Point(99, 127); + this.lblYout3.Name = "lblYout3"; + this.lblYout3.Size = new System.Drawing.Size(28, 13); + this.lblYout3.TabIndex = 14; + this.lblYout3.Text = "0.75"; + // + // lblYin3 + // + this.lblYin3.AutoSize = true; + this.lblYin3.Location = new System.Drawing.Point(59, 127); + this.lblYin3.Name = "lblYin3"; + this.lblYin3.Size = new System.Drawing.Size(28, 13); + this.lblYin3.TabIndex = 13; + this.lblYin3.Text = "0.75"; + // + // lblYout2 + // + this.lblYout2.AutoSize = true; + this.lblYout2.Location = new System.Drawing.Point(99, 109); + this.lblYout2.Name = "lblYout2"; + this.lblYout2.Size = new System.Drawing.Size(22, 13); + this.lblYout2.TabIndex = 12; + this.lblYout2.Text = "0.5"; + // + // lblYin2 + // + this.lblYin2.AutoSize = true; + this.lblYin2.Location = new System.Drawing.Point(59, 109); + this.lblYin2.Name = "lblYin2"; + this.lblYin2.Size = new System.Drawing.Size(22, 13); + this.lblYin2.TabIndex = 11; + this.lblYin2.Text = "0.5"; + // + // lblYout1 + // + this.lblYout1.AutoSize = true; + this.lblYout1.Location = new System.Drawing.Point(99, 91); + this.lblYout1.Name = "lblYout1"; + this.lblYout1.Size = new System.Drawing.Size(28, 13); + this.lblYout1.TabIndex = 10; + this.lblYout1.Text = "0.25"; + // + // lblYin1 + // + this.lblYin1.AutoSize = true; + this.lblYin1.Location = new System.Drawing.Point(59, 91); + this.lblYin1.Name = "lblYin1"; + this.lblYin1.Size = new System.Drawing.Size(28, 13); + this.lblYin1.TabIndex = 9; + this.lblYin1.Text = "0.25"; + // + // lblYsat + // + this.lblYsat.AutoSize = true; + this.lblYsat.Location = new System.Drawing.Point(99, 54); + this.lblYsat.Name = "lblYsat"; + this.lblYsat.Size = new System.Drawing.Size(34, 13); + this.lblYsat.TabIndex = 8; + this.lblYsat.Text = "1.000"; + // + // lblYexponent + // + this.lblYexponent.AutoSize = true; + this.lblYexponent.Location = new System.Drawing.Point(99, 72); + this.lblYexponent.Name = "lblYexponent"; + this.lblYexponent.Size = new System.Drawing.Size(34, 13); + this.lblYexponent.TabIndex = 6; + this.lblYexponent.Text = "1.000"; + // + // lblYdeadzone + // + this.lblYdeadzone.AutoSize = true; + this.lblYdeadzone.Location = new System.Drawing.Point(99, 36); + this.lblYdeadzone.Name = "lblYdeadzone"; + this.lblYdeadzone.Size = new System.Drawing.Size(34, 13); + this.lblYdeadzone.TabIndex = 4; + this.lblYdeadzone.Text = "0.000"; + // + // lblYCmd + // + this.lblYCmd.AutoSize = true; + this.lblYCmd.Font = new System.Drawing.Font("Segoe UI", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblYCmd.Location = new System.Drawing.Point(37, 1); + this.lblYCmd.Name = "lblYCmd"; + this.lblYCmd.Size = new System.Drawing.Size(47, 12); + this.lblYCmd.TabIndex = 2; + this.lblYCmd.Text = "Command"; + // + // lblYaw + // + this.lblYaw.AutoSize = true; + this.lblYaw.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblYaw.Location = new System.Drawing.Point(2, 0); + this.lblYaw.Name = "lblYaw"; + this.lblYaw.Size = new System.Drawing.Size(28, 13); + this.lblYaw.TabIndex = 1; + this.lblYaw.Text = "Yaw"; + // + // pnlPitch + // + this.pnlPitch.BackColor = System.Drawing.Color.Salmon; + this.pnlPitch.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; + this.pnlPitch.Controls.Add(this.lblPnt); + this.pnlPitch.Controls.Add(this.cbxPinvert); + this.pnlPitch.Controls.Add(this.cbxPpts); + this.pnlPitch.Controls.Add(this.cbxPexpo); + this.pnlPitch.Controls.Add(this.cbxPsat); + this.pnlPitch.Controls.Add(this.cbxPdeadzone); + this.pnlPitch.Controls.Add(this.label26); + this.pnlPitch.Controls.Add(this.label27); + this.pnlPitch.Controls.Add(this.label28); + this.pnlPitch.Controls.Add(this.lblPout3); + this.pnlPitch.Controls.Add(this.lblPin3); + this.pnlPitch.Controls.Add(this.lblPout2); + this.pnlPitch.Controls.Add(this.lblPin2); + this.pnlPitch.Controls.Add(this.lblPout1); + this.pnlPitch.Controls.Add(this.lblPin1); + this.pnlPitch.Controls.Add(this.lblPsat); + this.pnlPitch.Controls.Add(this.lblPexponent); + this.pnlPitch.Controls.Add(this.lblPdeadzone); + this.pnlPitch.Controls.Add(this.lblPCmd); + this.pnlPitch.Controls.Add(this.lblPitch); + this.pnlPitch.Dock = System.Windows.Forms.DockStyle.Fill; + this.pnlPitch.Location = new System.Drawing.Point(3, 284); + this.pnlPitch.Name = "pnlPitch"; + this.pnlPitch.Size = new System.Drawing.Size(138, 149); + this.pnlPitch.TabIndex = 3; + this.pnlPitch.MouseUp += new System.Windows.Forms.MouseEventHandler(this.pnlPitch_MouseUp); + // + // lblPnt + // + this.lblPnt.AutoSize = true; + this.lblPnt.Location = new System.Drawing.Point(107, 17); + this.lblPnt.Name = "lblPnt"; + this.lblPnt.Size = new System.Drawing.Size(20, 13); + this.lblPnt.TabIndex = 34; + this.lblPnt.Text = "NT"; + this.lblPnt.Visible = false; + // + // cbxPinvert + // + this.cbxPinvert.AutoSize = true; + this.cbxPinvert.Location = new System.Drawing.Point(6, 17); + this.cbxPinvert.Name = "cbxPinvert"; + this.cbxPinvert.Size = new System.Drawing.Size(55, 17); + this.cbxPinvert.TabIndex = 33; + this.cbxPinvert.Text = "Invert"; + this.cbxPinvert.UseVisualStyleBackColor = true; + this.cbxPinvert.CheckedChanged += new System.EventHandler(this.cbxPinvert_CheckedChanged); + // + // cbxPpts + // + this.cbxPpts.AutoSize = true; + this.cbxPpts.Location = new System.Drawing.Point(6, 91); + this.cbxPpts.Name = "cbxPpts"; + this.cbxPpts.Size = new System.Drawing.Size(15, 14); + this.cbxPpts.TabIndex = 32; + this.cbxPpts.UseVisualStyleBackColor = true; + this.cbxPpts.CheckedChanged += new System.EventHandler(this.cbxPpts_CheckedChanged); + // + // cbxPexpo + // + this.cbxPexpo.AutoSize = true; + this.cbxPexpo.Location = new System.Drawing.Point(6, 71); + this.cbxPexpo.Name = "cbxPexpo"; + this.cbxPexpo.Size = new System.Drawing.Size(75, 17); + this.cbxPexpo.TabIndex = 31; + this.cbxPexpo.Text = "Exponent"; + this.cbxPexpo.UseVisualStyleBackColor = true; + this.cbxPexpo.CheckedChanged += new System.EventHandler(this.cbxPexpo_CheckedChanged); + // + // cbxPsat + // + this.cbxPsat.AutoSize = true; + this.cbxPsat.Location = new System.Drawing.Point(6, 53); + this.cbxPsat.Name = "cbxPsat"; + this.cbxPsat.Size = new System.Drawing.Size(80, 17); + this.cbxPsat.TabIndex = 30; + this.cbxPsat.Text = "Saturation"; + this.cbxPsat.UseVisualStyleBackColor = true; + this.cbxPsat.CheckedChanged += new System.EventHandler(this.cbxPsense_CheckedChanged); + // + // cbxPdeadzone + // + this.cbxPdeadzone.AutoSize = true; + this.cbxPdeadzone.Location = new System.Drawing.Point(6, 35); + this.cbxPdeadzone.Name = "cbxPdeadzone"; + this.cbxPdeadzone.Size = new System.Drawing.Size(78, 17); + this.cbxPdeadzone.TabIndex = 29; + this.cbxPdeadzone.Text = "Deadzone"; + this.cbxPdeadzone.UseVisualStyleBackColor = true; + this.cbxPdeadzone.CheckedChanged += new System.EventHandler(this.cbxPdeadzone_CheckedChanged); + // + // label26 + // + this.label26.AutoSize = true; + this.label26.Location = new System.Drawing.Point(37, 126); + this.label26.Name = "label26"; + this.label26.Size = new System.Drawing.Size(23, 13); + this.label26.TabIndex = 28; + this.label26.Text = "Pt3"; + // + // label27 + // + this.label27.AutoSize = true; + this.label27.Location = new System.Drawing.Point(37, 108); + this.label27.Name = "label27"; + this.label27.Size = new System.Drawing.Size(23, 13); + this.label27.TabIndex = 27; + this.label27.Text = "Pt2"; + // + // label28 + // + this.label28.AutoSize = true; + this.label28.Location = new System.Drawing.Point(37, 90); + this.label28.Name = "label28"; + this.label28.Size = new System.Drawing.Size(23, 13); + this.label28.TabIndex = 26; + this.label28.Text = "Pt1"; + // + // lblPout3 + // + this.lblPout3.AutoSize = true; + this.lblPout3.Location = new System.Drawing.Point(99, 126); + this.lblPout3.Name = "lblPout3"; + this.lblPout3.Size = new System.Drawing.Size(28, 13); + this.lblPout3.TabIndex = 25; + this.lblPout3.Text = "0.75"; + // + // lblPin3 + // + this.lblPin3.AutoSize = true; + this.lblPin3.Location = new System.Drawing.Point(59, 126); + this.lblPin3.Name = "lblPin3"; + this.lblPin3.Size = new System.Drawing.Size(28, 13); + this.lblPin3.TabIndex = 24; + this.lblPin3.Text = "0.75"; + // + // lblPout2 + // + this.lblPout2.AutoSize = true; + this.lblPout2.Location = new System.Drawing.Point(99, 108); + this.lblPout2.Name = "lblPout2"; + this.lblPout2.Size = new System.Drawing.Size(22, 13); + this.lblPout2.TabIndex = 23; + this.lblPout2.Text = "0.5"; + // + // lblPin2 + // + this.lblPin2.AutoSize = true; + this.lblPin2.Location = new System.Drawing.Point(59, 108); + this.lblPin2.Name = "lblPin2"; + this.lblPin2.Size = new System.Drawing.Size(22, 13); + this.lblPin2.TabIndex = 22; + this.lblPin2.Text = "0.5"; + // + // lblPout1 + // + this.lblPout1.AutoSize = true; + this.lblPout1.Location = new System.Drawing.Point(99, 90); + this.lblPout1.Name = "lblPout1"; + this.lblPout1.Size = new System.Drawing.Size(28, 13); + this.lblPout1.TabIndex = 21; + this.lblPout1.Text = "0.25"; + // + // lblPin1 + // + this.lblPin1.AutoSize = true; + this.lblPin1.Location = new System.Drawing.Point(59, 90); + this.lblPin1.Name = "lblPin1"; + this.lblPin1.Size = new System.Drawing.Size(28, 13); + this.lblPin1.TabIndex = 20; + this.lblPin1.Text = "0.25"; + // + // lblPsat + // + this.lblPsat.AutoSize = true; + this.lblPsat.Location = new System.Drawing.Point(99, 54); + this.lblPsat.Name = "lblPsat"; + this.lblPsat.Size = new System.Drawing.Size(34, 13); + this.lblPsat.TabIndex = 10; + this.lblPsat.Text = "1.000"; + // + // lblPexponent + // + this.lblPexponent.AutoSize = true; + this.lblPexponent.Location = new System.Drawing.Point(99, 72); + this.lblPexponent.Name = "lblPexponent"; + this.lblPexponent.Size = new System.Drawing.Size(34, 13); + this.lblPexponent.TabIndex = 8; + this.lblPexponent.Text = "1.000"; + // + // lblPdeadzone + // + this.lblPdeadzone.AutoSize = true; + this.lblPdeadzone.Location = new System.Drawing.Point(99, 36); + this.lblPdeadzone.Name = "lblPdeadzone"; + this.lblPdeadzone.Size = new System.Drawing.Size(34, 13); + this.lblPdeadzone.TabIndex = 5; + this.lblPdeadzone.Text = "0.000"; + // + // lblPCmd + // + this.lblPCmd.AutoSize = true; + this.lblPCmd.Font = new System.Drawing.Font("Segoe UI", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblPCmd.Location = new System.Drawing.Point(37, 1); + this.lblPCmd.Name = "lblPCmd"; + this.lblPCmd.Size = new System.Drawing.Size(47, 12); + this.lblPCmd.TabIndex = 3; + this.lblPCmd.Text = "Command"; + // + // lblPitch + // + this.lblPitch.AutoSize = true; + this.lblPitch.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblPitch.Location = new System.Drawing.Point(2, 0); + this.lblPitch.Name = "lblPitch"; + this.lblPitch.Size = new System.Drawing.Size(33, 13); + this.lblPitch.TabIndex = 2; + this.lblPitch.Text = "Pitch"; + // + // pnlRoll + // + this.pnlRoll.BackColor = System.Drawing.Color.LightGreen; + this.pnlRoll.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; + this.pnlRoll.Controls.Add(this.lblRnt); + this.pnlRoll.Controls.Add(this.cbxRinvert); + this.pnlRoll.Controls.Add(this.cbxRpts); + this.pnlRoll.Controls.Add(this.cbxRexpo); + this.pnlRoll.Controls.Add(this.cbxRsat); + this.pnlRoll.Controls.Add(this.cbxRdeadzone); + this.pnlRoll.Controls.Add(this.label35); + this.pnlRoll.Controls.Add(this.label36); + this.pnlRoll.Controls.Add(this.label37); + this.pnlRoll.Controls.Add(this.lblRout3); + this.pnlRoll.Controls.Add(this.lblRin3); + this.pnlRoll.Controls.Add(this.lblRout2); + this.pnlRoll.Controls.Add(this.lblRin2); + this.pnlRoll.Controls.Add(this.lblRout1); + this.pnlRoll.Controls.Add(this.lblRin1); + this.pnlRoll.Controls.Add(this.lblRsat); + this.pnlRoll.Controls.Add(this.lblRexponent); + this.pnlRoll.Controls.Add(this.lblRdeadzone); + this.pnlRoll.Controls.Add(this.lblRCmd); + this.pnlRoll.Controls.Add(this.lblRoll); + this.pnlRoll.Dock = System.Windows.Forms.DockStyle.Fill; + this.pnlRoll.Location = new System.Drawing.Point(3, 445); + this.pnlRoll.Name = "pnlRoll"; + this.pnlRoll.Size = new System.Drawing.Size(138, 149); + this.pnlRoll.TabIndex = 4; + this.pnlRoll.MouseUp += new System.Windows.Forms.MouseEventHandler(this.pnlRoll_MouseUp); + // + // lblRnt + // + this.lblRnt.AutoSize = true; + this.lblRnt.Location = new System.Drawing.Point(107, 17); + this.lblRnt.Name = "lblRnt"; + this.lblRnt.Size = new System.Drawing.Size(20, 13); + this.lblRnt.TabIndex = 38; + this.lblRnt.Text = "NT"; + this.lblRnt.Visible = false; + // + // cbxRinvert + // + this.cbxRinvert.AutoSize = true; + this.cbxRinvert.Location = new System.Drawing.Point(6, 17); + this.cbxRinvert.Name = "cbxRinvert"; + this.cbxRinvert.Size = new System.Drawing.Size(55, 17); + this.cbxRinvert.TabIndex = 37; + this.cbxRinvert.Text = "Invert"; + this.cbxRinvert.UseVisualStyleBackColor = true; + this.cbxRinvert.CheckedChanged += new System.EventHandler(this.cbxRinvert_CheckedChanged); + // + // cbxRpts + // + this.cbxRpts.AutoSize = true; + this.cbxRpts.Location = new System.Drawing.Point(6, 91); + this.cbxRpts.Name = "cbxRpts"; + this.cbxRpts.Size = new System.Drawing.Size(15, 14); + this.cbxRpts.TabIndex = 36; + this.cbxRpts.UseVisualStyleBackColor = true; + this.cbxRpts.CheckedChanged += new System.EventHandler(this.cbxRpts_CheckedChanged); + // + // cbxRexpo + // + this.cbxRexpo.AutoSize = true; + this.cbxRexpo.Location = new System.Drawing.Point(6, 71); + this.cbxRexpo.Name = "cbxRexpo"; + this.cbxRexpo.Size = new System.Drawing.Size(75, 17); + this.cbxRexpo.TabIndex = 35; + this.cbxRexpo.Text = "Exponent"; + this.cbxRexpo.UseVisualStyleBackColor = true; + this.cbxRexpo.CheckedChanged += new System.EventHandler(this.cbxRexpo_CheckedChanged); + // + // cbxRsat + // + this.cbxRsat.AutoSize = true; + this.cbxRsat.Location = new System.Drawing.Point(6, 53); + this.cbxRsat.Name = "cbxRsat"; + this.cbxRsat.Size = new System.Drawing.Size(80, 17); + this.cbxRsat.TabIndex = 34; + this.cbxRsat.Text = "Saturation"; + this.cbxRsat.UseVisualStyleBackColor = true; + this.cbxRsat.CheckedChanged += new System.EventHandler(this.cbxRsense_CheckedChanged); + // + // cbxRdeadzone + // + this.cbxRdeadzone.AutoSize = true; + this.cbxRdeadzone.Location = new System.Drawing.Point(6, 35); + this.cbxRdeadzone.Name = "cbxRdeadzone"; + this.cbxRdeadzone.Size = new System.Drawing.Size(78, 17); + this.cbxRdeadzone.TabIndex = 33; + this.cbxRdeadzone.Text = "Deadzone"; + this.cbxRdeadzone.UseVisualStyleBackColor = true; + this.cbxRdeadzone.CheckedChanged += new System.EventHandler(this.cbxRdeadzone_CheckedChanged); + // + // label35 + // + this.label35.AutoSize = true; + this.label35.Location = new System.Drawing.Point(37, 126); + this.label35.Name = "label35"; + this.label35.Size = new System.Drawing.Size(23, 13); + this.label35.TabIndex = 28; + this.label35.Text = "Pt3"; + // + // label36 + // + this.label36.AutoSize = true; + this.label36.Location = new System.Drawing.Point(37, 108); + this.label36.Name = "label36"; + this.label36.Size = new System.Drawing.Size(23, 13); + this.label36.TabIndex = 27; + this.label36.Text = "Pt2"; + // + // label37 + // + this.label37.AutoSize = true; + this.label37.Location = new System.Drawing.Point(37, 90); + this.label37.Name = "label37"; + this.label37.Size = new System.Drawing.Size(23, 13); + this.label37.TabIndex = 26; + this.label37.Text = "Pt1"; + // + // lblRout3 + // + this.lblRout3.AutoSize = true; + this.lblRout3.Location = new System.Drawing.Point(99, 126); + this.lblRout3.Name = "lblRout3"; + this.lblRout3.Size = new System.Drawing.Size(28, 13); + this.lblRout3.TabIndex = 25; + this.lblRout3.Text = "0.75"; + // + // lblRin3 + // + this.lblRin3.AutoSize = true; + this.lblRin3.Location = new System.Drawing.Point(59, 126); + this.lblRin3.Name = "lblRin3"; + this.lblRin3.Size = new System.Drawing.Size(28, 13); + this.lblRin3.TabIndex = 24; + this.lblRin3.Text = "0.75"; + // + // lblRout2 + // + this.lblRout2.AutoSize = true; + this.lblRout2.Location = new System.Drawing.Point(99, 108); + this.lblRout2.Name = "lblRout2"; + this.lblRout2.Size = new System.Drawing.Size(22, 13); + this.lblRout2.TabIndex = 23; + this.lblRout2.Text = "0.5"; + // + // lblRin2 + // + this.lblRin2.AutoSize = true; + this.lblRin2.Location = new System.Drawing.Point(59, 108); + this.lblRin2.Name = "lblRin2"; + this.lblRin2.Size = new System.Drawing.Size(22, 13); + this.lblRin2.TabIndex = 22; + this.lblRin2.Text = "0.5"; + // + // lblRout1 + // + this.lblRout1.AutoSize = true; + this.lblRout1.Location = new System.Drawing.Point(99, 90); + this.lblRout1.Name = "lblRout1"; + this.lblRout1.Size = new System.Drawing.Size(28, 13); + this.lblRout1.TabIndex = 21; + this.lblRout1.Text = "0.25"; + // + // lblRin1 + // + this.lblRin1.AutoSize = true; + this.lblRin1.Location = new System.Drawing.Point(59, 90); + this.lblRin1.Name = "lblRin1"; + this.lblRin1.Size = new System.Drawing.Size(28, 13); + this.lblRin1.TabIndex = 20; + this.lblRin1.Text = "0.25"; + // + // lblRsat + // + this.lblRsat.AutoSize = true; + this.lblRsat.Location = new System.Drawing.Point(99, 54); + this.lblRsat.Name = "lblRsat"; + this.lblRsat.Size = new System.Drawing.Size(34, 13); + this.lblRsat.TabIndex = 10; + this.lblRsat.Text = "1.000"; + // + // lblRexponent + // + this.lblRexponent.AutoSize = true; + this.lblRexponent.Location = new System.Drawing.Point(99, 72); + this.lblRexponent.Name = "lblRexponent"; + this.lblRexponent.Size = new System.Drawing.Size(34, 13); + this.lblRexponent.TabIndex = 8; + this.lblRexponent.Text = "1.000"; + // + // lblRdeadzone + // + this.lblRdeadzone.AutoSize = true; + this.lblRdeadzone.Location = new System.Drawing.Point(99, 36); + this.lblRdeadzone.Name = "lblRdeadzone"; + this.lblRdeadzone.Size = new System.Drawing.Size(34, 13); + this.lblRdeadzone.TabIndex = 6; + this.lblRdeadzone.Text = "0.000"; + // + // lblRCmd + // + this.lblRCmd.AutoSize = true; + this.lblRCmd.Font = new System.Drawing.Font("Segoe UI", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblRCmd.Location = new System.Drawing.Point(37, 1); + this.lblRCmd.Name = "lblRCmd"; + this.lblRCmd.Size = new System.Drawing.Size(47, 12); + this.lblRCmd.TabIndex = 4; + this.lblRCmd.Text = "Command"; + // + // lblRoll + // + this.lblRoll.AutoSize = true; + this.lblRoll.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblRoll.Location = new System.Drawing.Point(2, 0); + this.lblRoll.Name = "lblRoll"; + this.lblRoll.Size = new System.Drawing.Size(27, 13); + this.lblRoll.TabIndex = 2; + this.lblRoll.Text = "Roll"; + // + // tableLayoutPanel1 + // + this.tableLayoutPanel1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); - this.tableLayoutPanel1.ColumnCount = 2; - this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 58.79447F)); - this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 41.20553F)); - this.tableLayoutPanel1.Controls.Add(this.panel9, 1, 1); - this.tableLayoutPanel1.Controls.Add(this.panel1, 1, 0); - this.tableLayoutPanel1.Controls.Add(this.panel6, 0, 0); - this.tableLayoutPanel1.Controls.Add(this.flowLayoutPanel1, 1, 2); - this.tableLayoutPanel1.Controls.Add(this.tableLayoutPanel3, 1, 3); - this.tableLayoutPanel1.GrowStyle = System.Windows.Forms.TableLayoutPanelGrowStyle.FixedSize; - this.tableLayoutPanel1.Location = new System.Drawing.Point(153, 619); - this.tableLayoutPanel1.Name = "tableLayoutPanel1"; - this.tableLayoutPanel1.RowCount = 4; - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 60F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 60F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 97F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tableLayoutPanel1.Size = new System.Drawing.Size(1028, 294); - this.tableLayoutPanel1.TabIndex = 1; - // - // panel9 - // - this.panel9.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + this.tableLayoutPanel1.ColumnCount = 2; + this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 58.79447F)); + this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 41.20553F)); + this.tableLayoutPanel1.Controls.Add(this.panel9, 1, 1); + this.tableLayoutPanel1.Controls.Add(this.panel1, 1, 0); + this.tableLayoutPanel1.Controls.Add(this.panel6, 0, 0); + this.tableLayoutPanel1.Controls.Add(this.flowLayoutPanel1, 1, 2); + this.tableLayoutPanel1.Controls.Add(this.tableLayoutPanel3, 1, 3); + this.tableLayoutPanel1.GrowStyle = System.Windows.Forms.TableLayoutPanelGrowStyle.FixedSize; + this.tableLayoutPanel1.Location = new System.Drawing.Point(153, 619); + this.tableLayoutPanel1.Name = "tableLayoutPanel1"; + this.tableLayoutPanel1.RowCount = 4; + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 60F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 60F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 61F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); + this.tableLayoutPanel1.Size = new System.Drawing.Size(1028, 294); + this.tableLayoutPanel1.TabIndex = 1; + // + // panel9 + // + this.panel9.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Right))); - this.panel9.Controls.Add(this.label6); - this.panel9.Controls.Add(this.lblDamping); - this.panel9.Controls.Add(this.slDamping); - this.panel9.Location = new System.Drawing.Point(624, 63); - this.panel9.Name = "panel9"; - this.panel9.Size = new System.Drawing.Size(401, 54); - this.panel9.TabIndex = 7; - // - // label6 - // - this.label6.AutoSize = true; - this.label6.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label6.Location = new System.Drawing.Point(273, 8); - this.label6.Name = "label6"; - this.label6.Size = new System.Drawing.Size(54, 13); - this.label6.TabIndex = 12; - this.label6.Text = "damping"; - // - // lblDamping - // - this.lblDamping.AutoSize = true; - this.lblDamping.Location = new System.Drawing.Point(273, 29); - this.lblDamping.Name = "lblDamping"; - this.lblDamping.Size = new System.Drawing.Size(13, 13); - this.lblDamping.TabIndex = 3; - this.lblDamping.Text = "1"; - // - // slDamping - // - this.slDamping.LargeChange = 1; - this.slDamping.Location = new System.Drawing.Point(3, 3); - this.slDamping.Minimum = 1; - this.slDamping.Name = "slDamping"; - this.slDamping.Size = new System.Drawing.Size(264, 45); - this.slDamping.TabIndex = 2; - this.slDamping.TickStyle = System.Windows.Forms.TickStyle.Both; - this.slDamping.Value = 4; - this.slDamping.ValueChanged += new System.EventHandler(this.slDamping_ValueChanged); - // - // panel1 - // - this.panel1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + this.panel9.Controls.Add(this.label6); + this.panel9.Controls.Add(this.lblDamping); + this.panel9.Controls.Add(this.slDamping); + this.panel9.Location = new System.Drawing.Point(624, 63); + this.panel9.Name = "panel9"; + this.panel9.Size = new System.Drawing.Size(401, 54); + this.panel9.TabIndex = 7; + // + // label6 + // + this.label6.AutoSize = true; + this.label6.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label6.Location = new System.Drawing.Point(273, 8); + this.label6.Name = "label6"; + this.label6.Size = new System.Drawing.Size(54, 13); + this.label6.TabIndex = 12; + this.label6.Text = "damping"; + // + // lblDamping + // + this.lblDamping.AutoSize = true; + this.lblDamping.Location = new System.Drawing.Point(273, 29); + this.lblDamping.Name = "lblDamping"; + this.lblDamping.Size = new System.Drawing.Size(13, 13); + this.lblDamping.TabIndex = 3; + this.lblDamping.Text = "1"; + // + // slDamping + // + this.slDamping.LargeChange = 1; + this.slDamping.Location = new System.Drawing.Point(3, 3); + this.slDamping.Minimum = 1; + this.slDamping.Name = "slDamping"; + this.slDamping.Size = new System.Drawing.Size(264, 45); + this.slDamping.TabIndex = 2; + this.slDamping.TickStyle = System.Windows.Forms.TickStyle.Both; + this.slDamping.Value = 4; + this.slDamping.ValueChanged += new System.EventHandler(this.slDamping_ValueChanged); + // + // panel1 + // + this.panel1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Right))); - this.panel1.Controls.Add(this.label16); - this.panel1.Controls.Add(this.lblTurnspeed); - this.panel1.Controls.Add(this.slTurnSpeed); - this.panel1.Location = new System.Drawing.Point(624, 3); - this.panel1.Name = "panel1"; - this.panel1.Size = new System.Drawing.Size(401, 54); - this.panel1.TabIndex = 4; - // - // label16 - // - this.label16.AutoSize = true; - this.label16.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label16.Location = new System.Drawing.Point(273, 8); - this.label16.Name = "label16"; - this.label16.Size = new System.Drawing.Size(93, 13); - this.label16.TabIndex = 12; - this.label16.Text = "sec per 360° turn"; - // - // lblTurnspeed - // - this.lblTurnspeed.AutoSize = true; - this.lblTurnspeed.Location = new System.Drawing.Point(273, 29); - this.lblTurnspeed.Name = "lblTurnspeed"; - this.lblTurnspeed.Size = new System.Drawing.Size(13, 13); - this.lblTurnspeed.TabIndex = 3; - this.lblTurnspeed.Text = "1"; - // - // slTurnSpeed - // - this.slTurnSpeed.LargeChange = 1; - this.slTurnSpeed.Location = new System.Drawing.Point(3, 3); - this.slTurnSpeed.Maximum = 30; - this.slTurnSpeed.Minimum = 1; - this.slTurnSpeed.Name = "slTurnSpeed"; - this.slTurnSpeed.Size = new System.Drawing.Size(264, 45); - this.slTurnSpeed.TabIndex = 2; - this.slTurnSpeed.TickStyle = System.Windows.Forms.TickStyle.Both; - this.slTurnSpeed.Value = 6; - this.slTurnSpeed.ValueChanged += new System.EventHandler(this.slTurnSpeed_ValueChanged); - // - // panel6 - // - this.panel6.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + this.panel1.Controls.Add(this.label16); + this.panel1.Controls.Add(this.lblTurnspeed); + this.panel1.Controls.Add(this.slTurnSpeed); + this.panel1.Location = new System.Drawing.Point(624, 3); + this.panel1.Name = "panel1"; + this.panel1.Size = new System.Drawing.Size(401, 54); + this.panel1.TabIndex = 4; + // + // label16 + // + this.label16.AutoSize = true; + this.label16.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label16.Location = new System.Drawing.Point(273, 8); + this.label16.Name = "label16"; + this.label16.Size = new System.Drawing.Size(93, 13); + this.label16.TabIndex = 12; + this.label16.Text = "sec per 360° turn"; + // + // lblTurnspeed + // + this.lblTurnspeed.AutoSize = true; + this.lblTurnspeed.Location = new System.Drawing.Point(273, 29); + this.lblTurnspeed.Name = "lblTurnspeed"; + this.lblTurnspeed.Size = new System.Drawing.Size(13, 13); + this.lblTurnspeed.TabIndex = 3; + this.lblTurnspeed.Text = "1"; + // + // slTurnSpeed + // + this.slTurnSpeed.LargeChange = 1; + this.slTurnSpeed.Location = new System.Drawing.Point(3, 3); + this.slTurnSpeed.Maximum = 30; + this.slTurnSpeed.Minimum = 1; + this.slTurnSpeed.Name = "slTurnSpeed"; + this.slTurnSpeed.Size = new System.Drawing.Size(264, 45); + this.slTurnSpeed.TabIndex = 2; + this.slTurnSpeed.TickStyle = System.Windows.Forms.TickStyle.Both; + this.slTurnSpeed.Value = 6; + this.slTurnSpeed.ValueChanged += new System.EventHandler(this.slTurnSpeed_ValueChanged); + // + // panel6 + // + this.panel6.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left))); - this.panel6.BackColor = System.Drawing.Color.WhiteSmoke; - this.panel6.Controls.Add(this.rbPtDeadzone); - this.panel6.Controls.Add(this.lblGraphSaturation); - this.panel6.Controls.Add(this.lblGraphDeadzone); - this.panel6.Controls.Add(this.lblNodetext); - this.panel6.Controls.Add(this.label12); - this.panel6.Controls.Add(this.cbRuse); - this.panel6.Controls.Add(this.cbPuse); - this.panel6.Controls.Add(this.cbYuse); - this.panel6.Controls.Add(this.label11); - this.panel6.Controls.Add(this.label10); - this.panel6.Controls.Add(this.lblROutput); - this.panel6.Controls.Add(this.lblRInput); - this.panel6.Controls.Add(this.lblPOutput); - this.panel6.Controls.Add(this.lblPInput); - this.panel6.Controls.Add(this.lblLiveRoll); - this.panel6.Controls.Add(this.lblLivePitch); - this.panel6.Controls.Add(this.btCopyToAllAxis); - this.panel6.Controls.Add(this.lblLiveYaw); - this.panel6.Controls.Add(this.label4); - this.panel6.Controls.Add(this.lblYOutput); - this.panel6.Controls.Add(this.lblYInput); - this.panel6.Controls.Add(this.rbPtExponent); - this.panel6.Controls.Add(this.rbPtSaturation); - this.panel6.Controls.Add(this.rbPt3); - this.panel6.Controls.Add(this.rbPt2); - this.panel6.Controls.Add(this.rbPt1); - this.panel6.Controls.Add(this.label33); - this.panel6.Controls.Add(this.label32); - this.panel6.Controls.Add(this.lblOut3); - this.panel6.Controls.Add(this.lblIn3); - this.panel6.Controls.Add(this.lblOut2); - this.panel6.Controls.Add(this.lblIn2); - this.panel6.Controls.Add(this.lblOut1); - this.panel6.Controls.Add(this.lblIn1); - this.panel6.Controls.Add(this.chart1); - this.panel6.Controls.Add(this.lblOutSlider); - this.panel6.Controls.Add(this.lblOutExponent); - this.panel6.Controls.Add(this.tbSlider); - this.panel6.Location = new System.Drawing.Point(3, 3); - this.panel6.Name = "panel6"; - this.tableLayoutPanel1.SetRowSpan(this.panel6, 4); - this.panel6.Size = new System.Drawing.Size(579, 288); - this.panel6.TabIndex = 5; - // - // rbPtDeadzone - // - this.rbPtDeadzone.AutoSize = true; - this.rbPtDeadzone.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.rbPtDeadzone.Location = new System.Drawing.Point(14, 72); - this.rbPtDeadzone.Name = "rbPtDeadzone"; - this.rbPtDeadzone.Size = new System.Drawing.Size(81, 19); - this.rbPtDeadzone.TabIndex = 54; - this.rbPtDeadzone.Text = "Deadzone"; - this.rbPtDeadzone.UseVisualStyleBackColor = true; - this.rbPtDeadzone.CheckedChanged += new System.EventHandler(this.rbPtAny_CheckedChanged); - // - // lblGraphSaturation - // - this.lblGraphSaturation.AutoSize = true; - this.lblGraphSaturation.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblGraphSaturation.Location = new System.Drawing.Point(531, 266); - this.lblGraphSaturation.Name = "lblGraphSaturation"; - this.lblGraphSaturation.Size = new System.Drawing.Size(34, 15); - this.lblGraphSaturation.TabIndex = 53; - this.lblGraphSaturation.Text = "0.000"; - // - // lblGraphDeadzone - // - this.lblGraphDeadzone.AutoSize = true; - this.lblGraphDeadzone.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblGraphDeadzone.Location = new System.Drawing.Point(252, 266); - this.lblGraphDeadzone.Name = "lblGraphDeadzone"; - this.lblGraphDeadzone.Size = new System.Drawing.Size(34, 15); - this.lblGraphDeadzone.TabIndex = 52; - this.lblGraphDeadzone.Text = "0.000"; - // - // lblNodetext - // - this.lblNodetext.AutoSize = true; - this.lblNodetext.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblNodetext.Location = new System.Drawing.Point(11, 3); - this.lblNodetext.Name = "lblNodetext"; - this.lblNodetext.Size = new System.Drawing.Size(16, 13); - this.lblNodetext.TabIndex = 51; - this.lblNodetext.Text = "..."; - // - // label12 - // - this.label12.AutoSize = true; - this.label12.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label12.Location = new System.Drawing.Point(213, 233); - this.label12.Name = "label12"; - this.label12.Size = new System.Drawing.Size(16, 45); - this.label12.TabIndex = 50; - this.label12.Text = "O\r\nF\r\nF\r\n"; - // - // cbRuse - // - this.cbRuse.AutoSize = true; - this.cbRuse.Location = new System.Drawing.Point(192, 267); - this.cbRuse.Name = "cbRuse"; - this.cbRuse.Size = new System.Drawing.Size(15, 14); - this.cbRuse.TabIndex = 49; - this.cbRuse.UseVisualStyleBackColor = true; - // - // cbPuse - // - this.cbPuse.AutoSize = true; - this.cbPuse.Location = new System.Drawing.Point(192, 248); - this.cbPuse.Name = "cbPuse"; - this.cbPuse.Size = new System.Drawing.Size(15, 14); - this.cbPuse.TabIndex = 48; - this.cbPuse.UseVisualStyleBackColor = true; - // - // cbYuse - // - this.cbYuse.AutoSize = true; - this.cbYuse.Location = new System.Drawing.Point(192, 228); - this.cbYuse.Name = "cbYuse"; - this.cbYuse.Size = new System.Drawing.Size(15, 14); - this.cbYuse.TabIndex = 47; - this.cbYuse.UseVisualStyleBackColor = true; - // - // label11 - // - this.label11.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; - this.label11.Location = new System.Drawing.Point(5, 216); - this.label11.Name = "label11"; - this.label11.Size = new System.Drawing.Size(246, 3); - this.label11.TabIndex = 46; - this.label11.Text = " sd"; - // - // label10 - // - this.label10.AutoSize = true; - this.label10.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label10.Location = new System.Drawing.Point(15, 225); - this.label10.Name = "label10"; - this.label10.Size = new System.Drawing.Size(13, 60); - this.label10.TabIndex = 45; - this.label10.Text = "L\r\ni\r\nv\r\ne"; - // - // lblROutput - // - this.lblROutput.AutoSize = true; - this.lblROutput.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblROutput.Location = new System.Drawing.Point(142, 266); - this.lblROutput.Name = "lblROutput"; - this.lblROutput.Size = new System.Drawing.Size(34, 15); - this.lblROutput.TabIndex = 44; - this.lblROutput.Text = "0.000"; - // - // lblRInput - // - this.lblRInput.AutoSize = true; - this.lblRInput.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblRInput.Location = new System.Drawing.Point(89, 266); - this.lblRInput.Name = "lblRInput"; - this.lblRInput.Size = new System.Drawing.Size(34, 15); - this.lblRInput.TabIndex = 43; - this.lblRInput.Text = "0.000"; - // - // lblPOutput - // - this.lblPOutput.AutoSize = true; - this.lblPOutput.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblPOutput.Location = new System.Drawing.Point(142, 247); - this.lblPOutput.Name = "lblPOutput"; - this.lblPOutput.Size = new System.Drawing.Size(34, 15); - this.lblPOutput.TabIndex = 42; - this.lblPOutput.Text = "0.000"; - // - // lblPInput - // - this.lblPInput.AutoSize = true; - this.lblPInput.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblPInput.Location = new System.Drawing.Point(89, 247); - this.lblPInput.Name = "lblPInput"; - this.lblPInput.Size = new System.Drawing.Size(34, 15); - this.lblPInput.TabIndex = 41; - this.lblPInput.Text = "0.000"; - // - // lblLiveRoll - // - this.lblLiveRoll.AutoSize = true; - this.lblLiveRoll.BackColor = System.Drawing.Color.LightGreen; - this.lblLiveRoll.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblLiveRoll.Location = new System.Drawing.Point(32, 266); - this.lblLiveRoll.Name = "lblLiveRoll"; - this.lblLiveRoll.Size = new System.Drawing.Size(46, 15); - this.lblLiveRoll.TabIndex = 40; - this.lblLiveRoll.Text = "R-Axis:"; - // - // lblLivePitch - // - this.lblLivePitch.AutoSize = true; - this.lblLivePitch.BackColor = System.Drawing.Color.Salmon; - this.lblLivePitch.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblLivePitch.Location = new System.Drawing.Point(32, 247); - this.lblLivePitch.Name = "lblLivePitch"; - this.lblLivePitch.Size = new System.Drawing.Size(45, 15); - this.lblLivePitch.TabIndex = 39; - this.lblLivePitch.Text = "P-Axis:"; - // - // btCopyToAllAxis - // - this.btCopyToAllAxis.Location = new System.Drawing.Point(192, 159); - this.btCopyToAllAxis.Name = "btCopyToAllAxis"; - this.btCopyToAllAxis.Size = new System.Drawing.Size(57, 44); - this.btCopyToAllAxis.TabIndex = 38; - this.btCopyToAllAxis.Text = "Copy to all axis"; - this.btCopyToAllAxis.UseVisualStyleBackColor = true; - this.btCopyToAllAxis.Click += new System.EventHandler(this.btCopyToAllAxis_Click); - // - // lblLiveYaw - // - this.lblLiveYaw.AutoSize = true; - this.lblLiveYaw.BackColor = System.Drawing.Color.PowderBlue; - this.lblLiveYaw.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblLiveYaw.Location = new System.Drawing.Point(32, 228); - this.lblLiveYaw.Name = "lblLiveYaw"; - this.lblLiveYaw.Size = new System.Drawing.Size(45, 15); - this.lblLiveYaw.TabIndex = 37; - this.lblLiveYaw.Text = "Y-Axis:"; - // - // label4 - // - this.label4.AutoSize = true; - this.label4.Location = new System.Drawing.Point(310, 272); - this.label4.Name = "label4"; - this.label4.Size = new System.Drawing.Size(193, 13); - this.label4.TabIndex = 36; - this.label4.Text = "Select an option then click and drag"; - // - // lblYOutput - // - this.lblYOutput.AutoSize = true; - this.lblYOutput.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblYOutput.Location = new System.Drawing.Point(142, 228); - this.lblYOutput.Name = "lblYOutput"; - this.lblYOutput.Size = new System.Drawing.Size(34, 15); - this.lblYOutput.TabIndex = 35; - this.lblYOutput.Text = "0.000"; - // - // lblYInput - // - this.lblYInput.AutoSize = true; - this.lblYInput.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblYInput.Location = new System.Drawing.Point(89, 228); - this.lblYInput.Name = "lblYInput"; - this.lblYInput.Size = new System.Drawing.Size(34, 15); - this.lblYInput.TabIndex = 34; - this.lblYInput.Text = "0.000"; - // - // rbPtExponent - // - this.rbPtExponent.AutoSize = true; - this.rbPtExponent.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.rbPtExponent.Location = new System.Drawing.Point(14, 108); - this.rbPtExponent.Name = "rbPtExponent"; - this.rbPtExponent.Size = new System.Drawing.Size(81, 19); - this.rbPtExponent.TabIndex = 33; - this.rbPtExponent.Text = "Exponent:"; - this.rbPtExponent.UseVisualStyleBackColor = true; - this.rbPtExponent.CheckedChanged += new System.EventHandler(this.rbPtAny_CheckedChanged); - // - // rbPtSaturation - // - this.rbPtSaturation.AutoSize = true; - this.rbPtSaturation.Checked = true; - this.rbPtSaturation.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.rbPtSaturation.Location = new System.Drawing.Point(101, 72); - this.rbPtSaturation.Name = "rbPtSaturation"; - this.rbPtSaturation.Size = new System.Drawing.Size(83, 19); - this.rbPtSaturation.TabIndex = 32; - this.rbPtSaturation.TabStop = true; - this.rbPtSaturation.Text = "Saturation"; - this.rbPtSaturation.UseVisualStyleBackColor = true; - this.rbPtSaturation.CheckedChanged += new System.EventHandler(this.rbPtAny_CheckedChanged); - // - // rbPt3 - // - this.rbPt3.AutoSize = true; - this.rbPt3.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.rbPt3.Location = new System.Drawing.Point(14, 194); - this.rbPt3.Name = "rbPt3"; - this.rbPt3.Size = new System.Drawing.Size(67, 19); - this.rbPt3.TabIndex = 31; - this.rbPt3.Text = "Point 3:"; - this.rbPt3.UseVisualStyleBackColor = true; - this.rbPt3.CheckedChanged += new System.EventHandler(this.rbPtAny_CheckedChanged); - // - // rbPt2 - // - this.rbPt2.AutoSize = true; - this.rbPt2.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.rbPt2.Location = new System.Drawing.Point(14, 171); - this.rbPt2.Name = "rbPt2"; - this.rbPt2.Size = new System.Drawing.Size(67, 19); - this.rbPt2.TabIndex = 30; - this.rbPt2.Text = "Point 2:"; - this.rbPt2.UseVisualStyleBackColor = true; - this.rbPt2.CheckedChanged += new System.EventHandler(this.rbPtAny_CheckedChanged); - // - // rbPt1 - // - this.rbPt1.AutoSize = true; - this.rbPt1.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.rbPt1.Location = new System.Drawing.Point(14, 148); - this.rbPt1.Name = "rbPt1"; - this.rbPt1.Size = new System.Drawing.Size(67, 19); - this.rbPt1.TabIndex = 29; - this.rbPt1.Text = "Point 1:"; - this.rbPt1.UseVisualStyleBackColor = true; - this.rbPt1.CheckedChanged += new System.EventHandler(this.rbPtAny_CheckedChanged); - // - // label33 - // - this.label33.AutoSize = true; - this.label33.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label33.Location = new System.Drawing.Point(135, 130); - this.label33.Name = "label33"; - this.label33.Size = new System.Drawing.Size(46, 15); - this.label33.TabIndex = 28; - this.label33.Text = "OUT(y)"; - // - // label32 - // - this.label32.AutoSize = true; - this.label32.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label32.Location = new System.Drawing.Point(89, 130); - this.label32.Name = "label32"; - this.label32.Size = new System.Drawing.Size(35, 15); - this.label32.TabIndex = 27; - this.label32.Text = "IN(x)"; - // - // lblOut3 - // - this.lblOut3.AutoSize = true; - this.lblOut3.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblOut3.Location = new System.Drawing.Point(142, 196); - this.lblOut3.Name = "lblOut3"; - this.lblOut3.Size = new System.Drawing.Size(28, 15); - this.lblOut3.TabIndex = 23; - this.lblOut3.Text = "0.75"; - // - // lblIn3 - // - this.lblIn3.AutoSize = true; - this.lblIn3.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblIn3.Location = new System.Drawing.Point(89, 196); - this.lblIn3.Name = "lblIn3"; - this.lblIn3.Size = new System.Drawing.Size(28, 15); - this.lblIn3.TabIndex = 22; - this.lblIn3.Text = "0.75"; - // - // lblOut2 - // - this.lblOut2.AutoSize = true; - this.lblOut2.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblOut2.Location = new System.Drawing.Point(142, 173); - this.lblOut2.Name = "lblOut2"; - this.lblOut2.Size = new System.Drawing.Size(22, 15); - this.lblOut2.TabIndex = 21; - this.lblOut2.Text = "0.5"; - // - // lblIn2 - // - this.lblIn2.AutoSize = true; - this.lblIn2.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblIn2.Location = new System.Drawing.Point(89, 173); - this.lblIn2.Name = "lblIn2"; - this.lblIn2.Size = new System.Drawing.Size(22, 15); - this.lblIn2.TabIndex = 20; - this.lblIn2.Text = "0.5"; - // - // lblOut1 - // - this.lblOut1.AutoSize = true; - this.lblOut1.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblOut1.Location = new System.Drawing.Point(142, 150); - this.lblOut1.Name = "lblOut1"; - this.lblOut1.Size = new System.Drawing.Size(28, 15); - this.lblOut1.TabIndex = 19; - this.lblOut1.Text = "0.25"; - // - // lblIn1 - // - this.lblIn1.AutoSize = true; - this.lblIn1.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblIn1.Location = new System.Drawing.Point(89, 150); - this.lblIn1.Name = "lblIn1"; - this.lblIn1.Size = new System.Drawing.Size(28, 15); - this.lblIn1.TabIndex = 18; - this.lblIn1.Text = "0.25"; - // - // chart1 - // - chartArea1.AxisX.Crossing = -1.7976931348623157E+308D; - chartArea1.AxisX.IsMarginVisible = false; - chartArea1.AxisX.LabelStyle.Enabled = false; - chartArea1.AxisX.MajorGrid.Interval = 0.2D; - chartArea1.AxisX.MajorGrid.IntervalType = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number; - chartArea1.AxisX.MajorTickMark.Interval = 0.2D; - chartArea1.AxisX.MajorTickMark.IntervalType = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number; - chartArea1.AxisX.Maximum = 1D; - chartArea1.AxisX.Minimum = 0D; - chartArea1.AxisX.MinorGrid.Interval = 0.1D; - chartArea1.AxisX.MinorGrid.IntervalType = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number; - chartArea1.AxisX.MinorTickMark.Interval = 0.1D; - chartArea1.AxisX.MinorTickMark.IntervalOffsetType = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number; - chartArea1.AxisY.Crossing = -1.7976931348623157E+308D; - chartArea1.AxisY.Interval = 5D; - chartArea1.AxisY.IsMarginVisible = false; - chartArea1.AxisY.LabelStyle.Enabled = false; - chartArea1.AxisY.MajorGrid.Interval = 0.2D; - chartArea1.AxisY.MajorGrid.IntervalType = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number; - chartArea1.AxisY.MajorTickMark.Interval = 0.2D; - chartArea1.AxisY.MajorTickMark.IntervalType = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number; - chartArea1.AxisY.Maximum = 1D; - chartArea1.AxisY.Minimum = 0D; - chartArea1.Name = "ChartArea1"; - this.chart1.ChartAreas.Add(chartArea1); - this.chart1.Location = new System.Drawing.Point(258, 7); - this.chart1.Name = "chart1"; - series1.ChartArea = "ChartArea1"; - series1.ChartType = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.Spline; - series1.MarkerColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0))))); - series1.MarkerStyle = System.Windows.Forms.DataVisualization.Charting.MarkerStyle.Circle; - series1.Name = "Series1"; - this.chart1.Series.Add(series1); - this.chart1.Size = new System.Drawing.Size(301, 262); - this.chart1.TabIndex = 16; - this.chart1.Text = "chart1"; - this.chart1.MouseDown += new System.Windows.Forms.MouseEventHandler(this.chartPoint_MouseDown); - this.chart1.MouseMove += new System.Windows.Forms.MouseEventHandler(this.chartPoint_MouseMove); - this.chart1.MouseUp += new System.Windows.Forms.MouseEventHandler(this.chartPoint_MouseUp); - // - // lblOutSlider - // - this.lblOutSlider.AutoSize = true; - this.lblOutSlider.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblOutSlider.Location = new System.Drawing.Point(174, 34); - this.lblOutSlider.Name = "lblOutSlider"; - this.lblOutSlider.Size = new System.Drawing.Size(34, 15); - this.lblOutSlider.TabIndex = 13; - this.lblOutSlider.Text = "0.000"; - // - // lblOutExponent - // - this.lblOutExponent.AutoSize = true; - this.lblOutExponent.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblOutExponent.Location = new System.Drawing.Point(112, 110); - this.lblOutExponent.Name = "lblOutExponent"; - this.lblOutExponent.Size = new System.Drawing.Size(34, 15); - this.lblOutExponent.TabIndex = 9; - this.lblOutExponent.Text = "0.000"; - // - // tbSlider - // - this.tbSlider.Location = new System.Drawing.Point(3, 21); - this.tbSlider.Maximum = 40; - this.tbSlider.Name = "tbSlider"; - this.tbSlider.Size = new System.Drawing.Size(165, 45); - this.tbSlider.TabIndex = 0; - this.tbSlider.TickFrequency = 5; - this.tbSlider.TickStyle = System.Windows.Forms.TickStyle.Both; - this.tbSlider.ValueChanged += new System.EventHandler(this.tbSlider_ValueChanged); - // - // flowLayoutPanel1 - // - this.flowLayoutPanel1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + this.panel6.BackColor = System.Drawing.Color.WhiteSmoke; + this.panel6.Controls.Add(this.rbPtDeadzone); + this.panel6.Controls.Add(this.lblGraphSaturation); + this.panel6.Controls.Add(this.lblGraphDeadzone); + this.panel6.Controls.Add(this.lblNodetext); + this.panel6.Controls.Add(this.label12); + this.panel6.Controls.Add(this.cbRuse); + this.panel6.Controls.Add(this.cbPuse); + this.panel6.Controls.Add(this.cbYuse); + this.panel6.Controls.Add(this.label11); + this.panel6.Controls.Add(this.label10); + this.panel6.Controls.Add(this.lblROutput); + this.panel6.Controls.Add(this.lblRInput); + this.panel6.Controls.Add(this.lblPOutput); + this.panel6.Controls.Add(this.lblPInput); + this.panel6.Controls.Add(this.lblLiveRoll); + this.panel6.Controls.Add(this.lblLivePitch); + this.panel6.Controls.Add(this.btCopyToAllAxis); + this.panel6.Controls.Add(this.lblLiveYaw); + this.panel6.Controls.Add(this.label4); + this.panel6.Controls.Add(this.lblYOutput); + this.panel6.Controls.Add(this.lblYInput); + this.panel6.Controls.Add(this.rbPtExponent); + this.panel6.Controls.Add(this.rbPtSaturation); + this.panel6.Controls.Add(this.rbPt3); + this.panel6.Controls.Add(this.rbPt2); + this.panel6.Controls.Add(this.rbPt1); + this.panel6.Controls.Add(this.label33); + this.panel6.Controls.Add(this.label32); + this.panel6.Controls.Add(this.lblOut3); + this.panel6.Controls.Add(this.lblIn3); + this.panel6.Controls.Add(this.lblOut2); + this.panel6.Controls.Add(this.lblIn2); + this.panel6.Controls.Add(this.lblOut1); + this.panel6.Controls.Add(this.lblIn1); + this.panel6.Controls.Add(this.chart1); + this.panel6.Controls.Add(this.lblOutSlider); + this.panel6.Controls.Add(this.lblOutExponent); + this.panel6.Controls.Add(this.tbSlider); + this.panel6.Location = new System.Drawing.Point(3, 3); + this.panel6.Name = "panel6"; + this.tableLayoutPanel1.SetRowSpan(this.panel6, 4); + this.panel6.Size = new System.Drawing.Size(579, 288); + this.panel6.TabIndex = 5; + // + // rbPtDeadzone + // + this.rbPtDeadzone.AutoSize = true; + this.rbPtDeadzone.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.rbPtDeadzone.Location = new System.Drawing.Point(14, 72); + this.rbPtDeadzone.Name = "rbPtDeadzone"; + this.rbPtDeadzone.Size = new System.Drawing.Size(81, 19); + this.rbPtDeadzone.TabIndex = 54; + this.rbPtDeadzone.Text = "Deadzone"; + this.rbPtDeadzone.UseVisualStyleBackColor = true; + this.rbPtDeadzone.CheckedChanged += new System.EventHandler(this.rbPtAny_CheckedChanged); + // + // lblGraphSaturation + // + this.lblGraphSaturation.AutoSize = true; + this.lblGraphSaturation.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblGraphSaturation.Location = new System.Drawing.Point(531, 266); + this.lblGraphSaturation.Name = "lblGraphSaturation"; + this.lblGraphSaturation.Size = new System.Drawing.Size(34, 15); + this.lblGraphSaturation.TabIndex = 53; + this.lblGraphSaturation.Text = "0.000"; + // + // lblGraphDeadzone + // + this.lblGraphDeadzone.AutoSize = true; + this.lblGraphDeadzone.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblGraphDeadzone.Location = new System.Drawing.Point(252, 266); + this.lblGraphDeadzone.Name = "lblGraphDeadzone"; + this.lblGraphDeadzone.Size = new System.Drawing.Size(34, 15); + this.lblGraphDeadzone.TabIndex = 52; + this.lblGraphDeadzone.Text = "0.000"; + // + // lblNodetext + // + this.lblNodetext.AutoSize = true; + this.lblNodetext.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblNodetext.Location = new System.Drawing.Point(11, 3); + this.lblNodetext.Name = "lblNodetext"; + this.lblNodetext.Size = new System.Drawing.Size(16, 13); + this.lblNodetext.TabIndex = 51; + this.lblNodetext.Text = "..."; + // + // label12 + // + this.label12.AutoSize = true; + this.label12.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label12.Location = new System.Drawing.Point(213, 233); + this.label12.Name = "label12"; + this.label12.Size = new System.Drawing.Size(16, 45); + this.label12.TabIndex = 50; + this.label12.Text = "O\r\nF\r\nF\r\n"; + // + // cbRuse + // + this.cbRuse.AutoSize = true; + this.cbRuse.Location = new System.Drawing.Point(192, 267); + this.cbRuse.Name = "cbRuse"; + this.cbRuse.Size = new System.Drawing.Size(15, 14); + this.cbRuse.TabIndex = 49; + this.cbRuse.UseVisualStyleBackColor = true; + // + // cbPuse + // + this.cbPuse.AutoSize = true; + this.cbPuse.Location = new System.Drawing.Point(192, 248); + this.cbPuse.Name = "cbPuse"; + this.cbPuse.Size = new System.Drawing.Size(15, 14); + this.cbPuse.TabIndex = 48; + this.cbPuse.UseVisualStyleBackColor = true; + // + // cbYuse + // + this.cbYuse.AutoSize = true; + this.cbYuse.Location = new System.Drawing.Point(192, 228); + this.cbYuse.Name = "cbYuse"; + this.cbYuse.Size = new System.Drawing.Size(15, 14); + this.cbYuse.TabIndex = 47; + this.cbYuse.UseVisualStyleBackColor = true; + // + // label11 + // + this.label11.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.label11.Location = new System.Drawing.Point(5, 216); + this.label11.Name = "label11"; + this.label11.Size = new System.Drawing.Size(246, 3); + this.label11.TabIndex = 46; + this.label11.Text = " sd"; + // + // label10 + // + this.label10.AutoSize = true; + this.label10.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label10.Location = new System.Drawing.Point(15, 225); + this.label10.Name = "label10"; + this.label10.Size = new System.Drawing.Size(13, 60); + this.label10.TabIndex = 45; + this.label10.Text = "L\r\ni\r\nv\r\ne"; + // + // lblROutput + // + this.lblROutput.AutoSize = true; + this.lblROutput.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblROutput.Location = new System.Drawing.Point(142, 266); + this.lblROutput.Name = "lblROutput"; + this.lblROutput.Size = new System.Drawing.Size(34, 15); + this.lblROutput.TabIndex = 44; + this.lblROutput.Text = "0.000"; + // + // lblRInput + // + this.lblRInput.AutoSize = true; + this.lblRInput.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblRInput.Location = new System.Drawing.Point(89, 266); + this.lblRInput.Name = "lblRInput"; + this.lblRInput.Size = new System.Drawing.Size(34, 15); + this.lblRInput.TabIndex = 43; + this.lblRInput.Text = "0.000"; + // + // lblPOutput + // + this.lblPOutput.AutoSize = true; + this.lblPOutput.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblPOutput.Location = new System.Drawing.Point(142, 247); + this.lblPOutput.Name = "lblPOutput"; + this.lblPOutput.Size = new System.Drawing.Size(34, 15); + this.lblPOutput.TabIndex = 42; + this.lblPOutput.Text = "0.000"; + // + // lblPInput + // + this.lblPInput.AutoSize = true; + this.lblPInput.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblPInput.Location = new System.Drawing.Point(89, 247); + this.lblPInput.Name = "lblPInput"; + this.lblPInput.Size = new System.Drawing.Size(34, 15); + this.lblPInput.TabIndex = 41; + this.lblPInput.Text = "0.000"; + // + // lblLiveRoll + // + this.lblLiveRoll.AutoSize = true; + this.lblLiveRoll.BackColor = System.Drawing.Color.LightGreen; + this.lblLiveRoll.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblLiveRoll.Location = new System.Drawing.Point(32, 266); + this.lblLiveRoll.Name = "lblLiveRoll"; + this.lblLiveRoll.Size = new System.Drawing.Size(46, 15); + this.lblLiveRoll.TabIndex = 40; + this.lblLiveRoll.Text = "R-Axis:"; + // + // lblLivePitch + // + this.lblLivePitch.AutoSize = true; + this.lblLivePitch.BackColor = System.Drawing.Color.Salmon; + this.lblLivePitch.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblLivePitch.Location = new System.Drawing.Point(32, 247); + this.lblLivePitch.Name = "lblLivePitch"; + this.lblLivePitch.Size = new System.Drawing.Size(45, 15); + this.lblLivePitch.TabIndex = 39; + this.lblLivePitch.Text = "P-Axis:"; + // + // btCopyToAllAxis + // + this.btCopyToAllAxis.Location = new System.Drawing.Point(192, 159); + this.btCopyToAllAxis.Name = "btCopyToAllAxis"; + this.btCopyToAllAxis.Size = new System.Drawing.Size(57, 44); + this.btCopyToAllAxis.TabIndex = 38; + this.btCopyToAllAxis.Text = "Copy to all axis"; + this.btCopyToAllAxis.UseVisualStyleBackColor = true; + this.btCopyToAllAxis.Click += new System.EventHandler(this.btCopyToAllAxis_Click); + // + // lblLiveYaw + // + this.lblLiveYaw.AutoSize = true; + this.lblLiveYaw.BackColor = System.Drawing.Color.PowderBlue; + this.lblLiveYaw.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblLiveYaw.Location = new System.Drawing.Point(32, 228); + this.lblLiveYaw.Name = "lblLiveYaw"; + this.lblLiveYaw.Size = new System.Drawing.Size(45, 15); + this.lblLiveYaw.TabIndex = 37; + this.lblLiveYaw.Text = "Y-Axis:"; + // + // label4 + // + this.label4.AutoSize = true; + this.label4.Location = new System.Drawing.Point(310, 272); + this.label4.Name = "label4"; + this.label4.Size = new System.Drawing.Size(193, 13); + this.label4.TabIndex = 36; + this.label4.Text = "Select an option then click and drag"; + // + // lblYOutput + // + this.lblYOutput.AutoSize = true; + this.lblYOutput.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblYOutput.Location = new System.Drawing.Point(142, 228); + this.lblYOutput.Name = "lblYOutput"; + this.lblYOutput.Size = new System.Drawing.Size(34, 15); + this.lblYOutput.TabIndex = 35; + this.lblYOutput.Text = "0.000"; + // + // lblYInput + // + this.lblYInput.AutoSize = true; + this.lblYInput.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblYInput.Location = new System.Drawing.Point(89, 228); + this.lblYInput.Name = "lblYInput"; + this.lblYInput.Size = new System.Drawing.Size(34, 15); + this.lblYInput.TabIndex = 34; + this.lblYInput.Text = "0.000"; + // + // rbPtExponent + // + this.rbPtExponent.AutoSize = true; + this.rbPtExponent.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.rbPtExponent.Location = new System.Drawing.Point(14, 108); + this.rbPtExponent.Name = "rbPtExponent"; + this.rbPtExponent.Size = new System.Drawing.Size(81, 19); + this.rbPtExponent.TabIndex = 33; + this.rbPtExponent.Text = "Exponent:"; + this.rbPtExponent.UseVisualStyleBackColor = true; + this.rbPtExponent.CheckedChanged += new System.EventHandler(this.rbPtAny_CheckedChanged); + // + // rbPtSaturation + // + this.rbPtSaturation.AutoSize = true; + this.rbPtSaturation.Checked = true; + this.rbPtSaturation.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.rbPtSaturation.Location = new System.Drawing.Point(101, 72); + this.rbPtSaturation.Name = "rbPtSaturation"; + this.rbPtSaturation.Size = new System.Drawing.Size(83, 19); + this.rbPtSaturation.TabIndex = 32; + this.rbPtSaturation.TabStop = true; + this.rbPtSaturation.Text = "Saturation"; + this.rbPtSaturation.UseVisualStyleBackColor = true; + this.rbPtSaturation.CheckedChanged += new System.EventHandler(this.rbPtAny_CheckedChanged); + // + // rbPt3 + // + this.rbPt3.AutoSize = true; + this.rbPt3.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.rbPt3.Location = new System.Drawing.Point(14, 194); + this.rbPt3.Name = "rbPt3"; + this.rbPt3.Size = new System.Drawing.Size(67, 19); + this.rbPt3.TabIndex = 31; + this.rbPt3.Text = "Point 3:"; + this.rbPt3.UseVisualStyleBackColor = true; + this.rbPt3.CheckedChanged += new System.EventHandler(this.rbPtAny_CheckedChanged); + // + // rbPt2 + // + this.rbPt2.AutoSize = true; + this.rbPt2.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.rbPt2.Location = new System.Drawing.Point(14, 171); + this.rbPt2.Name = "rbPt2"; + this.rbPt2.Size = new System.Drawing.Size(67, 19); + this.rbPt2.TabIndex = 30; + this.rbPt2.Text = "Point 2:"; + this.rbPt2.UseVisualStyleBackColor = true; + this.rbPt2.CheckedChanged += new System.EventHandler(this.rbPtAny_CheckedChanged); + // + // rbPt1 + // + this.rbPt1.AutoSize = true; + this.rbPt1.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.rbPt1.Location = new System.Drawing.Point(14, 148); + this.rbPt1.Name = "rbPt1"; + this.rbPt1.Size = new System.Drawing.Size(67, 19); + this.rbPt1.TabIndex = 29; + this.rbPt1.Text = "Point 1:"; + this.rbPt1.UseVisualStyleBackColor = true; + this.rbPt1.CheckedChanged += new System.EventHandler(this.rbPtAny_CheckedChanged); + // + // label33 + // + this.label33.AutoSize = true; + this.label33.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label33.Location = new System.Drawing.Point(135, 130); + this.label33.Name = "label33"; + this.label33.Size = new System.Drawing.Size(46, 15); + this.label33.TabIndex = 28; + this.label33.Text = "OUT(y)"; + // + // label32 + // + this.label32.AutoSize = true; + this.label32.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label32.Location = new System.Drawing.Point(89, 130); + this.label32.Name = "label32"; + this.label32.Size = new System.Drawing.Size(35, 15); + this.label32.TabIndex = 27; + this.label32.Text = "IN(x)"; + // + // lblOut3 + // + this.lblOut3.AutoSize = true; + this.lblOut3.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblOut3.Location = new System.Drawing.Point(142, 196); + this.lblOut3.Name = "lblOut3"; + this.lblOut3.Size = new System.Drawing.Size(28, 15); + this.lblOut3.TabIndex = 23; + this.lblOut3.Text = "0.75"; + // + // lblIn3 + // + this.lblIn3.AutoSize = true; + this.lblIn3.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblIn3.Location = new System.Drawing.Point(89, 196); + this.lblIn3.Name = "lblIn3"; + this.lblIn3.Size = new System.Drawing.Size(28, 15); + this.lblIn3.TabIndex = 22; + this.lblIn3.Text = "0.75"; + // + // lblOut2 + // + this.lblOut2.AutoSize = true; + this.lblOut2.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblOut2.Location = new System.Drawing.Point(142, 173); + this.lblOut2.Name = "lblOut2"; + this.lblOut2.Size = new System.Drawing.Size(22, 15); + this.lblOut2.TabIndex = 21; + this.lblOut2.Text = "0.5"; + // + // lblIn2 + // + this.lblIn2.AutoSize = true; + this.lblIn2.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblIn2.Location = new System.Drawing.Point(89, 173); + this.lblIn2.Name = "lblIn2"; + this.lblIn2.Size = new System.Drawing.Size(22, 15); + this.lblIn2.TabIndex = 20; + this.lblIn2.Text = "0.5"; + // + // lblOut1 + // + this.lblOut1.AutoSize = true; + this.lblOut1.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblOut1.Location = new System.Drawing.Point(142, 150); + this.lblOut1.Name = "lblOut1"; + this.lblOut1.Size = new System.Drawing.Size(28, 15); + this.lblOut1.TabIndex = 19; + this.lblOut1.Text = "0.25"; + // + // lblIn1 + // + this.lblIn1.AutoSize = true; + this.lblIn1.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblIn1.Location = new System.Drawing.Point(89, 150); + this.lblIn1.Name = "lblIn1"; + this.lblIn1.Size = new System.Drawing.Size(28, 15); + this.lblIn1.TabIndex = 18; + this.lblIn1.Text = "0.25"; + // + // chart1 + // + chartArea1.AxisX.Crossing = -1.7976931348623157E+308D; + chartArea1.AxisX.IsMarginVisible = false; + chartArea1.AxisX.LabelStyle.Enabled = false; + chartArea1.AxisX.MajorGrid.Interval = 0.2D; + chartArea1.AxisX.MajorGrid.IntervalType = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number; + chartArea1.AxisX.MajorTickMark.Interval = 0.2D; + chartArea1.AxisX.MajorTickMark.IntervalType = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number; + chartArea1.AxisX.Maximum = 1D; + chartArea1.AxisX.Minimum = 0D; + chartArea1.AxisX.MinorGrid.Interval = 0.1D; + chartArea1.AxisX.MinorGrid.IntervalType = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number; + chartArea1.AxisX.MinorTickMark.Interval = 0.1D; + chartArea1.AxisX.MinorTickMark.IntervalOffsetType = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number; + chartArea1.AxisY.Crossing = -1.7976931348623157E+308D; + chartArea1.AxisY.Interval = 5D; + chartArea1.AxisY.IsMarginVisible = false; + chartArea1.AxisY.LabelStyle.Enabled = false; + chartArea1.AxisY.MajorGrid.Interval = 0.2D; + chartArea1.AxisY.MajorGrid.IntervalType = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number; + chartArea1.AxisY.MajorTickMark.Interval = 0.2D; + chartArea1.AxisY.MajorTickMark.IntervalType = System.Windows.Forms.DataVisualization.Charting.DateTimeIntervalType.Number; + chartArea1.AxisY.Maximum = 1D; + chartArea1.AxisY.Minimum = 0D; + chartArea1.Name = "ChartArea1"; + this.chart1.ChartAreas.Add(chartArea1); + this.chart1.Location = new System.Drawing.Point(258, 7); + this.chart1.Name = "chart1"; + series1.ChartArea = "ChartArea1"; + series1.ChartType = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.Spline; + series1.MarkerColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0))))); + series1.MarkerStyle = System.Windows.Forms.DataVisualization.Charting.MarkerStyle.Circle; + series1.Name = "Series1"; + this.chart1.Series.Add(series1); + this.chart1.Size = new System.Drawing.Size(301, 262); + this.chart1.TabIndex = 16; + this.chart1.Text = "chart1"; + this.chart1.MouseDown += new System.Windows.Forms.MouseEventHandler(this.chartPoint_MouseDown); + this.chart1.MouseMove += new System.Windows.Forms.MouseEventHandler(this.chartPoint_MouseMove); + this.chart1.MouseUp += new System.Windows.Forms.MouseEventHandler(this.chartPoint_MouseUp); + // + // lblOutSlider + // + this.lblOutSlider.AutoSize = true; + this.lblOutSlider.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblOutSlider.Location = new System.Drawing.Point(174, 34); + this.lblOutSlider.Name = "lblOutSlider"; + this.lblOutSlider.Size = new System.Drawing.Size(34, 15); + this.lblOutSlider.TabIndex = 13; + this.lblOutSlider.Text = "0.000"; + // + // lblOutExponent + // + this.lblOutExponent.AutoSize = true; + this.lblOutExponent.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblOutExponent.Location = new System.Drawing.Point(112, 110); + this.lblOutExponent.Name = "lblOutExponent"; + this.lblOutExponent.Size = new System.Drawing.Size(34, 15); + this.lblOutExponent.TabIndex = 9; + this.lblOutExponent.Text = "0.000"; + // + // tbSlider + // + this.tbSlider.Location = new System.Drawing.Point(3, 21); + this.tbSlider.Maximum = 40; + this.tbSlider.Name = "tbSlider"; + this.tbSlider.Size = new System.Drawing.Size(165, 45); + this.tbSlider.TabIndex = 0; + this.tbSlider.TickFrequency = 5; + this.tbSlider.TickStyle = System.Windows.Forms.TickStyle.Both; + this.tbSlider.ValueChanged += new System.EventHandler(this.tbSlider_ValueChanged); + // + // flowLayoutPanel1 + // + this.flowLayoutPanel1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Right))); - this.flowLayoutPanel1.Controls.Add(this.rb300); - this.flowLayoutPanel1.Controls.Add(this.rbHornet); - this.flowLayoutPanel1.Controls.Add(this.rbAurora); - this.flowLayoutPanel1.Location = new System.Drawing.Point(624, 123); - this.flowLayoutPanel1.Name = "flowLayoutPanel1"; - this.flowLayoutPanel1.Size = new System.Drawing.Size(401, 91); - this.flowLayoutPanel1.TabIndex = 3; - // - // rb300 - // - this.rb300.AutoSize = true; - this.rb300.Checked = true; - this.rb300.Image = global::SCJMapper_V2.Properties.Resources._300i1; - this.rb300.Location = new System.Drawing.Point(3, 3); - this.rb300.Name = "rb300"; - this.rb300.Size = new System.Drawing.Size(114, 48); - this.rb300.TabIndex = 2; - this.rb300.TabStop = true; - this.rb300.UseVisualStyleBackColor = true; - this.rb300.CheckedChanged += new System.EventHandler(this.rb300i_CheckedChanged); - // - // rbHornet - // - this.rbHornet.AutoSize = true; - this.rbHornet.Image = global::SCJMapper_V2.Properties.Resources.hornet; - this.rbHornet.Location = new System.Drawing.Point(123, 3); - this.rbHornet.Name = "rbHornet"; - this.rbHornet.Size = new System.Drawing.Size(114, 50); - this.rbHornet.TabIndex = 0; - this.rbHornet.UseVisualStyleBackColor = true; - this.rbHornet.CheckedChanged += new System.EventHandler(this.rbHornet_CheckedChanged); - // - // rbAurora - // - this.rbAurora.AutoSize = true; - this.rbAurora.Image = global::SCJMapper_V2.Properties.Resources.aurora; - this.rbAurora.Location = new System.Drawing.Point(243, 3); - this.rbAurora.Name = "rbAurora"; - this.rbAurora.Size = new System.Drawing.Size(114, 50); - this.rbAurora.TabIndex = 1; - this.rbAurora.UseVisualStyleBackColor = true; - this.rbAurora.CheckedChanged += new System.EventHandler(this.rbAurora_CheckedChanged); - // - // tableLayoutPanel3 - // - this.tableLayoutPanel3.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); - this.tableLayoutPanel3.ColumnCount = 2; - this.tableLayoutPanel3.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 68.66029F)); - this.tableLayoutPanel3.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 31.33971F)); - this.tableLayoutPanel3.Controls.Add(this.btDone, 1, 0); - this.tableLayoutPanel3.Controls.Add(this.panel8, 0, 0); - this.tableLayoutPanel3.Location = new System.Drawing.Point(607, 220); - this.tableLayoutPanel3.Name = "tableLayoutPanel3"; - this.tableLayoutPanel3.RowCount = 1; - this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F)); - this.tableLayoutPanel3.Size = new System.Drawing.Size(418, 71); - this.tableLayoutPanel3.TabIndex = 6; - // - // btDone - // - this.btDone.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + this.flowLayoutPanel1.Controls.Add(this.rb300); + this.flowLayoutPanel1.Controls.Add(this.rbHornet); + this.flowLayoutPanel1.Controls.Add(this.rbAurora); + this.flowLayoutPanel1.Location = new System.Drawing.Point(624, 123); + this.flowLayoutPanel1.Name = "flowLayoutPanel1"; + this.flowLayoutPanel1.Size = new System.Drawing.Size(401, 55); + this.flowLayoutPanel1.TabIndex = 3; + // + // rb300 + // + this.rb300.AutoSize = true; + this.rb300.Checked = true; + this.rb300.Image = global::SCJMapper_V2.Properties.Resources._300i1; + this.rb300.Location = new System.Drawing.Point(3, 3); + this.rb300.Name = "rb300"; + this.rb300.Size = new System.Drawing.Size(114, 48); + this.rb300.TabIndex = 2; + this.rb300.TabStop = true; + this.rb300.UseVisualStyleBackColor = true; + this.rb300.CheckedChanged += new System.EventHandler(this.rb300i_CheckedChanged); + // + // rbHornet + // + this.rbHornet.AutoSize = true; + this.rbHornet.Image = global::SCJMapper_V2.Properties.Resources.hornet; + this.rbHornet.Location = new System.Drawing.Point(123, 3); + this.rbHornet.Name = "rbHornet"; + this.rbHornet.Size = new System.Drawing.Size(114, 50); + this.rbHornet.TabIndex = 0; + this.rbHornet.UseVisualStyleBackColor = true; + this.rbHornet.CheckedChanged += new System.EventHandler(this.rbHornet_CheckedChanged); + // + // rbAurora + // + this.rbAurora.AutoSize = true; + this.rbAurora.Image = global::SCJMapper_V2.Properties.Resources.aurora; + this.rbAurora.Location = new System.Drawing.Point(243, 3); + this.rbAurora.Name = "rbAurora"; + this.rbAurora.Size = new System.Drawing.Size(114, 50); + this.rbAurora.TabIndex = 1; + this.rbAurora.UseVisualStyleBackColor = true; + this.rbAurora.CheckedChanged += new System.EventHandler(this.rbAurora_CheckedChanged); + // + // tableLayoutPanel3 + // + this.tableLayoutPanel3.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.tableLayoutPanel3.ColumnCount = 2; + this.tableLayoutPanel3.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 68.66029F)); + this.tableLayoutPanel3.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 31.33971F)); + this.tableLayoutPanel3.Controls.Add(this.btDone, 1, 0); + this.tableLayoutPanel3.Controls.Add(this.panel8, 0, 0); + this.tableLayoutPanel3.Location = new System.Drawing.Point(607, 184); + this.tableLayoutPanel3.Name = "tableLayoutPanel3"; + this.tableLayoutPanel3.RowCount = 1; + this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F)); + this.tableLayoutPanel3.Size = new System.Drawing.Size(418, 107); + this.tableLayoutPanel3.TabIndex = 6; + // + // btDone + // + this.btDone.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); - this.btDone.DialogResult = System.Windows.Forms.DialogResult.OK; - this.btDone.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.btDone.Location = new System.Drawing.Point(290, 3); - this.btDone.Name = "btDone"; - this.btDone.Size = new System.Drawing.Size(125, 65); - this.btDone.TabIndex = 28; - this.btDone.Text = "Done"; - this.btDone.UseVisualStyleBackColor = true; - this.btDone.Click += new System.EventHandler(this.btDone_Click); - // - // panel8 - // - this.panel8.Controls.Add(this.rbSunset); - this.panel8.Controls.Add(this.rbOutThere3); - this.panel8.Controls.Add(this.rbSkybox); - this.panel8.Controls.Add(this.rbOutThere1); - this.panel8.Controls.Add(this.rbBigSight); - this.panel8.Controls.Add(this.rbHighway); - this.panel8.Controls.Add(this.rbHelipad); - this.panel8.Controls.Add(this.rbShiodome); - this.panel8.Controls.Add(this.rbCanyon); - this.panel8.Dock = System.Windows.Forms.DockStyle.Fill; - this.panel8.Location = new System.Drawing.Point(3, 3); - this.panel8.Name = "panel8"; - this.panel8.Size = new System.Drawing.Size(281, 65); - this.panel8.TabIndex = 4; - // - // rbSunset - // - this.rbSunset.AutoSize = true; - this.rbSunset.Location = new System.Drawing.Point(205, 35); - this.rbSunset.Name = "rbSunset"; - this.rbSunset.Size = new System.Drawing.Size(60, 17); - this.rbSunset.TabIndex = 7; - this.rbSunset.Text = "Sunset"; - this.rbSunset.UseVisualStyleBackColor = true; - this.rbSunset.CheckedChanged += new System.EventHandler(this.rbSunset_CheckedChanged); - // - // rbOutThere3 - // - this.rbOutThere3.AutoSize = true; - this.rbOutThere3.Location = new System.Drawing.Point(32, 18); - this.rbOutThere3.Name = "rbOutThere3"; - this.rbOutThere3.Size = new System.Drawing.Size(84, 17); - this.rbOutThere3.TabIndex = 6; - this.rbOutThere3.Text = "Out there 3"; - this.rbOutThere3.UseVisualStyleBackColor = true; - this.rbOutThere3.CheckedChanged += new System.EventHandler(this.rbOutThere3_CheckedChanged); - // - // rbSkybox - // - this.rbSkybox.AutoSize = true; - this.rbSkybox.Location = new System.Drawing.Point(32, 35); - this.rbSkybox.Name = "rbSkybox"; - this.rbSkybox.Size = new System.Drawing.Size(83, 17); - this.rbSkybox.TabIndex = 5; - this.rbSkybox.Text = "Skybox.dds"; - this.rbSkybox.UseVisualStyleBackColor = true; - this.rbSkybox.CheckedChanged += new System.EventHandler(this.rbSkybox_CheckedChanged); - // - // rbOutThere1 - // - this.rbOutThere1.AutoSize = true; - this.rbOutThere1.Checked = true; - this.rbOutThere1.Location = new System.Drawing.Point(32, 1); - this.rbOutThere1.Name = "rbOutThere1"; - this.rbOutThere1.Size = new System.Drawing.Size(84, 17); - this.rbOutThere1.TabIndex = 4; - this.rbOutThere1.TabStop = true; - this.rbOutThere1.Text = "Out there 1"; - this.rbOutThere1.UseVisualStyleBackColor = true; - this.rbOutThere1.CheckedChanged += new System.EventHandler(this.rbOutThere1_CheckedChanged); - // - // rbBigSight - // - this.rbBigSight.AutoSize = true; - this.rbBigSight.Location = new System.Drawing.Point(205, 18); - this.rbBigSight.Name = "rbBigSight"; - this.rbBigSight.Size = new System.Drawing.Size(72, 17); - this.rbBigSight.TabIndex = 3; - this.rbBigSight.Text = "Big Sight"; - this.rbBigSight.UseVisualStyleBackColor = true; - this.rbBigSight.CheckedChanged += new System.EventHandler(this.rbBigSight_CheckedChanged); - // - // rbHighway - // - this.rbHighway.AutoSize = true; - this.rbHighway.Location = new System.Drawing.Point(205, 1); - this.rbHighway.Name = "rbHighway"; - this.rbHighway.Size = new System.Drawing.Size(70, 17); - this.rbHighway.TabIndex = 2; - this.rbHighway.Text = "Highway"; - this.rbHighway.UseVisualStyleBackColor = true; - this.rbHighway.CheckedChanged += new System.EventHandler(this.rbHighway_CheckedChanged); - // - // rbHelipad - // - this.rbHelipad.AutoSize = true; - this.rbHelipad.Location = new System.Drawing.Point(122, 35); - this.rbHelipad.Name = "rbHelipad"; - this.rbHelipad.Size = new System.Drawing.Size(80, 17); - this.rbHelipad.TabIndex = 1; - this.rbHelipad.Text = "LA Helipad"; - this.rbHelipad.UseVisualStyleBackColor = true; - this.rbHelipad.CheckedChanged += new System.EventHandler(this.rbHelipad_CheckedChanged); - // - // rbShiodome - // - this.rbShiodome.AutoSize = true; - this.rbShiodome.Location = new System.Drawing.Point(122, 18); - this.rbShiodome.Name = "rbShiodome"; - this.rbShiodome.Size = new System.Drawing.Size(77, 17); - this.rbShiodome.TabIndex = 1; - this.rbShiodome.Text = "Shiodome"; - this.rbShiodome.UseVisualStyleBackColor = true; - this.rbShiodome.CheckedChanged += new System.EventHandler(this.rbShiodome_CheckedChanged); - // - // rbCanyon - // - this.rbCanyon.AutoSize = true; - this.rbCanyon.Location = new System.Drawing.Point(122, 1); - this.rbCanyon.Name = "rbCanyon"; - this.rbCanyon.Size = new System.Drawing.Size(64, 17); - this.rbCanyon.TabIndex = 0; - this.rbCanyon.Text = "Canyon"; - this.rbCanyon.UseVisualStyleBackColor = true; - this.rbCanyon.CheckedChanged += new System.EventHandler(this.rbCanyon_CheckedChanged); - // - // flowLayoutPanel2 - // - this.flowLayoutPanel2.Controls.Add(this.pnlAxisSelector); - this.flowLayoutPanel2.Controls.Add(this.panel10); - this.flowLayoutPanel2.Dock = System.Windows.Forms.DockStyle.Fill; - this.flowLayoutPanel2.FlowDirection = System.Windows.Forms.FlowDirection.TopDown; - this.flowLayoutPanel2.Location = new System.Drawing.Point(3, 619); - this.flowLayoutPanel2.Name = "flowLayoutPanel2"; - this.flowLayoutPanel2.Size = new System.Drawing.Size(144, 294); - this.flowLayoutPanel2.TabIndex = 3; - // - // pnlAxisSelector - // - this.pnlAxisSelector.BackColor = System.Drawing.Color.Gold; - this.pnlAxisSelector.Controls.Add(this.rbP); - this.pnlAxisSelector.Controls.Add(this.rbY); - this.pnlAxisSelector.Controls.Add(this.rbR); - this.pnlAxisSelector.Location = new System.Drawing.Point(0, 0); - this.pnlAxisSelector.Margin = new System.Windows.Forms.Padding(0); - this.pnlAxisSelector.Name = "pnlAxisSelector"; - this.pnlAxisSelector.Size = new System.Drawing.Size(144, 157); - this.pnlAxisSelector.TabIndex = 3; - // - // rbP - // - this.rbP.BackColor = System.Drawing.Color.Salmon; - this.rbP.Font = new System.Drawing.Font("Segoe UI", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.rbP.Location = new System.Drawing.Point(14, 58); - this.rbP.Name = "rbP"; - this.rbP.Size = new System.Drawing.Size(111, 42); - this.rbP.TabIndex = 6; - this.rbP.Text = "Pitch -->"; - this.rbP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - this.rbP.UseVisualStyleBackColor = false; - this.rbP.CheckedChanged += new System.EventHandler(this.rbP_CheckedChanged); - // - // rbY - // - this.rbY.BackColor = System.Drawing.Color.PowderBlue; - this.rbY.Checked = true; - this.rbY.Font = new System.Drawing.Font("Segoe UI", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.rbY.Location = new System.Drawing.Point(15, 10); - this.rbY.Name = "rbY"; - this.rbY.Size = new System.Drawing.Size(111, 42); - this.rbY.TabIndex = 5; - this.rbY.TabStop = true; - this.rbY.Text = "Yaw -->"; - this.rbY.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - this.rbY.UseVisualStyleBackColor = false; - this.rbY.CheckedChanged += new System.EventHandler(this.rbY_CheckedChanged); - // - // rbR - // - this.rbR.BackColor = System.Drawing.Color.LightGreen; - this.rbR.Font = new System.Drawing.Font("Segoe UI", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.rbR.Location = new System.Drawing.Point(15, 106); - this.rbR.Name = "rbR"; - this.rbR.Size = new System.Drawing.Size(111, 42); - this.rbR.TabIndex = 7; - this.rbR.Text = "Roll -->"; - this.rbR.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - this.rbR.UseVisualStyleBackColor = false; - this.rbR.CheckedChanged += new System.EventHandler(this.rbR_CheckedChanged); - // - // panel10 - // - this.panel10.Controls.Add(this.rbTuneStrafe); - this.panel10.Controls.Add(this.rbTuneYPR); - this.panel10.Location = new System.Drawing.Point(3, 160); - this.panel10.Name = "panel10"; - this.panel10.Size = new System.Drawing.Size(138, 128); - this.panel10.TabIndex = 4; - // - // rbTuneStrafe - // - this.rbTuneStrafe.BackColor = System.Drawing.Color.SandyBrown; - this.rbTuneStrafe.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.rbTuneStrafe.Location = new System.Drawing.Point(12, 68); - this.rbTuneStrafe.Name = "rbTuneStrafe"; - this.rbTuneStrafe.Size = new System.Drawing.Size(111, 42); - this.rbTuneStrafe.TabIndex = 0; - this.rbTuneStrafe.Text = "Tune Strafe"; - this.rbTuneStrafe.UseVisualStyleBackColor = false; - this.rbTuneStrafe.CheckedChanged += new System.EventHandler(this.rbTuneStrafe_CheckedChanged); - // - // rbTuneYPR - // - this.rbTuneYPR.BackColor = System.Drawing.Color.Gold; - this.rbTuneYPR.Checked = true; - this.rbTuneYPR.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.rbTuneYPR.Location = new System.Drawing.Point(12, 20); - this.rbTuneYPR.Name = "rbTuneYPR"; - this.rbTuneYPR.Size = new System.Drawing.Size(111, 42); - this.rbTuneYPR.TabIndex = 0; - this.rbTuneYPR.TabStop = true; - this.rbTuneYPR.Text = "Tune YPR"; - this.rbTuneYPR.UseVisualStyleBackColor = false; - this.rbTuneYPR.CheckedChanged += new System.EventHandler(this.rbTuneYPR_CheckedChanged); - // - // FormJSCalCurve - // - this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F); - this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Dpi; - this.ClientSize = new System.Drawing.Size(1184, 916); - this.Controls.Add(this.tlp); - this.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.SizableToolWindow; - this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); - this.MinimumSize = new System.Drawing.Size(1200, 950); - this.Name = "FormJSCalCurve"; - this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; - this.Text = "Joystick Tuning"; - this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.FormJSCalCurve_FormClosing); - this.Load += new System.EventHandler(this.FormJSCalCurve_Load); - this.tlp.ResumeLayout(false); - this.tlpData.ResumeLayout(false); - this.pnlYaw.ResumeLayout(false); - this.pnlYaw.PerformLayout(); - this.pnlPitch.ResumeLayout(false); - this.pnlPitch.PerformLayout(); - this.pnlRoll.ResumeLayout(false); - this.pnlRoll.PerformLayout(); - this.tableLayoutPanel1.ResumeLayout(false); - this.panel9.ResumeLayout(false); - this.panel9.PerformLayout(); - ((System.ComponentModel.ISupportInitialize)(this.slDamping)).EndInit(); - this.panel1.ResumeLayout(false); - this.panel1.PerformLayout(); - ((System.ComponentModel.ISupportInitialize)(this.slTurnSpeed)).EndInit(); - this.panel6.ResumeLayout(false); - this.panel6.PerformLayout(); - ((System.ComponentModel.ISupportInitialize)(this.chart1)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.tbSlider)).EndInit(); - this.flowLayoutPanel1.ResumeLayout(false); - this.flowLayoutPanel1.PerformLayout(); - this.tableLayoutPanel3.ResumeLayout(false); - this.panel8.ResumeLayout(false); - this.panel8.PerformLayout(); - this.flowLayoutPanel2.ResumeLayout(false); - this.pnlAxisSelector.ResumeLayout(false); - this.panel10.ResumeLayout(false); - this.ResumeLayout(false); + this.btDone.DialogResult = System.Windows.Forms.DialogResult.OK; + this.btDone.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btDone.Location = new System.Drawing.Point(290, 3); + this.btDone.Name = "btDone"; + this.btDone.Size = new System.Drawing.Size(125, 101); + this.btDone.TabIndex = 28; + this.btDone.Text = "Done"; + this.btDone.UseVisualStyleBackColor = true; + this.btDone.Click += new System.EventHandler(this.btDone_Click); + // + // panel8 + // + this.panel8.Controls.Add(this.rbArea18); + this.panel8.Controls.Add(this.rbDemien); + this.panel8.Controls.Add(this.rbBrokenMoon); + this.panel8.Controls.Add(this.rbDyingStar); + this.panel8.Controls.Add(this.rbSunset); + this.panel8.Controls.Add(this.rbOutThere3); + this.panel8.Controls.Add(this.rbSkybox); + this.panel8.Controls.Add(this.rbOutThere1); + this.panel8.Controls.Add(this.rbBigSight); + this.panel8.Controls.Add(this.rbHighway); + this.panel8.Controls.Add(this.rbHelipad); + this.panel8.Controls.Add(this.rbShiodome); + this.panel8.Controls.Add(this.rbCanyon); + this.panel8.Dock = System.Windows.Forms.DockStyle.Fill; + this.panel8.Location = new System.Drawing.Point(3, 3); + this.panel8.Name = "panel8"; + this.panel8.Size = new System.Drawing.Size(281, 101); + this.panel8.TabIndex = 4; + // + // rbArea18 + // + this.rbArea18.AutoSize = true; + this.rbArea18.Location = new System.Drawing.Point(27, 20); + this.rbArea18.Name = "rbArea18"; + this.rbArea18.Size = new System.Drawing.Size(63, 17); + this.rbArea18.TabIndex = 12; + this.rbArea18.Text = "Area 18"; + this.rbArea18.UseVisualStyleBackColor = true; + this.rbArea18.CheckedChanged += new System.EventHandler(this.rbArea18_CheckedChanged); + // + // rbDemien + // + this.rbDemien.AutoSize = true; + this.rbDemien.Location = new System.Drawing.Point(200, 20); + this.rbDemien.Name = "rbDemien"; + this.rbDemien.Size = new System.Drawing.Size(64, 17); + this.rbDemien.TabIndex = 11; + this.rbDemien.Text = "Demien"; + this.rbDemien.UseVisualStyleBackColor = true; + this.rbDemien.CheckedChanged += new System.EventHandler(this.rbKareah_CheckedChanged); + // + // rbBrokenMoon + // + this.rbBrokenMoon.AutoSize = true; + this.rbBrokenMoon.Checked = true; + this.rbBrokenMoon.Location = new System.Drawing.Point(27, 3); + this.rbBrokenMoon.Name = "rbBrokenMoon"; + this.rbBrokenMoon.Size = new System.Drawing.Size(96, 17); + this.rbBrokenMoon.TabIndex = 9; + this.rbBrokenMoon.TabStop = true; + this.rbBrokenMoon.Text = "Broken Moon"; + this.rbBrokenMoon.UseVisualStyleBackColor = true; + this.rbBrokenMoon.CheckedChanged += new System.EventHandler(this.rbBrokenMoon_CheckedChanged); + // + // rbDyingStar + // + this.rbDyingStar.AutoSize = true; + this.rbDyingStar.Location = new System.Drawing.Point(200, 3); + this.rbDyingStar.Name = "rbDyingStar"; + this.rbDyingStar.Size = new System.Drawing.Size(78, 17); + this.rbDyingStar.TabIndex = 8; + this.rbDyingStar.Text = "Dying Star"; + this.rbDyingStar.UseVisualStyleBackColor = true; + this.rbDyingStar.CheckedChanged += new System.EventHandler(this.rbDyingStar_CheckedChanged); + // + // rbSunset + // + this.rbSunset.AutoSize = true; + this.rbSunset.Location = new System.Drawing.Point(27, 71); + this.rbSunset.Name = "rbSunset"; + this.rbSunset.Size = new System.Drawing.Size(60, 17); + this.rbSunset.TabIndex = 7; + this.rbSunset.Text = "Sunset"; + this.rbSunset.UseVisualStyleBackColor = true; + this.rbSunset.CheckedChanged += new System.EventHandler(this.rbSunset_CheckedChanged); + // + // rbOutThere3 + // + this.rbOutThere3.AutoSize = true; + this.rbOutThere3.Location = new System.Drawing.Point(27, 54); + this.rbOutThere3.Name = "rbOutThere3"; + this.rbOutThere3.Size = new System.Drawing.Size(84, 17); + this.rbOutThere3.TabIndex = 6; + this.rbOutThere3.Text = "Out there 3"; + this.rbOutThere3.UseVisualStyleBackColor = true; + this.rbOutThere3.CheckedChanged += new System.EventHandler(this.rbOutThere3_CheckedChanged); + // + // rbSkybox + // + this.rbSkybox.AutoSize = true; + this.rbSkybox.Location = new System.Drawing.Point(200, 71); + this.rbSkybox.Name = "rbSkybox"; + this.rbSkybox.Size = new System.Drawing.Size(83, 17); + this.rbSkybox.TabIndex = 5; + this.rbSkybox.Text = "Skybox.dds"; + this.rbSkybox.UseVisualStyleBackColor = true; + this.rbSkybox.CheckedChanged += new System.EventHandler(this.rbSkybox_CheckedChanged); + // + // rbOutThere1 + // + this.rbOutThere1.AutoSize = true; + this.rbOutThere1.Location = new System.Drawing.Point(27, 37); + this.rbOutThere1.Name = "rbOutThere1"; + this.rbOutThere1.Size = new System.Drawing.Size(84, 17); + this.rbOutThere1.TabIndex = 4; + this.rbOutThere1.Text = "Out there 1"; + this.rbOutThere1.UseVisualStyleBackColor = true; + this.rbOutThere1.CheckedChanged += new System.EventHandler(this.rbOutThere1_CheckedChanged); + // + // rbBigSight + // + this.rbBigSight.AutoSize = true; + this.rbBigSight.Location = new System.Drawing.Point(200, 54); + this.rbBigSight.Name = "rbBigSight"; + this.rbBigSight.Size = new System.Drawing.Size(72, 17); + this.rbBigSight.TabIndex = 3; + this.rbBigSight.Text = "Big Sight"; + this.rbBigSight.UseVisualStyleBackColor = true; + this.rbBigSight.CheckedChanged += new System.EventHandler(this.rbBigSight_CheckedChanged); + // + // rbHighway + // + this.rbHighway.AutoSize = true; + this.rbHighway.Location = new System.Drawing.Point(200, 37); + this.rbHighway.Name = "rbHighway"; + this.rbHighway.Size = new System.Drawing.Size(70, 17); + this.rbHighway.TabIndex = 2; + this.rbHighway.Text = "Highway"; + this.rbHighway.UseVisualStyleBackColor = true; + this.rbHighway.CheckedChanged += new System.EventHandler(this.rbHighway_CheckedChanged); + // + // rbHelipad + // + this.rbHelipad.AutoSize = true; + this.rbHelipad.Location = new System.Drawing.Point(117, 71); + this.rbHelipad.Name = "rbHelipad"; + this.rbHelipad.Size = new System.Drawing.Size(80, 17); + this.rbHelipad.TabIndex = 1; + this.rbHelipad.Text = "LA Helipad"; + this.rbHelipad.UseVisualStyleBackColor = true; + this.rbHelipad.CheckedChanged += new System.EventHandler(this.rbHelipad_CheckedChanged); + // + // rbShiodome + // + this.rbShiodome.AutoSize = true; + this.rbShiodome.Location = new System.Drawing.Point(117, 54); + this.rbShiodome.Name = "rbShiodome"; + this.rbShiodome.Size = new System.Drawing.Size(77, 17); + this.rbShiodome.TabIndex = 1; + this.rbShiodome.Text = "Shiodome"; + this.rbShiodome.UseVisualStyleBackColor = true; + this.rbShiodome.CheckedChanged += new System.EventHandler(this.rbShiodome_CheckedChanged); + // + // rbCanyon + // + this.rbCanyon.AutoSize = true; + this.rbCanyon.Location = new System.Drawing.Point(117, 37); + this.rbCanyon.Name = "rbCanyon"; + this.rbCanyon.Size = new System.Drawing.Size(64, 17); + this.rbCanyon.TabIndex = 0; + this.rbCanyon.Text = "Canyon"; + this.rbCanyon.UseVisualStyleBackColor = true; + this.rbCanyon.CheckedChanged += new System.EventHandler(this.rbCanyon_CheckedChanged); + // + // flowLayoutPanel2 + // + this.flowLayoutPanel2.Controls.Add(this.pnlAxisSelector); + this.flowLayoutPanel2.Controls.Add(this.panel10); + this.flowLayoutPanel2.Dock = System.Windows.Forms.DockStyle.Fill; + this.flowLayoutPanel2.FlowDirection = System.Windows.Forms.FlowDirection.TopDown; + this.flowLayoutPanel2.Location = new System.Drawing.Point(3, 619); + this.flowLayoutPanel2.Name = "flowLayoutPanel2"; + this.flowLayoutPanel2.Size = new System.Drawing.Size(144, 294); + this.flowLayoutPanel2.TabIndex = 3; + // + // pnlAxisSelector + // + this.pnlAxisSelector.BackColor = System.Drawing.Color.Gold; + this.pnlAxisSelector.Controls.Add(this.rbP); + this.pnlAxisSelector.Controls.Add(this.rbY); + this.pnlAxisSelector.Controls.Add(this.rbR); + this.pnlAxisSelector.Location = new System.Drawing.Point(0, 0); + this.pnlAxisSelector.Margin = new System.Windows.Forms.Padding(0); + this.pnlAxisSelector.Name = "pnlAxisSelector"; + this.pnlAxisSelector.Size = new System.Drawing.Size(144, 157); + this.pnlAxisSelector.TabIndex = 3; + // + // rbP + // + this.rbP.BackColor = System.Drawing.Color.Salmon; + this.rbP.Font = new System.Drawing.Font("Segoe UI", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.rbP.Location = new System.Drawing.Point(14, 58); + this.rbP.Name = "rbP"; + this.rbP.Size = new System.Drawing.Size(111, 42); + this.rbP.TabIndex = 6; + this.rbP.Text = "Pitch -->"; + this.rbP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.rbP.UseVisualStyleBackColor = false; + this.rbP.CheckedChanged += new System.EventHandler(this.rbP_CheckedChanged); + // + // rbY + // + this.rbY.BackColor = System.Drawing.Color.PowderBlue; + this.rbY.Checked = true; + this.rbY.Font = new System.Drawing.Font("Segoe UI", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.rbY.Location = new System.Drawing.Point(15, 10); + this.rbY.Name = "rbY"; + this.rbY.Size = new System.Drawing.Size(111, 42); + this.rbY.TabIndex = 5; + this.rbY.TabStop = true; + this.rbY.Text = "Yaw -->"; + this.rbY.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.rbY.UseVisualStyleBackColor = false; + this.rbY.CheckedChanged += new System.EventHandler(this.rbY_CheckedChanged); + // + // rbR + // + this.rbR.BackColor = System.Drawing.Color.LightGreen; + this.rbR.Font = new System.Drawing.Font("Segoe UI", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.rbR.Location = new System.Drawing.Point(15, 106); + this.rbR.Name = "rbR"; + this.rbR.Size = new System.Drawing.Size(111, 42); + this.rbR.TabIndex = 7; + this.rbR.Text = "Roll -->"; + this.rbR.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.rbR.UseVisualStyleBackColor = false; + this.rbR.CheckedChanged += new System.EventHandler(this.rbR_CheckedChanged); + // + // panel10 + // + this.panel10.Controls.Add(this.rbTuneStrafe); + this.panel10.Controls.Add(this.rbTuneYPR); + this.panel10.Location = new System.Drawing.Point(3, 160); + this.panel10.Name = "panel10"; + this.panel10.Size = new System.Drawing.Size(138, 128); + this.panel10.TabIndex = 4; + // + // rbTuneStrafe + // + this.rbTuneStrafe.BackColor = System.Drawing.Color.SandyBrown; + this.rbTuneStrafe.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.rbTuneStrafe.Location = new System.Drawing.Point(12, 68); + this.rbTuneStrafe.Name = "rbTuneStrafe"; + this.rbTuneStrafe.Size = new System.Drawing.Size(111, 42); + this.rbTuneStrafe.TabIndex = 0; + this.rbTuneStrafe.Text = "Tune Strafe"; + this.rbTuneStrafe.UseVisualStyleBackColor = false; + this.rbTuneStrafe.CheckedChanged += new System.EventHandler(this.rbTuneStrafe_CheckedChanged); + // + // rbTuneYPR + // + this.rbTuneYPR.BackColor = System.Drawing.Color.Gold; + this.rbTuneYPR.Checked = true; + this.rbTuneYPR.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.rbTuneYPR.Location = new System.Drawing.Point(12, 20); + this.rbTuneYPR.Name = "rbTuneYPR"; + this.rbTuneYPR.Size = new System.Drawing.Size(111, 42); + this.rbTuneYPR.TabIndex = 0; + this.rbTuneYPR.TabStop = true; + this.rbTuneYPR.Text = "Tune YPR"; + this.rbTuneYPR.UseVisualStyleBackColor = false; + this.rbTuneYPR.CheckedChanged += new System.EventHandler(this.rbTuneYPR_CheckedChanged); + // + // FormJSCalCurve + // + this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Dpi; + this.ClientSize = new System.Drawing.Size(1184, 916); + this.Controls.Add(this.tlp); + this.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.SizableToolWindow; + this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); + this.MinimumSize = new System.Drawing.Size(1200, 950); + this.Name = "FormJSCalCurve"; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; + this.Text = "Joystick Tuning"; + this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.FormJSCalCurve_FormClosing); + this.Load += new System.EventHandler(this.FormJSCalCurve_Load); + this.tlp.ResumeLayout(false); + this.tlpData.ResumeLayout(false); + this.pnlYaw.ResumeLayout(false); + this.pnlYaw.PerformLayout(); + this.pnlPitch.ResumeLayout(false); + this.pnlPitch.PerformLayout(); + this.pnlRoll.ResumeLayout(false); + this.pnlRoll.PerformLayout(); + this.tableLayoutPanel1.ResumeLayout(false); + this.panel9.ResumeLayout(false); + this.panel9.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.slDamping)).EndInit(); + this.panel1.ResumeLayout(false); + this.panel1.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.slTurnSpeed)).EndInit(); + this.panel6.ResumeLayout(false); + this.panel6.PerformLayout(); + ((System.ComponentModel.ISupportInitialize)(this.chart1)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.tbSlider)).EndInit(); + this.flowLayoutPanel1.ResumeLayout(false); + this.flowLayoutPanel1.PerformLayout(); + this.tableLayoutPanel3.ResumeLayout(false); + this.panel8.ResumeLayout(false); + this.panel8.PerformLayout(); + this.flowLayoutPanel2.ResumeLayout(false); + this.pnlAxisSelector.ResumeLayout(false); + this.panel10.ResumeLayout(false); + this.ResumeLayout(false); } @@ -1990,5 +2042,9 @@ private System.Windows.Forms.Label lblGraphSaturation; private System.Windows.Forms.Label lblGraphDeadzone; private System.Windows.Forms.RadioButton rbPtDeadzone; - } + private System.Windows.Forms.RadioButton rbArea18; + private System.Windows.Forms.RadioButton rbDemien; + private System.Windows.Forms.RadioButton rbBrokenMoon; + private System.Windows.Forms.RadioButton rbDyingStar; + } } \ No newline at end of file diff --git a/OGL/FormJSCalCurve.cs b/OGL/FormJSCalCurve.cs index b383de5..7235562 100644 --- a/OGL/FormJSCalCurve.cs +++ b/OGL/FormJSCalCurve.cs @@ -22,812 +22,848 @@ using SCJMapper_V2.Options; namespace SCJMapper_V2.OGL { - public partial class FormJSCalCurve : Form - { - private static readonly log4net.ILog log = log4net.LogManager.GetLogger( System.Reflection.MethodBase.GetCurrentMethod( ).DeclaringType ); + public partial class FormJSCalCurve : Form + { + private static readonly log4net.ILog log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); - public bool Canceled { get; set; } + public bool Canceled { get; set; } - private bool loaded = false; + private bool loaded = false; - #region OGL Fields + #region OGL Fields - // Shader - int VertexShaderObject, FragmentShaderObject, ProgramObject; + // Shader + int VertexShaderObject, FragmentShaderObject, ProgramObject; + + // Textures + const TextureUnit TMU0_Unit = TextureUnit.Texture0; + const int TMU0_UnitInteger = 0; + string TMU0_Filename = ""; + uint TMU0_Handle; + TextureTarget TMU0_Target; - // Textures - const TextureUnit TMU0_Unit = TextureUnit.Texture0; - const int TMU0_UnitInteger = 0; - string TMU0_Filename = ""; - uint TMU0_Handle; - TextureTarget TMU0_Target; + private string[] SBFiles = { "graphics/SB_SC_BrokenMoon.dds","graphics/SB_SC_DyingStar.dds","graphics/SB_SC_Demien.dds","graphics/SB_SC_Area18.dds", + "graphics/SB_OutThere1.dds", "graphics/SB_OutThere3.dds", "graphics/SB_Canyon.dds", + "graphics/SB_Shiodome.dds", "graphics/SB_Highway.dds", "graphics/SB_BigSight.dds", "graphics/SB_LA_Helipad.dds", "graphics/SB_Sunset.dds", + "graphics/Skybox.dds" }; + // index into SBFiles + const int SB_BrokenMoon = 0; + const int SB_DyingStar = SB_BrokenMoon + 1; + const int SB_Demien = SB_DyingStar + 1; + const int SB_Area18 = SB_Demien + 1; + const int SB_OutThere1 = SB_Area18 + 1; + const int SB_OutThere3 = SB_OutThere1 + 1; + const int SB_Canyon = SB_OutThere3 + 1; + const int SB_Shiodome = SB_Canyon + 1; + const int SB_Highway = SB_Shiodome + 1; + const int SB_BigSight = SB_Highway + 1; + const int SB_LA_Helipad = SB_BigSight + 1; + const int SB_Sunset = SB_LA_Helipad + 1; + const int SB_Skybox = SB_Sunset + 1; - private string[] SBFiles = { "graphics/SB_OutThere1.dds", "graphics/SB_OutThere3.dds", "graphics/Skybox.dds", "graphics/SB_Canyon.dds", - "graphics/SB_Shiodome.dds", "graphics/SB_Highway.dds", "graphics/SB_BigSight.dds", "graphics/SB_LA_Helipad.dds", "graphics/SB_Sunset.dds" }; - // index into SBFiles - const int SB_OutThere1 = 0; - const int SB_OutThere3 = 1; - const int SB_Skybox = 2; - const int SB_Canyon = 3; - const int SB_Shiodome = 4; - const int SB_Highway = 5; - const int SB_BigSight = 6; - const int SB_LA_Helipad = 7; - const int SB_Sunset = 8; + #endregion internal Fields - #endregion internal Fields + #region Handling Vars - #region Handling Vars + // timing + private Int64 m_msElapsed = 0; + private Int64 m_ticks = 0; + private double DegPerMS = 360.0 / 3000.0; + private const Int64 m_frameTime = 25; // max Frametime msec 1/ = fps + // location / acceleration + private RK4Integrator m_flightModel = new RK4Integrator(); + private double m_damping = 5000; // range is around 3000 .. 30000 - // timing - private Int64 m_msElapsed = 0; - private Int64 m_ticks = 0; - private double DegPerMS = 360.0 / 3000.0; - private const Int64 m_frameTime = 25; // max Frametime msec 1/ = fps - // location / acceleration - private RK4Integrator m_flightModel = new RK4Integrator( ); - private double m_damping = 5000; // range is around 3000 .. 30000 + Label[] lblIn = null; + Label[] lblOut = null; - Label[] lblIn = null; - Label[] lblOut = null; + BezierSeries m_bSeries = new BezierSeries(); - BezierSeries m_bSeries = new BezierSeries( ); + bool m_isStrafe = false; // Strafe or YPR - bool m_isStrafe = false; // Strafe or YPR + #endregion - #endregion + #region Form Handling + + public FormJSCalCurve() + { + InitializeComponent(); + + log.Info("Enter FormJSCalCurve"); + + // helpers + lblIn = new Label[] { null, lblIn1, lblIn2, lblIn3, null, null }; // goes with PtNo 1.. + lblOut = new Label[] { null, lblOut1, lblOut2, lblOut3, lblOutExponent }; // goes with PtNo 1.. + + // add 5 points to the chart data series ( Zero, user1..3, max) + for (int i = 0; i < 5; i++) + { + m_bSeries.BezierPoints.Add(new DataPoint(0, 0)); + } + m_bSeries.ChartType = SeriesChartType.Line; + m_bSeries.Name = "Curve"; + chart1.Series[0] = m_bSeries; + // Create the Marker Series + chart1.Series.Add("Marker"); + chart1.Series[1].ChartType = SeriesChartType.Point; + chart1.Series[1].MarkerColor = Color.Orange; + chart1.Series[1].MarkerStyle = MarkerStyle.Circle; + chart1.Series[1].Points.AddXY(0, 0); + chart1.Series[1].Points.AddXY(0.25, 0.25); + chart1.Series[1].Points.AddXY(0.5, 0.5); + chart1.Series[1].Points.AddXY(0.75, 0.75); + chart1.Series[1].Points.AddXY(1.0, 1.0); + + // sliders + tbSlider.Maximum = Deviceoptions.DevOptSliderMax; + tbSlider.TickFrequency = Deviceoptions.DevOptSliderTick; + + // OGL map + TMU0_Filename = SBFiles[SB_BrokenMoon]; // initial sky + + Canceled = true; + } + + private void FormJSCalCurve_Load(object sender, EventArgs e) + { + rbHornet.Checked = true; + + rbTuneYPR.Checked = false; + rbTuneYPR.Checked = true; + // chain of triggers to maintain and format entries with default events... + rbY.Checked = false; + //back to default + rbY.Checked = true; + + rbPtDeadzone.Checked = false; // trigger value change.. + rbPtDeadzone.Checked = true; // default + + rbTuneYPR.Checked = true; + } + + private void FormJSCalCurve_FormClosing(object sender, FormClosingEventArgs e) + { + + if (loaded) + { + YawUpdateTuning(); + PitchUpdateTuning(); + RollUpdateTuning(); + + StrafeLatUpdateTuning(); + StrafeVertUpdateTuning(); + StrafeLonUpdateTuning(); + + Application.Idle -= Application_Idle; + GL.DeleteProgram(ProgramObject); + GL.DeleteTexture(TMU0_Handle); + } + } + + #endregion + + + #region class LiveValues (internal class) + + private class LiveValues + { + // load live from TuningParameters + public void Load(DeviceTuningParameter dp) + { + if (dp != null) + { + used = (!string.IsNullOrEmpty(dp.NodeText)); + if (!used) return; + + nodetext = dp.NodeText; + string[] e = nodetext.Split(new char[] { ActionTreeInputNode.RegDiv, ActionTreeInputNode.ModDiv }, StringSplitOptions.RemoveEmptyEntries); + if (e.Length > 0) + control = e[1].TrimEnd(); + else + control = dp.NodeText; + command = dp.CommandCtrl; + // the option data + if (dp.DeviceoptionRef == null) + { + deadzoneUsed = false; + saturationUsed = false; + } + else + { + deadzoneUsed = dp.DeviceoptionRef.DeadzoneUsed; + deadzoneS = dp.DeviceoptionRef.Deadzone; + saturationUsed = dp.DeviceoptionRef.SaturationUsed; + saturationS = dp.DeviceoptionRef.Saturation; + } + invertUsed = dp.InvertUsed; + exponentUsed = dp.ExponentUsed; + exponentS = dp.Exponent; + nonLinCurveUsed = dp.NonLinCurveUsed; + if (dp.NonLinCurveUsed) + { + nonLinCurve.Curve(float.Parse(dp.NonLinCurvePtsIn[0]), float.Parse(dp.NonLinCurvePtsOut[0]), + float.Parse(dp.NonLinCurvePtsIn[1]), float.Parse(dp.NonLinCurvePtsOut[1]), + float.Parse(dp.NonLinCurvePtsIn[2]), float.Parse(dp.NonLinCurvePtsOut[2])); + } + else + { + // dummy curve + nonLinCurve.Curve(0.25f, 0.25f, 0.5f, 0.5f, 0.75f, 0.75f); + } + } + } + + // update the TuningParameters + public void Update(ref DeviceTuningParameter dp) + { + if (!used) return; + // don't return strings to control the device + if (dp.DeviceoptionRef == null) + { + ; // nothing to update + } + else + { + dp.DeviceoptionRef.DeadzoneUsed = deadzoneUsed; + dp.DeviceoptionRef.Deadzone = deadzoneS; + dp.DeviceoptionRef.SaturationUsed = saturationUsed; + dp.DeviceoptionRef.Saturation = saturationS; + } + dp.InvertUsed = invertUsed; + dp.ExponentUsed = exponentUsed; + dp.Exponent = exponentS; + dp.NonLinCurveUsed = nonLinCurveUsed; + List pts = new List(); + pts.Add(nonLinCurve.Pt(0).X.ToString("0.000")); pts.Add(nonLinCurve.Pt(1).X.ToString("0.000")); pts.Add(nonLinCurve.Pt(2).X.ToString("0.000")); + dp.NonLinCurvePtsIn = pts; + pts = new List(); + pts.Add(nonLinCurve.Pt(0).Y.ToString("0.000")); pts.Add(nonLinCurve.Pt(1).Y.ToString("0.000")); pts.Add(nonLinCurve.Pt(2).Y.ToString("0.000")); + dp.NonLinCurvePtsOut = pts; + } + + // Context + public bool used = false; + public string nodetext = ""; // the node text + public string control = ""; // the device control item e.g. js2_x + public string command = ""; // the control item used to get the XDevice Input + + // calc values + private double MAX_DZ = 160.0; // avoid range issues and silly values.. + private double MIN_SAT = 200.0; // avoid range issues and silly values.. + private double m_range = 1000.0; + private double m_sign = 1.0; + + /// + /// Scales the input according to Deadzone and Saturation + /// + /// Int device input -1000 .. 0..1000 + /// A double in the range -1.0 .. 0.0 .. 1.0 + public double ScaledOut(int devIn) + { + int di = Math.Abs(devIn); + if (di <= m_deadzone) return 0.0; + if (di >= m_saturation) return 1.0 * Math.Sign(devIn); + + double fout = (di - m_deadzone) / m_range; // 0 .. 1.0 + if (exponentUsed) + { + fout = Math.Pow(fout, exponent) * Math.Sign(devIn); + } + else if (nonLinCurveUsed) + { + fout = nonLinCurve.EvalX((int)(fout * 1000.0 * Math.Sign(devIn))); // gets a scaled signed value (-1 .. +1) + } + else + { + fout = fout * Math.Sign(devIn); + } + + fout = (fout > 1.0) ? 1.0 : fout; // safeguard against any overshoots + fout = (fout < -1.0) ? -1.0 : fout; // safeguard against any overshoots + return fout; + } + /// + /// Applies the inversion if needed + /// + /// The new DevOut float 0.0 .. 1000.0 + /// Applied inverted DevOut + public double InvertedSign + { + get { return m_sign; } + } + + // set values + public bool m_invertUsed = false; + public bool invertUsed { get { return m_invertUsed; } set { m_invertUsed = value; m_sign = m_invertUsed ? -1.0 : 1.0; } } + + public bool deadzoneUsed = false; + private double m_deadzone = 0.0; // stores 1000 * set value + public double deadzone { get { return m_deadzone; } set { m_deadzone = (value > MAX_DZ) ? MAX_DZ : value; m_range = m_saturation - m_deadzone; } } + public string deadzoneS // get/set game value 0..1.000 + { + get { return (deadzone / 1000.0).ToString("0.000"); } + set { + double f; + if (double.TryParse(value, out f)) + { + deadzone = f * 1000.0; + } + else + { + deadzone = 0.0; + } + } + } + + public bool saturationUsed = false; + private double m_saturation = 1000.0;// stores 1000 * set value + public double saturation { get { return m_saturation; } set { m_saturation = (value < MIN_SAT) ? MIN_SAT : value; m_range = m_saturation - m_deadzone; } } + public string saturationS // get/set game value 0..1.000 + { + get { return (m_saturation / 1000.0).ToString("0.000"); } + set { + double f; + if (double.TryParse(value, out f)) + { + saturation = f * 1000.0; + } + else + { + saturation = 1000.0; + } + } + } + + public bool exponentUsed = false; + public double exponent = 1.0F; + public string exponentS + { + get { return exponent.ToString("0.000"); } + set { + double f; + if (double.TryParse(value, out f)) + { + exponent = f; + } + else + { + exponent = 1.0; + } + } + } + + public bool nonLinCurveUsed = false; + public xyPoints nonLinCurve = new xyPoints(1000); // max val of Joystick Input + } // class LiveValues + + #endregion + + + + private Tuningoptions m_tuningOptions = null; // will get the current optiontree on call + public Tuningoptions TuningOptions + { + get { + return m_tuningOptions; + } + set { + m_tuningOptions = value; + if (m_tuningOptions == null) + { + log.Error("- TuningOptions: m_tuningRef not assigned"); + return; + } + YawTuning = m_tuningOptions.FirstTuningItem("flight_move_yaw"); + PitchTuning = m_tuningOptions.FirstTuningItem("flight_move_pitch"); + RollTuning = m_tuningOptions.FirstTuningItem("flight_move_roll"); + + StrafeLatTuning = m_tuningOptions.FirstTuningItem("flight_move_strafe_lateral"); + StrafeVertTuning = m_tuningOptions.FirstTuningItem("flight_move_strafe_vertical"); + StrafeLonTuning = m_tuningOptions.FirstTuningItem("flight_move_strafe_longitudinal"); + } + } + + // Generic Interaction Pattern + // + // Assign TuningParameter (load Live data from Parameter) + // Switch YPR - Strafe (load live values into GUI) + // Switch Axis (load live values into working area) + // Change Parameters (live values are changed, GUI is updated) + // Retrieve TuningParameter (update Parameter from Live data + // + #region YAW - Interaction + + private DeviceTuningParameter m_YawTuning = new DeviceTuningParameter("flight_move_yaw"); + private LiveValues m_liveYaw = new LiveValues(); // live values + + /// + /// Submit the tuning parameters + /// + /// + private DeviceTuningParameter YawTuning + { + get { + YawUpdateTuning(); + return m_YawTuning; + } + set { + log.Info("FormJSCalCurve : Yaw Command is: " + value); + m_YawTuning = value; + // update live values from input + m_liveYaw.Load(m_YawTuning); + // populate from input + //YawUpdateGUIFromLiveValues( ); + } + } + + // update the GUI from Live + private void YawUpdateGUIFromLiveValues() + { + // updated the working area with Tuning parameters (obey live values) + LiveValues lv = m_liveYaw; + + if (!lv.used) + { + pnlYaw.Visible = false; rbY.Visible = false; + return; + } + pnlYaw.Visible = true; rbY.Visible = true; + + lblYCmd.Text = lv.control; + lblYnt.Text = lv.nodetext; + cbxYinvert.Checked = lv.invertUsed; + lblYdeadzone.Text = lv.deadzoneS; + cbxYdeadzone.Checked = lv.deadzoneUsed; + lblYsat.Text = lv.saturationS; + cbxYsat.Checked = lv.saturationUsed; + lblYexponent.Text = lv.exponentS; + cbxYexpo.Checked = lv.exponentUsed; + lblYin1.Text = lv.nonLinCurve.Pt(0).X.ToString("0.000"); lblYout1.Text = lv.nonLinCurve.Pt(0).Y.ToString("0.000"); + lblYin2.Text = lv.nonLinCurve.Pt(1).X.ToString("0.000"); lblYout2.Text = lv.nonLinCurve.Pt(1).Y.ToString("0.000"); + lblYin3.Text = lv.nonLinCurve.Pt(2).X.ToString("0.000"); lblYout3.Text = lv.nonLinCurve.Pt(2).Y.ToString("0.000"); + cbxYpts.Checked = lv.nonLinCurveUsed; + + rbY.Checked = false; rbY.Checked = true; + } + + // update Tuning from Live values + private void YawUpdateTuning() + { + m_liveYaw.Update(ref m_YawTuning); // update from live values + } + + #endregion + + + #region PITCH - Interaction + + private DeviceTuningParameter m_PitchTuning = new DeviceTuningParameter("flight_move_pitch"); + private LiveValues m_livePitch = new LiveValues(); // live values + + /// + /// Submit the tuning parameters + /// + /// + private DeviceTuningParameter PitchTuning + { + get { + // update + PitchUpdateTuning(); + return m_PitchTuning; + } + set { + log.Info("FormJSCalCurve : Pitch Command is: " + value); + m_PitchTuning = value; + // update live values from input + m_livePitch.Load(m_PitchTuning); + // populate from input + //PitchUpdateGUIFromLiveValues( ); + } + } + + // update the GUI from Live + private void PitchUpdateGUIFromLiveValues() + { + // updated the working area with Tuning parameters (obey live values) + LiveValues lv = m_livePitch; + + if (!lv.used) + { + pnlPitch.Visible = false; rbP.Visible = false; + return; + } + pnlPitch.Visible = true; rbP.Visible = true; + + lblPCmd.Text = lv.control; + lblPnt.Text = lv.nodetext; + cbxPinvert.Checked = lv.invertUsed; + lblPdeadzone.Text = lv.deadzoneS; + cbxPdeadzone.Checked = lv.deadzoneUsed; + lblPsat.Text = lv.saturationS; + cbxPsat.Checked = lv.saturationUsed; + lblPexponent.Text = lv.exponentS; + cbxPexpo.Checked = lv.exponentUsed; + lblPin1.Text = lv.nonLinCurve.Pt(0).X.ToString("0.000"); lblPout1.Text = lv.nonLinCurve.Pt(0).Y.ToString("0.000"); + lblPin2.Text = lv.nonLinCurve.Pt(1).X.ToString("0.000"); lblPout2.Text = lv.nonLinCurve.Pt(1).Y.ToString("0.000"); + lblPin3.Text = lv.nonLinCurve.Pt(2).X.ToString("0.000"); lblPout3.Text = lv.nonLinCurve.Pt(2).Y.ToString("0.000"); + cbxPpts.Checked = lv.nonLinCurveUsed; + + rbP.Checked = false; rbP.Checked = true; + } + + private void PitchUpdateTuning() + { + m_livePitch.Update(ref m_PitchTuning); // update from live values + } + + #endregion + + + #region ROLL - Interaction + + private DeviceTuningParameter m_RollTuning = new DeviceTuningParameter("flight_move_roll"); + private LiveValues m_liveRoll = new LiveValues(); // live values + + /// + /// Submit the tuning parameters + /// + /// + private DeviceTuningParameter RollTuning + { + get { + // update + RollUpdateTuning(); + return m_RollTuning; + } + set { + log.Info("FormJSCalCurve : Roll Command is: " + value); + m_RollTuning = value; + // update live values from input + m_liveRoll.Load(m_RollTuning); + // populate from input + //RollUpdateGUIFromLiveValues( ); + } + } + + // update the GUI from Live + private void RollUpdateGUIFromLiveValues() + { + // updated the working area with Tuning parameters (obey live values) + LiveValues lv = m_liveRoll; + + if (!lv.used) + { + pnlRoll.Visible = false; rbR.Visible = false; + + return; + } + pnlRoll.Visible = true; rbR.Visible = true; + + lblRCmd.Text = lv.control; + lblRnt.Text = lv.nodetext; + cbxRinvert.Checked = lv.invertUsed; + lblRdeadzone.Text = lv.deadzoneS; + cbxRdeadzone.Checked = lv.deadzoneUsed; + lblRsat.Text = lv.saturationS; + cbxRsat.Checked = lv.saturationUsed; + lblRexponent.Text = lv.exponentS; + cbxRexpo.Checked = lv.exponentUsed; + lblRin1.Text = lv.nonLinCurve.Pt(0).X.ToString("0.000"); lblRout1.Text = lv.nonLinCurve.Pt(0).Y.ToString("0.000"); + lblRin2.Text = lv.nonLinCurve.Pt(1).X.ToString("0.000"); lblRout2.Text = lv.nonLinCurve.Pt(1).Y.ToString("0.000"); + lblRin3.Text = lv.nonLinCurve.Pt(2).X.ToString("0.000"); lblRout3.Text = lv.nonLinCurve.Pt(2).Y.ToString("0.000"); + cbxRpts.Checked = lv.nonLinCurveUsed; + + rbR.Checked = false; rbR.Checked = true; + } + + private void RollUpdateTuning() + { + m_liveRoll.Update(ref m_RollTuning); // update from live values + } + + + #endregion + + + #region Strafe Lateral - Interaction (yaw GUI values) + + private DeviceTuningParameter m_StrafeLatTuning = new DeviceTuningParameter("flight_move_strafe_lateral"); + private LiveValues m_liveStrafeLat = new LiveValues(); // live values + + /// + /// Submit the tuning parameters + /// + /// + private DeviceTuningParameter StrafeLatTuning + { + get { + // update + StrafeLatUpdateTuning(); + return m_StrafeLatTuning; + } + set { + log.Info("FormJSCalCurve : Strafe Lateral Command is: " + value); + m_StrafeLatTuning = value; + // update live values from input + m_liveStrafeLat.Load(m_StrafeLatTuning); + // populate from input + //StrafeLatUpdateGUIFromLiveValues( ); + } + } + + // update the GUI from Live + private void StrafeLatUpdateGUIFromLiveValues() + { + // updated the working area with Tuning parameters (obey live values) + LiveValues lv = m_liveStrafeLat; + + if (!lv.used) + { + pnlYaw.Visible = false; rbY.Visible = false; + + return; + } + pnlYaw.Visible = true; rbY.Visible = true; + + lblYCmd.Text = lv.control; + lblYnt.Text = lv.nodetext; + cbxYinvert.Checked = lv.invertUsed; + lblYdeadzone.Text = lv.deadzoneS; + cbxYdeadzone.Checked = lv.deadzoneUsed; + lblYsat.Text = lv.saturationS; + cbxYsat.Checked = lv.saturationUsed; + lblYexponent.Text = lv.exponentS; + cbxYexpo.Checked = lv.exponentUsed; + lblYin1.Text = lv.nonLinCurve.Pt(0).X.ToString("0.000"); lblYout1.Text = lv.nonLinCurve.Pt(0).Y.ToString("0.000"); + lblYin2.Text = lv.nonLinCurve.Pt(1).X.ToString("0.000"); lblYout2.Text = lv.nonLinCurve.Pt(1).Y.ToString("0.000"); + lblYin3.Text = lv.nonLinCurve.Pt(2).X.ToString("0.000"); lblYout3.Text = lv.nonLinCurve.Pt(2).Y.ToString("0.000"); + cbxYpts.Checked = lv.nonLinCurveUsed; + + rbY.Checked = false; rbY.Checked = true; + } + + private void StrafeLatUpdateTuning() + { + m_liveStrafeLat.Update(ref m_StrafeLatTuning); // update from live values + } + + #endregion + + + #region Strafe Vertical - Interaction (pitch GUI values) + + private DeviceTuningParameter m_StrafeVertTuning = new DeviceTuningParameter("flight_move_strafe_vertical"); + private LiveValues m_liveStrafeVert = new LiveValues(); // live values + + /// + /// Submit the tuning parameters + /// + /// + private DeviceTuningParameter StrafeVertTuning + { + get { + // update + StrafeVertUpdateTuning(); + return m_StrafeVertTuning; + } + set { + log.Info("FormJSCalCurve : Strafe Vertical Command is: " + value); + m_StrafeVertTuning = value; + // update live values from input + m_liveStrafeVert.Load(m_StrafeVertTuning); + // populate from input + //StrafeVertUpdateGUIFromLiveValues( ); + } + } + + // update the GUI from Live + private void StrafeVertUpdateGUIFromLiveValues() + { + // updated the working area with Tuning parameters (obey live values) + LiveValues lv = m_liveStrafeVert; + + if (!lv.used) + { + pnlPitch.Visible = false; rbP.Visible = false; + + return; + } + pnlPitch.Visible = true; rbP.Visible = true; + + lblPCmd.Text = lv.control; + lblPnt.Text = lv.nodetext; + cbxPinvert.Checked = lv.invertUsed; + lblPdeadzone.Text = lv.deadzoneS; + cbxPdeadzone.Checked = lv.deadzoneUsed; + lblPsat.Text = lv.saturationS; + cbxPsat.Checked = lv.saturationUsed; + lblPexponent.Text = lv.exponentS; + cbxPexpo.Checked = lv.exponentUsed; + lblPin1.Text = lv.nonLinCurve.Pt(0).X.ToString("0.000"); lblPout1.Text = lv.nonLinCurve.Pt(0).Y.ToString("0.000"); + lblPin2.Text = lv.nonLinCurve.Pt(1).X.ToString("0.000"); lblPout2.Text = lv.nonLinCurve.Pt(1).Y.ToString("0.000"); + lblPin3.Text = lv.nonLinCurve.Pt(2).X.ToString("0.000"); lblPout3.Text = lv.nonLinCurve.Pt(2).Y.ToString("0.000"); + cbxPpts.Checked = lv.nonLinCurveUsed; + + rbP.Checked = false; rbP.Checked = true; + } + + private void StrafeVertUpdateTuning() + { + m_liveStrafeVert.Update(ref m_StrafeVertTuning); // update from live values + } + + #endregion + + + #region Strafe Longitudinal - Interaction (Roll GUI values) + + private DeviceTuningParameter m_StrafeLonTuning = new DeviceTuningParameter("flight_move_strafe_longitudinal"); + private LiveValues m_liveStrafeLon = new LiveValues(); // live values + + /// + /// Submit the tuning parameters + /// + /// + private DeviceTuningParameter StrafeLonTuning + { + get { + // update + StrafeLonUpdateTuning(); + return m_StrafeLonTuning; + } + set { + log.Info("FormJSCalCurve : Strafe Longitudinal Command is: " + value); + m_StrafeLonTuning = value; + // update live values from input + m_liveStrafeLon.Load(m_StrafeLonTuning); + // populate from input + //StrafeLonUpdateGUIFromLiveValues( ); + } + } - #region Form Handling - - public FormJSCalCurve() - { - InitializeComponent( ); - - log.Info( "Enter FormJSCalCurve" ); - - // helpers - lblIn = new Label[] { null, lblIn1, lblIn2, lblIn3, null, null }; // goes with PtNo 1.. - lblOut = new Label[] { null, lblOut1, lblOut2, lblOut3, lblOutExponent }; // goes with PtNo 1.. - - // add 5 points to the chart data series ( Zero, user1..3, max) - for ( int i = 0; i < 5; i++ ) { - m_bSeries.BezierPoints.Add( new DataPoint( 0, 0 ) ); - } - m_bSeries.ChartType = SeriesChartType.Line; - m_bSeries.Name = "Curve"; - chart1.Series[0] = m_bSeries; - // Create the Marker Series - chart1.Series.Add( "Marker" ); - chart1.Series[1].ChartType = SeriesChartType.Point; - chart1.Series[1].MarkerColor = Color.Orange; - chart1.Series[1].MarkerStyle = MarkerStyle.Circle; - chart1.Series[1].Points.AddXY( 0, 0 ); - chart1.Series[1].Points.AddXY( 0.25, 0.25 ); - chart1.Series[1].Points.AddXY( 0.5, 0.5 ); - chart1.Series[1].Points.AddXY( 0.75, 0.75 ); - chart1.Series[1].Points.AddXY( 1.0, 1.0 ); - - // sliders - tbSlider.Maximum = Deviceoptions.DevOptSliderMax; - tbSlider.TickFrequency = Deviceoptions.DevOptSliderTick; - - // OGL map - TMU0_Filename = SBFiles[SB_OutThere1]; // initial sky - - Canceled = true; - } - - private void FormJSCalCurve_Load( object sender, EventArgs e ) - { - rbHornet.Checked = true; - - rbTuneYPR.Checked = false; - rbTuneYPR.Checked = true; - // chain of triggers to maintain and format entries with default events... - rbY.Checked = false; - //back to default - rbY.Checked = true; - - rbPtDeadzone.Checked = false; // trigger value change.. - rbPtDeadzone.Checked = true; // default - - rbTuneYPR.Checked = true; - } - - private void FormJSCalCurve_FormClosing( object sender, FormClosingEventArgs e ) - { - - if ( loaded ) { - YawUpdateTuning( ); - PitchUpdateTuning( ); - RollUpdateTuning( ); - - StrafeLatUpdateTuning( ); - StrafeVertUpdateTuning( ); - StrafeLonUpdateTuning( ); - - Application.Idle -= Application_Idle; - GL.DeleteProgram( ProgramObject ); - GL.DeleteTexture( TMU0_Handle ); - } - } - - #endregion - - - #region class LiveValues (internal class) - - private class LiveValues - { - // load live from TuningParameters - public void Load( DeviceTuningParameter dp ) - { - if ( dp != null ) { - used = ( !string.IsNullOrEmpty( dp.NodeText ) ); - if ( !used ) return; - - nodetext = dp.NodeText; - string[] e = nodetext.Split( new char[] { ActionTreeInputNode.RegDiv, ActionTreeInputNode.ModDiv }, StringSplitOptions.RemoveEmptyEntries ); - if ( e.Length > 0 ) - control = e[1].TrimEnd( ); - else - control = dp.NodeText; - command = dp.CommandCtrl; - // the option data - if ( dp.DeviceoptionRef == null ) { - deadzoneUsed = false; - saturationUsed = false; - } - else { - deadzoneUsed = dp.DeviceoptionRef.DeadzoneUsed; - deadzoneS = dp.DeviceoptionRef.Deadzone; - saturationUsed = dp.DeviceoptionRef.SaturationUsed; - saturationS = dp.DeviceoptionRef.Saturation; - } - invertUsed = dp.InvertUsed; - exponentUsed = dp.ExponentUsed; - exponentS = dp.Exponent; - nonLinCurveUsed = dp.NonLinCurveUsed; - if ( dp.NonLinCurveUsed ) { - nonLinCurve.Curve( float.Parse( dp.NonLinCurvePtsIn[0] ), float.Parse( dp.NonLinCurvePtsOut[0] ), - float.Parse( dp.NonLinCurvePtsIn[1] ), float.Parse( dp.NonLinCurvePtsOut[1] ), - float.Parse( dp.NonLinCurvePtsIn[2] ), float.Parse( dp.NonLinCurvePtsOut[2] ) ); - } - else { - // dummy curve - nonLinCurve.Curve( 0.25f, 0.25f, 0.5f, 0.5f, 0.75f, 0.75f ); - } - } - } - - // update the TuningParameters - public void Update( ref DeviceTuningParameter dp ) - { - if ( !used ) return; - // don't return strings to control the device - if ( dp.DeviceoptionRef == null ) { - ; // nothing to update - } - else { - dp.DeviceoptionRef.DeadzoneUsed = deadzoneUsed; - dp.DeviceoptionRef.Deadzone = deadzoneS; - dp.DeviceoptionRef.SaturationUsed = saturationUsed; - dp.DeviceoptionRef.Saturation = saturationS; - } - dp.InvertUsed = invertUsed; - dp.ExponentUsed = exponentUsed; - dp.Exponent = exponentS; - dp.NonLinCurveUsed = nonLinCurveUsed; - List pts = new List( ); - pts.Add( nonLinCurve.Pt( 0 ).X.ToString( "0.000" ) ); pts.Add( nonLinCurve.Pt( 1 ).X.ToString( "0.000" ) ); pts.Add( nonLinCurve.Pt( 2 ).X.ToString( "0.000" ) ); - dp.NonLinCurvePtsIn = pts; - pts = new List( ); - pts.Add( nonLinCurve.Pt( 0 ).Y.ToString( "0.000" ) ); pts.Add( nonLinCurve.Pt( 1 ).Y.ToString( "0.000" ) ); pts.Add( nonLinCurve.Pt( 2 ).Y.ToString( "0.000" ) ); - dp.NonLinCurvePtsOut = pts; - } - - // Context - public bool used = false; - public string nodetext = ""; // the node text - public string control = ""; // the device control item e.g. js2_x - public string command = ""; // the control item used to get the XDevice Input - - // calc values - private double MAX_DZ = 160.0; // avoid range issues and silly values.. - private double MIN_SAT = 200.0; // avoid range issues and silly values.. - private double m_range = 1000.0; - private double m_sign = 1.0; - - /// - /// Scales the input according to Deadzone and Saturation - /// - /// Int device input -1000 .. 0..1000 - /// A double in the range -1.0 .. 0.0 .. 1.0 - public double ScaledOut( int devIn ) - { - int di = Math.Abs( devIn ); - if ( di <= m_deadzone ) return 0.0; - if ( di >= m_saturation ) return 1.0 * Math.Sign( devIn ); - - double fout = ( di - m_deadzone ) / m_range; // 0 .. 1.0 - if ( exponentUsed ) { - fout = Math.Pow( fout, exponent ) * Math.Sign( devIn ); - } - else if ( nonLinCurveUsed ) { - fout = nonLinCurve.EvalX( (int)( fout * 1000.0 * Math.Sign( devIn ) ) ); // gets a scaled signed value (-1 .. +1) - } - else { - fout = fout * Math.Sign( devIn ); - } - - fout = ( fout > 1.0 ) ? 1.0 : fout; // safeguard against any overshoots - fout = ( fout < -1.0 ) ? -1.0 : fout; // safeguard against any overshoots - return fout; - } - /// - /// Applies the inversion if needed - /// - /// The new DevOut float 0.0 .. 1000.0 - /// Applied inverted DevOut - public double InvertedSign - { - get { return m_sign; } - } - - // set values - public bool m_invertUsed = false; - public bool invertUsed { get { return m_invertUsed; } set { m_invertUsed = value; m_sign = m_invertUsed ? -1.0 : 1.0; } } - - public bool deadzoneUsed = false; - private double m_deadzone = 0.0; // stores 1000 * set value - public double deadzone { get { return m_deadzone; } set { m_deadzone = ( value > MAX_DZ ) ? MAX_DZ : value; m_range = m_saturation - m_deadzone; } } - public string deadzoneS // get/set game value 0..1.000 - { - get { return ( deadzone / 1000.0 ).ToString( "0.000" ); } - set { - double f; - if ( double.TryParse( value, out f ) ) { - deadzone = f * 1000.0; - } - else { - deadzone = 0.0; - } - } - } - - public bool saturationUsed = false; - private double m_saturation = 1000.0;// stores 1000 * set value - public double saturation { get { return m_saturation; } set { m_saturation = ( value < MIN_SAT ) ? MIN_SAT : value; m_range = m_saturation - m_deadzone; } } - public string saturationS // get/set game value 0..1.000 - { - get { return ( m_saturation / 1000.0 ).ToString( "0.000" ); } - set { - double f; - if ( double.TryParse( value, out f ) ) { - saturation = f * 1000.0; - } - else { - saturation = 1000.0; - } - } - } - - public bool exponentUsed = false; - public double exponent = 1.0F; - public string exponentS - { - get { return exponent.ToString( "0.000" ); } - set { - double f; - if ( double.TryParse( value, out f ) ) { - exponent = f; - } - else { - exponent = 1.0; - } - } - } - - public bool nonLinCurveUsed = false; - public xyPoints nonLinCurve = new xyPoints( 1000 ); // max val of Joystick Input - } // class LiveValues - - #endregion - - - - private Tuningoptions m_tuningOptions = null; // will get the current optiontree on call - public Tuningoptions TuningOptions - { - get { - return m_tuningOptions; - } - set { - m_tuningOptions = value; - if ( m_tuningOptions == null ) { - log.Error( "- TuningOptions: m_tuningRef not assigned" ); - return; - } - YawTuning = m_tuningOptions.FirstTuningItem( "flight_move_yaw" ); - PitchTuning = m_tuningOptions.FirstTuningItem( "flight_move_pitch" ); - RollTuning = m_tuningOptions.FirstTuningItem( "flight_move_roll" ); - - StrafeLatTuning = m_tuningOptions.FirstTuningItem( "flight_move_strafe_lateral" ); - StrafeVertTuning = m_tuningOptions.FirstTuningItem( "flight_move_strafe_vertical" ); - StrafeLonTuning = m_tuningOptions.FirstTuningItem( "flight_move_strafe_longitudinal" ); - } - } - - // Generic Interaction Pattern - // - // Assign TuningParameter (load Live data from Parameter) - // Switch YPR - Strafe (load live values into GUI) - // Switch Axis (load live values into working area) - // Change Parameters (live values are changed, GUI is updated) - // Retrieve TuningParameter (update Parameter from Live data - // - #region YAW - Interaction - - private DeviceTuningParameter m_YawTuning = new DeviceTuningParameter( "flight_move_yaw" ); - private LiveValues m_liveYaw = new LiveValues( ); // live values - - /// - /// Submit the tuning parameters - /// - /// - private DeviceTuningParameter YawTuning - { - get { - YawUpdateTuning( ); - return m_YawTuning; - } - set { - log.Info( "FormJSCalCurve : Yaw Command is: " + value ); - m_YawTuning = value; - // update live values from input - m_liveYaw.Load( m_YawTuning ); - // populate from input - //YawUpdateGUIFromLiveValues( ); - } - } - - // update the GUI from Live - private void YawUpdateGUIFromLiveValues() - { - // updated the working area with Tuning parameters (obey live values) - LiveValues lv = m_liveYaw; - - if ( !lv.used ) { - pnlYaw.Visible = false; rbY.Visible = false; - return; - } - pnlYaw.Visible = true; rbY.Visible = true; - - lblYCmd.Text = lv.control; - lblYnt.Text = lv.nodetext; - cbxYinvert.Checked = lv.invertUsed; - lblYdeadzone.Text = lv.deadzoneS; - cbxYdeadzone.Checked = lv.deadzoneUsed; - lblYsat.Text = lv.saturationS; - cbxYsat.Checked = lv.saturationUsed; - lblYexponent.Text = lv.exponentS; - cbxYexpo.Checked = lv.exponentUsed; - lblYin1.Text = lv.nonLinCurve.Pt( 0 ).X.ToString( "0.000" ); lblYout1.Text = lv.nonLinCurve.Pt( 0 ).Y.ToString( "0.000" ); - lblYin2.Text = lv.nonLinCurve.Pt( 1 ).X.ToString( "0.000" ); lblYout2.Text = lv.nonLinCurve.Pt( 1 ).Y.ToString( "0.000" ); - lblYin3.Text = lv.nonLinCurve.Pt( 2 ).X.ToString( "0.000" ); lblYout3.Text = lv.nonLinCurve.Pt( 2 ).Y.ToString( "0.000" ); - cbxYpts.Checked = lv.nonLinCurveUsed; - - rbY.Checked = false; rbY.Checked = true; - } - - // update Tuning from Live values - private void YawUpdateTuning() - { - m_liveYaw.Update( ref m_YawTuning ); // update from live values - } - - #endregion - - - #region PITCH - Interaction - - private DeviceTuningParameter m_PitchTuning = new DeviceTuningParameter( "flight_move_pitch" ); - private LiveValues m_livePitch = new LiveValues( ); // live values - - /// - /// Submit the tuning parameters - /// - /// - private DeviceTuningParameter PitchTuning - { - get { - // update - PitchUpdateTuning( ); - return m_PitchTuning; - } - set { - log.Info( "FormJSCalCurve : Pitch Command is: " + value ); - m_PitchTuning = value; - // update live values from input - m_livePitch.Load( m_PitchTuning ); - // populate from input - //PitchUpdateGUIFromLiveValues( ); - } - } - - // update the GUI from Live - private void PitchUpdateGUIFromLiveValues() - { - // updated the working area with Tuning parameters (obey live values) - LiveValues lv = m_livePitch; - - if ( !lv.used ) { - pnlPitch.Visible = false; rbP.Visible = false; - return; - } - pnlPitch.Visible = true; rbP.Visible = true; - - lblPCmd.Text = lv.control; - lblPnt.Text = lv.nodetext; - cbxPinvert.Checked = lv.invertUsed; - lblPdeadzone.Text = lv.deadzoneS; - cbxPdeadzone.Checked = lv.deadzoneUsed; - lblPsat.Text = lv.saturationS; - cbxPsat.Checked = lv.saturationUsed; - lblPexponent.Text = lv.exponentS; - cbxPexpo.Checked = lv.exponentUsed; - lblPin1.Text = lv.nonLinCurve.Pt( 0 ).X.ToString( "0.000" ); lblPout1.Text = lv.nonLinCurve.Pt( 0 ).Y.ToString( "0.000" ); - lblPin2.Text = lv.nonLinCurve.Pt( 1 ).X.ToString( "0.000" ); lblPout2.Text = lv.nonLinCurve.Pt( 1 ).Y.ToString( "0.000" ); - lblPin3.Text = lv.nonLinCurve.Pt( 2 ).X.ToString( "0.000" ); lblPout3.Text = lv.nonLinCurve.Pt( 2 ).Y.ToString( "0.000" ); - cbxPpts.Checked = lv.nonLinCurveUsed; - - rbP.Checked = false; rbP.Checked = true; - } - - private void PitchUpdateTuning() - { - m_livePitch.Update( ref m_PitchTuning ); // update from live values - } - - #endregion - - - #region ROLL - Interaction - - private DeviceTuningParameter m_RollTuning = new DeviceTuningParameter( "flight_move_roll" ); - private LiveValues m_liveRoll = new LiveValues( ); // live values - - /// - /// Submit the tuning parameters - /// - /// - private DeviceTuningParameter RollTuning - { - get { - // update - RollUpdateTuning( ); - return m_RollTuning; - } - set { - log.Info( "FormJSCalCurve : Roll Command is: " + value ); - m_RollTuning = value; - // update live values from input - m_liveRoll.Load( m_RollTuning ); - // populate from input - //RollUpdateGUIFromLiveValues( ); - } - } - - // update the GUI from Live - private void RollUpdateGUIFromLiveValues() - { - // updated the working area with Tuning parameters (obey live values) - LiveValues lv = m_liveRoll; - - if ( !lv.used ) { - pnlRoll.Visible = false; rbR.Visible = false; - - return; - } - pnlRoll.Visible = true; rbR.Visible = true; - - lblRCmd.Text = lv.control; - lblRnt.Text = lv.nodetext; - cbxRinvert.Checked = lv.invertUsed; - lblRdeadzone.Text = lv.deadzoneS; - cbxRdeadzone.Checked = lv.deadzoneUsed; - lblRsat.Text = lv.saturationS; - cbxRsat.Checked = lv.saturationUsed; - lblRexponent.Text = lv.exponentS; - cbxRexpo.Checked = lv.exponentUsed; - lblRin1.Text = lv.nonLinCurve.Pt( 0 ).X.ToString( "0.000" ); lblRout1.Text = lv.nonLinCurve.Pt( 0 ).Y.ToString( "0.000" ); - lblRin2.Text = lv.nonLinCurve.Pt( 1 ).X.ToString( "0.000" ); lblRout2.Text = lv.nonLinCurve.Pt( 1 ).Y.ToString( "0.000" ); - lblRin3.Text = lv.nonLinCurve.Pt( 2 ).X.ToString( "0.000" ); lblRout3.Text = lv.nonLinCurve.Pt( 2 ).Y.ToString( "0.000" ); - cbxRpts.Checked = lv.nonLinCurveUsed; - - rbR.Checked = false; rbR.Checked = true; - } - - private void RollUpdateTuning() - { - m_liveRoll.Update( ref m_RollTuning ); // update from live values - } - - - #endregion - - - #region Strafe Lateral - Interaction (yaw GUI values) - - private DeviceTuningParameter m_StrafeLatTuning = new DeviceTuningParameter( "flight_move_strafe_lateral" ); - private LiveValues m_liveStrafeLat = new LiveValues( ); // live values - - /// - /// Submit the tuning parameters - /// - /// - private DeviceTuningParameter StrafeLatTuning - { - get { - // update - StrafeLatUpdateTuning( ); - return m_StrafeLatTuning; - } - set { - log.Info( "FormJSCalCurve : Strafe Lateral Command is: " + value ); - m_StrafeLatTuning = value; - // update live values from input - m_liveStrafeLat.Load( m_StrafeLatTuning ); - // populate from input - //StrafeLatUpdateGUIFromLiveValues( ); - } - } - - // update the GUI from Live - private void StrafeLatUpdateGUIFromLiveValues() - { - // updated the working area with Tuning parameters (obey live values) - LiveValues lv = m_liveStrafeLat; - - if ( !lv.used ) { - pnlYaw.Visible = false; rbY.Visible = false; - - return; - } - pnlYaw.Visible = true; rbY.Visible = true; - - lblYCmd.Text = lv.control; - lblYnt.Text = lv.nodetext; - cbxYinvert.Checked = lv.invertUsed; - lblYdeadzone.Text = lv.deadzoneS; - cbxYdeadzone.Checked = lv.deadzoneUsed; - lblYsat.Text = lv.saturationS; - cbxYsat.Checked = lv.saturationUsed; - lblYexponent.Text = lv.exponentS; - cbxYexpo.Checked = lv.exponentUsed; - lblYin1.Text = lv.nonLinCurve.Pt( 0 ).X.ToString( "0.000" ); lblYout1.Text = lv.nonLinCurve.Pt( 0 ).Y.ToString( "0.000" ); - lblYin2.Text = lv.nonLinCurve.Pt( 1 ).X.ToString( "0.000" ); lblYout2.Text = lv.nonLinCurve.Pt( 1 ).Y.ToString( "0.000" ); - lblYin3.Text = lv.nonLinCurve.Pt( 2 ).X.ToString( "0.000" ); lblYout3.Text = lv.nonLinCurve.Pt( 2 ).Y.ToString( "0.000" ); - cbxYpts.Checked = lv.nonLinCurveUsed; - - rbY.Checked = false; rbY.Checked = true; - } - - private void StrafeLatUpdateTuning() - { - m_liveStrafeLat.Update( ref m_StrafeLatTuning ); // update from live values - } - - #endregion - - - #region Strafe Vertical - Interaction (pitch GUI values) - - private DeviceTuningParameter m_StrafeVertTuning = new DeviceTuningParameter( "flight_move_strafe_vertical" ); - private LiveValues m_liveStrafeVert = new LiveValues( ); // live values - - /// - /// Submit the tuning parameters - /// - /// - private DeviceTuningParameter StrafeVertTuning - { - get { - // update - StrafeVertUpdateTuning( ); - return m_StrafeVertTuning; - } - set { - log.Info( "FormJSCalCurve : Strafe Vertical Command is: " + value ); - m_StrafeVertTuning = value; - // update live values from input - m_liveStrafeVert.Load( m_StrafeVertTuning ); - // populate from input - //StrafeVertUpdateGUIFromLiveValues( ); - } - } - - // update the GUI from Live - private void StrafeVertUpdateGUIFromLiveValues() - { - // updated the working area with Tuning parameters (obey live values) - LiveValues lv = m_liveStrafeVert; - - if ( !lv.used ) { - pnlPitch.Visible = false; rbP.Visible = false; - - return; - } - pnlPitch.Visible = true; rbP.Visible = true; - - lblPCmd.Text = lv.control; - lblPnt.Text = lv.nodetext; - cbxPinvert.Checked = lv.invertUsed; - lblPdeadzone.Text = lv.deadzoneS; - cbxPdeadzone.Checked = lv.deadzoneUsed; - lblPsat.Text = lv.saturationS; - cbxPsat.Checked = lv.saturationUsed; - lblPexponent.Text = lv.exponentS; - cbxPexpo.Checked = lv.exponentUsed; - lblPin1.Text = lv.nonLinCurve.Pt( 0 ).X.ToString( "0.000" ); lblPout1.Text = lv.nonLinCurve.Pt( 0 ).Y.ToString( "0.000" ); - lblPin2.Text = lv.nonLinCurve.Pt( 1 ).X.ToString( "0.000" ); lblPout2.Text = lv.nonLinCurve.Pt( 1 ).Y.ToString( "0.000" ); - lblPin3.Text = lv.nonLinCurve.Pt( 2 ).X.ToString( "0.000" ); lblPout3.Text = lv.nonLinCurve.Pt( 2 ).Y.ToString( "0.000" ); - cbxPpts.Checked = lv.nonLinCurveUsed; - - rbP.Checked = false; rbP.Checked = true; - } - - private void StrafeVertUpdateTuning() - { - m_liveStrafeVert.Update( ref m_StrafeVertTuning ); // update from live values - } - - #endregion + // update the GUI from Live + private void StrafeLonUpdateGUIFromLiveValues() + { + // updated the working area with Tuning parameters (obey live values) + LiveValues lv = m_liveStrafeLon; + if (!lv.used) + { + pnlRoll.Visible = false; rbR.Visible = false; + + return; + } + pnlRoll.Visible = true; rbR.Visible = true; - #region Strafe Longitudinal - Interaction (Roll GUI values) + lblRCmd.Text = lv.control; + lblRnt.Text = lv.nodetext; + cbxRinvert.Checked = lv.invertUsed; + lblRdeadzone.Text = lv.deadzoneS; + cbxRdeadzone.Checked = lv.deadzoneUsed; + lblRsat.Text = lv.saturationS; + cbxRsat.Checked = lv.saturationUsed; + lblRexponent.Text = lv.exponentS; + cbxRexpo.Checked = lv.exponentUsed; + lblRin1.Text = lv.nonLinCurve.Pt(0).X.ToString("0.000"); lblRout1.Text = lv.nonLinCurve.Pt(0).Y.ToString("0.000"); + lblRin2.Text = lv.nonLinCurve.Pt(1).X.ToString("0.000"); lblRout2.Text = lv.nonLinCurve.Pt(1).Y.ToString("0.000"); + lblRin3.Text = lv.nonLinCurve.Pt(2).X.ToString("0.000"); lblRout3.Text = lv.nonLinCurve.Pt(2).Y.ToString("0.000"); + cbxRpts.Checked = lv.nonLinCurveUsed; - private DeviceTuningParameter m_StrafeLonTuning = new DeviceTuningParameter( "flight_move_strafe_longitudinal" ); - private LiveValues m_liveStrafeLon = new LiveValues( ); // live values + rbR.Checked = false; rbR.Checked = true; + } - /// - /// Submit the tuning parameters - /// - /// - private DeviceTuningParameter StrafeLonTuning - { - get { - // update - StrafeLonUpdateTuning( ); - return m_StrafeLonTuning; - } - set { - log.Info( "FormJSCalCurve : Strafe Longitudinal Command is: " + value ); - m_StrafeLonTuning = value; - // update live values from input - m_liveStrafeLon.Load( m_StrafeLonTuning ); - // populate from input - //StrafeLonUpdateGUIFromLiveValues( ); - } - } + private void StrafeLonUpdateTuning() + { + m_liveStrafeLon.Update(ref m_StrafeLonTuning); // update from live values + } - // update the GUI from Live - private void StrafeLonUpdateGUIFromLiveValues() - { - // updated the working area with Tuning parameters (obey live values) - LiveValues lv = m_liveStrafeLon; - - if ( !lv.used ) { - pnlRoll.Visible = false; rbR.Visible = false; - - return; - } - pnlRoll.Visible = true; rbR.Visible = true; - - lblRCmd.Text = lv.control; - lblRnt.Text = lv.nodetext; - cbxRinvert.Checked = lv.invertUsed; - lblRdeadzone.Text = lv.deadzoneS; - cbxRdeadzone.Checked = lv.deadzoneUsed; - lblRsat.Text = lv.saturationS; - cbxRsat.Checked = lv.saturationUsed; - lblRexponent.Text = lv.exponentS; - cbxRexpo.Checked = lv.exponentUsed; - lblRin1.Text = lv.nonLinCurve.Pt( 0 ).X.ToString( "0.000" ); lblRout1.Text = lv.nonLinCurve.Pt( 0 ).Y.ToString( "0.000" ); - lblRin2.Text = lv.nonLinCurve.Pt( 1 ).X.ToString( "0.000" ); lblRout2.Text = lv.nonLinCurve.Pt( 1 ).Y.ToString( "0.000" ); - lblRin3.Text = lv.nonLinCurve.Pt( 2 ).X.ToString( "0.000" ); lblRout3.Text = lv.nonLinCurve.Pt( 2 ).Y.ToString( "0.000" ); - cbxRpts.Checked = lv.nonLinCurveUsed; - - rbR.Checked = false; rbR.Checked = true; - } + #endregion - private void StrafeLonUpdateTuning() - { - m_liveStrafeLon.Update( ref m_StrafeLonTuning ); // update from live values - } - #endregion + #region OGL Content + private void LoadSkybox() + { + TextureLoaderParameters.FlipImages = false; + TextureLoaderParameters.MagnificationFilter = TextureMagFilter.Linear; + TextureLoaderParameters.MinificationFilter = TextureMinFilter.Linear; + TextureLoaderParameters.WrapModeS = TextureWrapMode.ClampToEdge; + TextureLoaderParameters.WrapModeT = TextureWrapMode.ClampToEdge; + TextureLoaderParameters.EnvMode = TextureEnvMode.Modulate; - #region OGL Content + try + { + ImageDDS.LoadFromDisk(TMU0_Filename, out TMU0_Handle, out TMU0_Target); + log.Info("Loaded " + TMU0_Filename + " with handle " + TMU0_Handle + " as " + TMU0_Target); + } + catch (Exception ex) + { + log.Error("Error loading DDS file:", ex); + } - private void LoadSkybox() - { - TextureLoaderParameters.FlipImages = false; - TextureLoaderParameters.MagnificationFilter = TextureMagFilter.Linear; - TextureLoaderParameters.MinificationFilter = TextureMinFilter.Linear; - TextureLoaderParameters.WrapModeS = TextureWrapMode.ClampToEdge; - TextureLoaderParameters.WrapModeT = TextureWrapMode.ClampToEdge; - TextureLoaderParameters.EnvMode = TextureEnvMode.Modulate; - - try { - ImageDDS.LoadFromDisk( TMU0_Filename, out TMU0_Handle, out TMU0_Target ); - log.Info( "Loaded " + TMU0_Filename + " with handle " + TMU0_Handle + " as " + TMU0_Target ); - } catch ( Exception ex ) { - log.Error( "Error loading DDS file:", ex ); - } - - log.Info( "End of Texture Loading. GL Error: " + GL.GetError( ) ); + log.Info("End of Texture Loading. GL Error: " + GL.GetError()); - } + } - private void glControl1_Load( object sender, EventArgs e ) - { - log.Info( "Enter glControl1_Load" ); + private void glControl1_Load(object sender, EventArgs e) + { + log.Info("Enter glControl1_Load"); - GL.ClearColor( Color.SkyBlue ); // Yey! .NET Colors can be used directly! - SetupViewport( ); - Application.Idle += Application_Idle; // press TAB twice after += + GL.ClearColor(Color.SkyBlue); // Yey! .NET Colors can be used directly! + SetupViewport(); + Application.Idle += Application_Idle; // press TAB twice after += - // init time keeping - m_ticks = DateTime.Now.Ticks; - m_msElapsed = 0; + // init time keeping + m_ticks = DateTime.Now.Ticks; + m_msElapsed = 0; - //////////////////////////////// + //////////////////////////////// - // Check for necessary capabilities: - string extensions = GL.GetString( StringName.Extensions ); - if ( !GL.GetString( StringName.Extensions ).Contains( "GL_ARB_shading_language" ) ) { - log.ErrorFormat( "glControl1_Load - This program requires OpenGL 2.0. Found {0}. Aborting.", GL.GetString( StringName.Version ).Substring( 0, 3 ) ); + // Check for necessary capabilities: + string extensions = GL.GetString(StringName.Extensions); + if (!GL.GetString(StringName.Extensions).Contains("GL_ARB_shading_language")) + { + log.ErrorFormat("glControl1_Load - This program requires OpenGL 2.0. Found {0}. Aborting.", GL.GetString(StringName.Version).Substring(0, 3)); - throw new NotSupportedException( string.Format( "This program requires OpenGL 2.0. Found {0}. Aborting.", - GL.GetString( StringName.Version ).Substring( 0, 3 ) ) ); - } + throw new NotSupportedException(string.Format("This program requires OpenGL 2.0. Found {0}. Aborting.", + GL.GetString(StringName.Version).Substring(0, 3))); + } - if ( !extensions.Contains( "GL_ARB_texture_compression" ) || - !extensions.Contains( "GL_EXT_texture_compression_s3tc" ) ) { - log.Error( "glControl1_Load - This program requires support for texture compression. Aborting." ); + if (!extensions.Contains("GL_ARB_texture_compression") || + !extensions.Contains("GL_EXT_texture_compression_s3tc")) + { + log.Error("glControl1_Load - This program requires support for texture compression. Aborting."); - throw new NotSupportedException( "This program requires support for texture compression. Aborting." ); - } + throw new NotSupportedException("This program requires support for texture compression. Aborting."); + } - #region GL State + #region GL State - GL.ClearColor( 0f, 0f, 0f, 0f ); + GL.ClearColor(0f, 0f, 0f, 0f); - GL.Disable( EnableCap.Dither ); + GL.Disable(EnableCap.Dither); - GL.Enable( EnableCap.CullFace ); - GL.FrontFace( FrontFaceDirection.Ccw ); - GL.PolygonMode( MaterialFace.Front, PolygonMode.Fill ); + GL.Enable(EnableCap.CullFace); + GL.FrontFace(FrontFaceDirection.Ccw); + GL.PolygonMode(MaterialFace.Front, PolygonMode.Fill); - #endregion GL State + #endregion GL State - #region Shaders + #region Shaders - string LogInfo; + string LogInfo; - // Load&Compile Vertex Shader - // Thanks: http://www.rioki.org/2013/03/07/glsl-skybox.html + // Load&Compile Vertex Shader + // Thanks: http://www.rioki.org/2013/03/07/glsl-skybox.html - // GLSL for vertex shader. - VertexShaderObject = GL.CreateShader( ShaderType.VertexShader ); - string vertSource = @" + // GLSL for vertex shader. + VertexShaderObject = GL.CreateShader(ShaderType.VertexShader); + string vertSource = @" #extension GL_ARB_gpu_shader5 : enable void main() { @@ -842,13 +878,13 @@ namespace SCJMapper_V2.OGL gl_Position = gl_Vertex; } "; - // compile shader - compileShader( VertexShaderObject, vertSource ); + // compile shader + compileShader(VertexShaderObject, vertSource); - // GLSL for fragment shader. - FragmentShaderObject = GL.CreateShader( ShaderType.FragmentShader ); - string fragSource = @" + // GLSL for fragment shader. + FragmentShaderObject = GL.CreateShader(ShaderType.FragmentShader); + string fragSource = @" uniform samplerCube Skybox; void main() @@ -856,1364 +892,1536 @@ namespace SCJMapper_V2.OGL gl_FragColor = textureCube(Skybox, gl_TexCoord[0]); } "; - // compile shader - compileShader( FragmentShaderObject, fragSource ); - - // Link the Shaders to a usable Program - ProgramObject = GL.CreateProgram( ); - GL.AttachShader( ProgramObject, VertexShaderObject ); - GL.AttachShader( ProgramObject, FragmentShaderObject ); - - // link it all together - GL.LinkProgram( ProgramObject ); - - // flag ShaderObjects for delete when not used anymore - GL.DeleteShader( VertexShaderObject ); - GL.DeleteShader( FragmentShaderObject ); - - int[] temp = new int[1]; - GL.GetProgram( ProgramObject, GetProgramParameterName.LinkStatus, out temp[0] ); - log.Info( "Linking Program (" + ProgramObject + ") " + ( ( temp[0] == 1 ) ? "succeeded." : "FAILED!" ) ); - if ( temp[0] != 1 ) { - GL.GetProgramInfoLog( ProgramObject, out LogInfo ); - log.Error( "Program Log:\n" + LogInfo ); - } - - GL.GetProgram( ProgramObject, GetProgramParameterName.ActiveAttributes, out temp[0] ); - log.Info( "Program registered " + temp[0] + " Attributes." ); - log.Info( "End of Shader build. GL Error: " + GL.GetError( ) ); - - #endregion Shaders + // compile shader + compileShader(FragmentShaderObject, fragSource); - #region Textures + // Link the Shaders to a usable Program + ProgramObject = GL.CreateProgram(); + GL.AttachShader(ProgramObject, VertexShaderObject); + GL.AttachShader(ProgramObject, FragmentShaderObject); - LoadSkybox( ); + // link it all together + GL.LinkProgram(ProgramObject); - #endregion Textures + // flag ShaderObjects for delete when not used anymore + GL.DeleteShader(VertexShaderObject); + GL.DeleteShader(FragmentShaderObject); + int[] temp = new int[1]; + GL.GetProgram(ProgramObject, GetProgramParameterName.LinkStatus, out temp[0]); + log.Info("Linking Program (" + ProgramObject + ") " + ((temp[0] == 1) ? "succeeded." : "FAILED!")); + if (temp[0] != 1) + { + GL.GetProgramInfoLog(ProgramObject, out LogInfo); + log.Error("Program Log:\n" + LogInfo); + } - loaded = true; - } - - - private void glControl1_Paint( object sender, PaintEventArgs e ) - { - if ( !loaded ) return; - Render( ); - } + GL.GetProgram(ProgramObject, GetProgramParameterName.ActiveAttributes, out temp[0]); + log.Info("Program registered " + temp[0] + " Attributes."); + log.Info("End of Shader build. GL Error: " + GL.GetError()); + #endregion Shaders - private void glControl1_Resize( object sender, EventArgs e ) - { - SetupViewport( ); - if ( m_bSeries != null ) m_bSeries.Invalidate( chart1 ); - else chart1.Invalidate( ); - } - - - /// - /// Helper method to avoid code duplication. - /// Compiles a shader and prints results using Debug.WriteLine. - /// - /// A shader object, gotten from GL.CreateShader. - /// The GLSL source to compile. - void compileShader( int shader, string source ) - { - GL.ShaderSource( shader, source ); - GL.CompileShader( shader ); - - string info; - GL.GetShaderInfoLog( shader, out info ); - Trace.WriteLine( info ); - - int compileResult; - GL.GetShader( shader, ShaderParameter.CompileStatus, out compileResult ); - if ( compileResult != 1 ) { - log.Error( "compileShader - Compile Error:" ); - log.Error( source ); - } - } - - - - private void SetupViewport() - { - int w = glControl1.Width; - int h = glControl1.Height; - - GL.Viewport( 0, 0, w, h ); // Use all of the glControl painting area - - GL.MatrixMode( MatrixMode.Projection ); - Matrix4 p = Matrix4.CreatePerspectiveFieldOfView( MathHelper.PiOver4, w / (float)h, 0.1f, 10.0f ); - GL.LoadMatrix( ref p ); - - GL.MatrixMode( MatrixMode.Modelview ); - GL.LoadIdentity( ); - } - - // One render cycle - beware this should be fast... - private void Render() - { - if ( !loaded ) return; + #region Textures - GL.Clear( ClearBufferMask.ColorBufferBit | ClearBufferMask.DepthBufferBit ); + LoadSkybox(); - GL.UseProgram( ProgramObject ); // use the compiled shader + #endregion Textures - // interface with shader variables - GL.Uniform1( GL.GetUniformLocation( ProgramObject, "Skybox" ), TMU0_UnitInteger ); - // get our own matrix - GL.PushMatrix( ); - GL.LoadIdentity( ); // Reset and transform the matrix. - - // part of the 3D orientation - the rest is in the idle routine - Matrix4d rm = new Matrix4d( m_right.X, m_right.Y, m_right.Z, 0, - m_up.X, m_up.Y, m_up.Z, 0, - m_front.X, m_front.Y, m_front.Z, 0, - 0, 0, 0, 1 ); - GL.MultMatrix( ref rm ); // transform - - // Enable/Disable features - GL.PushAttrib( AttribMask.EnableBit ); - GL.DepthMask( false ); - GL.Disable( EnableCap.DepthTest ); - GL.Disable( EnableCap.Lighting ); - GL.Disable( EnableCap.Blend ); - - // use the Skybox texture - GL.ActiveTexture( TMU0_Unit ); - GL.BindTexture( TMU0_Target, TMU0_Handle ); - - // Draw - GL.Color3( 1f, 1f, 1f ); // Just in case we set all vertices to white. - - // draw one Quad only - GL.Begin( PrimitiveType.Quads ); - { - GL.Vertex3( -1.0, -1.0, 0.0 ); - GL.Vertex3( 1.0, -1.0, 0.0 ); - GL.Vertex3( 1.0, 1.0, 0.0 ); - GL.Vertex3( -1.0, 1.0, 0.0 ); - } - GL.End( ); - - // END Draw - - - // Restore enable bits and matrix - GL.PopAttrib( ); - GL.PopMatrix( ); - - // finally show the contents - glControl1.SwapBuffers( ); - } - - #endregion - - - #region Joystick Input Handling - - /// - /// Proper 3D camera aiming... - /// Thanks: http://tutorialrandom.blogspot.ch/2012/08/how-to-rotate-in-3d-using-opengl-proper.html - /// - /// - Vector3d m_right = Vector3d.UnitX; - Vector3d m_up = Vector3d.UnitY; - Vector3d m_front = Vector3d.UnitZ; - - /// - /// Calc the view vector - take care of changing axis orientations - /// - /// Right-Left Direction - /// Up-Down Direction - /// RotLeft - RotRight Direction - private void rotDeg( Vector3d dir ) - { - Matrix4d temp = Matrix4d.CreateRotationX( MathHelper.DegreesToRadians( dir.Y ) );// invert y-> x - m_right = Vector3d.TransformVector( m_right, temp ); - m_up = Vector3d.TransformVector( m_up, temp ); - m_front = Vector3d.TransformVector( m_front, temp ); - - temp = Matrix4d.CreateRotationY( MathHelper.DegreesToRadians( dir.X ) ); // invert x-> y - m_right = Vector3d.TransformVector( m_right, temp ); - m_up = Vector3d.TransformVector( m_up, temp ); - m_front = Vector3d.TransformVector( m_front, temp ); - - temp = Matrix4d.CreateRotationZ( MathHelper.DegreesToRadians( dir.Z ) ); - m_right = Vector3d.TransformVector( m_right, temp ); - m_up = Vector3d.TransformVector( m_up, temp ); - m_front = Vector3d.TransformVector( m_front, temp ); - } - - - - /// - /// Sub Handler for Strafe - /// - Vector3d Idle_Strafe() - { - Vector3d m = Vector3d.Zero; ; - - bool lat = ( m_StrafeLatTuning != null ) && ( m_StrafeLatTuning.GameDevice != null ); - bool vert = ( m_StrafeVertTuning != null ) && ( m_StrafeVertTuning.GameDevice != null ); - bool lon = ( m_StrafeLonTuning != null ) && ( m_StrafeLonTuning.GameDevice != null ); - - int i_x = 0, i_y = 0, i_z = 0; // Joystick Input - int x = 0; int y = 0; int z = 0; // retain real input as i_xyz - - if ( lat ) m_StrafeLatTuning.GameDevice.GetCmdData( m_liveStrafeLat.command, out i_x ); // + = right - if ( vert ) m_StrafeVertTuning.GameDevice.GetCmdData( m_liveStrafeVert.command, out i_y ); // + = up - if ( lon ) m_StrafeLonTuning.GameDevice.GetCmdData( m_liveStrafeLon.command, out i_z ); // += twist right - // apply the modifications of the control (deadzone, shape, sensitivity) - x = i_x; y = i_y; z = i_z; // retain real input as i_xyz - m_flightModel.Velocity = Vector3d.Zero; - - // Lateral - if ( lat ) { - double fout = m_liveStrafeLat.ScaledOut( x ); // 0 .. 1000.0 - lblYInput.Text = ( i_x / 1000.0 ).ToString( "0.00" ); lblYOutput.Text = ( fout ).ToString( "0.00" ); - // calculate new direction vector - m.X = m_liveStrafeLat.InvertedSign * ( ( !cbYuse.Checked ) ? fout : 0 ) * m_msElapsed * DegPerMS; - } - - // Vertical - if ( vert ) { - double fout = m_liveStrafeVert.ScaledOut( y ); // 0 .. 1000.0 - lblPInput.Text = ( i_y / 1000.0 ).ToString( "0.00" ); lblPOutput.Text = ( fout ).ToString( "0.00" ); - // calculate new direction vector - m.Y = m_liveStrafeVert.InvertedSign * ( ( !cbPuse.Checked ) ? fout : 0 ) * m_msElapsed * DegPerMS; - } - - // Longitudinal - if ( lon ) { - double fout = m_liveStrafeLon.ScaledOut( z ); // 0 .. 1000.0 - lblRInput.Text = ( i_z / 1000.0 ).ToString( "0.00" ); lblROutput.Text = ( fout ).ToString( "0.00" ); - // calculate new direction vector - m.Z = m_liveStrafeLon.InvertedSign * ( ( !cbRuse.Checked ) ? fout : 0 ) * m_msElapsed * DegPerMS; - } - return m; - } - - - /// - /// Sub Handler for YPR (Yaw, Pitch, Roll) - /// - Vector3d Idle_YPR() - { - Vector3d m = Vector3d.Zero; ; - - bool yaw = ( m_YawTuning != null ) && ( m_YawTuning.GameDevice != null ); - bool pitch = ( m_PitchTuning != null ) && ( m_PitchTuning.GameDevice != null ); - bool roll = ( m_RollTuning != null ) && ( m_RollTuning.GameDevice != null ); - - int i_x = 0, i_y = 0, i_z = 0; // Joystick Input - int x = 0; int y = 0; int z = 0; // retain real input as i_xyz - - if ( yaw ) m_YawTuning.GameDevice.GetCmdData( m_liveYaw.command, out i_x ); // + = right - if ( pitch ) m_PitchTuning.GameDevice.GetCmdData( m_livePitch.command, out i_y ); // + = up - if ( roll ) m_RollTuning.GameDevice.GetCmdData( m_liveRoll.command, out i_z ); // += twist right - - // apply the modifications of the control (deadzone, shape, sensitivity) - x = i_x; y = i_y; z = i_z; // retain real input as i_xyz - m_flightModel.Velocity = Vector3d.Zero; - - // Yaw - if ( yaw ) { - double fout = m_liveYaw.ScaledOut( x ); // 0 .. 1000.0 - lblYInput.Text = ( i_x / 1000.0 ).ToString( "0.00" ); lblYOutput.Text = ( fout ).ToString( "0.00" ); - // calculate new direction vector - m.X = m_liveYaw.InvertedSign * ( ( !cbYuse.Checked ) ? fout : 0 ) * m_msElapsed * DegPerMS; - } - - // Pitch - if ( pitch ) { - double fout = m_livePitch.ScaledOut( y ); // 0 .. 1000.0 - lblPInput.Text = ( i_y / 1000.0 ).ToString( "0.00" ); lblPOutput.Text = ( fout ).ToString( "0.00" ); - // calculate new direction vector - m.Y = m_livePitch.InvertedSign * ( ( !cbPuse.Checked ) ? -fout : 0 ) * m_msElapsed * DegPerMS; // 20170801: fix - Must use inverted out value - } - - // Roll - if ( roll ) { - double fout = m_liveRoll.ScaledOut( z ); // 0 .. 1000.0 - lblRInput.Text = ( i_z / 1000.0 ).ToString( "0.00" ); lblROutput.Text = ( fout ).ToString( "0.00" ); - // calculate new direction vector - m.Z = m_liveRoll.InvertedSign * ( ( !cbRuse.Checked ) ? fout : 0 ) * m_msElapsed * DegPerMS; - } - - return m; - } - - - /// - /// Handle user input while Idle - /// - /// - /// - void Application_Idle( object sender, EventArgs e ) - { - // no guard needed -- we hooked into the event in Load handler - if ( glControl1.IsDisposed ) return; - if ( glControl1.Context == null ) return; - - while ( glControl1.IsIdle ) { - Vector3d m = Vector3d.Zero; ; - // calculate the aim change while the user is handling the control (integrating the amount of control) - Int64 newTick = DateTime.Now.Ticks; - m_msElapsed = ( newTick - m_ticks ) / TimeSpan.TicksPerMillisecond; - if ( m_msElapsed < m_frameTime ) { - // lblDebug.Text = "F"; - continue; //pace updates the max frametime allowed + loaded = true; } - //lblDebug.Text = "R"; - - // safeguard against locking (moving the window) so the integrator does not get crazy.. - // if deltatime gets too big we fake a regular cycle for this round - if ( m_msElapsed > 200 ) m_msElapsed = m_frameTime; - m_ticks = newTick; // prep next run - // query the Joysticks for the 3 controls and fill the flight model vector - if ( m_isStrafe ) { - m = Idle_Strafe( ); + private void glControl1_Paint(object sender, PaintEventArgs e) + { + if (!loaded) return; + Render(); } - else { - m = Idle_YPR( ); - } - - // finalize - m_flightModel.Velocity -= m; // new direction change vector - Vector3d deltaAngleV = m_flightModel.Integrate( (double)m_msElapsed / 1000.0, m_damping, 85.0 ); // heuristic K and B .. - - // rotate the view along the input - // rotDeg( m ); - rotDeg( deltaAngleV ); - - // render once more - Render( ); - - }//while - } - - #endregion - - #region Event Handling - #region turnspeed things - - private void rbAurora_CheckedChanged( object sender, EventArgs e ) - { - slDamping.Value = 6; - slTurnSpeed.Value = 10; - } - - private void rb300i_CheckedChanged( object sender, EventArgs e ) - { - slDamping.Value = 6; - slTurnSpeed.Value = 8; // turns in 4 seconds 360deg - } - - private void rbHornet_CheckedChanged( object sender, EventArgs e ) - { - slDamping.Value = 6; - slTurnSpeed.Value = 12; - } - - private void slTurnSpeed_ValueChanged( object sender, EventArgs e ) - { - // recalc the turning scale based on one full 360 deg sweep in the given time (sec) - DegPerMS = 360.0 / ( slTurnSpeed.Value * 500.0 ); // slider is 0.5 sec steps - lblTurnspeed.Text = ( slTurnSpeed.Value / 2.0 ).ToString( ); - } - - private void slDamping_ValueChanged( object sender, EventArgs e ) - { - m_damping = ( slDamping.Maximum - slDamping.Value + 1 ) * 100.0; // 100 .. 1000 - lblDamping.Text = slDamping.Value.ToString( ); - } - - #endregion - - #region Tune Kind Changed - - private void rbTuneYPR_CheckedChanged( object sender, EventArgs e ) - { - if ( rbTuneYPR.Checked ) { - m_isStrafe = false; - lblYaw.Text = "Yaw"; lblLiveYaw.Text = "Yaw"; rbY.Text = "Yaw -->"; - lblPitch.Text = "Pitch"; lblLivePitch.Text = "Pitch"; rbP.Text = "Pitch -->"; - lblRoll.Text = "Roll"; lblLiveRoll.Text = "Roll"; rbR.Text = "Roll -->"; - tlpData.BackColor = rbTuneYPR.BackColor; - pnlAxisSelector.BackColor = rbTuneYPR.BackColor; - RollUpdateGUIFromLiveValues( ); - PitchUpdateGUIFromLiveValues( ); - YawUpdateGUIFromLiveValues( ); - } - } - - private void rbTuneStrafe_CheckedChanged( object sender, EventArgs e ) - { - if ( rbTuneStrafe.Checked ) { - m_isStrafe = true; - lblYaw.Text = "Lat"; lblLiveYaw.Text = "Lateral"; rbY.Text = "Lateral -->"; - lblPitch.Text = "Vert"; lblLivePitch.Text = "Vertical"; rbP.Text = "Vertical -->"; - lblRoll.Text = "Lon"; lblLiveRoll.Text = "Long."; rbR.Text = "Longitudinal -->"; - tlpData.BackColor = rbTuneStrafe.BackColor; - pnlAxisSelector.BackColor = rbTuneStrafe.BackColor; - StrafeLonUpdateGUIFromLiveValues( ); - StrafeVertUpdateGUIFromLiveValues( ); - StrafeLatUpdateGUIFromLiveValues( ); - } - } - - #endregion - - #region Active Axis Changed - - copy data from left labels into the working area - - /// - /// Make Yaw Active - copy data from left labels into the working area - /// - private void rbY_CheckedChanged() - { - if ( rbY.Checked == true ) { - // get Labels from left area (current) - lblIn[1].Text = lblYin1.Text; lblIn[2].Text = lblYin2.Text; lblIn[3].Text = lblYin3.Text; - lblOut[1].Text = lblYout1.Text; lblOut[2].Text = lblYout2.Text; lblOut[3].Text = lblYout3.Text; - lblOut[4].Text = lblYexponent.Text; - lblNodetext.Text = lblYnt.Text; - // setup chart along the choosen parameter - rbPtDeadzone.Enabled = cbxYdeadzone.Checked; - rbPtSaturation.Enabled = cbxYsat.Checked; - - rbPtDeadzone.Checked = true; - if ( rbPtDeadzone.Enabled ) { - tbSlider.Value = Deviceoptions.DeadzoneToSlider( lblYdeadzone.Text ); - } - else { - rbPtSaturation.Checked = true; - if ( rbPtSaturation.Enabled ) { - tbSlider.Value = Deviceoptions.SaturationToSlider( lblYsat.Text ); - } - } - UpdateChartItems( ); - } - } - private void rbY_CheckedChanged( object sender, EventArgs e ) - { - rbY_CheckedChanged( ); - } - private void rbY_CheckUpdate() - { - rbY.Checked = false; rbY.Checked = true; // forces to check and to update in case of already checked - } - - - /// - /// Make Pitch Active - copy data from left labels into the working area - /// - private void rbP_CheckedChanged() - { - if ( rbP.Checked == true ) { - // get Labels from left area (current) - lblIn[1].Text = lblPin1.Text; lblIn[2].Text = lblPin2.Text; lblIn[3].Text = lblPin3.Text; - lblOut[1].Text = lblPout1.Text; lblOut[2].Text = lblPout2.Text; lblOut[3].Text = lblPout3.Text; - lblOut[4].Text = lblPexponent.Text; - lblNodetext.Text = lblPnt.Text; - // setup chart along the choosen parameter - rbPtDeadzone.Enabled = cbxPdeadzone.Checked; - rbPtSaturation.Enabled = cbxPsat.Checked; - - rbPtDeadzone.Checked = true; - if ( rbPtDeadzone.Enabled ) { - tbSlider.Value = Deviceoptions.DeadzoneToSlider( lblPdeadzone.Text ); - } - else { - rbPtSaturation.Checked = true; // force back to sense (available for both..) - if ( rbPtSaturation.Enabled ) { - tbSlider.Value = Deviceoptions.SaturationToSlider( lblPsat.Text ); - } - } - UpdateChartItems( ); - } - } - private void rbP_CheckedChanged( object sender, EventArgs e ) - { - rbP_CheckedChanged( ); - } - private void rbP_CheckUpdate() - { - rbP.Checked = false; rbP.Checked = true; // forces to check and to update in case of already checked - } - - /// - /// Make Roll Active - copy data from left labels into the working area - /// - private void rbR_CheckedChanged() - { - if ( rbR.Checked == true ) { - // get Labels from left area (current) - lblIn[1].Text = lblRin1.Text; lblIn[2].Text = lblRin2.Text; lblIn[3].Text = lblRin3.Text; - lblOut[1].Text = lblRout1.Text; lblOut[2].Text = lblRout2.Text; lblOut[3].Text = lblRout3.Text; - lblOut[4].Text = lblRexponent.Text; - lblNodetext.Text = lblRnt.Text; - // setup chart along the choosen parameter - rbPtDeadzone.Enabled = cbxRdeadzone.Checked; - rbPtSaturation.Enabled = cbxRsat.Checked; - - rbPtDeadzone.Checked = true; - if ( rbPtDeadzone.Enabled ) { - tbSlider.Value = Deviceoptions.DeadzoneToSlider( lblRdeadzone.Text ); - } - else { - rbPtSaturation.Checked = true; // force back to sense (available for both..) - if ( rbPtSaturation.Enabled ) { - tbSlider.Value = Deviceoptions.SaturationToSlider( lblRsat.Text ); - } - } - UpdateChartItems( ); - } - } - private void rbR_CheckedChanged( object sender, EventArgs e ) - { - rbR_CheckedChanged( ); - } - private void rbR_CheckUpdate() - { - rbR.Checked = false; rbR.Checked = true; // forces to check and to update in case of already checked - } - - // Interaction helper - changes panel on mouse up - - private void pnlYaw_MouseUp( object sender, System.Windows.Forms.MouseEventArgs e ) - { - rbY_CheckUpdate( ); - } - - private void pnlPitch_MouseUp( object sender, System.Windows.Forms.MouseEventArgs e ) - { - rbP_CheckUpdate( ); - } - - private void pnlRoll_MouseUp( object sender, System.Windows.Forms.MouseEventArgs e ) - { - rbR_CheckUpdate( ); - } - - #endregion - - #region Charts section - - // Chart - move Pts - - /// - /// Evaluate which tune parameter has the chart input - /// - private void EvalChartInput() - { - m_hitPt = 0; - if ( rbPt1.Enabled && rbPt1.Checked ) m_hitPt = 1; - if ( rbPt2.Enabled && rbPt2.Checked ) m_hitPt = 2; - if ( rbPt3.Enabled && rbPt3.Checked ) m_hitPt = 3; - if ( rbPtExponent.Enabled && rbPtExponent.Checked ) m_hitPt = 4; - - if ( m_hitPt > 0 ) return; - - // slider fudge - tbSlider.Enabled = false; - if ( rbPtDeadzone.Enabled && rbPtDeadzone.Checked ) { - tbSlider.Enabled = true; - if ( rbY.Checked ) { - tbSlider.Value = Deviceoptions.DeadzoneToSlider( lblYdeadzone.Text ); - } - else if ( rbP.Checked ) { - tbSlider.Value = Deviceoptions.DeadzoneToSlider( lblPdeadzone.Text ); + private void glControl1_Resize(object sender, EventArgs e) + { + SetupViewport(); + if (m_bSeries != null) m_bSeries.Invalidate(chart1); + else chart1.Invalidate(); } - else if ( rbR.Checked ) { - tbSlider.Value = Deviceoptions.DeadzoneToSlider( lblRdeadzone.Text ); - } - } - if ( rbPtSaturation.Enabled && rbPtSaturation.Checked ) { - tbSlider.Enabled = true; - if ( rbY.Checked ) { - tbSlider.Value = Deviceoptions.SaturationToSlider( lblYsat.Text ); - } - else if ( rbP.Checked ) { - tbSlider.Value = Deviceoptions.SaturationToSlider( lblPsat.Text ); - } - else if ( rbR.Checked ) { - tbSlider.Value = Deviceoptions.SaturationToSlider( lblRsat.Text ); - } - } - EvalSlider( ); - } - - - /// - /// Handle change of the mouse input within the chart - /// - private void rbPtAny_CheckedChanged( object sender, EventArgs e ) - { - EvalChartInput( ); - } - - // handle mouse interaction with the chart - int m_hitPt = 0; - bool m_hitActive = false; - int mX = 0; int mY = 0; + /// + /// Helper method to avoid code duplication. + /// Compiles a shader and prints results using Debug.WriteLine. + /// + /// A shader object, gotten from GL.CreateShader. + /// The GLSL source to compile. + void compileShader(int shader, string source) + { + GL.ShaderSource(shader, source); + GL.CompileShader(shader); - /// - /// Update the graph from changes of acitve label values - /// - private void UpdateChartItems() - { - bool deadzoneUsed = true; - bool satUsed = true; - bool expUsed = true; - bool ptsUsed = true; - // see what is on display.. - if ( rbY.Checked == true ) { - // Yaw - if ( m_isStrafe ) { - deadzoneUsed = ( m_liveStrafeLat.deadzoneUsed == true ); - satUsed = ( m_liveStrafeLat.saturationUsed == true ); - expUsed = ( m_liveStrafeLat.exponentUsed == true ); - ptsUsed = ( m_liveStrafeLat.nonLinCurveUsed == true ); - lblGraphDeadzone.Text = m_liveStrafeLat.deadzoneS; - lblGraphSaturation.Text = m_liveStrafeLat.saturationS; - - } - else { - deadzoneUsed = ( m_liveYaw.deadzoneUsed == true ); - satUsed = ( m_liveYaw.saturationUsed == true ); - expUsed = ( m_liveYaw.exponentUsed == true ); - ptsUsed = ( m_liveYaw.nonLinCurveUsed == true ); - lblGraphDeadzone.Text = m_liveYaw.deadzoneS; - lblGraphSaturation.Text = m_liveYaw.saturationS; - } - chart1.BackColor = rbY.BackColor; - - } - else if ( rbP.Checked == true ) { - // Pitch - if ( m_isStrafe ) { - deadzoneUsed = ( m_liveStrafeVert.deadzoneUsed == true ); - satUsed = ( m_liveStrafeVert.saturationUsed == true ); - expUsed = ( m_liveStrafeVert.exponentUsed == true ); - ptsUsed = ( m_liveStrafeVert.nonLinCurveUsed == true ); - lblGraphDeadzone.Text = m_liveStrafeVert.deadzoneS; - lblGraphSaturation.Text = m_liveStrafeVert.saturationS; - } - else { - deadzoneUsed = ( m_livePitch.deadzoneUsed == true ); - satUsed = ( m_livePitch.saturationUsed == true ); - expUsed = ( m_livePitch.exponentUsed == true ); - ptsUsed = ( m_livePitch.nonLinCurveUsed == true ); - lblGraphDeadzone.Text = m_livePitch.deadzoneS; - lblGraphSaturation.Text = m_livePitch.saturationS; - } - chart1.BackColor = rbP.BackColor; - - } - else { - // Roll - if ( m_isStrafe ) { - deadzoneUsed = ( m_liveStrafeLon.deadzoneUsed == true ); - satUsed = ( m_liveStrafeLon.saturationUsed == true ); - expUsed = ( m_liveStrafeLon.exponentUsed == true ); - ptsUsed = ( m_liveStrafeLon.nonLinCurveUsed == true ); - lblGraphDeadzone.Text = m_liveStrafeLon.deadzoneS; - lblGraphSaturation.Text = m_liveStrafeLon.saturationS; - } - else { - deadzoneUsed = ( m_liveRoll.deadzoneUsed == true ); - satUsed = ( m_liveRoll.saturationUsed == true ); - expUsed = ( m_liveRoll.exponentUsed == true ); - ptsUsed = ( m_liveRoll.nonLinCurveUsed == true ); - lblGraphDeadzone.Text = m_liveRoll.deadzoneS; - lblGraphSaturation.Text = m_liveRoll.saturationS; - } - chart1.BackColor = rbR.BackColor; - } - - // generic part - rbPtDeadzone.Enabled = deadzoneUsed; - lblGraphDeadzone.Visible = deadzoneUsed; - - rbPtSaturation.Enabled = satUsed; - lblGraphSaturation.Visible = satUsed; - - rbPtExponent.Enabled = expUsed; - rbPt1.Enabled = ptsUsed; rbPt2.Enabled = ptsUsed; rbPt3.Enabled = ptsUsed; - EvalChartInput( ); // review active chart input - - if ( !tbSlider.Enabled ) lblOutSlider.Text = "---"; - - if ( expUsed ) { - // Exp mode - double expo = double.Parse( lblOut[4].Text ); - // dont touch zero Point - m_bSeries.BezierPoints[1].SetValueXY( 0.25, Math.Pow( 0.25, expo ) ); - m_bSeries.BezierPoints[2].SetValueXY( 0.5, Math.Pow( 0.5, expo ) ); - m_bSeries.BezierPoints[3].SetValueXY( 0.75, Math.Pow( 0.75, expo ) ); - m_bSeries.BezierPoints[4].SetValueXY( 1.0, 1.0 ); - - } - else if ( ptsUsed ) { - // Pts mode - // dont touch zero Point - for ( int i = 1; i <= 3; i++ ) { - m_bSeries.BezierPoints[i].SetValueXY( float.Parse( lblIn[i].Text ), float.Parse( lblOut[i].Text ) ); - } - m_bSeries.BezierPoints[4].SetValueXY( 1.0, 1.0 ); - - } - else { - // linear - // dont touch zero Point - m_bSeries.BezierPoints[1].SetValueXY( 0.25, 0.25 ); - m_bSeries.BezierPoints[2].SetValueXY( 0.5, 0.5 ); - m_bSeries.BezierPoints[3].SetValueXY( 0.75, 0.75 ); - m_bSeries.BezierPoints[4].SetValueXY( 1.0, 1.0 ); - } - // update markers from curve points - chart1.Series[1].Points[1] = m_bSeries.BezierPoints[1]; - chart1.Series[1].Points[2] = m_bSeries.BezierPoints[2]; - chart1.Series[1].Points[3] = m_bSeries.BezierPoints[3]; - chart1.Series[1].Points[4] = m_bSeries.BezierPoints[4]; - - m_bSeries.Invalidate( chart1 ); - } - - - - private void chartPoint_MouseDown( object sender, System.Windows.Forms.MouseEventArgs e ) - { - m_hitActive = true; // activate movement tracking - mX = e.X; mY = e.Y; // save initial loc to get deltas - } - - private void chartPoint_MouseMove( object sender, System.Windows.Forms.MouseEventArgs e ) - { - if ( m_hitActive ) { - if ( m_hitPt < 1 ) { - // nothing selected ... - } - else if ( m_hitPt <= 3 ) { - // Pt1..3 - double newX = double.Parse( lblIn[m_hitPt].Text ) + ( e.X - mX ) * 0.001f; mX = e.X; - newX = ( newX > 1.0f ) ? 1.0f : newX; - newX = ( newX < 0.0f ) ? 0.0f : newX; - lblIn[m_hitPt].Text = newX.ToString( "0.000" ); - - double newY = double.Parse( lblOut[m_hitPt].Text ) + ( e.Y - mY ) * -0.001f; mY = e.Y; - newY = ( newY > 1.0f ) ? 1.0f : newY; - newY = ( newY < 0.0f ) ? 0.0f : newY; - lblOut[m_hitPt].Text = newY.ToString( "0.000" ); - - // update chart (Points[0] is zero) - m_bSeries.BezierPoints[m_hitPt].SetValueXY( newX, newY ); - // update markers from curve points - chart1.Series[1].Points[m_hitPt] = m_bSeries.BezierPoints[m_hitPt]; - - } - else if ( m_hitPt == 4 ) { - // Exponent - double newY = double.Parse( lblOut[m_hitPt].Text ) + ( e.Y - mY ) * 0.01f; mY = e.Y; - newY = ( newY > 3.0f ) ? 3.0f : newY; - newY = ( newY < 0.5f ) ? 0.5f : newY; - lblOut[m_hitPt].Text = newY.ToString( "0.00" ); - - // update chart (Points[0] is zero) - m_bSeries.BezierPoints[1].SetValueXY( 0.25, Math.Pow( 0.25, newY ) ); - m_bSeries.BezierPoints[2].SetValueXY( 0.5, Math.Pow( 0.5, newY ) ); - m_bSeries.BezierPoints[3].SetValueXY( 0.75, Math.Pow( 0.75, newY ) ); - } - - // update markers from curve points - chart1.Series[1].Points[1] = m_bSeries.BezierPoints[1]; - chart1.Series[1].Points[2] = m_bSeries.BezierPoints[2]; - chart1.Series[1].Points[3] = m_bSeries.BezierPoints[3]; - chart1.Series[1].Points[4] = m_bSeries.BezierPoints[4]; - - m_bSeries.Invalidate( chart1 ); - - } - } + string info; + GL.GetShaderInfoLog(shader, out info); + Trace.WriteLine(info); - private void chartPoint_MouseUp( object sender, System.Windows.Forms.MouseEventArgs e ) - { - m_hitActive = false; - - // update the rest of the fields from Entry - - if ( rbY.Checked == true ) { - // left area labels - lblYin1.Text = lblIn[1].Text; lblYin2.Text = lblIn[2].Text; lblYin3.Text = lblIn[3].Text; - lblYout1.Text = lblOut[1].Text; lblYout2.Text = lblOut[2].Text; lblYout3.Text = lblOut[3].Text; - lblYexponent.Text = lblOut[4].Text; - // update live values - if ( m_isStrafe ) { - m_liveStrafeLat.exponentS = lblYexponent.Text; - if ( m_liveStrafeLat.nonLinCurve != null ) { - m_liveStrafeLat.nonLinCurve.Curve( float.Parse( lblYin1.Text ), float.Parse( lblYout1.Text ), - float.Parse( lblYin2.Text ), float.Parse( lblYout2.Text ), - float.Parse( lblYin3.Text ), float.Parse( lblYout3.Text ) ); - } - } - else { - m_liveYaw.exponentS = lblYexponent.Text; - if ( m_liveYaw.nonLinCurve != null ) { - m_liveYaw.nonLinCurve.Curve( float.Parse( lblYin1.Text ), float.Parse( lblYout1.Text ), - float.Parse( lblYin2.Text ), float.Parse( lblYout2.Text ), - float.Parse( lblYin3.Text ), float.Parse( lblYout3.Text ) ); - } - } - - } - else if ( rbP.Checked == true ) { - // left area labels - lblPin1.Text = lblIn[1].Text; lblPin2.Text = lblIn[2].Text; lblPin3.Text = lblIn[3].Text; - lblPout1.Text = lblOut[1].Text; lblPout2.Text = lblOut[2].Text; lblPout3.Text = lblOut[3].Text; - lblPexponent.Text = lblOut[4].Text; - // update live values - if ( m_isStrafe ) { - m_liveStrafeVert.exponentS = lblPexponent.Text; - if ( m_liveStrafeVert.nonLinCurve != null ) { - m_liveStrafeVert.nonLinCurve.Curve( float.Parse( lblPin1.Text ), float.Parse( lblPout1.Text ), - float.Parse( lblPin2.Text ), float.Parse( lblPout2.Text ), - float.Parse( lblPin3.Text ), float.Parse( lblPout3.Text ) ); - } - } - else { - m_livePitch.exponentS = lblPexponent.Text; - if ( m_livePitch.nonLinCurve != null ) { - m_livePitch.nonLinCurve.Curve( float.Parse( lblPin1.Text ), float.Parse( lblPout1.Text ), - float.Parse( lblPin2.Text ), float.Parse( lblPout2.Text ), - float.Parse( lblPin3.Text ), float.Parse( lblPout3.Text ) ); - } - } - - } - else if ( rbR.Checked == true ) { - // left area labels - lblRin1.Text = lblIn[1].Text; lblRin2.Text = lblIn[2].Text; lblRin3.Text = lblIn[3].Text; - lblRout1.Text = lblOut[1].Text; lblRout2.Text = lblOut[2].Text; lblRout3.Text = lblOut[3].Text; - lblRexponent.Text = lblOut[4].Text; - // update live values - if ( m_isStrafe ) { - m_liveStrafeLon.exponentS = lblRexponent.Text; - if ( m_liveStrafeLon.nonLinCurve != null ) { - m_liveStrafeLon.nonLinCurve.Curve( float.Parse( lblRin1.Text ), float.Parse( lblRout1.Text ), - float.Parse( lblRin2.Text ), float.Parse( lblRout2.Text ), - float.Parse( lblRin3.Text ), float.Parse( lblRout3.Text ) ); - } - } - else { - m_liveRoll.exponentS = lblRexponent.Text; - if ( m_liveRoll.nonLinCurve != null ) { - m_liveRoll.nonLinCurve.Curve( float.Parse( lblRin1.Text ), float.Parse( lblRout1.Text ), - float.Parse( lblRin2.Text ), float.Parse( lblRout2.Text ), - float.Parse( lblRin3.Text ), float.Parse( lblRout3.Text ) ); - } - } - - } - } - #endregion - - #region Checked Invert Changed - - private void cbxYinvert_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeLat.invertUsed = false; - if ( cbxYinvert.Checked == true ) { - m_liveStrafeLat.invertUsed = true; - } - } - else { - m_liveYaw.invertUsed = false; - if ( cbxYinvert.Checked == true ) { - m_liveYaw.invertUsed = true; - } - } - rbY_CheckUpdate( ); - } - - private void cbxPinvert_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeVert.invertUsed = false; - if ( cbxPinvert.Checked == true ) { - m_liveStrafeVert.invertUsed = true; - } - } - else { - m_livePitch.invertUsed = false; - if ( cbxPinvert.Checked == true ) { - m_livePitch.invertUsed = true; - } - } - rbP_CheckUpdate( ); - } - - private void cbxRinvert_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeLon.invertUsed = false; - if ( cbxRinvert.Checked == true ) { - m_liveStrafeLon.invertUsed = true; - } - } - else { - m_liveRoll.invertUsed = false; - if ( cbxRinvert.Checked == true ) { - m_liveRoll.invertUsed = true; - } - } - rbR_CheckUpdate( ); - } - - #endregion - - #region Slider Value Changed (Deadzone / Saturation) - - // Deadzone slider 00 .. 40 -> 0 .. 0.160 ( 4 pt scale) - // Saturation slider 00 .. 40 -> 0.2 .. 1.0 ( 20 pt scale) - - private void EvalSlider() - { - if ( rbPtDeadzone.Enabled && rbPtDeadzone.Checked ) { - lblOutSlider.Text = Deviceoptions.DeadzoneFromSlider( tbSlider.Value ).ToString( "0.000" ); - float curDeadzone = 1000.0f * Deviceoptions.DeadzoneFromSlider( tbSlider.Value ); // % scaled to maxAxis - - if ( rbY.Checked == true ) { - if ( m_isStrafe ) m_liveStrafeLat.deadzone = curDeadzone; else m_liveYaw.deadzone = curDeadzone; - lblYdeadzone.Text = lblOutSlider.Text; - } - else if ( rbP.Checked == true ) { - if ( m_isStrafe ) m_liveStrafeVert.deadzone = curDeadzone; else m_livePitch.deadzone = curDeadzone; - lblPdeadzone.Text = lblOutSlider.Text; - } - else if ( rbR.Checked == true ) { - if ( m_isStrafe ) m_liveStrafeLon.deadzone = curDeadzone; else m_liveRoll.deadzone = curDeadzone; - lblRdeadzone.Text = lblOutSlider.Text; - } - lblGraphDeadzone.Text = lblOutSlider.Text; - } - else if ( rbPtSaturation.Enabled && rbPtSaturation.Checked ) { - lblOutSlider.Text = Deviceoptions.SaturationFromSlider( tbSlider.Value ).ToString( "0.000" ); - float curSaturation = 1000.0f * Deviceoptions.SaturationFromSlider( tbSlider.Value ); // % scaled to maxAxis - - if ( rbY.Checked == true ) { - if ( m_isStrafe ) m_liveStrafeLat.saturation = curSaturation; else m_liveYaw.saturation = curSaturation; - lblYsat.Text = lblOutSlider.Text; - } - else if ( rbP.Checked == true ) { - if ( m_isStrafe ) m_liveStrafeVert.saturation = curSaturation; else m_livePitch.saturation = curSaturation; - lblPsat.Text = lblOutSlider.Text; - } - else if ( rbR.Checked == true ) { - if ( m_isStrafe ) m_liveStrafeLon.saturation = curSaturation; else m_liveRoll.saturation = curSaturation; - lblRsat.Text = lblOutSlider.Text; - } - lblGraphSaturation.Text = lblOutSlider.Text; - } - } - - private void tbSlider_ValueChanged( object sender, EventArgs e ) - { - EvalSlider( ); - } + int compileResult; + GL.GetShader(shader, ShaderParameter.CompileStatus, out compileResult); + if (compileResult != 1) + { + log.Error("compileShader - Compile Error:"); + log.Error(source); + } + } - #endregion - #region Checked Deadzone Changed - private void cbxYdeadzone_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeLat.deadzoneUsed = false; - if ( cbxYdeadzone.Checked == true ) { - m_liveStrafeLat.deadzoneUsed = true; - } - } - else { - m_liveYaw.deadzoneUsed = false; - if ( cbxYdeadzone.Checked == true ) { - m_liveYaw.deadzoneUsed = true; - } - } - rbY_CheckUpdate( ); - rbPtDeadzone.Checked = cbxYdeadzone.Checked; - UpdateChartItems( ); - } + private void SetupViewport() + { + int w = glControl1.Width; + int h = glControl1.Height; - private void cbxPdeadzone_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeVert.deadzoneUsed = false; - if ( cbxPdeadzone.Checked == true ) { - m_liveStrafeVert.deadzoneUsed = true; - } - } - else { - m_livePitch.deadzoneUsed = false; - if ( cbxPdeadzone.Checked == true ) { - m_livePitch.deadzoneUsed = true; - } - } - rbP_CheckUpdate( ); - rbPtDeadzone.Checked = cbxPdeadzone.Checked; - UpdateChartItems( ); - } + GL.Viewport(0, 0, w, h); // Use all of the glControl painting area - private void cbxRdeadzone_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeLon.deadzoneUsed = false; - if ( cbxRdeadzone.Checked == true ) { - m_liveStrafeLon.deadzoneUsed = true; // update storage - } - } - else { - m_liveRoll.deadzoneUsed = false; - if ( cbxRdeadzone.Checked == true ) { - m_liveRoll.deadzoneUsed = true; // update storage - } - } - rbR_CheckUpdate( ); - rbPtDeadzone.Checked = cbxRdeadzone.Checked; - UpdateChartItems( ); - } + GL.MatrixMode(MatrixMode.Projection); + Matrix4 p = Matrix4.CreatePerspectiveFieldOfView(MathHelper.PiOver4, w / (float)h, 0.1f, 10.0f); + GL.LoadMatrix(ref p); - #endregion + GL.MatrixMode(MatrixMode.Modelview); + GL.LoadIdentity(); + } - #region Checked Saturation Changed + // One render cycle - beware this should be fast... + private void Render() + { + if (!loaded) return; - private void cbxYsense_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeLat.saturationUsed = false; - if ( cbxYsat.Checked == true ) { - m_liveStrafeLat.saturationUsed = true; - } - } - else { - m_liveYaw.saturationUsed = false; - if ( cbxYsat.Checked == true ) { - m_liveYaw.saturationUsed = true; - } - } - rbY_CheckUpdate( ); - rbPtSaturation.Checked = cbxYsat.Checked; - UpdateChartItems( ); - } + GL.Clear(ClearBufferMask.ColorBufferBit | ClearBufferMask.DepthBufferBit); - private void cbxPsense_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeVert.saturationUsed = false; - if ( cbxPsat.Checked == true ) { - m_liveStrafeVert.saturationUsed = true; - } - } - else { - m_livePitch.saturationUsed = false; - if ( cbxPsat.Checked == true ) { - m_livePitch.saturationUsed = true; - } - } - rbP_CheckUpdate( ); - rbPtSaturation.Checked = cbxPsat.Checked; - UpdateChartItems( ); - } + GL.UseProgram(ProgramObject); // use the compiled shader - private void cbxRsense_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeLon.saturationUsed = false; - if ( cbxRsat.Checked == true ) { - m_liveStrafeLon.saturationUsed = true; - } - } - else { - m_liveRoll.saturationUsed = false; - if ( cbxRsat.Checked == true ) { - m_liveRoll.saturationUsed = true; - } - } - rbR_CheckUpdate( ); - rbPtSaturation.Checked = cbxRsat.Checked; - UpdateChartItems( ); - } + // interface with shader variables + GL.Uniform1(GL.GetUniformLocation(ProgramObject, "Skybox"), TMU0_UnitInteger); - #endregion + // get our own matrix + GL.PushMatrix(); + GL.LoadIdentity(); // Reset and transform the matrix. - #region Checked Exponent Changed + // part of the 3D orientation - the rest is in the idle routine + Matrix4d rm = new Matrix4d(m_right.X, m_right.Y, m_right.Z, 0, + m_up.X, m_up.Y, m_up.Z, 0, + m_front.X, m_front.Y, m_front.Z, 0, + 0, 0, 0, 1); + GL.MultMatrix(ref rm); // transform - private void cbxYexpo_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeLat.exponentUsed = false; - if ( cbxYexpo.Checked == true ) { - m_liveStrafeLat.exponentUsed = true; - cbxYpts.Checked = false; // forced: either expo OR points - } - } - else { - m_liveYaw.exponentUsed = false; - if ( cbxYexpo.Checked == true ) { - m_liveYaw.exponentUsed = true; - cbxYpts.Checked = false; // forced: either expo OR points - } - } - rbY_CheckUpdate( ); - UpdateChartItems( ); - } + // Enable/Disable features + GL.PushAttrib(AttribMask.EnableBit); + GL.DepthMask(false); + GL.Disable(EnableCap.DepthTest); + GL.Disable(EnableCap.Lighting); + GL.Disable(EnableCap.Blend); - private void cbxPexpo_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeVert.exponentUsed = false; - if ( cbxPexpo.Checked == true ) { - m_liveStrafeVert.exponentUsed = true; - cbxPpts.Checked = false; // forced: either expo OR points - } - } - else { - m_livePitch.exponentUsed = false; - if ( cbxPexpo.Checked == true ) { - m_livePitch.exponentUsed = true; - cbxPpts.Checked = false; // forced: either expo OR points - } - } - rbP_CheckUpdate( ); - UpdateChartItems( ); - } + // use the Skybox texture + GL.ActiveTexture(TMU0_Unit); + GL.BindTexture(TMU0_Target, TMU0_Handle); - private void cbxRexpo_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeLon.exponentUsed = false; - if ( cbxRexpo.Checked == true ) { - m_liveStrafeLon.exponentUsed = true; - cbxRpts.Checked = false; // forced: either expo OR points - } - } - else { - m_liveRoll.exponentUsed = false; - if ( cbxRexpo.Checked == true ) { - m_liveRoll.exponentUsed = true; - cbxRpts.Checked = false; // forced: either expo OR points - } - } - rbR_CheckUpdate( ); - UpdateChartItems( ); - } + // Draw + GL.Color3(1f, 1f, 1f); // Just in case we set all vertices to white. - #endregion + // draw one Quad only + GL.Begin(PrimitiveType.Quads); + { + GL.Vertex3(-1.0, -1.0, 0.0); + GL.Vertex3(1.0, -1.0, 0.0); + GL.Vertex3(1.0, 1.0, 0.0); + GL.Vertex3(-1.0, 1.0, 0.0); + } + GL.End(); + + // END Draw - #region Checked Points Changed - private void cbxYpts_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeLat.nonLinCurveUsed = false; - if ( cbxYpts.Checked == true ) { - m_liveStrafeLat.nonLinCurveUsed = true; - cbxYexpo.Checked = false; // forced: either expo OR points - } - } - else { - m_liveYaw.nonLinCurveUsed = false; - if ( cbxYpts.Checked == true ) { - m_liveYaw.nonLinCurveUsed = true; - cbxYexpo.Checked = false; // forced: either expo OR points - } - } - rbY_CheckUpdate( ); - UpdateChartItems( ); - } + // Restore enable bits and matrix + GL.PopAttrib(); + GL.PopMatrix(); + + // finally show the contents + glControl1.SwapBuffers(); + } + + #endregion + + + #region Joystick Input Handling + + /// + /// Proper 3D camera aiming... + /// Thanks: http://tutorialrandom.blogspot.ch/2012/08/how-to-rotate-in-3d-using-opengl-proper.html + /// + /// + Vector3d m_right = Vector3d.UnitX; + Vector3d m_up = Vector3d.UnitY; + Vector3d m_front = Vector3d.UnitZ; + + /// + /// Calc the view vector - take care of changing axis orientations + /// + /// Right-Left Direction + /// Up-Down Direction + /// RotLeft - RotRight Direction + private void rotDeg(Vector3d dir) + { + Matrix4d temp = Matrix4d.CreateRotationX(MathHelper.DegreesToRadians(dir.Y));// invert y-> x + m_right = Vector3d.TransformVector(m_right, temp); + m_up = Vector3d.TransformVector(m_up, temp); + m_front = Vector3d.TransformVector(m_front, temp); + + temp = Matrix4d.CreateRotationY(MathHelper.DegreesToRadians(dir.X)); // invert x-> y + m_right = Vector3d.TransformVector(m_right, temp); + m_up = Vector3d.TransformVector(m_up, temp); + m_front = Vector3d.TransformVector(m_front, temp); + + temp = Matrix4d.CreateRotationZ(MathHelper.DegreesToRadians(dir.Z)); + m_right = Vector3d.TransformVector(m_right, temp); + m_up = Vector3d.TransformVector(m_up, temp); + m_front = Vector3d.TransformVector(m_front, temp); + } + + + + /// + /// Sub Handler for Strafe + /// + Vector3d Idle_Strafe() + { + Vector3d m = Vector3d.Zero; ; + + bool lat = (m_StrafeLatTuning != null) && (m_StrafeLatTuning.GameDevice != null); + bool vert = (m_StrafeVertTuning != null) && (m_StrafeVertTuning.GameDevice != null); + bool lon = (m_StrafeLonTuning != null) && (m_StrafeLonTuning.GameDevice != null); + + int i_x = 0, i_y = 0, i_z = 0; // Joystick Input + int x = 0; int y = 0; int z = 0; // retain real input as i_xyz + + if (lat) m_StrafeLatTuning.GameDevice.GetCmdData(m_liveStrafeLat.command, out i_x); // + = right + if (vert) m_StrafeVertTuning.GameDevice.GetCmdData(m_liveStrafeVert.command, out i_y); // + = up + if (lon) m_StrafeLonTuning.GameDevice.GetCmdData(m_liveStrafeLon.command, out i_z); // += twist right + // apply the modifications of the control (deadzone, shape, sensitivity) + x = i_x; y = i_y; z = i_z; // retain real input as i_xyz + m_flightModel.Velocity = Vector3d.Zero; + + // Lateral + if (lat) + { + double fout = m_liveStrafeLat.ScaledOut(x); // 0 .. 1000.0 + lblYInput.Text = (i_x / 1000.0).ToString("0.00"); lblYOutput.Text = (fout).ToString("0.00"); + // calculate new direction vector + m.X = m_liveStrafeLat.InvertedSign * ((!cbYuse.Checked) ? fout : 0) * m_msElapsed * DegPerMS; + } + + // Vertical + if (vert) + { + double fout = m_liveStrafeVert.ScaledOut(y); // 0 .. 1000.0 + lblPInput.Text = (i_y / 1000.0).ToString("0.00"); lblPOutput.Text = (fout).ToString("0.00"); + // calculate new direction vector + m.Y = m_liveStrafeVert.InvertedSign * ((!cbPuse.Checked) ? fout : 0) * m_msElapsed * DegPerMS; + } + + // Longitudinal + if (lon) + { + double fout = m_liveStrafeLon.ScaledOut(z); // 0 .. 1000.0 + lblRInput.Text = (i_z / 1000.0).ToString("0.00"); lblROutput.Text = (fout).ToString("0.00"); + // calculate new direction vector + m.Z = m_liveStrafeLon.InvertedSign * ((!cbRuse.Checked) ? fout : 0) * m_msElapsed * DegPerMS; + } + return m; + } + + + /// + /// Sub Handler for YPR (Yaw, Pitch, Roll) + /// + Vector3d Idle_YPR() + { + Vector3d m = Vector3d.Zero; ; + + bool yaw = (m_YawTuning != null) && (m_YawTuning.GameDevice != null); + bool pitch = (m_PitchTuning != null) && (m_PitchTuning.GameDevice != null); + bool roll = (m_RollTuning != null) && (m_RollTuning.GameDevice != null); + + int i_x = 0, i_y = 0, i_z = 0; // Joystick Input + int x = 0; int y = 0; int z = 0; // retain real input as i_xyz + + if (yaw) m_YawTuning.GameDevice.GetCmdData(m_liveYaw.command, out i_x); // + = right + if (pitch) m_PitchTuning.GameDevice.GetCmdData(m_livePitch.command, out i_y); // + = up + if (roll) m_RollTuning.GameDevice.GetCmdData(m_liveRoll.command, out i_z); // += twist right + + // apply the modifications of the control (deadzone, shape, sensitivity) + x = i_x; y = i_y; z = i_z; // retain real input as i_xyz + m_flightModel.Velocity = Vector3d.Zero; + + // Yaw + if (yaw) + { + double fout = m_liveYaw.ScaledOut(x); // 0 .. 1000.0 + lblYInput.Text = (i_x / 1000.0).ToString("0.00"); lblYOutput.Text = (fout).ToString("0.00"); + // calculate new direction vector + m.X = m_liveYaw.InvertedSign * ((!cbYuse.Checked) ? fout : 0) * m_msElapsed * DegPerMS; + } + + // Pitch + if (pitch) + { + double fout = m_livePitch.ScaledOut(y); // 0 .. 1000.0 + lblPInput.Text = (i_y / 1000.0).ToString("0.00"); lblPOutput.Text = (fout).ToString("0.00"); + // calculate new direction vector + m.Y = m_livePitch.InvertedSign * ((!cbPuse.Checked) ? -fout : 0) * m_msElapsed * DegPerMS; // 20170801: fix - Must use inverted out value + } + + // Roll + if (roll) + { + double fout = m_liveRoll.ScaledOut(z); // 0 .. 1000.0 + lblRInput.Text = (i_z / 1000.0).ToString("0.00"); lblROutput.Text = (fout).ToString("0.00"); + // calculate new direction vector + m.Z = m_liveRoll.InvertedSign * ((!cbRuse.Checked) ? fout : 0) * m_msElapsed * DegPerMS; + } + + return m; + } + + + /// + /// Handle user input while Idle + /// + /// + /// + void Application_Idle(object sender, EventArgs e) + { + // no guard needed -- we hooked into the event in Load handler + if (glControl1.IsDisposed) return; + if (glControl1.Context == null) return; + + while (glControl1.IsIdle) + { + Vector3d m = Vector3d.Zero; ; + // calculate the aim change while the user is handling the control (integrating the amount of control) + Int64 newTick = DateTime.Now.Ticks; + m_msElapsed = (newTick - m_ticks) / TimeSpan.TicksPerMillisecond; + if (m_msElapsed < m_frameTime) + { + // lblDebug.Text = "F"; + continue; //pace updates the max frametime allowed + } + //lblDebug.Text = "R"; + + // safeguard against locking (moving the window) so the integrator does not get crazy.. + // if deltatime gets too big we fake a regular cycle for this round + if (m_msElapsed > 200) m_msElapsed = m_frameTime; + + m_ticks = newTick; // prep next run + + // query the Joysticks for the 3 controls and fill the flight model vector + if (m_isStrafe) + { + m = Idle_Strafe(); + } + else + { + m = Idle_YPR(); + } + + // finalize + m_flightModel.Velocity -= m; // new direction change vector + Vector3d deltaAngleV = m_flightModel.Integrate((double)m_msElapsed / 1000.0, m_damping, 85.0); // heuristic K and B .. + + // rotate the view along the input + // rotDeg( m ); + rotDeg(deltaAngleV); + + // render once more + Render(); + + }//while + } + + #endregion + + + #region Event Handling + + #region turnspeed things + + private void rbAurora_CheckedChanged(object sender, EventArgs e) + { + slDamping.Value = 6; + slTurnSpeed.Value = 10; + } + + private void rb300i_CheckedChanged(object sender, EventArgs e) + { + slDamping.Value = 6; + slTurnSpeed.Value = 8; // turns in 4 seconds 360deg + } + + private void rbHornet_CheckedChanged(object sender, EventArgs e) + { + slDamping.Value = 6; + slTurnSpeed.Value = 12; + } + + private void slTurnSpeed_ValueChanged(object sender, EventArgs e) + { + // recalc the turning scale based on one full 360 deg sweep in the given time (sec) + DegPerMS = 360.0 / (slTurnSpeed.Value * 500.0); // slider is 0.5 sec steps + lblTurnspeed.Text = (slTurnSpeed.Value / 2.0).ToString(); + } + + private void slDamping_ValueChanged(object sender, EventArgs e) + { + m_damping = (slDamping.Maximum - slDamping.Value + 1) * 100.0; // 100 .. 1000 + lblDamping.Text = slDamping.Value.ToString(); + } + + #endregion + + #region Tune Kind Changed + + private void rbTuneYPR_CheckedChanged(object sender, EventArgs e) + { + if (rbTuneYPR.Checked) + { + m_isStrafe = false; + lblYaw.Text = "Yaw"; lblLiveYaw.Text = "Yaw"; rbY.Text = "Yaw -->"; + lblPitch.Text = "Pitch"; lblLivePitch.Text = "Pitch"; rbP.Text = "Pitch -->"; + lblRoll.Text = "Roll"; lblLiveRoll.Text = "Roll"; rbR.Text = "Roll -->"; + tlpData.BackColor = rbTuneYPR.BackColor; + pnlAxisSelector.BackColor = rbTuneYPR.BackColor; + RollUpdateGUIFromLiveValues(); + PitchUpdateGUIFromLiveValues(); + YawUpdateGUIFromLiveValues(); + } + } + + private void rbTuneStrafe_CheckedChanged(object sender, EventArgs e) + { + if (rbTuneStrafe.Checked) + { + m_isStrafe = true; + lblYaw.Text = "Lat"; lblLiveYaw.Text = "Lateral"; rbY.Text = "Lateral -->"; + lblPitch.Text = "Vert"; lblLivePitch.Text = "Vertical"; rbP.Text = "Vertical -->"; + lblRoll.Text = "Lon"; lblLiveRoll.Text = "Long."; rbR.Text = "Longitudinal -->"; + tlpData.BackColor = rbTuneStrafe.BackColor; + pnlAxisSelector.BackColor = rbTuneStrafe.BackColor; + StrafeLonUpdateGUIFromLiveValues(); + StrafeVertUpdateGUIFromLiveValues(); + StrafeLatUpdateGUIFromLiveValues(); + } + } + + #endregion + + #region Active Axis Changed - - copy data from left labels into the working area + + /// + /// Make Yaw Active - copy data from left labels into the working area + /// + private void rbY_CheckedChanged() + { + if (rbY.Checked == true) + { + // get Labels from left area (current) + lblIn[1].Text = lblYin1.Text; lblIn[2].Text = lblYin2.Text; lblIn[3].Text = lblYin3.Text; + lblOut[1].Text = lblYout1.Text; lblOut[2].Text = lblYout2.Text; lblOut[3].Text = lblYout3.Text; + lblOut[4].Text = lblYexponent.Text; + lblNodetext.Text = lblYnt.Text; + // setup chart along the choosen parameter + rbPtDeadzone.Enabled = cbxYdeadzone.Checked; + rbPtSaturation.Enabled = cbxYsat.Checked; + + rbPtDeadzone.Checked = true; + if (rbPtDeadzone.Enabled) + { + tbSlider.Value = Deviceoptions.DeadzoneToSlider(lblYdeadzone.Text); + } + else + { + rbPtSaturation.Checked = true; + if (rbPtSaturation.Enabled) + { + tbSlider.Value = Deviceoptions.SaturationToSlider(lblYsat.Text); + } + } + UpdateChartItems(); + } + } + private void rbY_CheckedChanged(object sender, EventArgs e) + { + rbY_CheckedChanged(); + } + private void rbY_CheckUpdate() + { + rbY.Checked = false; rbY.Checked = true; // forces to check and to update in case of already checked + } + + + /// + /// Make Pitch Active - copy data from left labels into the working area + /// + private void rbP_CheckedChanged() + { + if (rbP.Checked == true) + { + // get Labels from left area (current) + lblIn[1].Text = lblPin1.Text; lblIn[2].Text = lblPin2.Text; lblIn[3].Text = lblPin3.Text; + lblOut[1].Text = lblPout1.Text; lblOut[2].Text = lblPout2.Text; lblOut[3].Text = lblPout3.Text; + lblOut[4].Text = lblPexponent.Text; + lblNodetext.Text = lblPnt.Text; + // setup chart along the choosen parameter + rbPtDeadzone.Enabled = cbxPdeadzone.Checked; + rbPtSaturation.Enabled = cbxPsat.Checked; + + rbPtDeadzone.Checked = true; + if (rbPtDeadzone.Enabled) + { + tbSlider.Value = Deviceoptions.DeadzoneToSlider(lblPdeadzone.Text); + } + else + { + rbPtSaturation.Checked = true; // force back to sense (available for both..) + if (rbPtSaturation.Enabled) + { + tbSlider.Value = Deviceoptions.SaturationToSlider(lblPsat.Text); + } + } + UpdateChartItems(); + } + } + private void rbP_CheckedChanged(object sender, EventArgs e) + { + rbP_CheckedChanged(); + } + private void rbP_CheckUpdate() + { + rbP.Checked = false; rbP.Checked = true; // forces to check and to update in case of already checked + } + + /// + /// Make Roll Active - copy data from left labels into the working area + /// + private void rbR_CheckedChanged() + { + if (rbR.Checked == true) + { + // get Labels from left area (current) + lblIn[1].Text = lblRin1.Text; lblIn[2].Text = lblRin2.Text; lblIn[3].Text = lblRin3.Text; + lblOut[1].Text = lblRout1.Text; lblOut[2].Text = lblRout2.Text; lblOut[3].Text = lblRout3.Text; + lblOut[4].Text = lblRexponent.Text; + lblNodetext.Text = lblRnt.Text; + // setup chart along the choosen parameter + rbPtDeadzone.Enabled = cbxRdeadzone.Checked; + rbPtSaturation.Enabled = cbxRsat.Checked; + + rbPtDeadzone.Checked = true; + if (rbPtDeadzone.Enabled) + { + tbSlider.Value = Deviceoptions.DeadzoneToSlider(lblRdeadzone.Text); + } + else + { + rbPtSaturation.Checked = true; // force back to sense (available for both..) + if (rbPtSaturation.Enabled) + { + tbSlider.Value = Deviceoptions.SaturationToSlider(lblRsat.Text); + } + } + UpdateChartItems(); + } + } + private void rbR_CheckedChanged(object sender, EventArgs e) + { + rbR_CheckedChanged(); + } + private void rbR_CheckUpdate() + { + rbR.Checked = false; rbR.Checked = true; // forces to check and to update in case of already checked + } + + // Interaction helper - changes panel on mouse up + + private void pnlYaw_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e) + { + rbY_CheckUpdate(); + } + + private void pnlPitch_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e) + { + rbP_CheckUpdate(); + } + + private void pnlRoll_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e) + { + rbR_CheckUpdate(); + } + + #endregion + + #region Charts section + + // Chart - move Pts + + /// + /// Evaluate which tune parameter has the chart input + /// + private void EvalChartInput() + { + m_hitPt = 0; + if (rbPt1.Enabled && rbPt1.Checked) m_hitPt = 1; + if (rbPt2.Enabled && rbPt2.Checked) m_hitPt = 2; + if (rbPt3.Enabled && rbPt3.Checked) m_hitPt = 3; + if (rbPtExponent.Enabled && rbPtExponent.Checked) m_hitPt = 4; + + if (m_hitPt > 0) return; + + // slider fudge + tbSlider.Enabled = false; + if (rbPtDeadzone.Enabled && rbPtDeadzone.Checked) + { + tbSlider.Enabled = true; + if (rbY.Checked) + { + tbSlider.Value = Deviceoptions.DeadzoneToSlider(lblYdeadzone.Text); + } + else if (rbP.Checked) + { + tbSlider.Value = Deviceoptions.DeadzoneToSlider(lblPdeadzone.Text); + } + else if (rbR.Checked) + { + tbSlider.Value = Deviceoptions.DeadzoneToSlider(lblRdeadzone.Text); + } + } + if (rbPtSaturation.Enabled && rbPtSaturation.Checked) + { + tbSlider.Enabled = true; + if (rbY.Checked) + { + tbSlider.Value = Deviceoptions.SaturationToSlider(lblYsat.Text); + } + else if (rbP.Checked) + { + tbSlider.Value = Deviceoptions.SaturationToSlider(lblPsat.Text); + } + else if (rbR.Checked) + { + tbSlider.Value = Deviceoptions.SaturationToSlider(lblRsat.Text); + } + } + EvalSlider(); + } + + + /// + /// Handle change of the mouse input within the chart + /// + private void rbPtAny_CheckedChanged(object sender, EventArgs e) + { + EvalChartInput(); + } + + + // handle mouse interaction with the chart + + int m_hitPt = 0; + bool m_hitActive = false; + int mX = 0; int mY = 0; + + /// + /// Update the graph from changes of acitve label values + /// + private void UpdateChartItems() + { + bool deadzoneUsed = true; + bool satUsed = true; + bool expUsed = true; + bool ptsUsed = true; + // see what is on display.. + if (rbY.Checked == true) + { + // Yaw + if (m_isStrafe) + { + deadzoneUsed = (m_liveStrafeLat.deadzoneUsed == true); + satUsed = (m_liveStrafeLat.saturationUsed == true); + expUsed = (m_liveStrafeLat.exponentUsed == true); + ptsUsed = (m_liveStrafeLat.nonLinCurveUsed == true); + lblGraphDeadzone.Text = m_liveStrafeLat.deadzoneS; + lblGraphSaturation.Text = m_liveStrafeLat.saturationS; + + } + else + { + deadzoneUsed = (m_liveYaw.deadzoneUsed == true); + satUsed = (m_liveYaw.saturationUsed == true); + expUsed = (m_liveYaw.exponentUsed == true); + ptsUsed = (m_liveYaw.nonLinCurveUsed == true); + lblGraphDeadzone.Text = m_liveYaw.deadzoneS; + lblGraphSaturation.Text = m_liveYaw.saturationS; + } + chart1.BackColor = rbY.BackColor; + + } + else if (rbP.Checked == true) + { + // Pitch + if (m_isStrafe) + { + deadzoneUsed = (m_liveStrafeVert.deadzoneUsed == true); + satUsed = (m_liveStrafeVert.saturationUsed == true); + expUsed = (m_liveStrafeVert.exponentUsed == true); + ptsUsed = (m_liveStrafeVert.nonLinCurveUsed == true); + lblGraphDeadzone.Text = m_liveStrafeVert.deadzoneS; + lblGraphSaturation.Text = m_liveStrafeVert.saturationS; + } + else + { + deadzoneUsed = (m_livePitch.deadzoneUsed == true); + satUsed = (m_livePitch.saturationUsed == true); + expUsed = (m_livePitch.exponentUsed == true); + ptsUsed = (m_livePitch.nonLinCurveUsed == true); + lblGraphDeadzone.Text = m_livePitch.deadzoneS; + lblGraphSaturation.Text = m_livePitch.saturationS; + } + chart1.BackColor = rbP.BackColor; + + } + else + { + // Roll + if (m_isStrafe) + { + deadzoneUsed = (m_liveStrafeLon.deadzoneUsed == true); + satUsed = (m_liveStrafeLon.saturationUsed == true); + expUsed = (m_liveStrafeLon.exponentUsed == true); + ptsUsed = (m_liveStrafeLon.nonLinCurveUsed == true); + lblGraphDeadzone.Text = m_liveStrafeLon.deadzoneS; + lblGraphSaturation.Text = m_liveStrafeLon.saturationS; + } + else + { + deadzoneUsed = (m_liveRoll.deadzoneUsed == true); + satUsed = (m_liveRoll.saturationUsed == true); + expUsed = (m_liveRoll.exponentUsed == true); + ptsUsed = (m_liveRoll.nonLinCurveUsed == true); + lblGraphDeadzone.Text = m_liveRoll.deadzoneS; + lblGraphSaturation.Text = m_liveRoll.saturationS; + } + chart1.BackColor = rbR.BackColor; + } + + // generic part + rbPtDeadzone.Enabled = deadzoneUsed; + lblGraphDeadzone.Visible = deadzoneUsed; + + rbPtSaturation.Enabled = satUsed; + lblGraphSaturation.Visible = satUsed; + + rbPtExponent.Enabled = expUsed; + rbPt1.Enabled = ptsUsed; rbPt2.Enabled = ptsUsed; rbPt3.Enabled = ptsUsed; + EvalChartInput(); // review active chart input + + if (!tbSlider.Enabled) lblOutSlider.Text = "---"; + + if (expUsed) + { + // Exp mode + double expo = double.Parse(lblOut[4].Text); + // dont touch zero Point + m_bSeries.BezierPoints[1].SetValueXY(0.25, Math.Pow(0.25, expo)); + m_bSeries.BezierPoints[2].SetValueXY(0.5, Math.Pow(0.5, expo)); + m_bSeries.BezierPoints[3].SetValueXY(0.75, Math.Pow(0.75, expo)); + m_bSeries.BezierPoints[4].SetValueXY(1.0, 1.0); + + } + else if (ptsUsed) + { + // Pts mode + // dont touch zero Point + for (int i = 1; i <= 3; i++) + { + m_bSeries.BezierPoints[i].SetValueXY(float.Parse(lblIn[i].Text), float.Parse(lblOut[i].Text)); + } + m_bSeries.BezierPoints[4].SetValueXY(1.0, 1.0); + + } + else + { + // linear + // dont touch zero Point + m_bSeries.BezierPoints[1].SetValueXY(0.25, 0.25); + m_bSeries.BezierPoints[2].SetValueXY(0.5, 0.5); + m_bSeries.BezierPoints[3].SetValueXY(0.75, 0.75); + m_bSeries.BezierPoints[4].SetValueXY(1.0, 1.0); + } + // update markers from curve points + chart1.Series[1].Points[1] = m_bSeries.BezierPoints[1]; + chart1.Series[1].Points[2] = m_bSeries.BezierPoints[2]; + chart1.Series[1].Points[3] = m_bSeries.BezierPoints[3]; + chart1.Series[1].Points[4] = m_bSeries.BezierPoints[4]; + + m_bSeries.Invalidate(chart1); + } + + + + private void chartPoint_MouseDown(object sender, System.Windows.Forms.MouseEventArgs e) + { + m_hitActive = true; // activate movement tracking + mX = e.X; mY = e.Y; // save initial loc to get deltas + } + + private void chartPoint_MouseMove(object sender, System.Windows.Forms.MouseEventArgs e) + { + if (m_hitActive) + { + if (m_hitPt < 1) + { + // nothing selected ... + } + else if (m_hitPt <= 3) + { + // Pt1..3 + double newX = double.Parse(lblIn[m_hitPt].Text) + (e.X - mX) * 0.001f; mX = e.X; + newX = (newX > 1.0f) ? 1.0f : newX; + newX = (newX < 0.0f) ? 0.0f : newX; + lblIn[m_hitPt].Text = newX.ToString("0.000"); + + double newY = double.Parse(lblOut[m_hitPt].Text) + (e.Y - mY) * -0.001f; mY = e.Y; + newY = (newY > 1.0f) ? 1.0f : newY; + newY = (newY < 0.0f) ? 0.0f : newY; + lblOut[m_hitPt].Text = newY.ToString("0.000"); + + // update chart (Points[0] is zero) + m_bSeries.BezierPoints[m_hitPt].SetValueXY(newX, newY); + // update markers from curve points + chart1.Series[1].Points[m_hitPt] = m_bSeries.BezierPoints[m_hitPt]; + + } + else if (m_hitPt == 4) + { + // Exponent + double newY = double.Parse(lblOut[m_hitPt].Text) + (e.Y - mY) * 0.01f; mY = e.Y; + newY = (newY > 3.0f) ? 3.0f : newY; + newY = (newY < 0.5f) ? 0.5f : newY; + lblOut[m_hitPt].Text = newY.ToString("0.00"); + + // update chart (Points[0] is zero) + m_bSeries.BezierPoints[1].SetValueXY(0.25, Math.Pow(0.25, newY)); + m_bSeries.BezierPoints[2].SetValueXY(0.5, Math.Pow(0.5, newY)); + m_bSeries.BezierPoints[3].SetValueXY(0.75, Math.Pow(0.75, newY)); + } + + // update markers from curve points + chart1.Series[1].Points[1] = m_bSeries.BezierPoints[1]; + chart1.Series[1].Points[2] = m_bSeries.BezierPoints[2]; + chart1.Series[1].Points[3] = m_bSeries.BezierPoints[3]; + chart1.Series[1].Points[4] = m_bSeries.BezierPoints[4]; + + m_bSeries.Invalidate(chart1); + + } + } + + private void chartPoint_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e) + { + m_hitActive = false; + + // update the rest of the fields from Entry + + if (rbY.Checked == true) + { + // left area labels + lblYin1.Text = lblIn[1].Text; lblYin2.Text = lblIn[2].Text; lblYin3.Text = lblIn[3].Text; + lblYout1.Text = lblOut[1].Text; lblYout2.Text = lblOut[2].Text; lblYout3.Text = lblOut[3].Text; + lblYexponent.Text = lblOut[4].Text; + // update live values + if (m_isStrafe) + { + m_liveStrafeLat.exponentS = lblYexponent.Text; + if (m_liveStrafeLat.nonLinCurve != null) + { + m_liveStrafeLat.nonLinCurve.Curve(float.Parse(lblYin1.Text), float.Parse(lblYout1.Text), + float.Parse(lblYin2.Text), float.Parse(lblYout2.Text), + float.Parse(lblYin3.Text), float.Parse(lblYout3.Text)); + } + } + else + { + m_liveYaw.exponentS = lblYexponent.Text; + if (m_liveYaw.nonLinCurve != null) + { + m_liveYaw.nonLinCurve.Curve(float.Parse(lblYin1.Text), float.Parse(lblYout1.Text), + float.Parse(lblYin2.Text), float.Parse(lblYout2.Text), + float.Parse(lblYin3.Text), float.Parse(lblYout3.Text)); + } + } + + } + else if (rbP.Checked == true) + { + // left area labels + lblPin1.Text = lblIn[1].Text; lblPin2.Text = lblIn[2].Text; lblPin3.Text = lblIn[3].Text; + lblPout1.Text = lblOut[1].Text; lblPout2.Text = lblOut[2].Text; lblPout3.Text = lblOut[3].Text; + lblPexponent.Text = lblOut[4].Text; + // update live values + if (m_isStrafe) + { + m_liveStrafeVert.exponentS = lblPexponent.Text; + if (m_liveStrafeVert.nonLinCurve != null) + { + m_liveStrafeVert.nonLinCurve.Curve(float.Parse(lblPin1.Text), float.Parse(lblPout1.Text), + float.Parse(lblPin2.Text), float.Parse(lblPout2.Text), + float.Parse(lblPin3.Text), float.Parse(lblPout3.Text)); + } + } + else + { + m_livePitch.exponentS = lblPexponent.Text; + if (m_livePitch.nonLinCurve != null) + { + m_livePitch.nonLinCurve.Curve(float.Parse(lblPin1.Text), float.Parse(lblPout1.Text), + float.Parse(lblPin2.Text), float.Parse(lblPout2.Text), + float.Parse(lblPin3.Text), float.Parse(lblPout3.Text)); + } + } + + } + else if (rbR.Checked == true) + { + // left area labels + lblRin1.Text = lblIn[1].Text; lblRin2.Text = lblIn[2].Text; lblRin3.Text = lblIn[3].Text; + lblRout1.Text = lblOut[1].Text; lblRout2.Text = lblOut[2].Text; lblRout3.Text = lblOut[3].Text; + lblRexponent.Text = lblOut[4].Text; + // update live values + if (m_isStrafe) + { + m_liveStrafeLon.exponentS = lblRexponent.Text; + if (m_liveStrafeLon.nonLinCurve != null) + { + m_liveStrafeLon.nonLinCurve.Curve(float.Parse(lblRin1.Text), float.Parse(lblRout1.Text), + float.Parse(lblRin2.Text), float.Parse(lblRout2.Text), + float.Parse(lblRin3.Text), float.Parse(lblRout3.Text)); + } + } + else + { + m_liveRoll.exponentS = lblRexponent.Text; + if (m_liveRoll.nonLinCurve != null) + { + m_liveRoll.nonLinCurve.Curve(float.Parse(lblRin1.Text), float.Parse(lblRout1.Text), + float.Parse(lblRin2.Text), float.Parse(lblRout2.Text), + float.Parse(lblRin3.Text), float.Parse(lblRout3.Text)); + } + } + + } + } + #endregion + + #region Checked Invert Changed + + private void cbxYinvert_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeLat.invertUsed = false; + if (cbxYinvert.Checked == true) + { + m_liveStrafeLat.invertUsed = true; + } + } + else + { + m_liveYaw.invertUsed = false; + if (cbxYinvert.Checked == true) + { + m_liveYaw.invertUsed = true; + } + } + rbY_CheckUpdate(); + } + + private void cbxPinvert_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeVert.invertUsed = false; + if (cbxPinvert.Checked == true) + { + m_liveStrafeVert.invertUsed = true; + } + } + else + { + m_livePitch.invertUsed = false; + if (cbxPinvert.Checked == true) + { + m_livePitch.invertUsed = true; + } + } + rbP_CheckUpdate(); + } + + private void cbxRinvert_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeLon.invertUsed = false; + if (cbxRinvert.Checked == true) + { + m_liveStrafeLon.invertUsed = true; + } + } + else + { + m_liveRoll.invertUsed = false; + if (cbxRinvert.Checked == true) + { + m_liveRoll.invertUsed = true; + } + } + rbR_CheckUpdate(); + } + + #endregion + + #region Slider Value Changed (Deadzone / Saturation) + + // Deadzone slider 00 .. 40 -> 0 .. 0.160 ( 4 pt scale) + // Saturation slider 00 .. 40 -> 0.2 .. 1.0 ( 20 pt scale) + + private void EvalSlider() + { + if (rbPtDeadzone.Enabled && rbPtDeadzone.Checked) + { + lblOutSlider.Text = Deviceoptions.DeadzoneFromSlider(tbSlider.Value).ToString("0.000"); + float curDeadzone = 1000.0f * Deviceoptions.DeadzoneFromSlider(tbSlider.Value); // % scaled to maxAxis + + if (rbY.Checked == true) + { + if (m_isStrafe) m_liveStrafeLat.deadzone = curDeadzone; else m_liveYaw.deadzone = curDeadzone; + lblYdeadzone.Text = lblOutSlider.Text; + } + else if (rbP.Checked == true) + { + if (m_isStrafe) m_liveStrafeVert.deadzone = curDeadzone; else m_livePitch.deadzone = curDeadzone; + lblPdeadzone.Text = lblOutSlider.Text; + } + else if (rbR.Checked == true) + { + if (m_isStrafe) m_liveStrafeLon.deadzone = curDeadzone; else m_liveRoll.deadzone = curDeadzone; + lblRdeadzone.Text = lblOutSlider.Text; + } + lblGraphDeadzone.Text = lblOutSlider.Text; + } + else if (rbPtSaturation.Enabled && rbPtSaturation.Checked) + { + lblOutSlider.Text = Deviceoptions.SaturationFromSlider(tbSlider.Value).ToString("0.000"); + float curSaturation = 1000.0f * Deviceoptions.SaturationFromSlider(tbSlider.Value); // % scaled to maxAxis + + if (rbY.Checked == true) + { + if (m_isStrafe) m_liveStrafeLat.saturation = curSaturation; else m_liveYaw.saturation = curSaturation; + lblYsat.Text = lblOutSlider.Text; + } + else if (rbP.Checked == true) + { + if (m_isStrafe) m_liveStrafeVert.saturation = curSaturation; else m_livePitch.saturation = curSaturation; + lblPsat.Text = lblOutSlider.Text; + } + else if (rbR.Checked == true) + { + if (m_isStrafe) m_liveStrafeLon.saturation = curSaturation; else m_liveRoll.saturation = curSaturation; + lblRsat.Text = lblOutSlider.Text; + } + lblGraphSaturation.Text = lblOutSlider.Text; + } + } + + private void tbSlider_ValueChanged(object sender, EventArgs e) + { + EvalSlider(); + } + + #endregion + + #region Checked Deadzone Changed + + private void cbxYdeadzone_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeLat.deadzoneUsed = false; + if (cbxYdeadzone.Checked == true) + { + m_liveStrafeLat.deadzoneUsed = true; + } + } + else + { + m_liveYaw.deadzoneUsed = false; + if (cbxYdeadzone.Checked == true) + { + m_liveYaw.deadzoneUsed = true; + } + } + rbY_CheckUpdate(); + rbPtDeadzone.Checked = cbxYdeadzone.Checked; + UpdateChartItems(); + } + + private void cbxPdeadzone_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeVert.deadzoneUsed = false; + if (cbxPdeadzone.Checked == true) + { + m_liveStrafeVert.deadzoneUsed = true; + } + } + else + { + m_livePitch.deadzoneUsed = false; + if (cbxPdeadzone.Checked == true) + { + m_livePitch.deadzoneUsed = true; + } + } + rbP_CheckUpdate(); + rbPtDeadzone.Checked = cbxPdeadzone.Checked; + UpdateChartItems(); + } + + private void cbxRdeadzone_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeLon.deadzoneUsed = false; + if (cbxRdeadzone.Checked == true) + { + m_liveStrafeLon.deadzoneUsed = true; // update storage + } + } + else + { + m_liveRoll.deadzoneUsed = false; + if (cbxRdeadzone.Checked == true) + { + m_liveRoll.deadzoneUsed = true; // update storage + } + } + rbR_CheckUpdate(); + rbPtDeadzone.Checked = cbxRdeadzone.Checked; + UpdateChartItems(); + } + + #endregion + + #region Checked Saturation Changed + + private void cbxYsense_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeLat.saturationUsed = false; + if (cbxYsat.Checked == true) + { + m_liveStrafeLat.saturationUsed = true; + } + } + else + { + m_liveYaw.saturationUsed = false; + if (cbxYsat.Checked == true) + { + m_liveYaw.saturationUsed = true; + } + } + rbY_CheckUpdate(); + rbPtSaturation.Checked = cbxYsat.Checked; + UpdateChartItems(); + } + + private void cbxPsense_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeVert.saturationUsed = false; + if (cbxPsat.Checked == true) + { + m_liveStrafeVert.saturationUsed = true; + } + } + else + { + m_livePitch.saturationUsed = false; + if (cbxPsat.Checked == true) + { + m_livePitch.saturationUsed = true; + } + } + rbP_CheckUpdate(); + rbPtSaturation.Checked = cbxPsat.Checked; + UpdateChartItems(); + } + + private void cbxRsense_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeLon.saturationUsed = false; + if (cbxRsat.Checked == true) + { + m_liveStrafeLon.saturationUsed = true; + } + } + else + { + m_liveRoll.saturationUsed = false; + if (cbxRsat.Checked == true) + { + m_liveRoll.saturationUsed = true; + } + } + rbR_CheckUpdate(); + rbPtSaturation.Checked = cbxRsat.Checked; + UpdateChartItems(); + } + + #endregion + + #region Checked Exponent Changed + + private void cbxYexpo_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeLat.exponentUsed = false; + if (cbxYexpo.Checked == true) + { + m_liveStrafeLat.exponentUsed = true; + cbxYpts.Checked = false; // forced: either expo OR points + } + } + else + { + m_liveYaw.exponentUsed = false; + if (cbxYexpo.Checked == true) + { + m_liveYaw.exponentUsed = true; + cbxYpts.Checked = false; // forced: either expo OR points + } + } + rbY_CheckUpdate(); + UpdateChartItems(); + } + + private void cbxPexpo_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeVert.exponentUsed = false; + if (cbxPexpo.Checked == true) + { + m_liveStrafeVert.exponentUsed = true; + cbxPpts.Checked = false; // forced: either expo OR points + } + } + else + { + m_livePitch.exponentUsed = false; + if (cbxPexpo.Checked == true) + { + m_livePitch.exponentUsed = true; + cbxPpts.Checked = false; // forced: either expo OR points + } + } + rbP_CheckUpdate(); + UpdateChartItems(); + } + + private void cbxRexpo_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeLon.exponentUsed = false; + if (cbxRexpo.Checked == true) + { + m_liveStrafeLon.exponentUsed = true; + cbxRpts.Checked = false; // forced: either expo OR points + } + } + else + { + m_liveRoll.exponentUsed = false; + if (cbxRexpo.Checked == true) + { + m_liveRoll.exponentUsed = true; + cbxRpts.Checked = false; // forced: either expo OR points + } + } + rbR_CheckUpdate(); + UpdateChartItems(); + } + + #endregion + + #region Checked Points Changed + + private void cbxYpts_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeLat.nonLinCurveUsed = false; + if (cbxYpts.Checked == true) + { + m_liveStrafeLat.nonLinCurveUsed = true; + cbxYexpo.Checked = false; // forced: either expo OR points + } + } + else + { + m_liveYaw.nonLinCurveUsed = false; + if (cbxYpts.Checked == true) + { + m_liveYaw.nonLinCurveUsed = true; + cbxYexpo.Checked = false; // forced: either expo OR points + } + } + rbY_CheckUpdate(); + UpdateChartItems(); + } + + private void cbxPpts_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeVert.nonLinCurveUsed = false; + if (cbxPpts.Checked == true) + { + m_liveStrafeVert.nonLinCurveUsed = true; + cbxPexpo.Checked = false; // forced: either expo OR points + } + } + else + { + m_livePitch.nonLinCurveUsed = false; + if (cbxPpts.Checked == true) + { + m_livePitch.nonLinCurveUsed = true; + cbxPexpo.Checked = false; // forced: either expo OR points + } + } + rbP_CheckUpdate(); + UpdateChartItems(); + } + + private void cbxRpts_CheckedChanged(object sender, EventArgs e) + { + if (m_isStrafe) + { + m_liveStrafeLon.nonLinCurveUsed = false; + if (cbxRpts.Checked == true) + { + m_liveStrafeLon.nonLinCurveUsed = true; + cbxRexpo.Checked = false; // forced: either expo OR points + } + } + else + { + m_liveRoll.nonLinCurveUsed = false; + if (cbxRpts.Checked == true) + { + m_liveRoll.nonLinCurveUsed = true; + cbxRexpo.Checked = false; // forced: either expo OR points + } + } + rbR_CheckUpdate(); + UpdateChartItems(); + } + + #endregion + + #region Skybox Checked Changed + + private void rbOutThere1_CheckedChanged(object sender, EventArgs e) + { + TMU0_Filename = SBFiles[SB_OutThere1]; + LoadSkybox(); + } + + private void rbOutThere3_CheckedChanged(object sender, EventArgs e) + { + TMU0_Filename = SBFiles[SB_OutThere3]; + LoadSkybox(); + } + + private void rbCanyon_CheckedChanged(object sender, EventArgs e) + { + TMU0_Filename = SBFiles[SB_Canyon]; + LoadSkybox(); + } + + private void rbShiodome_CheckedChanged(object sender, EventArgs e) + { + TMU0_Filename = SBFiles[SB_Shiodome]; + LoadSkybox(); + } + + private void rbHighway_CheckedChanged(object sender, EventArgs e) + { + TMU0_Filename = SBFiles[SB_Highway]; + LoadSkybox(); + } + + private void rbBigSight_CheckedChanged(object sender, EventArgs e) + { + TMU0_Filename = SBFiles[SB_BigSight]; + LoadSkybox(); + } + + private void rbHelipad_CheckedChanged(object sender, EventArgs e) + { + TMU0_Filename = SBFiles[SB_LA_Helipad]; + LoadSkybox(); + } + + private void rbSkybox_CheckedChanged(object sender, EventArgs e) + { + TMU0_Filename = SBFiles[SB_Skybox]; + LoadSkybox(); + } + + private void rbSunset_CheckedChanged(object sender, EventArgs e) + { + TMU0_Filename = SBFiles[SB_Sunset]; + LoadSkybox(); + } + + + + private void rbDyingStar_CheckedChanged(object sender, EventArgs e) + { + TMU0_Filename = SBFiles[SB_DyingStar]; + LoadSkybox(); + } + + private void rbBrokenMoon_CheckedChanged(object sender, EventArgs e) + { + TMU0_Filename = SBFiles[SB_BrokenMoon]; + LoadSkybox(); + } - private void cbxPpts_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeVert.nonLinCurveUsed = false; - if ( cbxPpts.Checked == true ) { - m_liveStrafeVert.nonLinCurveUsed = true; - cbxPexpo.Checked = false; // forced: either expo OR points - } - } - else { - m_livePitch.nonLinCurveUsed = false; - if ( cbxPpts.Checked == true ) { - m_livePitch.nonLinCurveUsed = true; - cbxPexpo.Checked = false; // forced: either expo OR points - } - } - rbP_CheckUpdate( ); - UpdateChartItems( ); - } + private void rbKareah_CheckedChanged(object sender, EventArgs e) + { + TMU0_Filename = SBFiles[SB_Demien]; + LoadSkybox(); + } - private void cbxRpts_CheckedChanged( object sender, EventArgs e ) - { - if ( m_isStrafe ) { - m_liveStrafeLon.nonLinCurveUsed = false; - if ( cbxRpts.Checked == true ) { - m_liveStrafeLon.nonLinCurveUsed = true; - cbxRexpo.Checked = false; // forced: either expo OR points - } - } - else { - m_liveRoll.nonLinCurveUsed = false; - if ( cbxRpts.Checked == true ) { - m_liveRoll.nonLinCurveUsed = true; - cbxRexpo.Checked = false; // forced: either expo OR points - } - } - rbR_CheckUpdate( ); - UpdateChartItems( ); - } + private void rbArea18_CheckedChanged(object sender, EventArgs e) + { + TMU0_Filename = SBFiles[SB_Area18]; + LoadSkybox(); + } - #endregion - #region Skybox Checked Changed + #endregion - private void rbOutThere1_CheckedChanged( object sender, EventArgs e ) - { - TMU0_Filename = SBFiles[SB_OutThere1]; - LoadSkybox( ); - } - private void rbOutThere3_CheckedChanged( object sender, EventArgs e ) - { - TMU0_Filename = SBFiles[SB_OutThere3]; - LoadSkybox( ); - } + private void btCopyToAllAxis_Click(object sender, EventArgs e) + { + lblYin1.Text = lblIn1.Text; lblYout1.Text = lblOut1.Text; + lblYin2.Text = lblIn2.Text; lblYout2.Text = lblOut2.Text; + lblYin3.Text = lblIn3.Text; lblYout3.Text = lblOut3.Text; + if (m_isStrafe) + { + if (m_liveStrafeLat.nonLinCurve != null) + { + m_liveStrafeLat.nonLinCurve.Curve(float.Parse(lblYin1.Text), float.Parse(lblYout1.Text), + float.Parse(lblYin2.Text), float.Parse(lblYout2.Text), + float.Parse(lblYin3.Text), float.Parse(lblYout3.Text)); + } + } + else + { + if (m_liveYaw.nonLinCurve != null) + { + m_liveYaw.nonLinCurve.Curve(float.Parse(lblYin1.Text), float.Parse(lblYout1.Text), + float.Parse(lblYin2.Text), float.Parse(lblYout2.Text), + float.Parse(lblYin3.Text), float.Parse(lblYout3.Text)); + } + } - private void rbCanyon_CheckedChanged( object sender, EventArgs e ) - { - TMU0_Filename = SBFiles[SB_Canyon]; - LoadSkybox( ); - } + lblPin1.Text = lblIn1.Text; lblPout1.Text = lblOut1.Text; + lblPin2.Text = lblIn2.Text; lblPout2.Text = lblOut2.Text; + lblPin3.Text = lblIn3.Text; lblPout3.Text = lblOut3.Text; + if (m_isStrafe) + { + if (m_liveStrafeVert.nonLinCurve != null) + { + m_liveStrafeVert.nonLinCurve.Curve(float.Parse(lblPin1.Text), float.Parse(lblPout1.Text), + float.Parse(lblPin2.Text), float.Parse(lblPout2.Text), + float.Parse(lblPin3.Text), float.Parse(lblPout3.Text)); + } + } + else + { + if (m_livePitch.nonLinCurve != null) + { + m_livePitch.nonLinCurve.Curve(float.Parse(lblPin1.Text), float.Parse(lblPout1.Text), + float.Parse(lblPin2.Text), float.Parse(lblPout2.Text), + float.Parse(lblPin3.Text), float.Parse(lblPout3.Text)); + } + } - private void rbShiodome_CheckedChanged( object sender, EventArgs e ) - { - TMU0_Filename = SBFiles[SB_Shiodome]; - LoadSkybox( ); - } + lblRin1.Text = lblIn1.Text; lblRout1.Text = lblOut1.Text; + lblRin2.Text = lblIn2.Text; lblRout2.Text = lblOut2.Text; + lblRin3.Text = lblIn3.Text; lblRout3.Text = lblOut3.Text; + if (m_isStrafe) + { + if (m_liveStrafeLon.nonLinCurve != null) + { + m_liveStrafeLon.nonLinCurve.Curve(float.Parse(lblRin1.Text), float.Parse(lblRout1.Text), + float.Parse(lblRin2.Text), float.Parse(lblRout2.Text), + float.Parse(lblRin3.Text), float.Parse(lblRout3.Text)); + } + } + else + { + if (m_liveRoll.nonLinCurve != null) + { + m_liveRoll.nonLinCurve.Curve(float.Parse(lblRin1.Text), float.Parse(lblRout1.Text), + float.Parse(lblRin2.Text), float.Parse(lblRout2.Text), + float.Parse(lblRin3.Text), float.Parse(lblRout3.Text)); + } + } + } + + private void btDone_Click(object sender, EventArgs e) + { + // It ai setup as OK button - nothing here so far... + } - private void rbHighway_CheckedChanged( object sender, EventArgs e ) - { - TMU0_Filename = SBFiles[SB_Highway]; - LoadSkybox( ); - } - private void rbBigSight_CheckedChanged( object sender, EventArgs e ) - { - TMU0_Filename = SBFiles[SB_BigSight]; - LoadSkybox( ); - } + #endregion - private void rbHelipad_CheckedChanged( object sender, EventArgs e ) - { - TMU0_Filename = SBFiles[SB_LA_Helipad]; - LoadSkybox( ); - } - private void rbSkybox_CheckedChanged( object sender, EventArgs e ) - { - TMU0_Filename = SBFiles[SB_Skybox]; - LoadSkybox( ); - } - private void rbSunset_CheckedChanged( object sender, EventArgs e ) - { - TMU0_Filename = SBFiles[SB_Sunset]; - LoadSkybox( ); - } - #endregion - private void btCopyToAllAxis_Click( object sender, EventArgs e ) - { - lblYin1.Text = lblIn1.Text; lblYout1.Text = lblOut1.Text; - lblYin2.Text = lblIn2.Text; lblYout2.Text = lblOut2.Text; - lblYin3.Text = lblIn3.Text; lblYout3.Text = lblOut3.Text; - if ( m_isStrafe ) { - if ( m_liveStrafeLat.nonLinCurve != null ) { - m_liveStrafeLat.nonLinCurve.Curve( float.Parse( lblYin1.Text ), float.Parse( lblYout1.Text ), - float.Parse( lblYin2.Text ), float.Parse( lblYout2.Text ), - float.Parse( lblYin3.Text ), float.Parse( lblYout3.Text ) ); - } - } - else { - if ( m_liveYaw.nonLinCurve != null ) { - m_liveYaw.nonLinCurve.Curve( float.Parse( lblYin1.Text ), float.Parse( lblYout1.Text ), - float.Parse( lblYin2.Text ), float.Parse( lblYout2.Text ), - float.Parse( lblYin3.Text ), float.Parse( lblYout3.Text ) ); - } - } - - lblPin1.Text = lblIn1.Text; lblPout1.Text = lblOut1.Text; - lblPin2.Text = lblIn2.Text; lblPout2.Text = lblOut2.Text; - lblPin3.Text = lblIn3.Text; lblPout3.Text = lblOut3.Text; - if ( m_isStrafe ) { - if ( m_liveStrafeVert.nonLinCurve != null ) { - m_liveStrafeVert.nonLinCurve.Curve( float.Parse( lblPin1.Text ), float.Parse( lblPout1.Text ), - float.Parse( lblPin2.Text ), float.Parse( lblPout2.Text ), - float.Parse( lblPin3.Text ), float.Parse( lblPout3.Text ) ); - } - } - else { - if ( m_livePitch.nonLinCurve != null ) { - m_livePitch.nonLinCurve.Curve( float.Parse( lblPin1.Text ), float.Parse( lblPout1.Text ), - float.Parse( lblPin2.Text ), float.Parse( lblPout2.Text ), - float.Parse( lblPin3.Text ), float.Parse( lblPout3.Text ) ); - } - } - - lblRin1.Text = lblIn1.Text; lblRout1.Text = lblOut1.Text; - lblRin2.Text = lblIn2.Text; lblRout2.Text = lblOut2.Text; - lblRin3.Text = lblIn3.Text; lblRout3.Text = lblOut3.Text; - if ( m_isStrafe ) { - if ( m_liveStrafeLon.nonLinCurve != null ) { - m_liveStrafeLon.nonLinCurve.Curve( float.Parse( lblRin1.Text ), float.Parse( lblRout1.Text ), - float.Parse( lblRin2.Text ), float.Parse( lblRout2.Text ), - float.Parse( lblRin3.Text ), float.Parse( lblRout3.Text ) ); - } - } - else { - if ( m_liveRoll.nonLinCurve != null ) { - m_liveRoll.nonLinCurve.Curve( float.Parse( lblRin1.Text ), float.Parse( lblRout1.Text ), - float.Parse( lblRin2.Text ), float.Parse( lblRout2.Text ), - float.Parse( lblRin3.Text ), float.Parse( lblRout3.Text ) ); - } - } - } - private void btDone_Click( object sender, EventArgs e ) - { - // It ai setup as OK button - nothing here so far... } - - - #endregion - - - - - - - - - } } diff --git a/SCJMapper-V2.csproj b/SCJMapper-V2.csproj index cb20935..00b1060 100644 --- a/SCJMapper-V2.csproj +++ b/SCJMapper-V2.csproj @@ -348,6 +348,10 @@ Always + + + + diff --git a/graphics/SB_SC_Area18.dds b/graphics/SB_SC_Area18.dds new file mode 100644 index 0000000..c8898da Binary files /dev/null and b/graphics/SB_SC_Area18.dds differ diff --git a/graphics/SB_SC_BrokenMoon.dds b/graphics/SB_SC_BrokenMoon.dds new file mode 100644 index 0000000..fce8bec Binary files /dev/null and b/graphics/SB_SC_BrokenMoon.dds differ diff --git a/graphics/SB_SC_Demien.dds b/graphics/SB_SC_Demien.dds new file mode 100644 index 0000000..9e412e1 Binary files /dev/null and b/graphics/SB_SC_Demien.dds differ diff --git a/graphics/SB_SC_DyingStar.dds b/graphics/SB_SC_DyingStar.dds new file mode 100644 index 0000000..0f472e2 Binary files /dev/null and b/graphics/SB_SC_DyingStar.dds differ