From c0e54daa6fd4111ffcdec822eb03d883009247e4 Mon Sep 17 00:00:00 2001 From: Brian Tischler Date: Mon, 5 Feb 2024 09:12:28 -0700 Subject: [PATCH] Refy curve (#356) * Section on/off in config * Line Select * First Viz line, Start AgIO gfx * Put in vehicle in Draw and headlines * 2 size AB Draw * AB Draw fixes * Add Boundary Tool * Finish up MapToBnd * MapBnd Fixes - simplify * Map2Boundary complete * AB Draw and Headline Zoom * More zoom fixes * reorder left menu * Maximize AB Draw * Size ABDraw --- SourceCode/AgIO/Source/Forms/UDP.designer.cs | 8 +- SourceCode/GPS/AgOpenGPS.csproj | 25 + SourceCode/GPS/Classes/CABCurve.cs | 47 +- SourceCode/GPS/Classes/CABLine.cs | 2 +- SourceCode/GPS/Forms/Controls.Designer.cs | 61 +- .../GPS/Forms/Field/FormMapBnd.Designer.cs | 507 ++++++++ SourceCode/GPS/Forms/Field/FormMapBnd.cs | 1021 +++++++++++++++++ SourceCode/GPS/Forms/Field/FormMapBnd.resx | 126 ++ SourceCode/GPS/Forms/FormGPS.Designer.cs | 312 ++--- SourceCode/GPS/Forms/FormGPS.cs | 3 +- SourceCode/GPS/Forms/Form_First.Designer.cs | 2 +- .../GPS/Forms/Guidance/FormABDraw.Designer.cs | 576 ++++------ SourceCode/GPS/Forms/Guidance/FormABDraw.cs | 285 +++-- .../Forms/Guidance/FormABDraw2.Designer.cs | 509 ++++++++ SourceCode/GPS/Forms/Guidance/FormABDraw2.cs | 997 ++++++++++++++++ .../GPS/Forms/Guidance/FormABDraw2.resx | 126 ++ .../Forms/Guidance/FormHeadAche.Designer.cs | 35 +- SourceCode/GPS/Forms/Guidance/FormHeadAche.cs | 81 +- .../Forms/Guidance/FormHeadLine.Designer.cs | 51 +- SourceCode/GPS/Forms/Guidance/FormHeadLine.cs | 76 +- SourceCode/GPS/Forms/OpenGL.Designer.cs | 201 ++-- SourceCode/GPS/GlobalSuppressions.cs | 8 + .../GPS/Properties/Resources.Designer.cs | 60 + SourceCode/GPS/Properties/Resources.resx | 250 ++-- .../GPS/Properties/Settings.Designer.cs | 12 + SourceCode/GPS/Properties/Settings.settings | 3 + SourceCode/GPS/app.config | 3 + SourceCode/GPS/btnImages/APlusPlusA.png | Bin 0 -> 853 bytes SourceCode/GPS/btnImages/APlusPlusB.png | Bin 0 -> 834 bytes SourceCode/GPS/btnImages/BoundaryMakeLine.png | Bin 0 -> 2303 bytes SourceCode/GPS/btnImages/BoundaryReduce.png | Bin 0 -> 3124 bytes SourceCode/GPS/btnImages/BoundarySmooth.png | Bin 0 -> 2334 bytes SourceCode/GPS/btnImages/ZoomOGL.png | Bin 0 -> 4367 bytes SourceCode/GPS/gStr.Designer.cs | 9 + SourceCode/GPS/gStr.af.resx | 3 + SourceCode/GPS/gStr.hu.resx | 3 + SourceCode/GPS/gStr.resx | 3 + 37 files changed, 4473 insertions(+), 932 deletions(-) create mode 100644 SourceCode/GPS/Forms/Field/FormMapBnd.Designer.cs create mode 100644 SourceCode/GPS/Forms/Field/FormMapBnd.cs create mode 100644 SourceCode/GPS/Forms/Field/FormMapBnd.resx create mode 100644 SourceCode/GPS/Forms/Guidance/FormABDraw2.Designer.cs create mode 100644 SourceCode/GPS/Forms/Guidance/FormABDraw2.cs create mode 100644 SourceCode/GPS/Forms/Guidance/FormABDraw2.resx create mode 100644 SourceCode/GPS/GlobalSuppressions.cs create mode 100644 SourceCode/GPS/btnImages/APlusPlusA.png create mode 100644 SourceCode/GPS/btnImages/APlusPlusB.png create mode 100644 SourceCode/GPS/btnImages/BoundaryMakeLine.png create mode 100644 SourceCode/GPS/btnImages/BoundaryReduce.png create mode 100644 SourceCode/GPS/btnImages/BoundarySmooth.png create mode 100644 SourceCode/GPS/btnImages/ZoomOGL.png diff --git a/SourceCode/AgIO/Source/Forms/UDP.designer.cs b/SourceCode/AgIO/Source/Forms/UDP.designer.cs index 3b320f50c..d9e843add 100644 --- a/SourceCode/AgIO/Source/Forms/UDP.designer.cs +++ b/SourceCode/AgIO/Source/Forms/UDP.designer.cs @@ -237,8 +237,14 @@ private void ReceiveFromLoopBack(byte[] data) SendSteerModulePort(data, data.Length); break; } + case 0xE5: //232 Symmetric Sections - Zones + { + SendMachineModulePort(data, data.Length); + //SendSteerModulePort(data, data.Length); + break; + } } - } + } } private void ReceiveDataLoopAsync(IAsyncResult asyncResult) diff --git a/SourceCode/GPS/AgOpenGPS.csproj b/SourceCode/GPS/AgOpenGPS.csproj index 71d3c1815..0ecd6b253 100644 --- a/SourceCode/GPS/AgOpenGPS.csproj +++ b/SourceCode/GPS/AgOpenGPS.csproj @@ -174,6 +174,12 @@ FormEnterFlag.cs + + Form + + + FormMapBnd.cs + Form @@ -210,6 +216,12 @@ FormYes.cs + + Form + + + FormABDraw2.cs + Form @@ -488,6 +500,7 @@ FormSteerWiz.cs + gStr.da.resx True @@ -617,6 +630,9 @@ FormEnterFlag.cs + + FormMapBnd.cs + FormPan.cs Designer @@ -637,6 +653,9 @@ FormYes.cs + + FormABDraw2.cs + FormRecordName.cs @@ -998,6 +1017,12 @@ + + + + + + diff --git a/SourceCode/GPS/Classes/CABCurve.cs b/SourceCode/GPS/Classes/CABCurve.cs index 7c9363994..7805a5749 100644 --- a/SourceCode/GPS/Classes/CABCurve.cs +++ b/SourceCode/GPS/Classes/CABCurve.cs @@ -20,7 +20,7 @@ public class CABCurve public double howManyPathsAway; public vec2 refPoint1 = new vec2(1, 1), refPoint2 = new vec2(2, 2); - + private int A, B, C; private int rA, rB; @@ -157,7 +157,7 @@ public void BuildCurveCurrentList(vec3 pivot) distanceFromRefLine -= (0.5 * widthMinusOverlap); double RefDist = (distanceFromRefLine + (isHeadingSameWay ? mf.tool.offset : -mf.tool.offset)) / widthMinusOverlap; - + if (RefDist < 0) howManyPathsAway = (int)(RefDist - 0.5); else howManyPathsAway = (int)(RefDist + 0.5); @@ -167,7 +167,7 @@ public void BuildCurveCurrentList(vec3 pivot) //build the current line curList?.Clear(); - double distAway = widthMinusOverlap * howManyPathsAway + (isHeadingSameWay ? -mf.tool.offset : mf.tool.offset ) + mf.trk.gArr[idx].nudgeDistance; + double distAway = widthMinusOverlap * howManyPathsAway + (isHeadingSameWay ? -mf.tool.offset : mf.tool.offset) + mf.trk.gArr[idx].nudgeDistance; distAway += (0.5 * widthMinusOverlap); @@ -485,7 +485,7 @@ public void GetCurrentCurveLine(vec3 pivot, vec3 steer) return; } - SegmentFound: + SegmentFound: //get the distance from currently active AB line @@ -671,11 +671,12 @@ public void DrawCurveNew() public void DrawProposed(int i) { - GL.LineWidth(4); + GL.LineWidth(8); GL.Color3(0.3, 0.92f, 0.42f); - GL.Begin(PrimitiveType.LineStrip); + GL.Begin(PrimitiveType.LineStrip); for (int h = 0; h < mf.trk.gArr[i].curvePts.Count; h++) + GL.Vertex3( mf.trk.gArr[i].curvePts[h].easting, mf.trk.gArr[i].curvePts[h].northing, @@ -706,12 +707,12 @@ public void DrawCurve() GL.Begin(PrimitiveType.Lines); for (int h = 0; h < ptCount; h++) GL.Vertex3( - mf.trk.gArr[mf.trk.idx].curvePts[h].easting, - mf.trk.gArr[mf.trk.idx].curvePts[h].northing, + mf.trk.gArr[mf.trk.idx].curvePts[h].easting, + mf.trk.gArr[mf.trk.idx].curvePts[h].northing, 0); GL.End(); - + if (mf.font.isFontOn) { GL.Color3(0.40f, 0.90f, 0.95f); @@ -1011,8 +1012,8 @@ public void MakePointMinimumSpacing(ref List xList, double minDistance) } -//turning the visual line into the real reference line to use -public void SaveSmoothList() + //turning the visual line into the real reference line to use + public void SaveSmoothList() { //oops no smooth list generated if (smooList == null) return; @@ -1070,7 +1071,7 @@ public void AddFirstLastPoints(ref List xList) //end while (mf.bnd.bndList[0].fenceLineEar.IsPointInPolygon(xList[xList.Count - 1])) { - for (int i = 1; i < 10; i++) + for (int i = 1; i < 100; i++) { vec3 pt = new vec3(xList[ptCnt]); pt.easting += (Math.Sin(pt.heading) * i); @@ -1085,7 +1086,7 @@ public void AddFirstLastPoints(ref List xList) while (mf.bnd.bndList[0].fenceLineEar.IsPointInPolygon(xList[0])) { - for (int i = 1; i < 10; i++) + for (int i = 1; i < 100; i++) { vec3 pt = new vec3(start); pt.easting -= (Math.Sin(pt.heading) * i); @@ -1094,6 +1095,26 @@ public void AddFirstLastPoints(ref List xList) } start = new vec3(xList[0]); } + + for (int i = 1; i < 100; i++) + { + vec3 pt = new vec3(xList[ptCnt]); + pt.easting += (Math.Sin(pt.heading) * i); + pt.northing += (Math.Cos(pt.heading) * i); + xList.Add(pt); + } + + //and the beginning + start = new vec3(xList[0]); + + for (int i = 1; i < 100; i++) + { + vec3 pt = new vec3(start); + pt.easting -= (Math.Sin(pt.heading) * i); + pt.northing -= (Math.Cos(pt.heading) * i); + xList.Insert(0, pt); + } + } else { diff --git a/SourceCode/GPS/Classes/CABLine.cs b/SourceCode/GPS/Classes/CABLine.cs index ae3586c5a..c5d96550e 100644 --- a/SourceCode/GPS/Classes/CABLine.cs +++ b/SourceCode/GPS/Classes/CABLine.cs @@ -372,8 +372,8 @@ public void DrawProposed(int i) { GL.LineWidth(4); //GL.Enable(EnableCap.LineStipple); - GL.Begin(PrimitiveType.Lines); GL.Color3(0.30f, 0.972f, 0.32f); + GL.Begin(PrimitiveType.Lines); { GL.Vertex3(mf.trk.gArr[i].endPtA.easting, mf.trk.gArr[i].endPtA.northing, 0); GL.Vertex3(mf.trk.gArr[i].endPtB.easting, mf.trk.gArr[i].endPtB.northing, 0); diff --git a/SourceCode/GPS/Forms/Controls.Designer.cs b/SourceCode/GPS/Forms/Controls.Designer.cs index 1210ecccc..51d991e45 100644 --- a/SourceCode/GPS/Forms/Controls.Designer.cs +++ b/SourceCode/GPS/Forms/Controls.Designer.cs @@ -445,9 +445,22 @@ private void btnABDraw_Click(object sender, EventArgs e) flp1.Visible = false; } - using (var form = new FormABDraw(this)) + if (isBtnAutoSteerOn) btnAutoSteer.PerformClick(); + if (yt.isYouTurnBtnOn) btnAutoYouTurn.PerformClick(); + + if (this.Height > 1000 && this.Width > 1000) { - form.ShowDialog(this); + using (var form = new FormABDraw2(this)) + { + form.ShowDialog(this); + } + } + else + { + using (var form = new FormABDraw(this)) + { + form.ShowDialog(this); + } } PanelUpdateRightAndBottom(); @@ -575,14 +588,25 @@ private void btnJobMenu_Click(object sender, EventArgs e) } } - FieldMenuButtonEnableDisable(isJobStarted); toolStripBtnFieldTools.Enabled = isJobStarted; - bnd.isHeadlandOn = (bnd.bndList.Count > 0 && bnd.bndList[0].hdLine.Count > 0); + bnd.isHeadlandOn = (bnd.bndList.Count > 0 && bnd.bndList[0].hdLine.Count > 0); + + trk.idx = -1; - if (isJobStarted && trk.gArr.Count > 0) trk.idx = 0; + if (isJobStarted && trk.gArr.Count > 0) + { + for (int i = 0; i < trk.gArr.Count; i++) + { + if (trk.gArr[i].isVisible) + { + trk.idx = i; + break; + } + } + } PanelUpdateRightAndBottom(); @@ -1852,6 +1876,17 @@ private void btnHydLift_Click(object sender, EventArgs e) #region Tools Menu + private void boundaryToolToolStripMenu_Click(object sender, EventArgs e) + { + if (isJobStarted) + { + using (var form = new FormMapBnd(this)) + { + form.ShowDialog(this); + } + } + } + private void SmoothABtoolStripMenu_Click(object sender, EventArgs e) { if (isJobStarted && trk.idx > -1) @@ -2019,6 +2054,22 @@ private void correctionToolStrip_Click(object sender, EventArgs e) #endregion #region Nav Panel + + private void btnTiltUp_Click(object sender, EventArgs e) + { + camera.camPitch -= ((camera.camPitch * 0.012) - 1); + if (camera.camPitch > -58) camera.camPitch = 0; + navPanelCounter = 2; + } + + private void btnTiltDn_Click(object sender, EventArgs e) + { + if (camera.camPitch > -59) camera.camPitch = -60; + camera.camPitch += ((camera.camPitch * 0.012) - 1); + if (camera.camPitch < -70) camera.camPitch = -70; + navPanelCounter = 2; + } + private void btn2D_Click(object sender, EventArgs e) { if (isTT) diff --git a/SourceCode/GPS/Forms/Field/FormMapBnd.Designer.cs b/SourceCode/GPS/Forms/Field/FormMapBnd.Designer.cs new file mode 100644 index 000000000..cd94e2e05 --- /dev/null +++ b/SourceCode/GPS/Forms/Field/FormMapBnd.Designer.cs @@ -0,0 +1,507 @@ +namespace AgOpenGPS +{ + partial class FormMapBnd + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.components = new System.ComponentModel.Container(); + this.oglSelf = new OpenTK.GLControl(); + this.timer1 = new System.Windows.Forms.Timer(this.components); + this.lblStartPoints = new System.Windows.Forms.Label(); + this.cboxPointDistance = new System.Windows.Forms.ComboBox(); + this.lblReducedPoints = new System.Windows.Forms.Label(); + this.lblDist = new System.Windows.Forms.Label(); + this.cboxSmooth = new System.Windows.Forms.ComboBox(); + this.label1 = new System.Windows.Forms.Label(); + this.label2 = new System.Windows.Forms.Label(); + this.label3 = new System.Windows.Forms.Label(); + this.label4 = new System.Windows.Forms.Label(); + this.label5 = new System.Windows.Forms.Label(); + this.label7 = new System.Windows.Forms.Label(); + this.label6 = new System.Windows.Forms.Label(); + this.cboxIsZoom = new System.Windows.Forms.CheckBox(); + this.btnCenterOGL = new System.Windows.Forms.Button(); + this.btnSlice = new System.Windows.Forms.Button(); + this.btnMakeBoundary = new System.Windows.Forms.Button(); + this.btnStartStop = new System.Windows.Forms.Button(); + this.btnResetReduce = new System.Windows.Forms.Button(); + this.btnCancelTouch = new System.Windows.Forms.Button(); + this.btnExit = new System.Windows.Forms.Button(); + this.btnZoomOut = new System.Windows.Forms.Button(); + this.btnZoomIn = new System.Windows.Forms.Button(); + this.SuspendLayout(); + // + // oglSelf + // + this.oglSelf.BackColor = System.Drawing.Color.Black; + this.oglSelf.Cursor = System.Windows.Forms.Cursors.Cross; + this.oglSelf.Location = new System.Drawing.Point(5, 5); + this.oglSelf.Margin = new System.Windows.Forms.Padding(0); + this.oglSelf.Name = "oglSelf"; + this.oglSelf.Size = new System.Drawing.Size(700, 700); + this.oglSelf.TabIndex = 183; + this.oglSelf.VSync = false; + this.oglSelf.Load += new System.EventHandler(this.oglSelf_Load); + this.oglSelf.Paint += new System.Windows.Forms.PaintEventHandler(this.oglSelf_Paint); + this.oglSelf.MouseDown += new System.Windows.Forms.MouseEventHandler(this.oglSelf_MouseDown); + this.oglSelf.Resize += new System.EventHandler(this.oglSelf_Resize); + // + // timer1 + // + this.timer1.Enabled = true; + this.timer1.Interval = 500; + this.timer1.Tick += new System.EventHandler(this.timer1_Tick); + // + // lblStartPoints + // + this.lblStartPoints.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.lblStartPoints.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblStartPoints.ForeColor = System.Drawing.Color.Black; + this.lblStartPoints.Location = new System.Drawing.Point(848, 23); + this.lblStartPoints.Name = "lblStartPoints"; + this.lblStartPoints.Size = new System.Drawing.Size(139, 25); + this.lblStartPoints.TabIndex = 524; + this.lblStartPoints.Text = "Points"; + this.lblStartPoints.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; + // + // cboxPointDistance + // + this.cboxPointDistance.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.cboxPointDistance.BackColor = System.Drawing.Color.Lavender; + this.cboxPointDistance.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; + this.cboxPointDistance.Enabled = false; + this.cboxPointDistance.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.cboxPointDistance.Font = new System.Drawing.Font("Tahoma", 27.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.cboxPointDistance.FormattingEnabled = true; + this.cboxPointDistance.Items.AddRange(new object[] { + "1", + "2", + "3", + "4", + "5", + "6", + "7", + "8", + "9", + "10"}); + this.cboxPointDistance.Location = new System.Drawing.Point(726, 115); + this.cboxPointDistance.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3); + this.cboxPointDistance.Name = "cboxPointDistance"; + this.cboxPointDistance.Size = new System.Drawing.Size(88, 53); + this.cboxPointDistance.TabIndex = 541; + this.cboxPointDistance.SelectedIndexChanged += new System.EventHandler(this.cboxPointDistance_SelectedIndexChanged); + // + // lblReducedPoints + // + this.lblReducedPoints.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.lblReducedPoints.Enabled = false; + this.lblReducedPoints.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblReducedPoints.ForeColor = System.Drawing.Color.Black; + this.lblReducedPoints.Location = new System.Drawing.Point(871, 81); + this.lblReducedPoints.Name = "lblReducedPoints"; + this.lblReducedPoints.Size = new System.Drawing.Size(115, 25); + this.lblReducedPoints.TabIndex = 542; + this.lblReducedPoints.Text = "***"; + this.lblReducedPoints.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // lblDist + // + this.lblDist.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.lblDist.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblDist.ForeColor = System.Drawing.Color.Black; + this.lblDist.Location = new System.Drawing.Point(726, 295); + this.lblDist.Name = "lblDist"; + this.lblDist.Size = new System.Drawing.Size(237, 25); + this.lblDist.TabIndex = 543; + this.lblDist.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // cboxSmooth + // + this.cboxSmooth.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.cboxSmooth.BackColor = System.Drawing.Color.Lavender; + this.cboxSmooth.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; + this.cboxSmooth.Enabled = false; + this.cboxSmooth.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.cboxSmooth.Font = new System.Drawing.Font("Tahoma", 27.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.cboxSmooth.FormattingEnabled = true; + this.cboxSmooth.Items.AddRange(new object[] { + "4", + "8", + "16", + "32", + "64"}); + this.cboxSmooth.Location = new System.Drawing.Point(726, 231); + this.cboxSmooth.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3); + this.cboxSmooth.Name = "cboxSmooth"; + this.cboxSmooth.Size = new System.Drawing.Size(88, 53); + this.cboxSmooth.TabIndex = 547; + this.cboxSmooth.SelectedIndexChanged += new System.EventHandler(this.cboxSmooth_SelectedIndexChanged); + // + // label1 + // + this.label1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.label1.AutoSize = true; + this.label1.Enabled = false; + this.label1.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label1.ForeColor = System.Drawing.Color.Black; + this.label1.Location = new System.Drawing.Point(817, 127); + this.label1.Name = "label1"; + this.label1.Size = new System.Drawing.Size(32, 25); + this.label1.TabIndex = 562; + this.label1.Text = "m"; + this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label2 + // + this.label2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.label2.AutoSize = true; + this.label2.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label2.ForeColor = System.Drawing.Color.Black; + this.label2.Location = new System.Drawing.Point(712, 32); + this.label2.Name = "label2"; + this.label2.Size = new System.Drawing.Size(14, 13); + this.label2.TabIndex = 563; + this.label2.Text = "1"; + this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label3 + // + this.label3.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.label3.AutoSize = true; + this.label3.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label3.ForeColor = System.Drawing.Color.Black; + this.label3.Location = new System.Drawing.Point(706, 137); + this.label3.Name = "label3"; + this.label3.Size = new System.Drawing.Size(14, 13); + this.label3.TabIndex = 564; + this.label3.Text = "2"; + this.label3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label4 + // + this.label4.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.label4.AutoSize = true; + this.label4.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label4.ForeColor = System.Drawing.Color.Black; + this.label4.Location = new System.Drawing.Point(855, 137); + this.label4.Name = "label4"; + this.label4.Size = new System.Drawing.Size(14, 13); + this.label4.TabIndex = 565; + this.label4.Text = "3"; + this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label5 + // + this.label5.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.label5.AutoSize = true; + this.label5.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label5.ForeColor = System.Drawing.Color.Black; + this.label5.Location = new System.Drawing.Point(708, 251); + this.label5.Name = "label5"; + this.label5.Size = new System.Drawing.Size(14, 13); + this.label5.TabIndex = 566; + this.label5.Text = "4"; + this.label5.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label7 + // + this.label7.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.label7.AutoSize = true; + this.label7.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label7.ForeColor = System.Drawing.Color.Black; + this.label7.Location = new System.Drawing.Point(856, 252); + this.label7.Name = "label7"; + this.label7.Size = new System.Drawing.Size(14, 13); + this.label7.TabIndex = 568; + this.label7.Text = "5"; + this.label7.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label6 + // + this.label6.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.label6.AutoSize = true; + this.label6.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label6.ForeColor = System.Drawing.Color.Black; + this.label6.Location = new System.Drawing.Point(741, 215); + this.label6.Name = "label6"; + this.label6.Size = new System.Drawing.Size(51, 13); + this.label6.TabIndex = 569; + this.label6.Text = "Smooth"; + this.label6.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // cboxIsZoom + // + this.cboxIsZoom.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.cboxIsZoom.Appearance = System.Windows.Forms.Appearance.Button; + this.cboxIsZoom.BackColor = System.Drawing.Color.WhiteSmoke; + this.cboxIsZoom.Checked = true; + this.cboxIsZoom.CheckState = System.Windows.Forms.CheckState.Checked; + this.cboxIsZoom.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.cboxIsZoom.FlatAppearance.CheckedBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(255)))), ((int)(((byte)(160))))); + this.cboxIsZoom.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.cboxIsZoom.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.cboxIsZoom.ForeColor = System.Drawing.SystemColors.ButtonFace; + this.cboxIsZoom.Image = global::AgOpenGPS.Properties.Resources.ZoomOGL; + this.cboxIsZoom.Location = new System.Drawing.Point(731, 344); + this.cboxIsZoom.Name = "cboxIsZoom"; + this.cboxIsZoom.RightToLeft = System.Windows.Forms.RightToLeft.Yes; + this.cboxIsZoom.Size = new System.Drawing.Size(81, 83); + this.cboxIsZoom.TabIndex = 561; + this.cboxIsZoom.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.cboxIsZoom.UseVisualStyleBackColor = false; + this.cboxIsZoom.CheckedChanged += new System.EventHandler(this.cboxIsZoom_CheckedChanged); + this.cboxIsZoom.Click += new System.EventHandler(this.cboxIsZoom_Click); + // + // btnCenterOGL + // + this.btnCenterOGL.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnCenterOGL.BackColor = System.Drawing.Color.White; + this.btnCenterOGL.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; + this.btnCenterOGL.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.btnCenterOGL.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnCenterOGL.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnCenterOGL.Image = global::AgOpenGPS.Properties.Resources.ConS_SourceFix; + this.btnCenterOGL.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnCenterOGL.Location = new System.Drawing.Point(731, 466); + this.btnCenterOGL.Name = "btnCenterOGL"; + this.btnCenterOGL.Size = new System.Drawing.Size(81, 83); + this.btnCenterOGL.TabIndex = 560; + this.btnCenterOGL.UseVisualStyleBackColor = false; + this.btnCenterOGL.Click += new System.EventHandler(this.btnCenterOGL_Click); + // + // btnSlice + // + this.btnSlice.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnSlice.BackColor = System.Drawing.Color.WhiteSmoke; + this.btnSlice.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; + this.btnSlice.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.btnSlice.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnSlice.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnSlice.Image = global::AgOpenGPS.Properties.Resources.BoundaryMakeLine; + this.btnSlice.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnSlice.Location = new System.Drawing.Point(877, 345); + this.btnSlice.Name = "btnSlice"; + this.btnSlice.Size = new System.Drawing.Size(81, 83); + this.btnSlice.TabIndex = 548; + this.btnSlice.UseVisualStyleBackColor = false; + this.btnSlice.Click += new System.EventHandler(this.btnSlice_Click); + // + // btnMakeBoundary + // + this.btnMakeBoundary.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.btnMakeBoundary.BackColor = System.Drawing.Color.WhiteSmoke; + this.btnMakeBoundary.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; + this.btnMakeBoundary.Enabled = false; + this.btnMakeBoundary.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.btnMakeBoundary.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnMakeBoundary.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnMakeBoundary.Image = global::AgOpenGPS.Properties.Resources.BoundaryOuter; + this.btnMakeBoundary.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnMakeBoundary.Location = new System.Drawing.Point(877, 221); + this.btnMakeBoundary.Name = "btnMakeBoundary"; + this.btnMakeBoundary.Size = new System.Drawing.Size(110, 68); + this.btnMakeBoundary.TabIndex = 545; + this.btnMakeBoundary.UseVisualStyleBackColor = false; + this.btnMakeBoundary.Click += new System.EventHandler(this.btnMakeBoundary_Click); + // + // btnStartStop + // + this.btnStartStop.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.btnStartStop.BackColor = System.Drawing.Color.WhiteSmoke; + this.btnStartStop.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; + this.btnStartStop.Enabled = false; + this.btnStartStop.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.btnStartStop.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnStartStop.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnStartStop.Image = global::AgOpenGPS.Properties.Resources.BoundaryReduce; + this.btnStartStop.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnStartStop.Location = new System.Drawing.Point(877, 110); + this.btnStartStop.Name = "btnStartStop"; + this.btnStartStop.Size = new System.Drawing.Size(115, 61); + this.btnStartStop.TabIndex = 544; + this.btnStartStop.UseVisualStyleBackColor = false; + this.btnStartStop.Click += new System.EventHandler(this.btnStartStop_Click); + // + // btnResetReduce + // + this.btnResetReduce.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.btnResetReduce.BackColor = System.Drawing.Color.WhiteSmoke; + this.btnResetReduce.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; + this.btnResetReduce.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.btnResetReduce.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnResetReduce.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnResetReduce.Image = global::AgOpenGPS.Properties.Resources.BoundarySmooth; + this.btnResetReduce.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnResetReduce.Location = new System.Drawing.Point(726, 5); + this.btnResetReduce.Name = "btnResetReduce"; + this.btnResetReduce.Size = new System.Drawing.Size(115, 61); + this.btnResetReduce.TabIndex = 540; + this.btnResetReduce.UseVisualStyleBackColor = false; + this.btnResetReduce.Click += new System.EventHandler(this.btnResetReduce_Click); + // + // btnCancelTouch + // + this.btnCancelTouch.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnCancelTouch.BackColor = System.Drawing.Color.WhiteSmoke; + this.btnCancelTouch.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnCancelTouch.FlatAppearance.BorderColor = System.Drawing.SystemColors.ControlText; + this.btnCancelTouch.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnCancelTouch.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnCancelTouch.Image = global::AgOpenGPS.Properties.Resources.HeadlandDeletePoints; + this.btnCancelTouch.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnCancelTouch.Location = new System.Drawing.Point(877, 466); + this.btnCancelTouch.Name = "btnCancelTouch"; + this.btnCancelTouch.Size = new System.Drawing.Size(81, 83); + this.btnCancelTouch.TabIndex = 470; + this.btnCancelTouch.UseVisualStyleBackColor = false; + this.btnCancelTouch.Click += new System.EventHandler(this.btnCancelTouch_Click); + // + // btnExit + // + this.btnExit.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnExit.BackColor = System.Drawing.Color.Transparent; + this.btnExit.DialogResult = System.Windows.Forms.DialogResult.Cancel; + this.btnExit.FlatAppearance.BorderSize = 0; + this.btnExit.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnExit.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnExit.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(64)))), ((int)(((byte)(0))))); + this.btnExit.Image = global::AgOpenGPS.Properties.Resources.OK64; + this.btnExit.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; + this.btnExit.Location = new System.Drawing.Point(906, 628); + this.btnExit.Name = "btnExit"; + this.btnExit.Size = new System.Drawing.Size(83, 70); + this.btnExit.TabIndex = 0; + this.btnExit.UseVisualStyleBackColor = false; + this.btnExit.Click += new System.EventHandler(this.btnExit_Click); + // + // btnZoomOut + // + this.btnZoomOut.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnZoomOut.BackColor = System.Drawing.Color.White; + this.btnZoomOut.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; + this.btnZoomOut.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.btnZoomOut.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnZoomOut.Font = new System.Drawing.Font("Tahoma", 36F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnZoomOut.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnZoomOut.Location = new System.Drawing.Point(729, 582); + this.btnZoomOut.Name = "btnZoomOut"; + this.btnZoomOut.Size = new System.Drawing.Size(66, 69); + this.btnZoomOut.TabIndex = 570; + this.btnZoomOut.Text = "-"; + this.btnZoomOut.UseVisualStyleBackColor = false; + this.btnZoomOut.Click += new System.EventHandler(this.btnZoomOut_Click); + // + // btnZoomIn + // + this.btnZoomIn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.btnZoomIn.BackColor = System.Drawing.Color.White; + this.btnZoomIn.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; + this.btnZoomIn.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.btnZoomIn.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnZoomIn.Font = new System.Drawing.Font("Tahoma", 27.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnZoomIn.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnZoomIn.Location = new System.Drawing.Point(822, 582); + this.btnZoomIn.Name = "btnZoomIn"; + this.btnZoomIn.Size = new System.Drawing.Size(66, 69); + this.btnZoomIn.TabIndex = 571; + this.btnZoomIn.Text = "+"; + this.btnZoomIn.UseVisualStyleBackColor = false; + this.btnZoomIn.Click += new System.EventHandler(this.btnZoomIn_Click); + // + // FormMapBnd + // + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.BackColor = System.Drawing.Color.DarkGray; + this.ClientSize = new System.Drawing.Size(1000, 711); + this.Controls.Add(this.btnZoomIn); + this.Controls.Add(this.btnZoomOut); + this.Controls.Add(this.label6); + this.Controls.Add(this.label7); + this.Controls.Add(this.label5); + this.Controls.Add(this.label4); + this.Controls.Add(this.label3); + this.Controls.Add(this.label2); + this.Controls.Add(this.label1); + this.Controls.Add(this.cboxIsZoom); + this.Controls.Add(this.btnCenterOGL); + this.Controls.Add(this.btnSlice); + this.Controls.Add(this.cboxSmooth); + this.Controls.Add(this.btnMakeBoundary); + this.Controls.Add(this.btnStartStop); + this.Controls.Add(this.lblReducedPoints); + this.Controls.Add(this.cboxPointDistance); + this.Controls.Add(this.btnResetReduce); + this.Controls.Add(this.lblStartPoints); + this.Controls.Add(this.btnCancelTouch); + this.Controls.Add(this.btnExit); + this.Controls.Add(this.oglSelf); + this.Controls.Add(this.lblDist); + this.ForeColor = System.Drawing.Color.Black; + this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None; + this.HelpButton = true; + this.MaximizeBox = false; + this.MinimizeBox = false; + this.Name = "FormMapBnd"; + this.ShowInTaskbar = false; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; + this.Text = "Draw AB - Click 2 points on the Boundary to Begin"; + this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.FormMapBnd_FormClosing); + this.Load += new System.EventHandler(this.FormMapBnd_Load); + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + + private OpenTK.GLControl oglSelf; + private System.Windows.Forms.Timer timer1; + private System.Windows.Forms.Button btnExit; + private System.Windows.Forms.Button btnCancelTouch; + private System.Windows.Forms.Label lblStartPoints; + private System.Windows.Forms.ComboBox cboxPointDistance; + private System.Windows.Forms.Button btnResetReduce; + private System.Windows.Forms.Label lblReducedPoints; + private System.Windows.Forms.Label lblDist; + private System.Windows.Forms.Button btnStartStop; + private System.Windows.Forms.Button btnMakeBoundary; + private System.Windows.Forms.ComboBox cboxSmooth; + private System.Windows.Forms.Button btnSlice; + private System.Windows.Forms.Button btnCenterOGL; + private System.Windows.Forms.CheckBox cboxIsZoom; + private System.Windows.Forms.Label label1; + private System.Windows.Forms.Label label2; + private System.Windows.Forms.Label label3; + private System.Windows.Forms.Label label4; + private System.Windows.Forms.Label label5; + private System.Windows.Forms.Label label7; + private System.Windows.Forms.Label label6; + private System.Windows.Forms.Button btnZoomOut; + private System.Windows.Forms.Button btnZoomIn; + } +} \ No newline at end of file diff --git a/SourceCode/GPS/Forms/Field/FormMapBnd.cs b/SourceCode/GPS/Forms/Field/FormMapBnd.cs new file mode 100644 index 000000000..c4e72979d --- /dev/null +++ b/SourceCode/GPS/Forms/Field/FormMapBnd.cs @@ -0,0 +1,1021 @@ +using OpenTK; +using OpenTK.Graphics.OpenGL; +using System; +using System.Collections.Generic; +using System.Drawing; +using System.Globalization; +using System.Runtime.CompilerServices; +using System.Windows.Forms; +using static System.Windows.Forms.VisualStyles.VisualStyleElement; + +namespace AgOpenGPS +{ + public partial class FormMapBnd : Form + { + //access to the main GPS form and all its variables + private readonly FormGPS mf = null; + + private Point fixPt; + + private bool isA = true; + private int start = 99999, end = 99999; + private int bndSelect = 0, smPtsChoose = 1, smPts = 4; + + private double zoom = 1, sX = 0, sY = 0; + + private int operations; + + //public List gTemp = new List(); + + public vec3 pint = new vec3(0.0, 1.0, 0.0); + + public List secList = new List(); + public List bndList = new List(); + public List smooList = new List(); + public List tempList = new List(); + + private double minDistSq = 1, minDistDisp = 1; + + private bool isStep = false; + + private double mdA = double.MaxValue; + private double mdB = double.MaxValue; + private double mdC = double.MaxValue; + private double mdD = double.MaxValue; + private double mdE = double.MaxValue; + private double mdF = double.MaxValue; + private double mdG = double.MaxValue; + private int rA, rB, rC, rD, rE, rF, rG; + + private int firstPoint, currentPoint; + + //find 3 closest points + private vec3[] arr; + + //baseline to calc the most right vector - starts at 270 deg. + private double prevHeading = Math.PI + glm.PIBy2; + + public FormMapBnd(Form callingForm) + { + //get copy of the calling main form + mf = callingForm as FormGPS; + + InitializeComponent(); + + mf.CalculateMinMax(); + } + + private void FormMapBnd_Load(object sender, EventArgs e) + { + //already have a boundary + if (mf.bnd.bndList.Count == 0) + { + //draw patches j= # of sections + for (int j = 0; j < mf.triStrip.Count; j++) + { + //every time the section turns off and on is a new patch + int patchCount = mf.triStrip[j].patchList.Count; + + if (patchCount > 0) + { + //for every new chunk of patch + foreach (var triList in mf.triStrip[j].patchList) + { + for (int i = 1; i < triList.Count; i++) + { + vec3 bob = new vec3(triList[i].easting, triList[i].northing, 0); + + secList.Add(bob); + } + } + } + } + lblStartPoints.Text = secList.Count.ToString(); + } + else + { + + } + + cboxPointDistance.SelectedIndexChanged -= cboxPointDistance_SelectedIndexChanged; + cboxPointDistance.Text = "1"; + cboxPointDistance.SelectedIndexChanged += cboxPointDistance_SelectedIndexChanged; + + cboxSmooth.SelectedIndexChanged -= cboxSmooth_SelectedIndexChanged; + cboxSmooth.Text = "4"; + cboxSmooth.SelectedIndexChanged += cboxSmooth_SelectedIndexChanged; + cboxIsZoom.Checked = false; + } + + private void FormMapBnd_FormClosing(object sender, FormClosingEventArgs e) + { + } + + private void KNN() + { + timer1.Enabled = false; + rA = rB = rC = rD = rE = rF = rG = 0; + + for (int j = 0; j < secList.Count; j++) + { + operations++; + + if (j == currentPoint) continue; + + if (arr[j].heading == 1) + continue; + + double dist = glm.DistanceSquared(secList[currentPoint], secList[j]); + + if (dist < mdA) + { + mdG = mdF; mdF = mdE; mdE = mdD; mdD = mdC; mdC = mdB; mdB = mdA; mdA = dist; rG = rF; rF = rE; rE = rD; rD = rC; rC = rB; rB = rA; rA = j; + } + else if (dist < mdB) + { + rG = rF; rF = rE; rE = rD; rD = rC; rC = rB; rB = j; mdG = mdF; mdF = mdE; mdE = mdD; mdD = mdC; mdC = mdB; mdB = dist; + } + else if (dist < mdC) + { + mdG = mdF; mdF = mdE; mdE = mdD; mdD = mdC; mdC = dist; rG = rF; rF = rE; rE = rD; rD = rC; rC = j; + } + else if (dist < mdD) + { + mdG = mdF; mdF = mdE; mdE = mdD; mdD = dist; rG = rF; rF = rE; rE = rD; rD = j; + } + else if (dist < mdE) + { + mdG = mdF; mdF = mdE; mdE = dist; rG = rF; rF = rE; rE = j; + } + else if (dist < mdF) + { + mdG = mdF; mdF = dist; rG = rF; rF = j; + } + else if (dist < mdG) + { + mdG = dist; rG = j; + } + } + + double aMax = 5; + double aMin = 1.14; + + double aA = Math.Atan2(secList[rA].easting - secList[currentPoint].easting, + secList[rA].northing - secList[currentPoint].northing); + double pA = aA; + + aA -= prevHeading; + if (aA < 0) aA += glm.twoPI; if (aA < 0) aA += glm.twoPI; + if (aA > aMax || aA < aMin) aA = 0; + + double aB = Math.Atan2(secList[rB].easting - secList[currentPoint].easting, + secList[rB].northing - secList[currentPoint].northing); + double pB = aB; + aB -= prevHeading; + if (aB < 0) aB += glm.twoPI; if (aB < 0) aB += glm.twoPI; + + if (aB > aMax || aB < aMin) aB = 0; + + double aC = Math.Atan2(secList[rC].easting - secList[currentPoint].easting, + secList[rC].northing - secList[currentPoint].northing); + double pC = aC; + + aC -= prevHeading; + if (aC < 0) aC += glm.twoPI; if (aC < 0) aC += glm.twoPI; + if (aC > aMax || aC < aMin) aC = 0; + + double aD = Math.Atan2(secList[rD].easting - secList[currentPoint].easting, + secList[rD].northing - secList[currentPoint].northing); + double pD = aD; + + aD -= prevHeading; + if (aD < 0) aD += glm.twoPI; if (aD < 0) aD += glm.twoPI; + if (aD > aMax || aD < aMin) aD = 0; + + double aE = Math.Atan2(secList[rE].easting - secList[currentPoint].easting, + secList[rE].northing - secList[currentPoint].northing); + double pE = aE; + + aE -= prevHeading; + if (aE < 0) aE += glm.twoPI; if (aE < 0) aE += glm.twoPI; + if (aE > aMax || aE < aMin) aE = 0; + + double aF = Math.Atan2(secList[rF].easting - secList[currentPoint].easting, + secList[rF].northing - secList[currentPoint].northing); + double pF = aF; + + aF -= prevHeading; + if (aF < 0) aF += glm.twoPI; if (aF < 0) aF += glm.twoPI; + if (aF > aMax || aF < aMin) aF = 0; + + double aG = Math.Atan2(secList[rG].easting - secList[currentPoint].easting, + secList[rG].northing - secList[currentPoint].northing); + double pG = aG; + + aG -= prevHeading; + if (aG < 0) aG += glm.twoPI; if (aG < 0) aG += glm.twoPI; + if (aG > aMax || aG < aMin) aG = 0; + + //double maxAngle = 999; + //switch (k) + //{ + // case 3: + // maxAngle = Math.Max(Math.Max(aA, aB), aC); + // break; + // case 4: + // maxAngle = Math.Max(Math.Max(Math.Max(aA, aB), aC), aD); + // break; + // case 5: + // maxAngle = Math.Max(Math.Max(Math.Max(Math.Max(aA, aB), aC), aD), aE); + // break; + // case 6: + // maxAngle = Math.Max(Math.Max(Math.Max(Math.Max(Math.Max(aA, aB), aC), aD), aE), aF); + // break; + // case 7: + // maxAngle = Math.Max(Math.Max(Math.Max(Math.Max(Math.Max(Math.Max(aA, aB), aC), aD), aE), aF), aG); + // break; + //} + + double maxAngle = Math.Max(Math.Max(Math.Max(Math.Max(Math.Max(Math.Max(aA, aB), aC), aD), aE), aF), aG); + + //remove from list + arr[currentPoint].heading = 1; + + if (maxAngle == aA) { currentPoint = rA; prevHeading = pA + Math.PI; } + else if (maxAngle == aB) { currentPoint = rB; prevHeading = pB + Math.PI; } + else if (maxAngle == aC) { currentPoint = rC; prevHeading = pC + Math.PI; } + else if (maxAngle == aD) { currentPoint = rD; prevHeading = pD + Math.PI; } + else if (maxAngle == aE) { currentPoint = rE; prevHeading = pE + Math.PI; } + else if (maxAngle == aF) { currentPoint = rF; prevHeading = pF + Math.PI; } + else if (maxAngle == aG) { currentPoint = rG; prevHeading = pG + Math.PI; } + + if (prevHeading >= glm.twoPI) prevHeading -= glm.twoPI; + if (prevHeading < 0) prevHeading += glm.twoPI; + + mdA = double.MaxValue; + mdB = double.MaxValue; + mdC = double.MaxValue; + mdD = double.MaxValue; + mdE = double.MaxValue; + mdF = double.MaxValue; + mdG = double.MaxValue; + + + lblDist.Text = operations.ToString(); + + if (bndList.Count > 7) + { + //unhide first point + arr[firstPoint].heading = 0; + + //are we back to start? + if (rA == firstPoint || rB == firstPoint || rC == firstPoint || + rD == firstPoint || rE == firstPoint || rF == firstPoint || rG == firstPoint) + { + isStep = false; + timer1.Interval = 500; + timer1.Enabled = true; + cboxSmooth.Enabled = true; + + int bndCount = bndList.Count; + + for (int i = 0; i < bndCount; i++) + { + int j = i + 1; + + if (j == bndCount) j = 0; + double distance = glm.Distance(bndList[i], bndList[j]); + if (distance > 1.1) + { + vec3 pointB = new vec3((bndList[i].easting + bndList[j].easting) / 2.0, + (bndList[i].northing + bndList[j].northing) / 2.0, bndList[i].heading); + + bndList.Insert(j, pointB); + bndCount = bndList.Count; + i--; + } + } + return; + } + } + + bndList.Add(new vec3(secList[currentPoint])); + timer1.Enabled = true; + } + + private void DeleteBoundary() + { + mf.bnd.bndList?.Clear(); + mf.FileSaveBoundary(); + mf.fd.UpdateFieldBoundaryGUIAreas(); + mf.FileSaveHeadland(); + } + + private void btnResetReduce_Click(object sender, EventArgs e) + { + //start all over + operations = 0; + lblDist.Text = ""; + zoom = 1; + sX = 0; + sY = 0; + + btnStartStop.Enabled = false; + cboxPointDistance.Enabled = false; + cboxSmooth.Enabled = false; + btnMakeBoundary.Enabled = false; + + if (mf.bnd.bndList.Count > 0) + { + DialogResult result3 = MessageBox.Show(gStr.gsDeleteBoundaryMapping, + gStr.gsDeleteForSure, + MessageBoxButtons.YesNo, + MessageBoxIcon.Question, + MessageBoxDefaultButton.Button2); + if (result3 != DialogResult.Yes) + { + return; + } + } + + DeleteBoundary(); + lblStartPoints.Text = secList.Count.ToString(); + + isStep = false; + timer1.Interval = 500; + prevHeading = Math.PI + glm.PIBy2; + + secList?.Clear(); + bndList?.Clear(); + smooList?.Clear(); + + for (int j = 0; j < mf.triStrip.Count; j++) + { + //every time the section turns off and on is a new patch + int patchCount = mf.triStrip[j].patchList.Count; + + if (patchCount > 0) + { + //for every new chunk of patch + foreach (var triList in mf.triStrip[j].patchList) + { + for (int i = 1; i < triList.Count; i++) + { + vec3 bob = new vec3(triList[i].easting, triList[i].northing, 0); + + secList.Add(bob); + } + } + } + } + + lblReducedPoints.Text = secList.Count.ToString(); + lblStartPoints.Text = secList.Count.ToString(); + + rA = rB = rC = rD = rE = rF = rG = firstPoint = currentPoint = 0; + bndList?.Clear(); + + btnStartStop.BackColor = Color.OrangeRed; + + cboxPointDistance.Enabled = true; + } + + private void btnMakeBoundary_Click(object sender, EventArgs e) + { + if (smooList.Count == 0) return; + + if (smooList.Count > 5) + { + secList?.Clear(); + + //just in case + DeleteBoundary(); + + CBoundaryList New = new CBoundaryList(); + + for (int i = 0; i < smooList.Count; i++) + { + New.fenceLine.Add(new vec3(smooList[i])); + } + + New.CalculateFenceArea(0); + New.FixFenceLine(0); + mf.bnd.bndList.Add(New); + smooList.Clear(); + bndList?.Clear(); + + //turn lines made from boundaries + mf.CalculateMinMax(); + mf.bnd.BuildTurnLines(); + + mf.fd.UpdateFieldBoundaryGUIAreas(); + mf.FileSaveBoundary(); + } + + btnStartStop.Enabled = false; + cboxPointDistance.Enabled = false; + cboxSmooth.Enabled = false; + btnMakeBoundary.Enabled = false; + } + + private void cboxSmooth_SelectedIndexChanged(object sender, EventArgs e) + { + smPtsChoose = cboxSmooth.SelectedIndex + 1; + smPts = 2; + for (int i = 1; i <= smPtsChoose; i++) + smPts *= 2; + cboxSmooth.Text = smPts.ToString(); + SmoothList(); + } + + private void cboxPointDistance_SelectedIndexChanged(object sender, EventArgs e) + { + timer1.Interval = 500; + isStep = false; + + minDistDisp = (double)(cboxPointDistance.SelectedIndex + 1); + minDistSq = minDistDisp * minDistDisp; + + rA = rB = rC = rD = rE = rF = rG = firstPoint = currentPoint = 0; + + secList?.Clear(); + + for (int j = 0; j < mf.triStrip.Count; j++) + { + //every time the section turns off and on is a new patch + int patchCount = mf.triStrip[j].patchList.Count; + + if (patchCount > 0) + { + //for every new chunk of patch + foreach (var triList in mf.triStrip[j].patchList) + { + for (int i = 1; i < triList.Count; i++) + { + vec3 bob = new vec3(triList[i].easting, triList[i].northing, 0); + + secList.Add(bob); + } + } + } + } + + vec3[] arr = new vec3[secList.Count]; + secList.CopyTo(arr); + + for (int i = 0; i < secList.Count; i++) + { + //already checked + if (arr[i].heading > 0) + continue; + + for (int j = 0; j < secList.Count; j++) + { + if (j == i) continue; + //if (arr[j].heading != 0) continue; + + if (arr[j].heading == 0) + { + double dist = glm.DistanceSquared(secList[i], secList[j]); + if (dist < minDistSq) + { + //means delete this point + arr[j].heading = 1; + } + } + } + + //points all around it are removed or > minDist + arr[i].heading = 2; + } + + secList?.Clear(); + foreach (var item in arr) + { + //0 will mean visible + if (item.heading == 2) secList.Add(new vec3(item.easting, item.northing, 0)); + } + + lblReducedPoints.Text = secList.Count.ToString(); + + //Find most South point + double minny = double.MaxValue; + + for (int j = 0; j < secList.Count; j++) + { + if (minny > secList[j].northing) + { + firstPoint = j; + minny = secList[j].northing; + } + } + + btnStartStop.BackColor = Color.LightGreen; + btnStartStop.Enabled = true; + } + + private void btnZoomOut_Click(object sender, EventArgs e) + { + zoom += 0.1; + if (zoom > 1) zoom = 1; + } + + private void btnZoomIn_Click(object sender, EventArgs e) + { + zoom -= 0.1; + if (zoom < 0.1) zoom = 0.1; + } + + private void cboxIsZoom_CheckedChanged(object sender, EventArgs e) + { + + } + + private void btnStartStop_Click(object sender, EventArgs e) + { + if (secList.Count == 0) return; + + arr = new vec3[secList.Count]; + prevHeading = Math.PI + glm.PIBy2; + + //find most southerly - lowest Y point + double minny = double.MaxValue; + for (int j = 0; j < secList.Count; j++) + { + if (minny > secList[j].northing) + { + firstPoint = j; + minny = secList[j].northing; + } + } + + //keep firstPoint + currentPoint = firstPoint; + + //first point of bnd + bndList?.Clear(); + bndList.Add(new vec3(secList[currentPoint])); + + secList.CopyTo(arr); + + isStep = !isStep; + + if (isStep) timer1.Interval = 50; + else timer1.Interval = 500; + btnStartStop.BackColor = Color.WhiteSmoke; + //btnStartStop.Enabled = false; + cboxSmooth.Enabled = false; + } + + private void SmoothList() + { + secList?.Clear(); + + //just go back if not very long + if (bndList.Count < 20) return; + + int cnt = bndList.Count; + + //the temp array + vec3[] arr = new vec3[cnt]; + + //read the points before and after the setpoint + for (int s = 0; s < smPts / 2; s++) + { + arr[s].easting = bndList[s].easting; + arr[s].northing = bndList[s].northing; + arr[s].heading = bndList[s].heading; + } + + for (int s = cnt - (smPts / 2); s < cnt; s++) + { + arr[s].easting = bndList[s].easting; + arr[s].northing = bndList[s].northing; + arr[s].heading = bndList[s].heading; + } + + //average them - center weighted average + for (int i = smPts / 2; i < cnt - (smPts / 2); i++) + { + for (int j = -smPts / 2; j < smPts / 2; j++) + { + arr[i].easting += bndList[j + i].easting; + arr[i].northing += bndList[j + i].northing; + } + arr[i].easting /= smPts; + arr[i].northing /= smPts; + arr[i].heading = bndList[i].heading; + } + + //make a list to draw + smooList?.Clear(); + + if (arr == null || cnt < 1) return; + if (smooList == null) return; + + for (int i = 0; i < cnt; i++) + { + smooList.Add(arr[i]); + } + + mf.curve.CalculateHeadings(ref smooList); + + List smList = new List(); + + for (int i = 0; i < smooList.Count; i++) + { + smList.Add(new vec3(smooList[i])); + } + double delta = 0; + smooList?.Clear(); + + for (int i = 0; i < smList.Count; i++) + { + if (i == 0) + { + smooList.Add(new vec3(smList[i])); + continue; + } + delta += (smList[i - 1].heading - smList[i].heading); + if (Math.Abs(delta) > 0.05) + { + smooList.Add(new vec3(smList[i])); + delta = 0; + } + } + + int bndCount = smooList.Count; + + for (int i = 0; i < bndCount; i++) + { + int j = i + 1; + + if (j == bndCount) j = 0; + double distance = glm.Distance(smooList[i], smooList[j]); + if (distance > 1.6) + { + vec3 pointB = new vec3((smooList[i].easting + smooList[j].easting) / 2.0, + (smooList[i].northing + smooList[j].northing) / 2.0, smooList[i].heading); + + smooList.Insert(j, pointB); + bndCount = smooList.Count; + i--; + } + } + + mf.curve.CalculateHeadings(ref smooList); + + btnMakeBoundary.Enabled = true; + } + + private void btnSlice_Click(object sender, EventArgs e) + { + bool isLoop = false; + int limit = end; + + if ((Math.Abs(start - end)) > (mf.bnd.bndList[bndSelect].fenceLine.Count * 0.5)) + { + isLoop = true; + if (start < end) + { + (end, start) = (start, end); + } + + limit = end; + end = mf.bnd.bndList[bndSelect].fenceLine.Count; + } + else //normal + { + if (start > end) + { + (end, start) = (start, end); + } + } + + vec3[] arr = new vec3[mf.bnd.bndList[0].fenceLine.Count]; + mf.bnd.bndList[0].fenceLine.CopyTo(arr); + + if (start++ == arr.Length) start--; + //if (end-- == -1) end = 0; + if (start == end) return; + + for (int i = start; i < end; i++) + { + //calculate the point inside the boundary + arr[i].heading = 999; + + if (isLoop && i == mf.bnd.bndList[bndSelect].fenceLine.Count - 1) + { + i = -1; + isLoop = false; + end = limit; + } + } + + mf.bnd.bndList[bndSelect].fenceLine.Clear(); + + for (int i = 0; i < arr.Length; i++) + { + //calculate the point inside the boundary + if (arr[i].heading != 999) + mf.bnd.bndList[bndSelect].fenceLine.Add(new vec3(arr[i])); + + if (isLoop && i == arr.Length - 1) + { + i = -1; + isLoop = false; + end = limit; + } + } + + mf.bnd.bndList[0].FixFenceLine(0); + + mf.CalculateMinMax(); + mf.bnd.BuildTurnLines(); + + mf.fd.UpdateFieldBoundaryGUIAreas(); + mf.FileSaveBoundary(); + + start = 99999; end = 99999; + isA = true; + + zoom = 1; + sX = 0; + sY = 0; + } + + private void cboxIsZoom_Click(object sender, EventArgs e) + { + } + + private void btnCenterOGL_Click(object sender, EventArgs e) + { + zoom = 1; + sX = 0; + sY = 0; + } + + private void btnExit_Click(object sender, EventArgs e) + { + Close(); + } + + private void btnCancelTouch_Click(object sender, EventArgs e) + { + //update the arrays + start = 99999; end = 99999; + btnExit.Focus(); + } + + private void oglSelf_MouseDown(object sender, MouseEventArgs e) + { + + Point pt = oglSelf.PointToClient(Cursor.Position); + + //Convert to Origin in the center of window, 800 pixels + fixPt.X = pt.X - 350; + fixPt.Y = (700 - pt.Y - 350); + + if (cboxIsZoom.Checked) + { + sX = ((350 - (double)pt.X) / 700) * 1.1; + sY = ((350 - (double)pt.Y) / -700) * 1.1; + zoom = 0.2; + cboxIsZoom.Checked = false; + return; + } + + if (mf.bnd.bndList.Count < 1) { return; } + + vec3 plotPt = new vec3 + { + //convert screen coordinates to field coordinates + easting = fixPt.X * mf.maxFieldDistance / 632 * zoom, + northing = fixPt.Y * mf.maxFieldDistance / 632 * zoom, + heading = 0 + }; + + plotPt.easting += mf.fieldCenterX+mf.maxFieldDistance*-sX; + plotPt.northing += mf.fieldCenterY+mf.maxFieldDistance*-sY; + + pint.easting = plotPt.easting; + pint.northing = plotPt.northing; + + if (isA) + { + double minDistA = double.MaxValue; + start = 99999; end = 99999; + + for (int j = 0; j < mf.bnd.bndList.Count; j++) + { + for (int i = 0; i < mf.bnd.bndList[j].fenceLine.Count; i++) + { + double dist = ((pint.easting - mf.bnd.bndList[j].fenceLine[i].easting) * (pint.easting - mf.bnd.bndList[j].fenceLine[i].easting)) + + ((pint.northing - mf.bnd.bndList[j].fenceLine[i].northing) * (pint.northing - mf.bnd.bndList[j].fenceLine[i].northing)); + if (dist < minDistA) + { + minDistA = dist; + bndSelect = j; + start = i; + } + } + } + + isA = false; + } + else + { + double minDistA = double.MaxValue; + int j = bndSelect; + + for (int i = 0; i < mf.bnd.bndList[j].fenceLine.Count; i++) + { + double dist = ((pint.easting - mf.bnd.bndList[j].fenceLine[i].easting) * (pint.easting - mf.bnd.bndList[j].fenceLine[i].easting)) + + ((pint.northing - mf.bnd.bndList[j].fenceLine[i].northing) * (pint.northing - mf.bnd.bndList[j].fenceLine[i].northing)); + if (dist < minDistA) + { + minDistA = dist; + end = i; + } + } + + isA = true; + } + } + + private void oglSelf_Paint(object sender, PaintEventArgs e) + { + if (isStep) KNN(); + + + oglSelf.MakeCurrent(); + + GL.Clear(ClearBufferMask.DepthBufferBit | ClearBufferMask.ColorBufferBit); + GL.LoadIdentity(); // Reset The View + + if (isStep) + { + //back the camera up + GL.Translate(0, 0, -mf.maxFieldDistance * 0.5); + + //translate to that spot in the world + GL.Translate(-secList[currentPoint].easting, -secList[currentPoint].northing, 0); + } + else + { + //back the camera up + GL.Translate(0, 0, -mf.maxFieldDistance * zoom); + + //translate to that spot in the world + GL.Translate(-mf.fieldCenterX + sX * mf.maxFieldDistance, -mf.fieldCenterY + sY * mf.maxFieldDistance, 0); + } + + //draw all the boundaries + + GL.LineWidth(2); + + GL.Color3(0.725f, 0.95f, 0.950f); + + if (mf.bnd.bndList.Count > 0) + { + GL.Begin(PrimitiveType.LineLoop); + for (int i = 0; i < mf.bnd.bndList[0].fenceLine.Count; i++) + { + GL.Vertex3(mf.bnd.bndList[0].fenceLine[i].easting, mf.bnd.bndList[0].fenceLine[i].northing, 0); + } + GL.End(); + + GL.PointSize(4); + GL.Begin(PrimitiveType.Points); + for (int i = 0; i < mf.bnd.bndList[0].fenceLine.Count; i++) + { + GL.Vertex3(mf.bnd.bndList[0].fenceLine[i].easting, mf.bnd.bndList[0].fenceLine[i].northing, 0); + } + GL.End(); + } + + //new boundary being made + if (bndList.Count > 0) + { + GL.LineWidth(2); + GL.Color3(0.90f, 0.25f, 0.10f); + GL.Begin(PrimitiveType.LineStrip); + for (int i = 0; i < bndList.Count; i++) + { + GL.Vertex3(bndList[i].easting, bndList[i].northing, 0); + } + GL.End(); + + GL.PointSize(4); + GL.Color3(0.90f, 0.25f, 0.910f); + GL.Begin(PrimitiveType.Points); + for (int i = 0; i < bndList.Count; i++) + { + GL.Vertex3(bndList[i].easting, bndList[i].northing, 0); + } + GL.End(); + + + GL.Color3(0.82f, 0.835f, 0.5f); + GL.Begin(PrimitiveType.LineLoop); + for (int j = 0; j < smooList.Count; j++) + { + GL.Vertex3(smooList[j].easting, smooList[j].northing, 0); + } + GL.End(); + + } + + + //the section grid if loaded + if (secList.Count > 0) + { + GL.PointSize(2); + if (isStep) + GL.Color3(0.64f, 0.64f, 0.6); + else + GL.Color3(1.0f, 1.0f, 0); + + GL.Begin(PrimitiveType.Points); + + for (int j = 0; j < secList.Count; j++) + GL.Vertex3(secList[j].easting, secList[j].northing, 0); + GL.End(); + + //GL.PointSize(24); + //GL.Color3(0.90f, 0.25f, 0.910f); + //GL.Begin(PrimitiveType.Points); + // GL.Vertex3(0,0, 0); + //GL.End(); + } + + //draw the line building graphics + if (start != 99999 || end != 99999) DrawABTouchPoints(); + + //draw the actual built lines + if (start != 99999 && end != 99999) + { + GL.LineWidth(4); + GL.Color3(0.90f, 0.5f, 0.25f); + GL.Begin(PrimitiveType.Lines); + { + GL.Vertex3(mf.bnd.bndList[0].fenceLine[start].easting, mf.bnd.bndList[0].fenceLine[start].northing, 0); + GL.Vertex3(mf.bnd.bndList[0].fenceLine[end].easting, mf.bnd.bndList[0].fenceLine[end].northing, 0); + } + GL.End(); + } + + GL.Flush(); + oglSelf.SwapBuffers(); + } + + private void DrawABTouchPoints() + { + GL.PointSize(24); + GL.Begin(PrimitiveType.Points); + + GL.Color3(0, 0, 0); + if (start != 99999) GL.Vertex3(mf.bnd.bndList[bndSelect].fenceLine[start].easting, mf.bnd.bndList[bndSelect].fenceLine[start].northing, 0); + if (end != 99999) GL.Vertex3(mf.bnd.bndList[bndSelect].fenceLine[end].easting, mf.bnd.bndList[bndSelect].fenceLine[end].northing, 0); + GL.End(); + + GL.PointSize(16); + GL.Begin(PrimitiveType.Points); + + GL.Color3(.950f, 0.75f, 0.50f); + if (start != 99999) GL.Vertex3(mf.bnd.bndList[bndSelect].fenceLine[start].easting, mf.bnd.bndList[bndSelect].fenceLine[start].northing, 0); + + GL.Color3(0.5f, 0.5f, 0.935f); + if (end != 99999) GL.Vertex3(mf.bnd.bndList[bndSelect].fenceLine[end].easting, mf.bnd.bndList[bndSelect].fenceLine[end].northing, 0); + GL.End(); + + + } + + private void timer1_Tick(object sender, EventArgs e) + { + oglSelf.Refresh(); + } + + private void oglSelf_Resize(object sender, EventArgs e) + { + oglSelf.MakeCurrent(); + GL.MatrixMode(MatrixMode.Projection); + GL.LoadIdentity(); + + //58 degrees view + Matrix4 mat = Matrix4.CreatePerspectiveFieldOfView(1.01f, 1.0f, 1.0f, 20000); + GL.LoadMatrix(ref mat); + + GL.MatrixMode(MatrixMode.Modelview); + } + + private void oglSelf_Load(object sender, EventArgs e) + { + oglSelf.MakeCurrent(); + GL.Enable(EnableCap.CullFace); + GL.CullFace(CullFaceMode.Back); + GL.ClearColor(0.0f, 0.0f, 0.0f, 1.0f); + } + } +} \ No newline at end of file diff --git a/SourceCode/GPS/Forms/Field/FormMapBnd.resx b/SourceCode/GPS/Forms/Field/FormMapBnd.resx new file mode 100644 index 000000000..9d24b35ed --- /dev/null +++ b/SourceCode/GPS/Forms/Field/FormMapBnd.resx @@ -0,0 +1,126 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 17, 17 + + + 56 + + \ No newline at end of file diff --git a/SourceCode/GPS/Forms/FormGPS.Designer.cs b/SourceCode/GPS/Forms/FormGPS.Designer.cs index ddddc30bd..3f797d4a9 100644 --- a/SourceCode/GPS/Forms/FormGPS.Designer.cs +++ b/SourceCode/GPS/Forms/FormGPS.Designer.cs @@ -113,6 +113,7 @@ private void InitializeComponent() this.headingChartToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.xTEChartToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.rollCheckToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); + this.boundaryToolToolStripMenu = new System.Windows.Forms.ToolStripMenuItem(); this.SmoothABtoolStripMenu = new System.Windows.Forms.ToolStripMenuItem(); this.deleteContourPathsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.deleteAppliedAreaToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); @@ -129,13 +130,15 @@ private void InitializeComponent() this.btnSection14Man = new System.Windows.Forms.Button(); this.btnSection13Man = new System.Windows.Forms.Button(); this.panelNavigation = new System.Windows.Forms.TableLayoutPanel(); + this.btnTiltDn = new System.Windows.Forms.Button(); + this.btnTiltUp = new System.Windows.Forms.Button(); + this.btnBrightnessDn = new System.Windows.Forms.Button(); + this.btnBrightnessUp = new System.Windows.Forms.Button(); + this.btnDayNightMode = new System.Windows.Forms.Button(); this.btnN3D = new System.Windows.Forms.Button(); this.btnN2D = new System.Windows.Forms.Button(); this.btn3D = new System.Windows.Forms.Button(); this.btn2D = new System.Windows.Forms.Button(); - this.btnDayNightMode = new System.Windows.Forms.Button(); - this.btnBrightnessUp = new System.Windows.Forms.Button(); - this.btnBrightnessDn = new System.Windows.Forms.Button(); this.timer2 = new System.Windows.Forms.Timer(this.components); this.lblSpeed = new System.Windows.Forms.Label(); this.lblFix = new System.Windows.Forms.Label(); @@ -593,7 +596,7 @@ private void InitializeComponent() this.toolStripMenuFlagForm.Image = global::AgOpenGPS.Properties.Resources.OK64; this.toolStripMenuFlagForm.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; this.toolStripMenuFlagForm.Name = "toolStripMenuFlagForm"; - this.toolStripMenuFlagForm.Size = new System.Drawing.Size(267, 70); + this.toolStripMenuFlagForm.Size = new System.Drawing.Size(259, 70); this.toolStripMenuFlagForm.Text = "toolStripMenuItem3"; this.toolStripMenuFlagForm.Click += new System.EventHandler(this.toolStripMenuFlagForm_Click); // @@ -1039,7 +1042,7 @@ private void InitializeComponent() this.oglMain.Location = new System.Drawing.Point(76, 49); this.oglMain.Margin = new System.Windows.Forms.Padding(0); this.oglMain.Name = "oglMain"; - this.oglMain.Size = new System.Drawing.Size(849, 600); + this.oglMain.Size = new System.Drawing.Size(929, 636); this.oglMain.TabIndex = 180; this.oglMain.VSync = false; this.oglMain.Load += new System.EventHandler(this.oglMain_Load); @@ -1052,7 +1055,7 @@ private void InitializeComponent() this.oglBack.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.oglBack.BackColor = System.Drawing.Color.Black; this.oglBack.ForeColor = System.Drawing.Color.Transparent; - this.oglBack.Location = new System.Drawing.Point(122, 70); + this.oglBack.Location = new System.Drawing.Point(202, 70); this.oglBack.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1); this.oglBack.Name = "oglBack"; this.oglBack.Size = new System.Drawing.Size(500, 250); @@ -1065,11 +1068,10 @@ private void InitializeComponent() // lblHz // this.lblHz.BackColor = System.Drawing.Color.WhiteSmoke; - this.lblHz.Dock = System.Windows.Forms.DockStyle.Fill; this.lblHz.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblHz.ForeColor = System.Drawing.SystemColors.ActiveCaptionText; this.lblHz.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.lblHz.Location = new System.Drawing.Point(92, 158); + this.lblHz.Location = new System.Drawing.Point(92, 276); this.lblHz.Name = "lblHz"; this.lblHz.Size = new System.Drawing.Size(84, 79); this.lblHz.TabIndex = 249; @@ -1091,7 +1093,7 @@ private void InitializeComponent() this.distanceToolBtn, this.toolStripDropDownButton4}); this.statusStripLeft.LayoutStyle = System.Windows.Forms.ToolStripLayoutStyle.Flow; - this.statusStripLeft.Location = new System.Drawing.Point(2, 65); + this.statusStripLeft.Location = new System.Drawing.Point(2, 69); this.statusStripLeft.Name = "statusStripLeft"; this.statusStripLeft.Size = new System.Drawing.Size(67, 111); this.statusStripLeft.SizingGrip = false; @@ -1116,12 +1118,13 @@ private void InitializeComponent() this.toolStripDropDownButton4.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { this.wizardsMenu, this.steerChartStripMenu, + this.boundaryToolToolStripMenu, this.SmoothABtoolStripMenu, this.deleteContourPathsToolStripMenuItem, this.deleteAppliedAreaToolStripMenuItem, this.webcamToolStrip, this.offsetFixToolStrip}); - this.toolStripDropDownButton4.Font = new System.Drawing.Font("Tahoma", 21.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.toolStripDropDownButton4.Font = new System.Drawing.Font("Tahoma", 24F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.toolStripDropDownButton4.Image = global::AgOpenGPS.Properties.Resources.SpecialFunctions; this.toolStripDropDownButton4.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; this.toolStripDropDownButton4.ImageTransparentColor = System.Drawing.Color.Magenta; @@ -1137,7 +1140,7 @@ private void InitializeComponent() this.steerWizardMenuItem}); this.wizardsMenu.Image = global::AgOpenGPS.Properties.Resources.WizardWand; this.wizardsMenu.Name = "wizardsMenu"; - this.wizardsMenu.Size = new System.Drawing.Size(426, 70); + this.wizardsMenu.Size = new System.Drawing.Size(459, 70); this.wizardsMenu.Text = "Wizards"; // // steerWizardMenuItem @@ -1145,7 +1148,7 @@ private void InitializeComponent() this.steerWizardMenuItem.Image = global::AgOpenGPS.Properties.Resources.AutoSteerOn; this.steerWizardMenuItem.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft; this.steerWizardMenuItem.Name = "steerWizardMenuItem"; - this.steerWizardMenuItem.Size = new System.Drawing.Size(278, 40); + this.steerWizardMenuItem.Size = new System.Drawing.Size(301, 44); this.steerWizardMenuItem.Text = "Steer Wizard"; this.steerWizardMenuItem.Click += new System.EventHandler(this.steerWizardMenuItem_Click); // @@ -1158,14 +1161,14 @@ private void InitializeComponent() this.rollCheckToolStripMenuItem}); this.steerChartStripMenu.Image = global::AgOpenGPS.Properties.Resources.Chart; this.steerChartStripMenu.Name = "steerChartStripMenu"; - this.steerChartStripMenu.Size = new System.Drawing.Size(426, 70); + this.steerChartStripMenu.Size = new System.Drawing.Size(459, 70); this.steerChartStripMenu.Text = "Charts"; // // steerChartToolStripMenuItem // this.steerChartToolStripMenuItem.Image = global::AgOpenGPS.Properties.Resources.AutoSteerOn; this.steerChartToolStripMenuItem.Name = "steerChartToolStripMenuItem"; - this.steerChartToolStripMenuItem.Size = new System.Drawing.Size(299, 40); + this.steerChartToolStripMenuItem.Size = new System.Drawing.Size(322, 44); this.steerChartToolStripMenuItem.Text = "Steer Chart"; this.steerChartToolStripMenuItem.Click += new System.EventHandler(this.toolStripAutoSteerChart_Click); // @@ -1173,7 +1176,7 @@ private void InitializeComponent() // this.headingChartToolStripMenuItem.Image = global::AgOpenGPS.Properties.Resources.ConS_SourcesHeading; this.headingChartToolStripMenuItem.Name = "headingChartToolStripMenuItem"; - this.headingChartToolStripMenuItem.Size = new System.Drawing.Size(299, 40); + this.headingChartToolStripMenuItem.Size = new System.Drawing.Size(322, 44); this.headingChartToolStripMenuItem.Text = "Heading Chart"; this.headingChartToolStripMenuItem.Click += new System.EventHandler(this.headingChartToolStripMenuItem_Click); // @@ -1181,22 +1184,30 @@ private void InitializeComponent() // this.xTEChartToolStripMenuItem.Image = global::AgOpenGPS.Properties.Resources.AutoManualIsAuto; this.xTEChartToolStripMenuItem.Name = "xTEChartToolStripMenuItem"; - this.xTEChartToolStripMenuItem.Size = new System.Drawing.Size(299, 40); + this.xTEChartToolStripMenuItem.Size = new System.Drawing.Size(322, 44); this.xTEChartToolStripMenuItem.Text = "XTE Chart"; this.xTEChartToolStripMenuItem.Click += new System.EventHandler(this.xTEChartToolStripMenuItem_Click); // // rollCheckToolStripMenuItem // this.rollCheckToolStripMenuItem.Name = "rollCheckToolStripMenuItem"; - this.rollCheckToolStripMenuItem.Size = new System.Drawing.Size(299, 40); + this.rollCheckToolStripMenuItem.Size = new System.Drawing.Size(322, 44); this.rollCheckToolStripMenuItem.Text = "Roll Check"; this.rollCheckToolStripMenuItem.Click += new System.EventHandler(this.correctionToolStrip_Click); // + // boundaryToolToolStripMenu + // + this.boundaryToolToolStripMenu.Image = global::AgOpenGPS.Properties.Resources.Boundary; + this.boundaryToolToolStripMenu.Name = "boundaryToolToolStripMenu"; + this.boundaryToolToolStripMenu.Size = new System.Drawing.Size(459, 70); + this.boundaryToolToolStripMenu.Text = "Boundary Tool"; + this.boundaryToolToolStripMenu.Click += new System.EventHandler(this.boundaryToolToolStripMenu_Click); + // // SmoothABtoolStripMenu // this.SmoothABtoolStripMenu.Image = global::AgOpenGPS.Properties.Resources.ABSmooth; this.SmoothABtoolStripMenu.Name = "SmoothABtoolStripMenu"; - this.SmoothABtoolStripMenu.Size = new System.Drawing.Size(426, 70); + this.SmoothABtoolStripMenu.Size = new System.Drawing.Size(459, 70); this.SmoothABtoolStripMenu.Text = "Smooth AB Curve"; this.SmoothABtoolStripMenu.Click += new System.EventHandler(this.SmoothABtoolStripMenu_Click); // @@ -1205,7 +1216,7 @@ private void InitializeComponent() this.deleteContourPathsToolStripMenuItem.Image = global::AgOpenGPS.Properties.Resources.TrashContourRef; this.deleteContourPathsToolStripMenuItem.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; this.deleteContourPathsToolStripMenuItem.Name = "deleteContourPathsToolStripMenuItem"; - this.deleteContourPathsToolStripMenuItem.Size = new System.Drawing.Size(426, 70); + this.deleteContourPathsToolStripMenuItem.Size = new System.Drawing.Size(459, 70); this.deleteContourPathsToolStripMenuItem.Text = "Hide Contour Paths"; this.deleteContourPathsToolStripMenuItem.Click += new System.EventHandler(this.deleteContourPathsToolStripMenuItem_Click); // @@ -1215,13 +1226,13 @@ private void InitializeComponent() this.deleteForSureToolStripMenuItem}); this.deleteAppliedAreaToolStripMenuItem.Image = global::AgOpenGPS.Properties.Resources.TrashApplied; this.deleteAppliedAreaToolStripMenuItem.Name = "deleteAppliedAreaToolStripMenuItem"; - this.deleteAppliedAreaToolStripMenuItem.Size = new System.Drawing.Size(426, 70); + this.deleteAppliedAreaToolStripMenuItem.Size = new System.Drawing.Size(459, 70); this.deleteAppliedAreaToolStripMenuItem.Text = "Delete Applied Area"; // // deleteForSureToolStripMenuItem // this.deleteForSureToolStripMenuItem.Name = "deleteForSureToolStripMenuItem"; - this.deleteForSureToolStripMenuItem.Size = new System.Drawing.Size(317, 40); + this.deleteForSureToolStripMenuItem.Size = new System.Drawing.Size(342, 44); this.deleteForSureToolStripMenuItem.Text = "Delete For Sure"; this.deleteForSureToolStripMenuItem.Click += new System.EventHandler(this.toolStripAreYouSure_Click); // @@ -1229,7 +1240,7 @@ private void InitializeComponent() // this.webcamToolStrip.Image = global::AgOpenGPS.Properties.Resources.Webcam; this.webcamToolStrip.Name = "webcamToolStrip"; - this.webcamToolStrip.Size = new System.Drawing.Size(426, 70); + this.webcamToolStrip.Size = new System.Drawing.Size(459, 70); this.webcamToolStrip.Text = "WebCam"; this.webcamToolStrip.Click += new System.EventHandler(this.webcamToolStrip_Click); // @@ -1237,7 +1248,7 @@ private void InitializeComponent() // this.offsetFixToolStrip.Image = global::AgOpenGPS.Properties.Resources.YouTurnReverse; this.offsetFixToolStrip.Name = "offsetFixToolStrip"; - this.offsetFixToolStrip.Size = new System.Drawing.Size(426, 70); + this.offsetFixToolStrip.Size = new System.Drawing.Size(459, 70); this.offsetFixToolStrip.Text = "Offset Fix"; this.offsetFixToolStrip.Click += new System.EventHandler(this.offsetFixToolStrip_Click); // @@ -1254,7 +1265,7 @@ private void InitializeComponent() this.panelSim.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 21F)); this.panelSim.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F)); this.panelSim.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 58F)); - this.panelSim.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F)); + this.panelSim.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F)); this.panelSim.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 49F)); this.panelSim.Controls.Add(this.btnSpeedDn, 5, 0); this.panelSim.Controls.Add(this.btnSimSpeedUp, 7, 0); @@ -1263,7 +1274,7 @@ private void InitializeComponent() this.panelSim.Controls.Add(this.btnResetSteerAngle, 1, 0); this.panelSim.Controls.Add(this.hsbarSteerAngle, 3, 0); this.panelSim.Controls.Add(this.btnSimReverseDirection, 8, 0); - this.panelSim.Location = new System.Drawing.Point(152, 594); + this.panelSim.Location = new System.Drawing.Point(192, 630); this.panelSim.Name = "panelSim"; this.panelSim.RowCount = 1; this.panelSim.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); @@ -1280,7 +1291,8 @@ private void InitializeComponent() this.btnSpeedDn.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnSpeedDn.Location = new System.Drawing.Point(404, 4); this.btnSpeedDn.Name = "btnSpeedDn"; - this.btnSpeedDn.Size = new System.Drawing.Size(117, 34); + this.btnSpeedDn.Size = new System.Drawing.Size(113, 34); + this.btnSpeedDn.TabIndex = 533; this.btnSpeedDn.UseVisualStyleBackColor = false; this.btnSpeedDn.MouseDown += new System.Windows.Forms.MouseEventHandler(this.btnSpeedDn_MouseDown); @@ -1293,9 +1305,10 @@ private void InitializeComponent() this.btnSimSpeedUp.Dock = System.Windows.Forms.DockStyle.Fill; this.btnSimSpeedUp.FlatAppearance.BorderSize = 0; this.btnSimSpeedUp.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnSimSpeedUp.Location = new System.Drawing.Point(587, 4); + + this.btnSimSpeedUp.Location = new System.Drawing.Point(583, 4); this.btnSimSpeedUp.Name = "btnSimSpeedUp"; - this.btnSimSpeedUp.Size = new System.Drawing.Size(117, 34); + this.btnSimSpeedUp.Size = new System.Drawing.Size(113, 34); this.btnSimSpeedUp.TabIndex = 532; this.btnSimSpeedUp.UseVisualStyleBackColor = false; this.btnSimSpeedUp.MouseDown += new System.Windows.Forms.MouseEventHandler(this.btnSimSpeedUp_MouseDown); @@ -1309,7 +1322,8 @@ private void InitializeComponent() this.btnSimSetSpeedToZero.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnSimSetSpeedToZero.Font = new System.Drawing.Font("Tahoma", 9.75F); this.btnSimSetSpeedToZero.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnSimSetSpeedToZero.Location = new System.Drawing.Point(528, 4); + this.btnSimSetSpeedToZero.Location = new System.Drawing.Point(524, 4); + this.btnSimSetSpeedToZero.Name = "btnSimSetSpeedToZero"; this.btnSimSetSpeedToZero.Size = new System.Drawing.Size(52, 34); this.btnSimSetSpeedToZero.TabIndex = 453; @@ -1326,6 +1340,7 @@ private void InitializeComponent() this.btnSimReverseDirection.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnSimReverseDirection.Font = new System.Drawing.Font("Tahoma", 9.75F); this.btnSimReverseDirection.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnSimReverseDirection.Location = new System.Drawing.Point(715, 4); this.btnSimReverseDirection.Name = "btnSimReverseDirection"; this.btnSimReverseDirection.Size = new System.Drawing.Size(35, 34); @@ -1407,26 +1422,115 @@ private void InitializeComponent() this.panelNavigation.ColumnCount = 2; this.panelNavigation.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F)); this.panelNavigation.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F)); - this.panelNavigation.Controls.Add(this.btnN3D, 1, 1); - this.panelNavigation.Controls.Add(this.btnN2D, 0, 1); - this.panelNavigation.Controls.Add(this.btn3D, 1, 0); - this.panelNavigation.Controls.Add(this.btn2D, 0, 0); - this.panelNavigation.Controls.Add(this.btnDayNightMode, 0, 2); - this.panelNavigation.Controls.Add(this.lblHz, 1, 2); - this.panelNavigation.Controls.Add(this.btnBrightnessUp, 1, 3); - this.panelNavigation.Controls.Add(this.btnBrightnessDn, 0, 3); + this.panelNavigation.Controls.Add(this.btnTiltDn, 0, 0); + this.panelNavigation.Controls.Add(this.btnTiltUp, 1, 0); + this.panelNavigation.Controls.Add(this.btnBrightnessDn, 0, 4); + this.panelNavigation.Controls.Add(this.btnBrightnessUp, 1, 4); + this.panelNavigation.Controls.Add(this.btnDayNightMode, 0, 3); + this.panelNavigation.Controls.Add(this.lblHz, 1, 3); + this.panelNavigation.Controls.Add(this.btnN3D, 1, 2); + this.panelNavigation.Controls.Add(this.btnN2D, 0, 2); + this.panelNavigation.Controls.Add(this.btn3D, 1, 1); + this.panelNavigation.Controls.Add(this.btn2D, 0, 1); this.panelNavigation.Location = new System.Drawing.Point(527, 61); this.panelNavigation.Name = "panelNavigation"; - this.panelNavigation.RowCount = 4; - this.panelNavigation.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F)); - this.panelNavigation.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F)); - this.panelNavigation.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F)); - this.panelNavigation.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F)); - this.panelNavigation.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 20F)); - this.panelNavigation.Size = new System.Drawing.Size(179, 318); + this.panelNavigation.RowCount = 5; + this.panelNavigation.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F)); + this.panelNavigation.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F)); + this.panelNavigation.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F)); + this.panelNavigation.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F)); + this.panelNavigation.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F)); + this.panelNavigation.Size = new System.Drawing.Size(179, 460); this.panelNavigation.TabIndex = 468; this.panelNavigation.Visible = false; // + // btnTiltDn + // + this.btnTiltDn.Anchor = System.Windows.Forms.AnchorStyles.None; + this.btnTiltDn.BackColor = System.Drawing.Color.Transparent; + this.btnTiltDn.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnTiltDn.FlatAppearance.BorderColor = System.Drawing.Color.RoyalBlue; + this.btnTiltDn.FlatAppearance.BorderSize = 0; + this.btnTiltDn.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnTiltDn.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnTiltDn.Image = global::AgOpenGPS.Properties.Resources.TiltDown; + this.btnTiltDn.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnTiltDn.Location = new System.Drawing.Point(16, 18); + this.btnTiltDn.Name = "btnTiltDn"; + this.btnTiltDn.Size = new System.Drawing.Size(57, 55); + this.btnTiltDn.TabIndex = 543; + this.btnTiltDn.TextAlign = System.Drawing.ContentAlignment.BottomCenter; + this.btnTiltDn.UseVisualStyleBackColor = false; + this.btnTiltDn.Click += new System.EventHandler(this.btnTiltDn_Click); + // + // btnTiltUp + // + this.btnTiltUp.Anchor = System.Windows.Forms.AnchorStyles.None; + this.btnTiltUp.BackColor = System.Drawing.Color.Transparent; + this.btnTiltUp.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnTiltUp.FlatAppearance.BorderColor = System.Drawing.Color.RoyalBlue; + this.btnTiltUp.FlatAppearance.BorderSize = 0; + this.btnTiltUp.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnTiltUp.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnTiltUp.Image = global::AgOpenGPS.Properties.Resources.TiltUp; + this.btnTiltUp.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnTiltUp.Location = new System.Drawing.Point(105, 18); + this.btnTiltUp.Name = "btnTiltUp"; + this.btnTiltUp.Size = new System.Drawing.Size(57, 55); + this.btnTiltUp.TabIndex = 544; + this.btnTiltUp.TextAlign = System.Drawing.ContentAlignment.BottomCenter; + this.btnTiltUp.UseVisualStyleBackColor = false; + this.btnTiltUp.Click += new System.EventHandler(this.btnTiltUp_Click); + // + // btnBrightnessDn + // + this.btnBrightnessDn.BackColor = System.Drawing.Color.Transparent; + this.btnBrightnessDn.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center; + this.btnBrightnessDn.FlatAppearance.BorderSize = 0; + this.btnBrightnessDn.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnBrightnessDn.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnBrightnessDn.Image = global::AgOpenGPS.Properties.Resources.BrightnessDn; + this.btnBrightnessDn.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnBrightnessDn.Location = new System.Drawing.Point(3, 371); + this.btnBrightnessDn.Name = "btnBrightnessDn"; + this.btnBrightnessDn.Size = new System.Drawing.Size(83, 75); + this.btnBrightnessDn.TabIndex = 474; + this.btnBrightnessDn.Text = "20%"; + this.btnBrightnessDn.TextAlign = System.Drawing.ContentAlignment.BottomCenter; + this.btnBrightnessDn.UseVisualStyleBackColor = false; + this.btnBrightnessDn.Click += new System.EventHandler(this.btnBrightnessDn_Click); + // + // btnBrightnessUp + // + this.btnBrightnessUp.BackColor = System.Drawing.Color.Transparent; + this.btnBrightnessUp.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center; + this.btnBrightnessUp.FlatAppearance.BorderSize = 0; + this.btnBrightnessUp.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnBrightnessUp.Image = global::AgOpenGPS.Properties.Resources.BrightnessUp; + this.btnBrightnessUp.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnBrightnessUp.Location = new System.Drawing.Point(92, 371); + this.btnBrightnessUp.Name = "btnBrightnessUp"; + this.btnBrightnessUp.Size = new System.Drawing.Size(84, 75); + this.btnBrightnessUp.TabIndex = 473; + this.btnBrightnessUp.UseVisualStyleBackColor = false; + this.btnBrightnessUp.Click += new System.EventHandler(this.btnBrightnessUp_Click); + // + // btnDayNightMode + // + this.btnDayNightMode.Anchor = System.Windows.Forms.AnchorStyles.None; + this.btnDayNightMode.BackColor = System.Drawing.Color.Transparent; + this.btnDayNightMode.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center; + this.btnDayNightMode.FlatAppearance.BorderSize = 0; + this.btnDayNightMode.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnDayNightMode.Image = global::AgOpenGPS.Properties.Resources.WindowNightMode; + this.btnDayNightMode.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnDayNightMode.Location = new System.Drawing.Point(16, 294); + this.btnDayNightMode.Name = "btnDayNightMode"; + this.btnDayNightMode.Size = new System.Drawing.Size(57, 55); + this.btnDayNightMode.TabIndex = 452; + this.btnDayNightMode.UseVisualStyleBackColor = false; + this.btnDayNightMode.Click += new System.EventHandler(this.btnDayNightMode_Click); + // // btnN3D // this.btnN3D.Anchor = System.Windows.Forms.AnchorStyles.None; @@ -1438,7 +1542,7 @@ private void InitializeComponent() this.btnN3D.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btnN3D.Image = global::AgOpenGPS.Properties.Resources.CameraNorth64; this.btnN3D.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnN3D.Location = new System.Drawing.Point(105, 91); + this.btnN3D.Location = new System.Drawing.Point(105, 202); this.btnN3D.Name = "btnN3D"; this.btnN3D.Size = new System.Drawing.Size(57, 55); this.btnN3D.TabIndex = 472; @@ -1457,7 +1561,7 @@ private void InitializeComponent() this.btnN2D.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btnN2D.Image = global::AgOpenGPS.Properties.Resources.CameraNorth2D; this.btnN2D.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnN2D.Location = new System.Drawing.Point(16, 91); + this.btnN2D.Location = new System.Drawing.Point(16, 202); this.btnN2D.Name = "btnN2D"; this.btnN2D.Size = new System.Drawing.Size(57, 55); this.btnN2D.TabIndex = 470; @@ -1476,7 +1580,7 @@ private void InitializeComponent() this.btn3D.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btn3D.Image = global::AgOpenGPS.Properties.Resources.Camera3D64; this.btn3D.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btn3D.Location = new System.Drawing.Point(105, 12); + this.btn3D.Location = new System.Drawing.Point(105, 110); this.btn3D.Name = "btn3D"; this.btn3D.Size = new System.Drawing.Size(57, 55); this.btn3D.TabIndex = 471; @@ -1495,7 +1599,7 @@ private void InitializeComponent() this.btn2D.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btn2D.Image = global::AgOpenGPS.Properties.Resources.Camera2D64; this.btn2D.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btn2D.Location = new System.Drawing.Point(16, 12); + this.btn2D.Location = new System.Drawing.Point(16, 110); this.btn2D.Name = "btn2D"; this.btn2D.Size = new System.Drawing.Size(57, 55); this.btn2D.TabIndex = 469; @@ -1503,57 +1607,6 @@ private void InitializeComponent() this.btn2D.UseVisualStyleBackColor = false; this.btn2D.Click += new System.EventHandler(this.btn2D_Click); // - // btnDayNightMode - // - this.btnDayNightMode.Anchor = System.Windows.Forms.AnchorStyles.None; - this.btnDayNightMode.BackColor = System.Drawing.Color.Transparent; - this.btnDayNightMode.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center; - this.btnDayNightMode.FlatAppearance.BorderSize = 0; - this.btnDayNightMode.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnDayNightMode.Image = global::AgOpenGPS.Properties.Resources.WindowNightMode; - this.btnDayNightMode.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnDayNightMode.Location = new System.Drawing.Point(16, 170); - this.btnDayNightMode.Name = "btnDayNightMode"; - this.btnDayNightMode.Size = new System.Drawing.Size(57, 55); - this.btnDayNightMode.TabIndex = 452; - this.btnDayNightMode.UseVisualStyleBackColor = false; - this.btnDayNightMode.Click += new System.EventHandler(this.btnDayNightMode_Click); - // - // btnBrightnessUp - // - this.btnBrightnessUp.BackColor = System.Drawing.Color.Transparent; - this.btnBrightnessUp.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center; - this.btnBrightnessUp.Dock = System.Windows.Forms.DockStyle.Fill; - this.btnBrightnessUp.FlatAppearance.BorderSize = 0; - this.btnBrightnessUp.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnBrightnessUp.Image = global::AgOpenGPS.Properties.Resources.BrightnessUp; - this.btnBrightnessUp.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnBrightnessUp.Location = new System.Drawing.Point(92, 240); - this.btnBrightnessUp.Name = "btnBrightnessUp"; - this.btnBrightnessUp.Size = new System.Drawing.Size(84, 75); - this.btnBrightnessUp.TabIndex = 473; - this.btnBrightnessUp.UseVisualStyleBackColor = false; - this.btnBrightnessUp.Click += new System.EventHandler(this.btnBrightnessUp_Click); - // - // btnBrightnessDn - // - this.btnBrightnessDn.BackColor = System.Drawing.Color.Transparent; - this.btnBrightnessDn.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center; - this.btnBrightnessDn.Dock = System.Windows.Forms.DockStyle.Fill; - this.btnBrightnessDn.FlatAppearance.BorderSize = 0; - this.btnBrightnessDn.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnBrightnessDn.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.btnBrightnessDn.Image = global::AgOpenGPS.Properties.Resources.BrightnessDn; - this.btnBrightnessDn.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnBrightnessDn.Location = new System.Drawing.Point(3, 240); - this.btnBrightnessDn.Name = "btnBrightnessDn"; - this.btnBrightnessDn.Size = new System.Drawing.Size(83, 75); - this.btnBrightnessDn.TabIndex = 474; - this.btnBrightnessDn.Text = "20%"; - this.btnBrightnessDn.TextAlign = System.Drawing.ContentAlignment.BottomCenter; - this.btnBrightnessDn.UseVisualStyleBackColor = false; - this.btnBrightnessDn.Click += new System.EventHandler(this.btnBrightnessDn_Click); - // // timer2 // this.timer2.Interval = 4200; @@ -1729,13 +1782,13 @@ private void InitializeComponent() | System.Windows.Forms.AnchorStyles.Left))); this.panelLeft.ColumnCount = 1; this.panelLeft.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F)); + this.panelLeft.Controls.Add(this.btnConfig, 0, 4); this.panelLeft.Controls.Add(this.btnNavigationSettings, 0, 0); this.panelLeft.Controls.Add(this.btnAutoSteerConfig, 0, 5); - this.panelLeft.Controls.Add(this.btnConfig, 0, 2); - this.panelLeft.Controls.Add(this.btnJobMenu, 0, 3); - this.panelLeft.Controls.Add(this.statusStrip1, 0, 4); this.panelLeft.Controls.Add(this.btnStartAgIO, 0, 6); this.panelLeft.Controls.Add(this.statusStripLeft, 0, 1); + this.panelLeft.Controls.Add(this.btnJobMenu, 0, 2); + this.panelLeft.Controls.Add(this.statusStrip1, 0, 3); this.panelLeft.Location = new System.Drawing.Point(3, 53); this.panelLeft.Name = "panelLeft"; this.panelLeft.RowCount = 7; @@ -1746,7 +1799,7 @@ private void InitializeComponent() this.panelLeft.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 17.43421F)); this.panelLeft.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 14.63816F)); this.panelLeft.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 14.47368F)); - this.panelLeft.Size = new System.Drawing.Size(72, 652); + this.panelLeft.Size = new System.Drawing.Size(72, 688); this.panelLeft.TabIndex = 529; // // btnNavigationSettings @@ -1785,12 +1838,12 @@ private void InitializeComponent() this.btnAutoSteerConfig.ForeColor = System.Drawing.Color.Black; this.btnAutoSteerConfig.Image = global::AgOpenGPS.Properties.Resources.AutoSteerConf; this.btnAutoSteerConfig.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnAutoSteerConfig.Location = new System.Drawing.Point(0, 479); + this.btnAutoSteerConfig.Location = new System.Drawing.Point(0, 505); this.btnAutoSteerConfig.Margin = new System.Windows.Forms.Padding(0); this.btnAutoSteerConfig.Name = "btnAutoSteerConfig"; this.btnAutoSteerConfig.Padding = new System.Windows.Forms.Padding(0, 5, 0, 0); this.btnAutoSteerConfig.RightToLeft = System.Windows.Forms.RightToLeft.No; - this.btnAutoSteerConfig.Size = new System.Drawing.Size(72, 86); + this.btnAutoSteerConfig.Size = new System.Drawing.Size(72, 91); this.btnAutoSteerConfig.TabIndex = 475; this.btnAutoSteerConfig.Text = "-38.8."; this.btnAutoSteerConfig.UseVisualStyleBackColor = false; @@ -1808,11 +1861,11 @@ private void InitializeComponent() this.btnConfig.ForeColor = System.Drawing.Color.DarkGray; this.btnConfig.Image = global::AgOpenGPS.Properties.Resources.Settings48; this.btnConfig.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnConfig.Location = new System.Drawing.Point(0, 178); + this.btnConfig.Location = new System.Drawing.Point(0, 396); this.btnConfig.Margin = new System.Windows.Forms.Padding(0); this.btnConfig.Name = "btnConfig"; this.btnConfig.RightToLeft = System.Windows.Forms.RightToLeft.No; - this.btnConfig.Size = new System.Drawing.Size(72, 95); + this.btnConfig.Size = new System.Drawing.Size(72, 109); this.btnConfig.TabIndex = 537; this.btnConfig.UseVisualStyleBackColor = false; this.btnConfig.Click += new System.EventHandler(this.btnConfig_Click); @@ -1831,11 +1884,11 @@ private void InitializeComponent() this.btnJobMenu.ForeColor = System.Drawing.Color.DarkGray; this.btnJobMenu.Image = global::AgOpenGPS.Properties.Resources.JobActive; this.btnJobMenu.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnJobMenu.Location = new System.Drawing.Point(0, 273); + this.btnJobMenu.Location = new System.Drawing.Point(0, 185); this.btnJobMenu.Margin = new System.Windows.Forms.Padding(0); this.btnJobMenu.Name = "btnJobMenu"; this.btnJobMenu.RightToLeft = System.Windows.Forms.RightToLeft.No; - this.btnJobMenu.Size = new System.Drawing.Size(72, 104); + this.btnJobMenu.Size = new System.Drawing.Size(72, 100); this.btnJobMenu.TabIndex = 536; this.btnJobMenu.UseVisualStyleBackColor = false; this.btnJobMenu.Click += new System.EventHandler(this.btnJobMenu_Click); @@ -1854,7 +1907,7 @@ private void InitializeComponent() this.statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.toolStripBtnFieldTools}); this.statusStrip1.LayoutStyle = System.Windows.Forms.ToolStripLayoutStyle.Flow; - this.statusStrip1.Location = new System.Drawing.Point(2, 377); + this.statusStrip1.Location = new System.Drawing.Point(2, 285); this.statusStrip1.Name = "statusStrip1"; this.statusStrip1.Size = new System.Drawing.Size(67, 90); this.statusStrip1.SizingGrip = false; @@ -1946,11 +1999,11 @@ private void InitializeComponent() this.btnStartAgIO.ForeColor = System.Drawing.Color.DarkGray; this.btnStartAgIO.Image = global::AgOpenGPS.Properties.Resources.AgIO; this.btnStartAgIO.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnStartAgIO.Location = new System.Drawing.Point(0, 565); + this.btnStartAgIO.Location = new System.Drawing.Point(0, 596); this.btnStartAgIO.Margin = new System.Windows.Forms.Padding(0); this.btnStartAgIO.Name = "btnStartAgIO"; this.btnStartAgIO.RightToLeft = System.Windows.Forms.RightToLeft.No; - this.btnStartAgIO.Size = new System.Drawing.Size(72, 87); + this.btnStartAgIO.Size = new System.Drawing.Size(72, 92); this.btnStartAgIO.TabIndex = 467; this.btnStartAgIO.UseVisualStyleBackColor = false; this.btnStartAgIO.Click += new System.EventHandler(this.btnStartAgIO_Click); @@ -1975,7 +2028,7 @@ private void InitializeComponent() this.lblGuidanceLine.Anchor = System.Windows.Forms.AnchorStyles.Top; this.lblGuidanceLine.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.lblGuidanceLine.Font = new System.Drawing.Font("Tahoma", 24F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblGuidanceLine.Location = new System.Drawing.Point(211, 66); + this.lblGuidanceLine.Location = new System.Drawing.Point(251, 66); this.lblGuidanceLine.Name = "lblGuidanceLine"; this.lblGuidanceLine.Size = new System.Drawing.Size(583, 83); this.lblGuidanceLine.TabIndex = 538; @@ -1994,9 +2047,9 @@ private void InitializeComponent() this.flp1.Controls.Add(this.cboxAutoSnapToPivot); this.flp1.Controls.Add(this.btnRefNudge); this.flp1.FlowDirection = System.Windows.Forms.FlowDirection.RightToLeft; - this.flp1.Location = new System.Drawing.Point(90, 480); + this.flp1.Location = new System.Drawing.Point(179, 546); this.flp1.Name = "flp1"; - this.flp1.Size = new System.Drawing.Size(636, 102); + this.flp1.Size = new System.Drawing.Size(676, 102); this.flp1.TabIndex = 539; // // btnNudge @@ -2010,9 +2063,9 @@ private void InitializeComponent() this.btnNudge.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btnNudge.Image = global::AgOpenGPS.Properties.Resources.ABSnapNudgeMenu; this.btnNudge.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnNudge.Location = new System.Drawing.Point(533, 3); + this.btnNudge.Location = new System.Drawing.Point(563, 3); this.btnNudge.Name = "btnNudge"; - this.btnNudge.Size = new System.Drawing.Size(100, 96); + this.btnNudge.Size = new System.Drawing.Size(110, 96); this.btnNudge.TabIndex = 489; this.btnNudge.TextAlign = System.Drawing.ContentAlignment.BottomCenter; this.btnNudge.UseVisualStyleBackColor = false; @@ -2029,9 +2082,9 @@ private void InitializeComponent() this.btnBuildTracks.Font = new System.Drawing.Font("Tahoma", 12F); this.btnBuildTracks.Image = global::AgOpenGPS.Properties.Resources.ABTracks; this.btnBuildTracks.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnBuildTracks.Location = new System.Drawing.Point(427, 6); + this.btnBuildTracks.Location = new System.Drawing.Point(447, 3); this.btnBuildTracks.Name = "btnBuildTracks"; - this.btnBuildTracks.Size = new System.Drawing.Size(100, 90); + this.btnBuildTracks.Size = new System.Drawing.Size(110, 96); this.btnBuildTracks.TabIndex = 539; this.btnBuildTracks.TextAlign = System.Drawing.ContentAlignment.TopCenter; this.btnBuildTracks.UseVisualStyleBackColor = false; @@ -2049,9 +2102,9 @@ private void InitializeComponent() this.btnABDraw.Font = new System.Drawing.Font("Tahoma", 12F); this.btnABDraw.Image = global::AgOpenGPS.Properties.Resources.ABDraw; this.btnABDraw.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnABDraw.Location = new System.Drawing.Point(321, 6); + this.btnABDraw.Location = new System.Drawing.Point(331, 3); this.btnABDraw.Name = "btnABDraw"; - this.btnABDraw.Size = new System.Drawing.Size(100, 90); + this.btnABDraw.Size = new System.Drawing.Size(110, 96); this.btnABDraw.TabIndex = 250; this.btnABDraw.TextAlign = System.Drawing.ContentAlignment.TopCenter; this.btnABDraw.UseVisualStyleBackColor = false; @@ -2067,9 +2120,9 @@ private void InitializeComponent() this.btnTracksOff.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.btnTracksOff.Image = global::AgOpenGPS.Properties.Resources.SwitchOff; this.btnTracksOff.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnTracksOff.Location = new System.Drawing.Point(215, 6); + this.btnTracksOff.Location = new System.Drawing.Point(215, 3); this.btnTracksOff.Name = "btnTracksOff"; - this.btnTracksOff.Size = new System.Drawing.Size(100, 90); + this.btnTracksOff.Size = new System.Drawing.Size(110, 96); this.btnTracksOff.TabIndex = 539; this.btnTracksOff.TextAlign = System.Drawing.ContentAlignment.TopCenter; this.btnTracksOff.UseVisualStyleBackColor = false; @@ -2131,7 +2184,7 @@ private void InitializeComponent() this.panelAB.Controls.Add(this.btnYouSkipEnable); this.panelAB.Controls.Add(this.cboxpRowWidth); this.panelAB.FlowDirection = System.Windows.Forms.FlowDirection.RightToLeft; - this.panelAB.Location = new System.Drawing.Point(117, 652); + this.panelAB.Location = new System.Drawing.Point(197, 688); this.panelAB.Name = "panelAB"; this.panelAB.Size = new System.Drawing.Size(784, 62); this.panelAB.TabIndex = 540; @@ -2332,7 +2385,7 @@ private void InitializeComponent() this.panelRight.Controls.Add(this.btnContourLock); this.panelRight.Controls.Add(this.lblNumCu); this.panelRight.FlowDirection = System.Windows.Forms.FlowDirection.BottomUp; - this.panelRight.Location = new System.Drawing.Point(926, 53); + this.panelRight.Location = new System.Drawing.Point(1006, 89); this.panelRight.Name = "panelRight"; this.panelRight.Size = new System.Drawing.Size(70, 650); this.panelRight.TabIndex = 541; @@ -2569,7 +2622,7 @@ private void InitializeComponent() this.pictureboxStart.BackColor = System.Drawing.Color.Black; this.pictureboxStart.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch; this.pictureboxStart.Image = global::AgOpenGPS.Properties.Resources.Splash; - this.pictureboxStart.Location = new System.Drawing.Point(842, 515); + this.pictureboxStart.Location = new System.Drawing.Point(922, 533); this.pictureboxStart.Name = "pictureboxStart"; this.pictureboxStart.Size = new System.Drawing.Size(44, 37); this.pictureboxStart.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage; @@ -2644,7 +2697,7 @@ private void InitializeComponent() this.panelControlBox.Controls.Add(this.btnMaximizeMainForm); this.panelControlBox.Controls.Add(this.btnMinimizeMainForm); this.panelControlBox.Controls.Add(this.btnHelp); - this.panelControlBox.Location = new System.Drawing.Point(556, 4); + this.panelControlBox.Location = new System.Drawing.Point(636, 4); this.panelControlBox.Name = "panelControlBox"; this.panelControlBox.Size = new System.Drawing.Size(441, 43); this.panelControlBox.TabIndex = 542; @@ -2654,7 +2707,7 @@ private void InitializeComponent() this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Dpi; this.BackColor = System.Drawing.Color.WhiteSmoke; - this.ClientSize = new System.Drawing.Size(1000, 720); + this.ClientSize = new System.Drawing.Size(1080, 756); this.Controls.Add(this.panelControlBox); this.Controls.Add(this.panelRight); this.Controls.Add(this.panelAB); @@ -2898,6 +2951,9 @@ private void InitializeComponent() private System.Windows.Forms.ToolStripMenuItem flagByLatLonToolStripMenuItem; private System.Windows.Forms.ToolStripMenuItem recordedPathStripMenu; private System.Windows.Forms.Panel panelControlBox; + public System.Windows.Forms.Button btnTiltDn; + public System.Windows.Forms.Button btnTiltUp; + private System.Windows.Forms.ToolStripMenuItem boundaryToolToolStripMenu; } } diff --git a/SourceCode/GPS/Forms/FormGPS.cs b/SourceCode/GPS/Forms/FormGPS.cs index 30131950b..f572c3e3a 100644 --- a/SourceCode/GPS/Forms/FormGPS.cs +++ b/SourceCode/GPS/Forms/FormGPS.cs @@ -251,6 +251,7 @@ private void panelRight_Paint(object sender, PaintEventArgs e) #endregion // Class Props and instances + public FormGPS() { //winform initialization @@ -534,7 +535,7 @@ private void FormGPS_Load(object sender, EventArgs e) } } - DateTime dt2 = new DateTime(2024, 02, 05); + DateTime dt2 = new DateTime(2024, 02, 13); if (DateTime.Now > dt2) { YesMessageBox("This version is expired"); diff --git a/SourceCode/GPS/Forms/Form_First.Designer.cs b/SourceCode/GPS/Forms/Form_First.Designer.cs index 897e6207e..e288ac5ac 100644 --- a/SourceCode/GPS/Forms/Form_First.Designer.cs +++ b/SourceCode/GPS/Forms/Form_First.Designer.cs @@ -223,7 +223,7 @@ private void InitializeComponent() this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(382, 138); this.label1.TabIndex = 134; - this.label1.Text = "This version expires: Feb 5. 2024"; + this.label1.Text = "This version expires: Feb 12 2024"; this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // Form_First diff --git a/SourceCode/GPS/Forms/Guidance/FormABDraw.Designer.cs b/SourceCode/GPS/Forms/Guidance/FormABDraw.Designer.cs index 55eea4939..62879718f 100644 --- a/SourceCode/GPS/Forms/Guidance/FormABDraw.Designer.cs +++ b/SourceCode/GPS/Forms/Guidance/FormABDraw.Designer.cs @@ -31,41 +31,32 @@ private void InitializeComponent() this.components = new System.ComponentModel.Container(); this.oglSelf = new OpenTK.GLControl(); this.timer1 = new System.Windows.Forms.Timer(this.components); - this.lblNumCu = new System.Windows.Forms.Label(); this.lblCurveSelected = new System.Windows.Forms.Label(); - this.label1 = new System.Windows.Forms.Label(); - this.nudDistance = new AgOpenGPS.NudlessNumericUpDown(); this.tboxNameCurve = new System.Windows.Forms.TextBox(); - this.label4 = new System.Windows.Forms.Label(); - this.label8 = new System.Windows.Forms.Label(); - this.btnFlipOffset = new System.Windows.Forms.Button(); - this.lblCmInch = new System.Windows.Forms.Label(); - this.label6 = new System.Windows.Forms.Label(); - this.cboxIsVisible = new System.Windows.Forms.CheckBox(); - this.btnAddTime = new System.Windows.Forms.Button(); - this.panel1 = new System.Windows.Forms.Panel(); + this.tlp1 = new System.Windows.Forms.TableLayoutPanel(); this.btnBLength = new System.Windows.Forms.Button(); - this.btnALength = new System.Windows.Forms.Button(); - this.btnMakeBoundaryCurve = new System.Windows.Forms.Button(); this.btnDrawSections = new System.Windows.Forms.Button(); + this.btnCancel = new System.Windows.Forms.Button(); + this.btnALength = new System.Windows.Forms.Button(); + this.btnExit = new System.Windows.Forms.Button(); this.btnDeleteCurve = new System.Windows.Forms.Button(); - this.btnSelectCurve = new System.Windows.Forms.Button(); this.btnMakeCurve = new System.Windows.Forms.Button(); this.btnMakeABLine = new System.Windows.Forms.Button(); - this.btnExit = new System.Windows.Forms.Button(); - this.btnCancel = new System.Windows.Forms.Button(); + this.cboxIsZoom = new System.Windows.Forms.CheckBox(); + this.cboxIsVisible = new System.Windows.Forms.CheckBox(); + this.btnMakeBoundaryCurve = new System.Windows.Forms.Button(); this.btnCancelTouch = new System.Windows.Forms.Button(); - this.label2 = new System.Windows.Forms.Label(); this.btnSelectCurveBk = new System.Windows.Forms.Button(); - ((System.ComponentModel.ISupportInitialize)(this.nudDistance)).BeginInit(); - this.panel1.SuspendLayout(); + this.btnSelectCurve = new System.Windows.Forms.Button(); + this.btnAddTime = new System.Windows.Forms.Button(); + this.tlp1.SuspendLayout(); this.SuspendLayout(); // // oglSelf // this.oglSelf.BackColor = System.Drawing.Color.Black; this.oglSelf.Cursor = System.Windows.Forms.Cursors.Cross; - this.oglSelf.Location = new System.Drawing.Point(5, 9); + this.oglSelf.Location = new System.Drawing.Point(2, 2); this.oglSelf.Margin = new System.Windows.Forms.Padding(0); this.oglSelf.Name = "oglSelf"; this.oglSelf.Size = new System.Drawing.Size(700, 700); @@ -83,198 +74,79 @@ private void InitializeComponent() this.timer1.Interval = 500; this.timer1.Tick += new System.EventHandler(this.timer1_Tick); // - // lblNumCu - // - this.lblNumCu.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblNumCu.ForeColor = System.Drawing.Color.Black; - this.lblNumCu.Location = new System.Drawing.Point(894, 451); - this.lblNumCu.Margin = new System.Windows.Forms.Padding(0); - this.lblNumCu.Name = "lblNumCu"; - this.lblNumCu.Size = new System.Drawing.Size(35, 26); - this.lblNumCu.TabIndex = 327; - this.lblNumCu.Text = "1"; - this.lblNumCu.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; - // // lblCurveSelected // + this.lblCurveSelected.Anchor = System.Windows.Forms.AnchorStyles.None; this.lblCurveSelected.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblCurveSelected.ForeColor = System.Drawing.Color.Black; - this.lblCurveSelected.Location = new System.Drawing.Point(815, 451); + this.lblCurveSelected.Location = new System.Drawing.Point(9, 573); this.lblCurveSelected.Margin = new System.Windows.Forms.Padding(0); this.lblCurveSelected.Name = "lblCurveSelected"; - this.lblCurveSelected.Size = new System.Drawing.Size(35, 26); + this.lblCurveSelected.Size = new System.Drawing.Size(130, 26); this.lblCurveSelected.TabIndex = 329; this.lblCurveSelected.Text = "1"; - this.lblCurveSelected.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // label1 - // - this.label1.AutoSize = true; - this.label1.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label1.ForeColor = System.Drawing.Color.Black; - this.label1.Location = new System.Drawing.Point(857, 452); - this.label1.Margin = new System.Windows.Forms.Padding(0); - this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(29, 23); - this.label1.TabIndex = 332; - this.label1.Text = "of"; - this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // - // nudDistance - // - this.nudDistance.BackColor = System.Drawing.Color.AliceBlue; - this.nudDistance.Font = new System.Drawing.Font("Tahoma", 27.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.nudDistance.Location = new System.Drawing.Point(1078, 84); - this.nudDistance.Maximum = new decimal(new int[] { - 5000, - 0, - 0, - 0}); - this.nudDistance.Minimum = new decimal(new int[] { - 5000, - 0, - 0, - -2147483648}); - this.nudDistance.Name = "nudDistance"; - this.nudDistance.ReadOnly = true; - this.nudDistance.Size = new System.Drawing.Size(132, 52); - this.nudDistance.TabIndex = 16; - this.nudDistance.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; - this.nudDistance.Click += new System.EventHandler(this.nudDistance_Click); - this.nudDistance.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.nudDistance_HelpRequested); + this.lblCurveSelected.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // tboxNameCurve // + this.tboxNameCurve.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right))); this.tboxNameCurve.BackColor = System.Drawing.SystemColors.ControlLight; this.tboxNameCurve.CausesValidation = false; + this.tlp1.SetColumnSpan(this.tboxNameCurve, 2); this.tboxNameCurve.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.tboxNameCurve.Location = new System.Drawing.Point(710, 487); + this.tboxNameCurve.Location = new System.Drawing.Point(0, 532); this.tboxNameCurve.Margin = new System.Windows.Forms.Padding(0); this.tboxNameCurve.MaxLength = 100; this.tboxNameCurve.Name = "tboxNameCurve"; - this.tboxNameCurve.Size = new System.Drawing.Size(292, 27); + this.tboxNameCurve.Size = new System.Drawing.Size(299, 27); this.tboxNameCurve.TabIndex = 10; this.tboxNameCurve.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; this.tboxNameCurve.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.tboxNameCurve_HelpRequested); this.tboxNameCurve.Enter += new System.EventHandler(this.tboxNameCurve_Enter); this.tboxNameCurve.Leave += new System.EventHandler(this.tboxNameCurve_Leave); // - // label4 - // - this.label4.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label4.ForeColor = System.Drawing.Color.Black; - this.label4.Location = new System.Drawing.Point(875, 286); - this.label4.Margin = new System.Windows.Forms.Padding(0); - this.label4.Name = "label4"; - this.label4.Size = new System.Drawing.Size(109, 17); - this.label4.TabIndex = 12; - this.label4.Text = "Boundary Curve"; - this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // - // label8 - // - this.label8.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label8.ForeColor = System.Drawing.Color.Black; - this.label8.Location = new System.Drawing.Point(876, 80); - this.label8.Margin = new System.Windows.Forms.Padding(0); - this.label8.Name = "label8"; - this.label8.Size = new System.Drawing.Size(93, 20); - this.label8.TabIndex = 13; - this.label8.Text = "Mapping"; - this.label8.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // - // btnFlipOffset - // - this.btnFlipOffset.BackColor = System.Drawing.Color.Azure; - this.btnFlipOffset.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.btnFlipOffset.FlatAppearance.BorderColor = System.Drawing.Color.Black; - this.btnFlipOffset.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnFlipOffset.Font = new System.Drawing.Font("Tahoma", 20.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.btnFlipOffset.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnFlipOffset.Location = new System.Drawing.Point(1097, 35); - this.btnFlipOffset.Name = "btnFlipOffset"; - this.btnFlipOffset.Size = new System.Drawing.Size(92, 43); - this.btnFlipOffset.TabIndex = 14; - this.btnFlipOffset.Text = "In"; - this.btnFlipOffset.UseVisualStyleBackColor = false; - this.btnFlipOffset.Click += new System.EventHandler(this.btnFlipOffset_Click); - this.btnFlipOffset.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnFlipOffset_HelpRequested); - // - // lblCmInch - // - this.lblCmInch.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.lblCmInch.ForeColor = System.Drawing.Color.Black; - this.lblCmInch.Location = new System.Drawing.Point(1153, 139); - this.lblCmInch.Margin = new System.Windows.Forms.Padding(0); - this.lblCmInch.Name = "lblCmInch"; - this.lblCmInch.Size = new System.Drawing.Size(44, 24); - this.lblCmInch.TabIndex = 350; - this.lblCmInch.Text = "cm"; - this.lblCmInch.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; - // - // label6 - // - this.label6.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label6.ForeColor = System.Drawing.Color.Black; - this.label6.Location = new System.Drawing.Point(1092, 139); - this.label6.Margin = new System.Windows.Forms.Padding(0); - this.label6.Name = "label6"; - this.label6.Size = new System.Drawing.Size(58, 24); - this.label6.TabIndex = 341; - this.label6.Text = "2"; - this.label6.TextAlign = System.Drawing.ContentAlignment.MiddleRight; - // - // cboxIsVisible - // - this.cboxIsVisible.Appearance = System.Windows.Forms.Appearance.Button; - this.cboxIsVisible.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(200)))), ((int)(((byte)(200))))); - this.cboxIsVisible.Checked = true; - this.cboxIsVisible.CheckState = System.Windows.Forms.CheckState.Checked; - this.cboxIsVisible.FlatAppearance.BorderColor = System.Drawing.Color.Black; - this.cboxIsVisible.FlatAppearance.CheckedBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(220)))), ((int)(((byte)(250)))), ((int)(((byte)(220))))); - this.cboxIsVisible.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.cboxIsVisible.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.cboxIsVisible.ForeColor = System.Drawing.SystemColors.ButtonFace; - this.cboxIsVisible.Image = global::AgOpenGPS.Properties.Resources.TrackVisible; - this.cboxIsVisible.Location = new System.Drawing.Point(716, 226); - this.cboxIsVisible.Name = "cboxIsVisible"; - this.cboxIsVisible.RightToLeft = System.Windows.Forms.RightToLeft.Yes; - this.cboxIsVisible.Size = new System.Drawing.Size(81, 80); - this.cboxIsVisible.TabIndex = 468; - this.cboxIsVisible.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - this.cboxIsVisible.UseVisualStyleBackColor = false; - this.cboxIsVisible.Click += new System.EventHandler(this.cboxIsVisible_Click); - // - // btnAddTime - // - this.btnAddTime.BackColor = System.Drawing.Color.Transparent; - this.btnAddTime.FlatAppearance.BorderColor = System.Drawing.Color.Black; - this.btnAddTime.FlatAppearance.BorderSize = 0; - this.btnAddTime.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnAddTime.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.btnAddTime.Image = global::AgOpenGPS.Properties.Resources.JobNameTime; - this.btnAddTime.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnAddTime.Location = new System.Drawing.Point(927, 398); - this.btnAddTime.Name = "btnAddTime"; - this.btnAddTime.Size = new System.Drawing.Size(68, 69); - this.btnAddTime.TabIndex = 356; - this.btnAddTime.TextAlign = System.Drawing.ContentAlignment.BottomCenter; - this.btnAddTime.UseVisualStyleBackColor = false; - this.btnAddTime.Click += new System.EventHandler(this.btnAddTime_Click); - // - // panel1 - // - this.panel1.BackgroundImage = global::AgOpenGPS.Properties.Resources.ABShrinkGrow; - this.panel1.Controls.Add(this.btnBLength); - this.panel1.Controls.Add(this.btnALength); - this.panel1.Location = new System.Drawing.Point(719, 4); - this.panel1.Name = "panel1"; - this.panel1.Size = new System.Drawing.Size(115, 179); - this.panel1.TabIndex = 355; + // tlp1 + // + this.tlp1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) + | System.Windows.Forms.AnchorStyles.Right))); + this.tlp1.ColumnCount = 2; + this.tlp1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F)); + this.tlp1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F)); + this.tlp1.Controls.Add(this.btnBLength, 0, 0); + this.tlp1.Controls.Add(this.btnDrawSections, 1, 0); + this.tlp1.Controls.Add(this.btnCancel, 0, 8); + this.tlp1.Controls.Add(this.btnALength, 0, 1); + this.tlp1.Controls.Add(this.btnExit, 1, 8); + this.tlp1.Controls.Add(this.btnDeleteCurve, 1, 3); + this.tlp1.Controls.Add(this.btnMakeCurve, 0, 4); + this.tlp1.Controls.Add(this.btnMakeABLine, 1, 4); + this.tlp1.Controls.Add(this.cboxIsZoom, 0, 3); + this.tlp1.Controls.Add(this.cboxIsVisible, 0, 2); + this.tlp1.Controls.Add(this.btnMakeBoundaryCurve, 1, 2); + this.tlp1.Controls.Add(this.btnCancelTouch, 1, 1); + this.tlp1.Controls.Add(this.tboxNameCurve, 0, 6); + this.tlp1.Controls.Add(this.btnSelectCurveBk, 0, 5); + this.tlp1.Controls.Add(this.btnSelectCurve, 1, 5); + this.tlp1.Controls.Add(this.lblCurveSelected, 0, 7); + this.tlp1.Controls.Add(this.btnAddTime, 1, 7); + this.tlp1.Location = new System.Drawing.Point(703, 2); + this.tlp1.Name = "tlp1"; + this.tlp1.RowCount = 9; + this.tlp1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 11.14701F)); + this.tlp1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 11.47011F)); + this.tlp1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 17.7706F)); + this.tlp1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 15.50888F)); + this.tlp1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 15.34733F)); + this.tlp1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 14.37803F)); + this.tlp1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 32F)); + this.tlp1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 48F)); + this.tlp1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 14.37803F)); + this.tlp1.Size = new System.Drawing.Size(299, 700); + this.tlp1.TabIndex = 564; // // btnBLength // - this.btnBLength.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.btnBLength.Anchor = System.Windows.Forms.AnchorStyles.None; this.btnBLength.BackColor = System.Drawing.Color.Transparent; this.btnBLength.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; this.btnBLength.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; @@ -283,17 +155,55 @@ private void InitializeComponent() this.btnBLength.FlatAppearance.MouseOverBackColor = System.Drawing.Color.Transparent; this.btnBLength.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnBLength.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnBLength.Image = global::AgOpenGPS.Properties.Resources.APlusPlusA; this.btnBLength.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnBLength.Location = new System.Drawing.Point(3, 3); + this.btnBLength.Location = new System.Drawing.Point(19, 13); this.btnBLength.Name = "btnBLength"; - this.btnBLength.Size = new System.Drawing.Size(63, 75); + this.btnBLength.Size = new System.Drawing.Size(110, 43); this.btnBLength.TabIndex = 351; this.btnBLength.UseVisualStyleBackColor = false; this.btnBLength.Click += new System.EventHandler(this.btnBLength_Click); // + // btnDrawSections + // + this.btnDrawSections.Anchor = System.Windows.Forms.AnchorStyles.None; + this.btnDrawSections.BackColor = System.Drawing.Color.Transparent; + this.btnDrawSections.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; + this.btnDrawSections.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnDrawSections.FlatAppearance.BorderSize = 0; + this.btnDrawSections.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnDrawSections.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnDrawSections.Image = global::AgOpenGPS.Properties.Resources.MappingOff; + this.btnDrawSections.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnDrawSections.Location = new System.Drawing.Point(188, 3); + this.btnDrawSections.Name = "btnDrawSections"; + this.btnDrawSections.Size = new System.Drawing.Size(72, 63); + this.btnDrawSections.TabIndex = 11; + this.btnDrawSections.UseVisualStyleBackColor = false; + this.btnDrawSections.Click += new System.EventHandler(this.btnDrawSections_Click); + this.btnDrawSections.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnDrawSections_HelpRequested); + // + // btnCancel + // + this.btnCancel.Anchor = System.Windows.Forms.AnchorStyles.None; + this.btnCancel.BackColor = System.Drawing.Color.Transparent; + this.btnCancel.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel; + this.btnCancel.FlatAppearance.BorderSize = 0; + this.btnCancel.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnCancel.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnCancel.Image = global::AgOpenGPS.Properties.Resources.Cancel64; + this.btnCancel.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnCancel.Location = new System.Drawing.Point(30, 627); + this.btnCancel.Name = "btnCancel"; + this.btnCancel.Size = new System.Drawing.Size(88, 56); + this.btnCancel.TabIndex = 469; + this.btnCancel.UseVisualStyleBackColor = false; + this.btnCancel.Click += new System.EventHandler(this.btnCancel_Click); + // // btnALength // - this.btnALength.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.btnALength.Anchor = System.Windows.Forms.AnchorStyles.None; this.btnALength.BackColor = System.Drawing.Color.Transparent; this.btnALength.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; this.btnALength.FlatAppearance.BorderColor = System.Drawing.Color.DarkOrange; @@ -302,52 +212,37 @@ private void InitializeComponent() this.btnALength.FlatAppearance.MouseOverBackColor = System.Drawing.Color.Transparent; this.btnALength.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.btnALength.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnALength.Image = global::AgOpenGPS.Properties.Resources.APlusPlusB; this.btnALength.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnALength.Location = new System.Drawing.Point(9, 101); + this.btnALength.Location = new System.Drawing.Point(19, 83); this.btnALength.Name = "btnALength"; - this.btnALength.Size = new System.Drawing.Size(63, 75); + this.btnALength.Size = new System.Drawing.Size(110, 43); this.btnALength.TabIndex = 352; this.btnALength.UseVisualStyleBackColor = false; this.btnALength.Click += new System.EventHandler(this.btnALength_Click); // - // btnMakeBoundaryCurve - // - this.btnMakeBoundaryCurve.BackColor = System.Drawing.Color.Transparent; - this.btnMakeBoundaryCurve.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.btnMakeBoundaryCurve.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; - this.btnMakeBoundaryCurve.FlatAppearance.BorderSize = 0; - this.btnMakeBoundaryCurve.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnMakeBoundaryCurve.Font = new System.Drawing.Font("Tahoma", 14.25F); - this.btnMakeBoundaryCurve.Image = global::AgOpenGPS.Properties.Resources.BoundaryCurveLine; - this.btnMakeBoundaryCurve.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnMakeBoundaryCurve.Location = new System.Drawing.Point(889, 226); - this.btnMakeBoundaryCurve.Name = "btnMakeBoundaryCurve"; - this.btnMakeBoundaryCurve.Size = new System.Drawing.Size(80, 71); - this.btnMakeBoundaryCurve.TabIndex = 4; - this.btnMakeBoundaryCurve.UseVisualStyleBackColor = false; - this.btnMakeBoundaryCurve.Click += new System.EventHandler(this.btnMakeBoundaryCurve_Click); - this.btnMakeBoundaryCurve.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnMakeBoundaryCurve_HelpRequested); - // - // btnDrawSections + // btnExit // - this.btnDrawSections.BackColor = System.Drawing.Color.Transparent; - this.btnDrawSections.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; - this.btnDrawSections.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; - this.btnDrawSections.FlatAppearance.BorderSize = 0; - this.btnDrawSections.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnDrawSections.Font = new System.Drawing.Font("Tahoma", 14.25F); - this.btnDrawSections.Image = global::AgOpenGPS.Properties.Resources.MappingOff; - this.btnDrawSections.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnDrawSections.Location = new System.Drawing.Point(880, 13); - this.btnDrawSections.Name = "btnDrawSections"; - this.btnDrawSections.Size = new System.Drawing.Size(89, 63); - this.btnDrawSections.TabIndex = 11; - this.btnDrawSections.UseVisualStyleBackColor = false; - this.btnDrawSections.Click += new System.EventHandler(this.btnDrawSections_Click); - this.btnDrawSections.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnDrawSections_HelpRequested); + this.btnExit.Anchor = System.Windows.Forms.AnchorStyles.None; + this.btnExit.BackColor = System.Drawing.Color.Transparent; + this.btnExit.DialogResult = System.Windows.Forms.DialogResult.Cancel; + this.btnExit.FlatAppearance.BorderSize = 0; + this.btnExit.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnExit.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnExit.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(64)))), ((int)(((byte)(0))))); + this.btnExit.Image = global::AgOpenGPS.Properties.Resources.OK64; + this.btnExit.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; + this.btnExit.Location = new System.Drawing.Point(180, 627); + this.btnExit.Name = "btnExit"; + this.btnExit.Size = new System.Drawing.Size(88, 56); + this.btnExit.TabIndex = 0; + this.btnExit.UseVisualStyleBackColor = false; + this.btnExit.Click += new System.EventHandler(this.btnExit_Click); + this.btnExit.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnExit_HelpRequested); // // btnDeleteCurve // + this.btnDeleteCurve.Anchor = System.Windows.Forms.AnchorStyles.None; this.btnDeleteCurve.BackColor = System.Drawing.Color.Transparent; this.btnDeleteCurve.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; this.btnDeleteCurve.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; @@ -356,34 +251,17 @@ private void InitializeComponent() this.btnDeleteCurve.Font = new System.Drawing.Font("Tahoma", 14.25F); this.btnDeleteCurve.Image = global::AgOpenGPS.Properties.Resources.Trash; this.btnDeleteCurve.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnDeleteCurve.Location = new System.Drawing.Point(842, 348); + this.btnDeleteCurve.Location = new System.Drawing.Point(188, 272); this.btnDeleteCurve.Name = "btnDeleteCurve"; - this.btnDeleteCurve.Size = new System.Drawing.Size(44, 45); + this.btnDeleteCurve.Size = new System.Drawing.Size(72, 52); this.btnDeleteCurve.TabIndex = 6; this.btnDeleteCurve.UseVisualStyleBackColor = false; this.btnDeleteCurve.Click += new System.EventHandler(this.btnDeleteCurve_Click); this.btnDeleteCurve.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnDeleteCurve_HelpRequested); // - // btnSelectCurve - // - this.btnSelectCurve.BackColor = System.Drawing.Color.Transparent; - this.btnSelectCurve.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.btnSelectCurve.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; - this.btnSelectCurve.FlatAppearance.BorderSize = 0; - this.btnSelectCurve.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnSelectCurve.Font = new System.Drawing.Font("Tahoma", 14.25F); - this.btnSelectCurve.Image = global::AgOpenGPS.Properties.Resources.ABLineCycle; - this.btnSelectCurve.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnSelectCurve.Location = new System.Drawing.Point(924, 517); - this.btnSelectCurve.Name = "btnSelectCurve"; - this.btnSelectCurve.Size = new System.Drawing.Size(70, 68); - this.btnSelectCurve.TabIndex = 5; - this.btnSelectCurve.UseVisualStyleBackColor = false; - this.btnSelectCurve.Click += new System.EventHandler(this.btnSelectCurve_Click); - this.btnSelectCurve.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnSelectCurve_HelpRequested); - // // btnMakeCurve // + this.btnMakeCurve.Anchor = System.Windows.Forms.AnchorStyles.None; this.btnMakeCurve.BackColor = System.Drawing.Color.Transparent; this.btnMakeCurve.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; this.btnMakeCurve.Enabled = false; @@ -393,9 +271,9 @@ private void InitializeComponent() this.btnMakeCurve.Font = new System.Drawing.Font("Tahoma", 14.25F); this.btnMakeCurve.Image = global::AgOpenGPS.Properties.Resources.ABTrackCurve; this.btnMakeCurve.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnMakeCurve.Location = new System.Drawing.Point(716, 398); + this.btnMakeCurve.Location = new System.Drawing.Point(29, 353); this.btnMakeCurve.Name = "btnMakeCurve"; - this.btnMakeCurve.Size = new System.Drawing.Size(81, 80); + this.btnMakeCurve.Size = new System.Drawing.Size(90, 80); this.btnMakeCurve.TabIndex = 2; this.btnMakeCurve.UseVisualStyleBackColor = false; this.btnMakeCurve.Click += new System.EventHandler(this.BtnMakeCurve_Click); @@ -403,6 +281,7 @@ private void InitializeComponent() // // btnMakeABLine // + this.btnMakeABLine.Anchor = System.Windows.Forms.AnchorStyles.None; this.btnMakeABLine.BackColor = System.Drawing.Color.Transparent; this.btnMakeABLine.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; this.btnMakeABLine.Enabled = false; @@ -412,51 +291,78 @@ private void InitializeComponent() this.btnMakeABLine.Font = new System.Drawing.Font("Tahoma", 14.25F); this.btnMakeABLine.Image = global::AgOpenGPS.Properties.Resources.ABTrackAB; this.btnMakeABLine.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnMakeABLine.Location = new System.Drawing.Point(717, 520); + this.btnMakeABLine.Location = new System.Drawing.Point(179, 353); this.btnMakeABLine.Name = "btnMakeABLine"; - this.btnMakeABLine.Size = new System.Drawing.Size(81, 80); + this.btnMakeABLine.Size = new System.Drawing.Size(90, 80); this.btnMakeABLine.TabIndex = 3; this.btnMakeABLine.UseVisualStyleBackColor = false; this.btnMakeABLine.Click += new System.EventHandler(this.BtnMakeABLine_Click); this.btnMakeABLine.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnMakeABLine_HelpRequested); // - // btnExit + // cboxIsZoom + // + this.cboxIsZoom.Anchor = System.Windows.Forms.AnchorStyles.None; + this.cboxIsZoom.Appearance = System.Windows.Forms.Appearance.Button; + this.cboxIsZoom.BackColor = System.Drawing.Color.WhiteSmoke; + this.cboxIsZoom.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.cboxIsZoom.FlatAppearance.CheckedBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(255)))), ((int)(((byte)(160))))); + this.cboxIsZoom.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.cboxIsZoom.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.cboxIsZoom.ForeColor = System.Drawing.SystemColors.ButtonFace; + this.cboxIsZoom.Image = global::AgOpenGPS.Properties.Resources.ZoomOGL; + this.cboxIsZoom.Location = new System.Drawing.Point(38, 264); + this.cboxIsZoom.Name = "cboxIsZoom"; + this.cboxIsZoom.RightToLeft = System.Windows.Forms.RightToLeft.Yes; + this.cboxIsZoom.Size = new System.Drawing.Size(72, 68); + this.cboxIsZoom.TabIndex = 563; + this.cboxIsZoom.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.cboxIsZoom.UseVisualStyleBackColor = false; + this.cboxIsZoom.CheckedChanged += new System.EventHandler(this.cboxIsZoom_CheckedChanged); // - this.btnExit.BackColor = System.Drawing.Color.Transparent; - this.btnExit.DialogResult = System.Windows.Forms.DialogResult.Cancel; - this.btnExit.FlatAppearance.BorderSize = 0; - this.btnExit.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnExit.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.btnExit.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(64)))), ((int)(((byte)(0))))); - this.btnExit.Image = global::AgOpenGPS.Properties.Resources.OK64; - this.btnExit.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; - this.btnExit.Location = new System.Drawing.Point(915, 637); - this.btnExit.Name = "btnExit"; - this.btnExit.Size = new System.Drawing.Size(83, 70); - this.btnExit.TabIndex = 0; - this.btnExit.UseVisualStyleBackColor = false; - this.btnExit.Click += new System.EventHandler(this.btnExit_Click); - this.btnExit.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnExit_HelpRequested); + // cboxIsVisible // - // btnCancel + this.cboxIsVisible.Anchor = System.Windows.Forms.AnchorStyles.None; + this.cboxIsVisible.Appearance = System.Windows.Forms.Appearance.Button; + this.cboxIsVisible.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(200)))), ((int)(((byte)(200))))); + this.cboxIsVisible.Checked = true; + this.cboxIsVisible.CheckState = System.Windows.Forms.CheckState.Checked; + this.cboxIsVisible.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.cboxIsVisible.FlatAppearance.CheckedBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(220)))), ((int)(((byte)(250)))), ((int)(((byte)(220))))); + this.cboxIsVisible.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.cboxIsVisible.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.cboxIsVisible.ForeColor = System.Drawing.SystemColors.ButtonFace; + this.cboxIsVisible.Image = global::AgOpenGPS.Properties.Resources.TrackVisible; + this.cboxIsVisible.Location = new System.Drawing.Point(38, 161); + this.cboxIsVisible.Name = "cboxIsVisible"; + this.cboxIsVisible.RightToLeft = System.Windows.Forms.RightToLeft.Yes; + this.cboxIsVisible.Size = new System.Drawing.Size(72, 68); + this.cboxIsVisible.TabIndex = 468; + this.cboxIsVisible.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.cboxIsVisible.UseVisualStyleBackColor = false; + this.cboxIsVisible.Click += new System.EventHandler(this.cboxIsVisible_Click); // - this.btnCancel.BackColor = System.Drawing.Color.Transparent; - this.btnCancel.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; - this.btnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel; - this.btnCancel.FlatAppearance.BorderSize = 0; - this.btnCancel.FlatStyle = System.Windows.Forms.FlatStyle.Flat; - this.btnCancel.Font = new System.Drawing.Font("Tahoma", 14.25F); - this.btnCancel.Image = global::AgOpenGPS.Properties.Resources.Cancel64; - this.btnCancel.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnCancel.Location = new System.Drawing.Point(713, 641); - this.btnCancel.Name = "btnCancel"; - this.btnCancel.Size = new System.Drawing.Size(88, 66); - this.btnCancel.TabIndex = 469; - this.btnCancel.UseVisualStyleBackColor = false; - this.btnCancel.Click += new System.EventHandler(this.btnCancel_Click); + // btnMakeBoundaryCurve + // + this.btnMakeBoundaryCurve.Anchor = System.Windows.Forms.AnchorStyles.None; + this.btnMakeBoundaryCurve.BackColor = System.Drawing.Color.Transparent; + this.btnMakeBoundaryCurve.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnMakeBoundaryCurve.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnMakeBoundaryCurve.FlatAppearance.BorderSize = 0; + this.btnMakeBoundaryCurve.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnMakeBoundaryCurve.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnMakeBoundaryCurve.Image = global::AgOpenGPS.Properties.Resources.BoundaryCurveLine; + this.btnMakeBoundaryCurve.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnMakeBoundaryCurve.Location = new System.Drawing.Point(174, 161); + this.btnMakeBoundaryCurve.Name = "btnMakeBoundaryCurve"; + this.btnMakeBoundaryCurve.Size = new System.Drawing.Size(100, 68); + this.btnMakeBoundaryCurve.TabIndex = 4; + this.btnMakeBoundaryCurve.UseVisualStyleBackColor = false; + this.btnMakeBoundaryCurve.Click += new System.EventHandler(this.btnMakeBoundaryCurve_Click); + this.btnMakeBoundaryCurve.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnMakeBoundaryCurve_HelpRequested); // // btnCancelTouch // + this.btnCancelTouch.Anchor = System.Windows.Forms.AnchorStyles.None; this.btnCancelTouch.BackColor = System.Drawing.Color.Transparent; this.btnCancelTouch.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; this.btnCancelTouch.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; @@ -465,29 +371,17 @@ private void InitializeComponent() this.btnCancelTouch.Font = new System.Drawing.Font("Tahoma", 14.25F); this.btnCancelTouch.Image = global::AgOpenGPS.Properties.Resources.HeadlandDeletePoints; this.btnCancelTouch.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnCancelTouch.Location = new System.Drawing.Point(889, 113); + this.btnCancelTouch.Location = new System.Drawing.Point(188, 72); this.btnCancelTouch.Name = "btnCancelTouch"; - this.btnCancelTouch.Size = new System.Drawing.Size(70, 68); + this.btnCancelTouch.Size = new System.Drawing.Size(72, 65); this.btnCancelTouch.TabIndex = 470; this.btnCancelTouch.UseVisualStyleBackColor = false; this.btnCancelTouch.Click += new System.EventHandler(this.btnCancelTouch_Click); this.btnCancelTouch.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnCancelTouch_HelpRequested); // - // label2 - // - this.label2.AutoSize = true; - this.label2.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.label2.ForeColor = System.Drawing.Color.Black; - this.label2.Location = new System.Drawing.Point(949, 372); - this.label2.Margin = new System.Windows.Forms.Padding(0); - this.label2.Name = "label2"; - this.label2.Size = new System.Drawing.Size(26, 23); - this.label2.TabIndex = 471; - this.label2.Text = "+"; - this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; - // // btnSelectCurveBk // + this.btnSelectCurveBk.Anchor = System.Windows.Forms.AnchorStyles.None; this.btnSelectCurveBk.BackColor = System.Drawing.Color.Transparent; this.btnSelectCurveBk.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; this.btnSelectCurveBk.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; @@ -496,59 +390,75 @@ private void InitializeComponent() this.btnSelectCurveBk.Font = new System.Drawing.Font("Tahoma", 14.25F); this.btnSelectCurveBk.Image = global::AgOpenGPS.Properties.Resources.ABLineCycleBk; this.btnSelectCurveBk.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnSelectCurveBk.Location = new System.Drawing.Point(831, 517); + this.btnSelectCurveBk.Location = new System.Drawing.Point(10, 451); this.btnSelectCurveBk.Name = "btnSelectCurveBk"; - this.btnSelectCurveBk.Size = new System.Drawing.Size(70, 68); + this.btnSelectCurveBk.Size = new System.Drawing.Size(128, 68); this.btnSelectCurveBk.TabIndex = 472; this.btnSelectCurveBk.UseVisualStyleBackColor = false; this.btnSelectCurveBk.Click += new System.EventHandler(this.btnSelectCurveBk_Click); // + // btnSelectCurve + // + this.btnSelectCurve.Anchor = System.Windows.Forms.AnchorStyles.None; + this.btnSelectCurve.BackColor = System.Drawing.Color.Transparent; + this.btnSelectCurve.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnSelectCurve.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnSelectCurve.FlatAppearance.BorderSize = 0; + this.btnSelectCurve.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnSelectCurve.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnSelectCurve.Image = global::AgOpenGPS.Properties.Resources.ABLineCycle; + this.btnSelectCurve.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnSelectCurve.Location = new System.Drawing.Point(160, 451); + this.btnSelectCurve.Name = "btnSelectCurve"; + this.btnSelectCurve.Size = new System.Drawing.Size(128, 68); + this.btnSelectCurve.TabIndex = 5; + this.btnSelectCurve.UseVisualStyleBackColor = false; + this.btnSelectCurve.Click += new System.EventHandler(this.btnSelectCurve_Click); + this.btnSelectCurve.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnSelectCurve_HelpRequested); + // + // btnAddTime + // + this.btnAddTime.Anchor = System.Windows.Forms.AnchorStyles.None; + this.btnAddTime.BackColor = System.Drawing.Color.Transparent; + this.btnAddTime.BackgroundImage = global::AgOpenGPS.Properties.Resources.JobNameTime; + this.btnAddTime.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnAddTime.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.btnAddTime.FlatAppearance.BorderSize = 0; + this.btnAddTime.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnAddTime.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnAddTime.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnAddTime.Location = new System.Drawing.Point(152, 565); + this.btnAddTime.Name = "btnAddTime"; + this.btnAddTime.Size = new System.Drawing.Size(144, 42); + this.btnAddTime.TabIndex = 356; + this.btnAddTime.TextAlign = System.Drawing.ContentAlignment.BottomCenter; + this.btnAddTime.UseVisualStyleBackColor = false; + this.btnAddTime.Click += new System.EventHandler(this.btnAddTime_Click); + // // FormABDraw // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.BackColor = System.Drawing.Color.WhiteSmoke; - this.ClientSize = new System.Drawing.Size(1006, 720); - this.Controls.Add(this.btnSelectCurveBk); - this.Controls.Add(this.label2); - this.Controls.Add(this.btnCancelTouch); - this.Controls.Add(this.btnCancel); - this.Controls.Add(this.cboxIsVisible); - this.Controls.Add(this.btnAddTime); - this.Controls.Add(this.panel1); - this.Controls.Add(this.btnFlipOffset); - this.Controls.Add(this.label8); - this.Controls.Add(this.label4); - this.Controls.Add(this.tboxNameCurve); - this.Controls.Add(this.btnMakeBoundaryCurve); - this.Controls.Add(this.label6); - this.Controls.Add(this.btnDrawSections); - this.Controls.Add(this.nudDistance); - this.Controls.Add(this.lblCurveSelected); - this.Controls.Add(this.lblNumCu); - this.Controls.Add(this.btnDeleteCurve); - this.Controls.Add(this.btnSelectCurve); - this.Controls.Add(this.btnMakeCurve); - this.Controls.Add(this.btnMakeABLine); - this.Controls.Add(this.btnExit); + this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(245)))), ((int)(((byte)(245)))), ((int)(((byte)(235))))); + this.ClientSize = new System.Drawing.Size(1006, 703); + this.Controls.Add(this.tlp1); this.Controls.Add(this.oglSelf); - this.Controls.Add(this.label1); - this.Controls.Add(this.lblCmInch); this.ForeColor = System.Drawing.Color.Black; - this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog; this.HelpButton = true; this.MaximizeBox = false; this.MinimizeBox = false; + this.MinimumSize = new System.Drawing.Size(1022, 742); this.Name = "FormABDraw"; this.ShowInTaskbar = false; this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; this.Text = "Draw AB - Click 2 points on the Boundary to Begin"; this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.FormABDraw_FormClosing); this.Load += new System.EventHandler(this.FormABDraw_Load); - ((System.ComponentModel.ISupportInitialize)(this.nudDistance)).EndInit(); - this.panel1.ResumeLayout(false); + this.ResizeEnd += new System.EventHandler(this.FormABDraw_ResizeEnd); + this.Resize += new System.EventHandler(this.FormABDraw_Resize); + this.tlp1.ResumeLayout(false); + this.tlp1.PerformLayout(); this.ResumeLayout(false); - this.PerformLayout(); } @@ -561,26 +471,18 @@ private void InitializeComponent() private System.Windows.Forms.Button btnMakeCurve; private System.Windows.Forms.Button btnSelectCurve; private System.Windows.Forms.Button btnDeleteCurve; - private System.Windows.Forms.Label lblNumCu; private System.Windows.Forms.Label lblCurveSelected; - private System.Windows.Forms.Label label1; - private NudlessNumericUpDown nudDistance; private System.Windows.Forms.Button btnDrawSections; private System.Windows.Forms.Button btnMakeBoundaryCurve; private System.Windows.Forms.TextBox tboxNameCurve; - private System.Windows.Forms.Label label4; - private System.Windows.Forms.Label label8; - private System.Windows.Forms.Button btnFlipOffset; private System.Windows.Forms.Button btnBLength; private System.Windows.Forms.Button btnALength; - private System.Windows.Forms.Label lblCmInch; - private System.Windows.Forms.Label label6; - private System.Windows.Forms.Panel panel1; private System.Windows.Forms.Button btnAddTime; private System.Windows.Forms.CheckBox cboxIsVisible; private System.Windows.Forms.Button btnCancel; private System.Windows.Forms.Button btnCancelTouch; - private System.Windows.Forms.Label label2; private System.Windows.Forms.Button btnSelectCurveBk; + private System.Windows.Forms.CheckBox cboxIsZoom; + private System.Windows.Forms.TableLayoutPanel tlp1; } } \ No newline at end of file diff --git a/SourceCode/GPS/Forms/Guidance/FormABDraw.cs b/SourceCode/GPS/Forms/Guidance/FormABDraw.cs index eb43200a2..5a79c86fa 100644 --- a/SourceCode/GPS/Forms/Guidance/FormABDraw.cs +++ b/SourceCode/GPS/Forms/Guidance/FormABDraw.cs @@ -22,6 +22,10 @@ public partial class FormABDraw : Form private int bndSelect = 0, originalLine; private bool isCancel = false; + private bool zoomToggle; + + private double zoom = 1, sX = 0, sY = 0; + public List gTemp = new List(); public vec3 pint = new vec3(0.0, 1.0, 0.0); @@ -35,16 +39,6 @@ public FormABDraw(Form callingForm) InitializeComponent(); - lblCmInch.Text = mf.unitsInCm; - - nudDistance.Controls[0].Enabled = false; - - if (!mf.isMetric) - { - nudDistance.Maximum = (int)(nudDistance.Maximum / 2.54M); - nudDistance.Minimum = (int)(nudDistance.Minimum / 2.54M); - } - mf.CalculateMinMax(); } @@ -52,13 +46,10 @@ private void FormABDraw_Load(object sender, EventArgs e) { originalLine = mf.trk.idx; //nudDistance.Value = (decimal)Math.Round(((mf.tool.width * mf.m2InchOrCm) * 0.5), 0); // - nudDistance.Value = 0; - label6.Text = Math.Round((mf.tool.width * mf.m2InchOrCm), 0).ToString(); FixLabelsCurve(); if (isDrawSections) btnDrawSections.Image = Properties.Resources.MappingOn; else btnDrawSections.Image = Properties.Resources.MappingOff; - btnFlipOffset.Text = "In"; for (int i = 0; i < mf.trk.gArr.Count; i++) { @@ -79,6 +70,17 @@ private void FormABDraw_Load(object sender, EventArgs e) } FixLabelsCurve(); + + cboxIsZoom.Checked = false; + zoomToggle = false; + Size = Properties.Settings.Default.setWindow_abDrawSize; + + Screen myScreen = Screen.FromControl(this); + Rectangle area = myScreen.WorkingArea; + + this.Top = (area.Height - this.Height) / 2; + this.Left = (area.Width - this.Width) / 2; + FormABDraw_ResizeEnd(this, e); } private void FormABDraw_FormClosing(object sender, FormClosingEventArgs e) @@ -149,6 +151,21 @@ private void FormABDraw_FormClosing(object sender, FormClosingEventArgs e) mf.twoSecondCounter = 100; mf.FileSaveTracks(); + + Properties.Settings.Default.setWindow_abDrawSize = Size; + Properties.Settings.Default.Save(); + } + + private void btnCenterOGL_Click(object sender, EventArgs e) + { + zoom = 1; + sX = 0; + sY = 0; + zoomToggle = false; + } + private void cboxIsZoom_CheckedChanged(object sender, EventArgs e) + { + zoomToggle = false; } private void btnExit_Click(object sender, EventArgs e) @@ -174,18 +191,21 @@ private void btnCancelTouch_Click(object sender, EventArgs e) mf.curve.desList?.Clear(); + zoom = 1; + sX = 0; + sY = 0; + zoomToggle = false; + btnExit.Focus(); } private void FixLabelsCurve() { - lblNumCu.Text = mf.trk.gArr.Count.ToString(); - if (mf.trk.idx > -1 && mf.trk.gArr.Count > 0) { tboxNameCurve.Text = mf.trk.gArr[mf.trk.idx].name; tboxNameCurve.Enabled = true; - lblCurveSelected.Text = (mf.trk.idx + 1).ToString(); + lblCurveSelected.Text = (mf.trk.idx + 1).ToString() + " / " + mf.trk.gArr.Count.ToString(); cboxIsVisible.Visible = true; cboxIsVisible.Checked = mf.trk.gArr[mf.trk.idx].isVisible; if (mf.trk.gArr[mf.trk.idx].isVisible) @@ -234,7 +254,7 @@ private void btnSelectCurveBk_Click(object sender, EventArgs e) if (mf.trk.gArr.Count > 0) { mf.trk.idx--; - if (mf.trk.idx <= 0) mf.trk.idx = mf.trk.gArr.Count - 1; + if (mf.trk.idx < 0) mf.trk.idx = mf.trk.gArr.Count - 1; } else { @@ -287,13 +307,6 @@ private void btnDrawSections_Click(object sender, EventArgs e) else btnDrawSections.Image = Properties.Resources.MappingOff; } - private void btnFlipOffset_Click(object sender, EventArgs e) - { - nudDistance.Value *= -1; - if (nudDistance.Value < 0) btnFlipOffset.Text = "Out"; - else btnFlipOffset.Text = "In"; - } - private void tboxNameCurve_Leave(object sender, EventArgs e) { if (mf.trk.idx > -1) @@ -327,17 +340,11 @@ private void btnMakeBoundaryCurve_Click(object sender, EventArgs e) { //count the points from the boundary for (int q = 0; q < mf.bnd.bndList.Count; q++) { - int ptCount = mf.bnd.bndList[q].fenceLine.Count; mf.curve.desList?.Clear(); //outside point vec3 pt3 = new vec3(); - double moveDist = (double)nudDistance.Value * mf.inchOrCm2m; - double distSq = (moveDist) * (moveDist) * 0.999; - - if (nudDistance.Value == 0) - { for (int i = 0; i < mf.bnd.bndList[bndSelect].fenceLine.Count; i++) { //calculate the point inside the boundary @@ -345,47 +352,7 @@ private void btnMakeBoundaryCurve_Click(object sender, EventArgs e) mf.curve.desList.Add(new vec3(pt3)); } - } - else - { - //make the boundary tram outer array - for (int i = 0; i < ptCount; i++) - { - //calculate the point inside the boundary - pt3.easting = mf.bnd.bndList[q].fenceLine[i].easting - - (Math.Sin(glm.PIBy2 + mf.bnd.bndList[q].fenceLine[i].heading) * (moveDist)); - - pt3.northing = mf.bnd.bndList[q].fenceLine[i].northing - - (Math.Cos(glm.PIBy2 + mf.bnd.bndList[q].fenceLine[i].heading) * (moveDist)); - - pt3.heading = mf.bnd.bndList[q].fenceLine[i].heading; - bool Add = true; - - for (int j = 0; j < ptCount; j++) - { - double check = glm.DistanceSquared(pt3.northing, pt3.easting, - mf.bnd.bndList[q].fenceLine[j].northing, mf.bnd.bndList[q].fenceLine[j].easting); - if (check < distSq) - { - Add = false; - break; - } - } - - if (Add) - { - if (mf.curve.desList.Count > 0) - { - double dist = ((pt3.easting - mf.curve.desList[mf.curve.desList.Count - 1].easting) * (pt3.easting - mf.curve.desList[mf.curve.desList.Count - 1].easting)) - + ((pt3.northing - mf.curve.desList[mf.curve.desList.Count - 1].northing) * (pt3.northing - mf.curve.desList[mf.curve.desList.Count - 1].northing)); - if (dist > 1) - mf.curve.desList.Add(pt3); - } - else mf.curve.desList.Add(pt3); - } - } - } mf.trk.gArr.Add(new CTrk()); //array number is 1 less since it starts at zero @@ -459,14 +426,9 @@ private void BtnMakeCurve_Click(object sender, EventArgs e) } } - double moveDist = (double)nudDistance.Value * mf.inchOrCm2m; - double distSq = (moveDist) * (moveDist) * 0.999; - mf.curve.desList?.Clear(); vec3 pt3 = new vec3(); - if (nudDistance.Value == 0) - { for (int i = start; i < end; i++) { //calculate the point inside the boundary @@ -481,53 +443,7 @@ private void BtnMakeCurve_Click(object sender, EventArgs e) end = limit; } } - } - else - { - for (int i = start; i < end; i++) - { - //calculate the point inside the boundary - pt3.easting = mf.bnd.bndList[bndSelect].fenceLine[i].easting - - (Math.Sin(glm.PIBy2 + mf.bnd.bndList[bndSelect].fenceLine[i].heading) * (moveDist)); - - pt3.northing = mf.bnd.bndList[bndSelect].fenceLine[i].northing - - (Math.Cos(glm.PIBy2 + mf.bnd.bndList[bndSelect].fenceLine[i].heading) * (moveDist)); - - pt3.heading = mf.bnd.bndList[bndSelect].fenceLine[i].heading; - - bool Add = true; - - for (int j = start; j < end; j++) - { - double check = glm.DistanceSquared(pt3.northing, pt3.easting, - mf.bnd.bndList[bndSelect].fenceLine[j].northing, mf.bnd.bndList[bndSelect].fenceLine[j].easting); - if (check < distSq) - { - Add = false; - break; - } - } - - if (Add) - { - if (mf.curve.desList.Count > 0) - { - double dist = ((pt3.easting - mf.curve.desList[mf.curve.desList.Count - 1].easting) * (pt3.easting - mf.curve.desList[mf.curve.desList.Count - 1].easting)) - + ((pt3.northing - mf.curve.desList[mf.curve.desList.Count - 1].northing) * (pt3.northing - mf.curve.desList[mf.curve.desList.Count - 1].northing)); - if (dist > 1) - mf.curve.desList.Add(new vec3(pt3)); - } - else mf.curve.desList.Add(new vec3(pt3)); - } - - if (isLoop && i == mf.bnd.bndList[bndSelect].fenceLine.Count - 1) - { - i = -1; - isLoop = false; - end = limit; - } - } - } + mf.trk.gArr.Add(new CTrk()); //array number is 1 less since it starts at zero @@ -618,10 +534,6 @@ private void BtnMakeABLine_Click(object sender, EventArgs e) mf.bnd.bndList[bndSelect].fenceLine[end].northing - mf.bnd.bndList[bndSelect].fenceLine[start].northing); if (abHead < 0) abHead += glm.twoPI; - double offset = ((double)nudDistance.Value * mf.inchOrCm2m); - - double headingCalc = abHead + glm.PIBy2; - mf.trk.gArr.Add(new CTrk()); mf.trk.idx = mf.trk.gArr.Count - 1; @@ -630,11 +542,11 @@ private void BtnMakeABLine_Click(object sender, EventArgs e) mf.trk.gArr[mf.trk.idx].mode = (int)TrackMode.AB; //calculate the new points for the reference line and points - mf.trk.gArr[mf.trk.idx].ptA.easting = (Math.Sin(headingCalc) * (offset)) + mf.bnd.bndList[bndSelect].fenceLine[start].easting; - mf.trk.gArr[mf.trk.idx].ptA.northing = (Math.Cos(headingCalc) * (offset)) + mf.bnd.bndList[bndSelect].fenceLine[start].northing; + mf.trk.gArr[mf.trk.idx].ptA.easting = mf.bnd.bndList[bndSelect].fenceLine[start].easting; + mf.trk.gArr[mf.trk.idx].ptA.northing = mf.bnd.bndList[bndSelect].fenceLine[start].northing; - mf.trk.gArr[mf.trk.idx].ptB.easting = (Math.Sin(headingCalc) * (offset)) + mf.bnd.bndList[bndSelect].fenceLine[end].easting; - mf.trk.gArr[mf.trk.idx].ptB.northing = (Math.Cos(headingCalc) * (offset)) + mf.bnd.bndList[bndSelect].fenceLine[end].northing; + mf.trk.gArr[mf.trk.idx].ptB.easting = mf.bnd.bndList[bndSelect].fenceLine[end].easting; + mf.trk.gArr[mf.trk.idx].ptB.northing = mf.bnd.bndList[bndSelect].fenceLine[end].northing; //create a name mf.trk.gArr[mf.trk.idx].name = "AB " + @@ -651,28 +563,47 @@ private void BtnMakeABLine_Click(object sender, EventArgs e) private void oglSelf_MouseDown(object sender, MouseEventArgs e) { + Point pt = oglSelf.PointToClient(Cursor.Position); + + int wid = oglSelf.Width; + int halfWid = oglSelf.Width / 2; + double scale = (double)wid * 0.903; + + if (cboxIsZoom.Checked && !zoomToggle) + { + sX = (( halfWid - (double)pt.X) / wid)*1.1; + sY = ((halfWid - (double)pt.Y) / -wid)*1.1; + zoom = 0.1; + zoomToggle = true; + return; + } + + zoomToggle = false; btnMakeABLine.Enabled = false; btnMakeCurve.Enabled = false; - Point pt = oglSelf.PointToClient(Cursor.Position); //Convert to Origin in the center of window, 800 pixels - fixPt.X = pt.X - 350; - fixPt.Y = (700 - pt.Y - 350); + fixPt.X = pt.X - halfWid; + fixPt.Y = (wid - pt.Y - halfWid); vec3 plotPt = new vec3 { //convert screen coordinates to field coordinates - easting = fixPt.X * mf.maxFieldDistance / 632.0, - northing = fixPt.Y * mf.maxFieldDistance / 632.0, + easting = fixPt.X * mf.maxFieldDistance / scale * zoom, + northing = fixPt.Y * mf.maxFieldDistance / scale * zoom, heading = 0 }; - plotPt.easting += mf.fieldCenterX; - plotPt.northing += mf.fieldCenterY; + plotPt.easting += mf.fieldCenterX + mf.maxFieldDistance * -sX; + plotPt.northing += mf.fieldCenterY + mf.maxFieldDistance * -sY; pint.easting = plotPt.easting; pint.northing = plotPt.northing; + zoom = 1; + sX = 0; + sY = 0; + if (isA) { double minDistA = double.MaxValue; @@ -726,21 +657,19 @@ private void oglSelf_Paint(object sender, PaintEventArgs e) GL.LoadIdentity(); // Reset The View //back the camera up - GL.Translate(0, 0, -mf.maxFieldDistance); + GL.Translate(0, 0, -mf.maxFieldDistance * zoom); //translate to that spot in the world - GL.Translate(-mf.fieldCenterX, -mf.fieldCenterY, 0); + GL.Translate(-mf.fieldCenterX + sX * mf.maxFieldDistance, -mf.fieldCenterY + sY * mf.maxFieldDistance, 0); - GL.Color3(1, 1, 1); - - //draw all the boundaries + if (isDrawSections) DrawSections(); - GL.LineWidth(1); + GL.LineWidth(3); for (int j = 0; j < mf.bnd.bndList.Count; j++) { if (j == bndSelect) - GL.Color3(0.25f, 0.5f, 0.50f); + GL.Color3(0.0f, 0.0f, 0.0f); else GL.Color3(0.2f, 0.35f, 0.35f); @@ -752,14 +681,19 @@ private void oglSelf_Paint(object sender, PaintEventArgs e) GL.End(); } - ////the vehicle - //GL.PointSize(8.0f); - //GL.Begin(PrimitiveType.Points); - //GL.Color3(0.95f, 0.90f, 0.0f); - //GL.Vertex3(mf.pivotAxlePos.easting, mf.pivotAxlePos.northing, 0.0); - //GL.End(); + //the vehicle + GL.PointSize(16.0f); + GL.Begin(PrimitiveType.Points); + GL.Color3(0.0f, 0.00f, 0.0f); + GL.Vertex3(mf.pivotAxlePos.easting, mf.pivotAxlePos.northing, 0.0); + GL.End(); + + GL.PointSize(8.0f); + GL.Begin(PrimitiveType.Points); + GL.Color3(0.95f, 0.190f, 0.20f); + GL.Vertex3(mf.pivotAxlePos.easting, mf.pivotAxlePos.northing, 0.0); + GL.End(); - if (isDrawSections) DrawSections(); //draw the line building graphics if (start != 99999 || end != 99999) DrawABTouchPoints(); @@ -783,7 +717,7 @@ private void DrawBuiltLines() if (mf.trk.gArr[i].mode == (int)TrackMode.AB) { GL.Enable(EnableCap.LineStipple); - GL.LineWidth(2); + GL.LineWidth(4); if (i == mf.trk.idx) { @@ -821,7 +755,7 @@ private void DrawBuiltLines() else if (mf.trk.gArr[i].mode == (int)TrackMode.Curve || mf.trk.gArr[i].mode == (int)TrackMode.bndCurve) { GL.Enable(EnableCap.LineStipple); - GL.LineWidth(4); + GL.LineWidth(5); if (mf.trk.gArr[i].mode == (int)TrackMode.bndCurve) GL.LineStipple(1, 0x0007); else GL.LineStipple(1, 0x0707); @@ -962,6 +896,47 @@ private void btnBLength_Click(object sender, EventArgs e) } } + private void FormABDraw_ResizeEnd(object sender, EventArgs e) + { + Width = (Height * 4 / 3); + + if (Height > Width) + { + oglSelf.Height = oglSelf.Width = Width - 60; + } + else + { + oglSelf.Height = oglSelf.Width = Height - 60; + } + + oglSelf.Left = 2; + oglSelf.Top = 2; + + oglSelf.MakeCurrent(); + GL.MatrixMode(MatrixMode.Projection); + GL.LoadIdentity(); + + //58 degrees view + GL.Viewport(0, 0, oglSelf.Width, oglSelf.Height); + Matrix4 mat = Matrix4.CreatePerspectiveFieldOfView(1.01f, 1.0f, 1.0f, 20000); + GL.LoadMatrix(ref mat); + + GL.MatrixMode(MatrixMode.Modelview); + + tlp1.Width = Width - oglSelf.Width - 4; + tlp1.Left = oglSelf.Width + 4; + + Screen myScreen = Screen.FromControl(this); + Rectangle area = myScreen.WorkingArea; + + this.Top = (area.Height - this.Height) / 2; + this.Left = (area.Width - this.Width) / 2; + } + + private void FormABDraw_Resize(object sender, EventArgs e) + { + } + private void oglSelf_Resize(object sender, EventArgs e) { oglSelf.MakeCurrent(); @@ -969,6 +944,8 @@ private void oglSelf_Resize(object sender, EventArgs e) GL.LoadIdentity(); //58 degrees view + GL.Viewport(0, 0, oglSelf.Width, oglSelf.Height); + Matrix4 mat = Matrix4.CreatePerspectiveFieldOfView(1.01f, 1.0f, 1.0f, 20000); GL.LoadMatrix(ref mat); @@ -988,7 +965,7 @@ private void DrawSections() int cnt, step, patchCount; int mipmap = 8; - GL.Color3(0.0, 0.0, 0.352); + GL.Color3(0.9f, 0.9f, 0.8f); //draw patches j= # of sections for (int j = 0; j < mf.triStrip.Count; j++) diff --git a/SourceCode/GPS/Forms/Guidance/FormABDraw2.Designer.cs b/SourceCode/GPS/Forms/Guidance/FormABDraw2.Designer.cs new file mode 100644 index 000000000..1006af9e1 --- /dev/null +++ b/SourceCode/GPS/Forms/Guidance/FormABDraw2.Designer.cs @@ -0,0 +1,509 @@ +namespace AgOpenGPS +{ + partial class FormABDraw2 + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.components = new System.ComponentModel.Container(); + this.oglSelf = new OpenTK.GLControl(); + this.timer1 = new System.Windows.Forms.Timer(this.components); + this.lblNumCu = new System.Windows.Forms.Label(); + this.lblCurveSelected = new System.Windows.Forms.Label(); + this.label1 = new System.Windows.Forms.Label(); + this.tboxNameCurve = new System.Windows.Forms.TextBox(); + this.label4 = new System.Windows.Forms.Label(); + this.label8 = new System.Windows.Forms.Label(); + this.cboxIsVisible = new System.Windows.Forms.CheckBox(); + this.btnAddTime = new System.Windows.Forms.Button(); + this.panel1 = new System.Windows.Forms.Panel(); + this.btnBLength = new System.Windows.Forms.Button(); + this.btnALength = new System.Windows.Forms.Button(); + this.btnMakeBoundaryCurve = new System.Windows.Forms.Button(); + this.btnDrawSections = new System.Windows.Forms.Button(); + this.btnDeleteCurve = new System.Windows.Forms.Button(); + this.btnSelectCurve = new System.Windows.Forms.Button(); + this.btnMakeCurve = new System.Windows.Forms.Button(); + this.btnMakeABLine = new System.Windows.Forms.Button(); + this.btnExit = new System.Windows.Forms.Button(); + this.btnCancel = new System.Windows.Forms.Button(); + this.btnCancelTouch = new System.Windows.Forms.Button(); + this.label2 = new System.Windows.Forms.Label(); + this.btnSelectCurveBk = new System.Windows.Forms.Button(); + this.panel1.SuspendLayout(); + this.SuspendLayout(); + // + // oglSelf + // + this.oglSelf.BackColor = System.Drawing.Color.Black; + this.oglSelf.Cursor = System.Windows.Forms.Cursors.Cross; + this.oglSelf.Location = new System.Drawing.Point(5, 2); + this.oglSelf.Margin = new System.Windows.Forms.Padding(0); + this.oglSelf.Name = "oglSelf"; + this.oglSelf.Size = new System.Drawing.Size(1000, 1000); + this.oglSelf.TabIndex = 183; + this.oglSelf.VSync = false; + this.oglSelf.Load += new System.EventHandler(this.oglSelf_Load); + this.oglSelf.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.oglSelf_HelpRequested); + this.oglSelf.Paint += new System.Windows.Forms.PaintEventHandler(this.oglSelf_Paint); + this.oglSelf.MouseDown += new System.Windows.Forms.MouseEventHandler(this.oglSelf_MouseDown); + this.oglSelf.Resize += new System.EventHandler(this.oglSelf_Resize); + // + // timer1 + // + this.timer1.Enabled = true; + this.timer1.Interval = 500; + this.timer1.Tick += new System.EventHandler(this.timer1_Tick); + // + // lblNumCu + // + this.lblNumCu.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblNumCu.ForeColor = System.Drawing.Color.Black; + this.lblNumCu.Location = new System.Drawing.Point(1207, 702); + this.lblNumCu.Margin = new System.Windows.Forms.Padding(0); + this.lblNumCu.Name = "lblNumCu"; + this.lblNumCu.Size = new System.Drawing.Size(35, 26); + this.lblNumCu.TabIndex = 327; + this.lblNumCu.Text = "1"; + this.lblNumCu.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; + // + // lblCurveSelected + // + this.lblCurveSelected.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.lblCurveSelected.ForeColor = System.Drawing.Color.Black; + this.lblCurveSelected.Location = new System.Drawing.Point(1128, 702); + this.lblCurveSelected.Margin = new System.Windows.Forms.Padding(0); + this.lblCurveSelected.Name = "lblCurveSelected"; + this.lblCurveSelected.Size = new System.Drawing.Size(35, 26); + this.lblCurveSelected.TabIndex = 329; + this.lblCurveSelected.Text = "1"; + this.lblCurveSelected.TextAlign = System.Drawing.ContentAlignment.MiddleRight; + // + // label1 + // + this.label1.AutoSize = true; + this.label1.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label1.ForeColor = System.Drawing.Color.Black; + this.label1.Location = new System.Drawing.Point(1170, 703); + this.label1.Margin = new System.Windows.Forms.Padding(0); + this.label1.Name = "label1"; + this.label1.Size = new System.Drawing.Size(29, 23); + this.label1.TabIndex = 332; + this.label1.Text = "of"; + this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // tboxNameCurve + // + this.tboxNameCurve.BackColor = System.Drawing.SystemColors.ControlLight; + this.tboxNameCurve.CausesValidation = false; + this.tboxNameCurve.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.tboxNameCurve.Location = new System.Drawing.Point(1023, 738); + this.tboxNameCurve.Margin = new System.Windows.Forms.Padding(0); + this.tboxNameCurve.MaxLength = 100; + this.tboxNameCurve.Name = "tboxNameCurve"; + this.tboxNameCurve.Size = new System.Drawing.Size(316, 27); + this.tboxNameCurve.TabIndex = 10; + this.tboxNameCurve.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; + this.tboxNameCurve.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.tboxNameCurve_HelpRequested); + this.tboxNameCurve.Enter += new System.EventHandler(this.tboxNameCurve_Enter); + this.tboxNameCurve.Leave += new System.EventHandler(this.tboxNameCurve_Leave); + // + // label4 + // + this.label4.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label4.ForeColor = System.Drawing.Color.Black; + this.label4.Location = new System.Drawing.Point(1211, 288); + this.label4.Margin = new System.Windows.Forms.Padding(0); + this.label4.Name = "label4"; + this.label4.Size = new System.Drawing.Size(109, 17); + this.label4.TabIndex = 12; + this.label4.Text = "Boundary Curve"; + this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // label8 + // + this.label8.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label8.ForeColor = System.Drawing.Color.Black; + this.label8.Location = new System.Drawing.Point(1212, 82); + this.label8.Margin = new System.Windows.Forms.Padding(0); + this.label8.Name = "label8"; + this.label8.Size = new System.Drawing.Size(93, 20); + this.label8.TabIndex = 13; + this.label8.Text = "Mapping"; + this.label8.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // cboxIsVisible + // + this.cboxIsVisible.Appearance = System.Windows.Forms.Appearance.Button; + this.cboxIsVisible.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(200)))), ((int)(((byte)(200))))); + this.cboxIsVisible.Checked = true; + this.cboxIsVisible.CheckState = System.Windows.Forms.CheckState.Checked; + this.cboxIsVisible.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.cboxIsVisible.FlatAppearance.CheckedBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(220)))), ((int)(((byte)(250)))), ((int)(((byte)(220))))); + this.cboxIsVisible.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.cboxIsVisible.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.cboxIsVisible.ForeColor = System.Drawing.SystemColors.ButtonFace; + this.cboxIsVisible.Image = global::AgOpenGPS.Properties.Resources.TrackVisible; + this.cboxIsVisible.Location = new System.Drawing.Point(1143, 548); + this.cboxIsVisible.Name = "cboxIsVisible"; + this.cboxIsVisible.RightToLeft = System.Windows.Forms.RightToLeft.Yes; + this.cboxIsVisible.Size = new System.Drawing.Size(81, 80); + this.cboxIsVisible.TabIndex = 468; + this.cboxIsVisible.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.cboxIsVisible.UseVisualStyleBackColor = false; + this.cboxIsVisible.Click += new System.EventHandler(this.cboxIsVisible_Click); + // + // btnAddTime + // + this.btnAddTime.BackColor = System.Drawing.Color.Transparent; + this.btnAddTime.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.btnAddTime.FlatAppearance.BorderSize = 0; + this.btnAddTime.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnAddTime.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnAddTime.Image = global::AgOpenGPS.Properties.Resources.JobNameTime; + this.btnAddTime.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnAddTime.Location = new System.Drawing.Point(1237, 779); + this.btnAddTime.Name = "btnAddTime"; + this.btnAddTime.Size = new System.Drawing.Size(68, 69); + this.btnAddTime.TabIndex = 356; + this.btnAddTime.TextAlign = System.Drawing.ContentAlignment.BottomCenter; + this.btnAddTime.UseVisualStyleBackColor = false; + this.btnAddTime.Click += new System.EventHandler(this.btnAddTime_Click); + // + // panel1 + // + this.panel1.BackgroundImage = global::AgOpenGPS.Properties.Resources.ABShrinkGrow; + this.panel1.Controls.Add(this.btnBLength); + this.panel1.Controls.Add(this.btnALength); + this.panel1.Location = new System.Drawing.Point(1017, 6); + this.panel1.Name = "panel1"; + this.panel1.Size = new System.Drawing.Size(115, 179); + this.panel1.TabIndex = 355; + // + // btnBLength + // + this.btnBLength.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.btnBLength.BackColor = System.Drawing.Color.Transparent; + this.btnBLength.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnBLength.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnBLength.FlatAppearance.BorderSize = 0; + this.btnBLength.FlatAppearance.MouseDownBackColor = System.Drawing.Color.Transparent; + this.btnBLength.FlatAppearance.MouseOverBackColor = System.Drawing.Color.Transparent; + this.btnBLength.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnBLength.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnBLength.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnBLength.Location = new System.Drawing.Point(3, 3); + this.btnBLength.Name = "btnBLength"; + this.btnBLength.Size = new System.Drawing.Size(63, 75); + this.btnBLength.TabIndex = 351; + this.btnBLength.UseVisualStyleBackColor = false; + this.btnBLength.Click += new System.EventHandler(this.btnBLength_Click); + // + // btnALength + // + this.btnALength.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.btnALength.BackColor = System.Drawing.Color.Transparent; + this.btnALength.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnALength.FlatAppearance.BorderColor = System.Drawing.Color.DarkOrange; + this.btnALength.FlatAppearance.BorderSize = 0; + this.btnALength.FlatAppearance.MouseDownBackColor = System.Drawing.Color.Transparent; + this.btnALength.FlatAppearance.MouseOverBackColor = System.Drawing.Color.Transparent; + this.btnALength.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnALength.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnALength.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnALength.Location = new System.Drawing.Point(9, 101); + this.btnALength.Name = "btnALength"; + this.btnALength.Size = new System.Drawing.Size(63, 75); + this.btnALength.TabIndex = 352; + this.btnALength.UseVisualStyleBackColor = false; + this.btnALength.Click += new System.EventHandler(this.btnALength_Click); + // + // btnMakeBoundaryCurve + // + this.btnMakeBoundaryCurve.BackColor = System.Drawing.Color.Transparent; + this.btnMakeBoundaryCurve.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnMakeBoundaryCurve.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnMakeBoundaryCurve.FlatAppearance.BorderSize = 0; + this.btnMakeBoundaryCurve.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnMakeBoundaryCurve.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnMakeBoundaryCurve.Image = global::AgOpenGPS.Properties.Resources.BoundaryCurveLine; + this.btnMakeBoundaryCurve.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnMakeBoundaryCurve.Location = new System.Drawing.Point(1225, 228); + this.btnMakeBoundaryCurve.Name = "btnMakeBoundaryCurve"; + this.btnMakeBoundaryCurve.Size = new System.Drawing.Size(80, 71); + this.btnMakeBoundaryCurve.TabIndex = 4; + this.btnMakeBoundaryCurve.UseVisualStyleBackColor = false; + this.btnMakeBoundaryCurve.Click += new System.EventHandler(this.btnMakeBoundaryCurve_Click); + this.btnMakeBoundaryCurve.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnMakeBoundaryCurve_HelpRequested); + // + // btnDrawSections + // + this.btnDrawSections.BackColor = System.Drawing.Color.Transparent; + this.btnDrawSections.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; + this.btnDrawSections.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnDrawSections.FlatAppearance.BorderSize = 0; + this.btnDrawSections.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnDrawSections.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnDrawSections.Image = global::AgOpenGPS.Properties.Resources.MappingOff; + this.btnDrawSections.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnDrawSections.Location = new System.Drawing.Point(1216, 15); + this.btnDrawSections.Name = "btnDrawSections"; + this.btnDrawSections.Size = new System.Drawing.Size(89, 63); + this.btnDrawSections.TabIndex = 11; + this.btnDrawSections.UseVisualStyleBackColor = false; + this.btnDrawSections.Click += new System.EventHandler(this.btnDrawSections_Click); + this.btnDrawSections.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnDrawSections_HelpRequested); + // + // btnDeleteCurve + // + this.btnDeleteCurve.BackColor = System.Drawing.Color.Transparent; + this.btnDeleteCurve.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnDeleteCurve.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnDeleteCurve.FlatAppearance.BorderSize = 0; + this.btnDeleteCurve.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnDeleteCurve.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnDeleteCurve.Image = global::AgOpenGPS.Properties.Resources.Trash; + this.btnDeleteCurve.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnDeleteCurve.Location = new System.Drawing.Point(1070, 789); + this.btnDeleteCurve.Name = "btnDeleteCurve"; + this.btnDeleteCurve.Size = new System.Drawing.Size(44, 45); + this.btnDeleteCurve.TabIndex = 6; + this.btnDeleteCurve.UseVisualStyleBackColor = false; + this.btnDeleteCurve.Click += new System.EventHandler(this.btnDeleteCurve_Click); + this.btnDeleteCurve.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnDeleteCurve_HelpRequested); + // + // btnSelectCurve + // + this.btnSelectCurve.BackColor = System.Drawing.Color.Transparent; + this.btnSelectCurve.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnSelectCurve.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnSelectCurve.FlatAppearance.BorderSize = 0; + this.btnSelectCurve.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnSelectCurve.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnSelectCurve.Image = global::AgOpenGPS.Properties.Resources.ABLineCycle; + this.btnSelectCurve.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnSelectCurve.Location = new System.Drawing.Point(1251, 646); + this.btnSelectCurve.Name = "btnSelectCurve"; + this.btnSelectCurve.Size = new System.Drawing.Size(70, 68); + this.btnSelectCurve.TabIndex = 5; + this.btnSelectCurve.UseVisualStyleBackColor = false; + this.btnSelectCurve.Click += new System.EventHandler(this.btnSelectCurve_Click); + this.btnSelectCurve.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnSelectCurve_HelpRequested); + // + // btnMakeCurve + // + this.btnMakeCurve.BackColor = System.Drawing.Color.Transparent; + this.btnMakeCurve.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnMakeCurve.Enabled = false; + this.btnMakeCurve.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnMakeCurve.FlatAppearance.BorderSize = 0; + this.btnMakeCurve.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnMakeCurve.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnMakeCurve.Image = global::AgOpenGPS.Properties.Resources.ABTrackCurve; + this.btnMakeCurve.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnMakeCurve.Location = new System.Drawing.Point(1033, 385); + this.btnMakeCurve.Name = "btnMakeCurve"; + this.btnMakeCurve.Size = new System.Drawing.Size(81, 80); + this.btnMakeCurve.TabIndex = 2; + this.btnMakeCurve.UseVisualStyleBackColor = false; + this.btnMakeCurve.Click += new System.EventHandler(this.BtnMakeCurve_Click); + this.btnMakeCurve.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnMakeCurve_HelpRequested); + // + // btnMakeABLine + // + this.btnMakeABLine.BackColor = System.Drawing.Color.Transparent; + this.btnMakeABLine.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnMakeABLine.Enabled = false; + this.btnMakeABLine.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnMakeABLine.FlatAppearance.BorderSize = 0; + this.btnMakeABLine.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnMakeABLine.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnMakeABLine.Image = global::AgOpenGPS.Properties.Resources.ABTrackAB; + this.btnMakeABLine.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnMakeABLine.Location = new System.Drawing.Point(1189, 385); + this.btnMakeABLine.Name = "btnMakeABLine"; + this.btnMakeABLine.Size = new System.Drawing.Size(81, 80); + this.btnMakeABLine.TabIndex = 3; + this.btnMakeABLine.UseVisualStyleBackColor = false; + this.btnMakeABLine.Click += new System.EventHandler(this.BtnMakeABLine_Click); + this.btnMakeABLine.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnMakeABLine_HelpRequested); + // + // btnExit + // + this.btnExit.BackColor = System.Drawing.Color.Transparent; + this.btnExit.DialogResult = System.Windows.Forms.DialogResult.Cancel; + this.btnExit.FlatAppearance.BorderSize = 0; + this.btnExit.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnExit.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.btnExit.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(64)))), ((int)(((byte)(0))))); + this.btnExit.Image = global::AgOpenGPS.Properties.Resources.OK64; + this.btnExit.ImageAlign = System.Drawing.ContentAlignment.MiddleRight; + this.btnExit.Location = new System.Drawing.Point(1251, 933); + this.btnExit.Name = "btnExit"; + this.btnExit.Size = new System.Drawing.Size(83, 70); + this.btnExit.TabIndex = 0; + this.btnExit.UseVisualStyleBackColor = false; + this.btnExit.Click += new System.EventHandler(this.btnExit_Click); + this.btnExit.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnExit_HelpRequested); + // + // btnCancel + // + this.btnCancel.BackColor = System.Drawing.Color.Transparent; + this.btnCancel.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel; + this.btnCancel.FlatAppearance.BorderSize = 0; + this.btnCancel.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnCancel.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnCancel.Image = global::AgOpenGPS.Properties.Resources.Cancel64; + this.btnCancel.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnCancel.Location = new System.Drawing.Point(1026, 937); + this.btnCancel.Name = "btnCancel"; + this.btnCancel.Size = new System.Drawing.Size(88, 66); + this.btnCancel.TabIndex = 469; + this.btnCancel.UseVisualStyleBackColor = false; + this.btnCancel.Click += new System.EventHandler(this.btnCancel_Click); + // + // btnCancelTouch + // + this.btnCancelTouch.BackColor = System.Drawing.Color.Transparent; + this.btnCancelTouch.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnCancelTouch.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnCancelTouch.FlatAppearance.BorderSize = 0; + this.btnCancelTouch.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnCancelTouch.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnCancelTouch.Image = global::AgOpenGPS.Properties.Resources.HeadlandDeletePoints; + this.btnCancelTouch.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnCancelTouch.Location = new System.Drawing.Point(1044, 229); + this.btnCancelTouch.Name = "btnCancelTouch"; + this.btnCancelTouch.Size = new System.Drawing.Size(70, 68); + this.btnCancelTouch.TabIndex = 470; + this.btnCancelTouch.UseVisualStyleBackColor = false; + this.btnCancelTouch.Click += new System.EventHandler(this.btnCancelTouch_Click); + this.btnCancelTouch.HelpRequested += new System.Windows.Forms.HelpEventHandler(this.btnCancelTouch_HelpRequested); + // + // label2 + // + this.label2.AutoSize = true; + this.label2.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.label2.ForeColor = System.Drawing.Color.Black; + this.label2.Location = new System.Drawing.Point(1207, 800); + this.label2.Margin = new System.Windows.Forms.Padding(0); + this.label2.Name = "label2"; + this.label2.Size = new System.Drawing.Size(26, 23); + this.label2.TabIndex = 471; + this.label2.Text = "+"; + this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + // + // btnSelectCurveBk + // + this.btnSelectCurveBk.BackColor = System.Drawing.Color.Transparent; + this.btnSelectCurveBk.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom; + this.btnSelectCurveBk.FlatAppearance.BorderColor = System.Drawing.SystemColors.HotTrack; + this.btnSelectCurveBk.FlatAppearance.BorderSize = 0; + this.btnSelectCurveBk.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnSelectCurveBk.Font = new System.Drawing.Font("Tahoma", 14.25F); + this.btnSelectCurveBk.Image = global::AgOpenGPS.Properties.Resources.ABLineCycleBk; + this.btnSelectCurveBk.ImeMode = System.Windows.Forms.ImeMode.NoControl; + this.btnSelectCurveBk.Location = new System.Drawing.Point(1044, 646); + this.btnSelectCurveBk.Name = "btnSelectCurveBk"; + this.btnSelectCurveBk.Size = new System.Drawing.Size(70, 68); + this.btnSelectCurveBk.TabIndex = 472; + this.btnSelectCurveBk.UseVisualStyleBackColor = false; + this.btnSelectCurveBk.Click += new System.EventHandler(this.btnSelectCurveBk_Click); + // + // FormABDraw2 + // + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.BackColor = System.Drawing.Color.WhiteSmoke; + this.ClientSize = new System.Drawing.Size(1346, 1006); + this.ControlBox = false; + this.Controls.Add(this.btnSelectCurveBk); + this.Controls.Add(this.label2); + this.Controls.Add(this.btnCancelTouch); + this.Controls.Add(this.btnCancel); + this.Controls.Add(this.cboxIsVisible); + this.Controls.Add(this.btnAddTime); + this.Controls.Add(this.panel1); + this.Controls.Add(this.label8); + this.Controls.Add(this.label4); + this.Controls.Add(this.tboxNameCurve); + this.Controls.Add(this.btnMakeBoundaryCurve); + this.Controls.Add(this.btnDrawSections); + this.Controls.Add(this.lblCurveSelected); + this.Controls.Add(this.lblNumCu); + this.Controls.Add(this.btnDeleteCurve); + this.Controls.Add(this.btnSelectCurve); + this.Controls.Add(this.btnMakeCurve); + this.Controls.Add(this.btnMakeABLine); + this.Controls.Add(this.btnExit); + this.Controls.Add(this.oglSelf); + this.Controls.Add(this.label1); + this.ForeColor = System.Drawing.Color.Black; + this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow; + this.HelpButton = true; + this.MaximizeBox = false; + this.MinimizeBox = false; + this.Name = "FormABDraw2"; + this.ShowInTaskbar = false; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; + this.Text = "Draw AB - Click 2 points on the Boundary to Begin"; + this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.FormABDraw_FormClosing); + this.Load += new System.EventHandler(this.FormABDraw_Load); + this.panel1.ResumeLayout(false); + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + + private OpenTK.GLControl oglSelf; + private System.Windows.Forms.Timer timer1; + private System.Windows.Forms.Button btnExit; + private System.Windows.Forms.Button btnMakeABLine; + private System.Windows.Forms.Button btnMakeCurve; + private System.Windows.Forms.Button btnSelectCurve; + private System.Windows.Forms.Button btnDeleteCurve; + private System.Windows.Forms.Label lblNumCu; + private System.Windows.Forms.Label lblCurveSelected; + private System.Windows.Forms.Label label1; + private System.Windows.Forms.Button btnDrawSections; + private System.Windows.Forms.Button btnMakeBoundaryCurve; + private System.Windows.Forms.TextBox tboxNameCurve; + private System.Windows.Forms.Label label4; + private System.Windows.Forms.Label label8; + private System.Windows.Forms.Button btnBLength; + private System.Windows.Forms.Button btnALength; + private System.Windows.Forms.Panel panel1; + private System.Windows.Forms.Button btnAddTime; + private System.Windows.Forms.CheckBox cboxIsVisible; + private System.Windows.Forms.Button btnCancel; + private System.Windows.Forms.Button btnCancelTouch; + private System.Windows.Forms.Label label2; + private System.Windows.Forms.Button btnSelectCurveBk; + } +} \ No newline at end of file diff --git a/SourceCode/GPS/Forms/Guidance/FormABDraw2.cs b/SourceCode/GPS/Forms/Guidance/FormABDraw2.cs new file mode 100644 index 000000000..effc8bfb3 --- /dev/null +++ b/SourceCode/GPS/Forms/Guidance/FormABDraw2.cs @@ -0,0 +1,997 @@ +using OpenTK; +using OpenTK.Graphics.OpenGL; +using System; +using System.Collections.Generic; +using System.Drawing; +using System.Globalization; +using System.Runtime.CompilerServices; +using System.Windows.Forms; +using static System.Windows.Forms.VisualStyles.VisualStyleElement; + +namespace AgOpenGPS +{ + public partial class FormABDraw2 : Form + { + //access to the main GPS form and all its variables + private readonly FormGPS mf = null; + + private Point fixPt; + + private bool isA = true; + private int start = 99999, end = 99999; + private int bndSelect = 0, originalLine; + private bool isCancel = false; + + public List gTemp = new List(); + + public vec3 pint = new vec3(0.0, 1.0, 0.0); + + private bool isDrawSections = false; + + public FormABDraw2(Form callingForm) + { + //get copy of the calling main form + mf = callingForm as FormGPS; + + InitializeComponent(); + + mf.CalculateMinMax(); + } + + private void FormABDraw_Load(object sender, EventArgs e) + { + originalLine = mf.trk.idx; + //nudDistance.Value = (decimal)Math.Round(((mf.tool.width * mf.m2InchOrCm) * 0.5), 0); // + FixLabelsCurve(); + + if (isDrawSections) btnDrawSections.Image = Properties.Resources.MappingOn; + else btnDrawSections.Image = Properties.Resources.MappingOff; + + for (int i = 0; i < mf.trk.gArr.Count; i++) + { + if (mf.trk.gArr[i].mode == 0) + return; + } + + if (mf.trk.idx == -1) + { + if (mf.trk.gArr.Count > 0) mf.trk.idx = 0; + } + + gTemp.Clear(); + + foreach (var item in mf.trk.gArr) + { + gTemp.Add(new CTrk(item)); + } + + FixLabelsCurve(); + } + + private void FormABDraw_FormClosing(object sender, FormClosingEventArgs e) + { + if (!isCancel) + { + if (mf.trk.gArr.Count == 0) + { + mf.trk.idx = -1; + mf.FileSaveTracks(); + if (mf.isBtnAutoSteerOn) mf.btnAutoSteer.PerformClick(); + if (mf.yt.isYouTurnBtnOn) mf.btnAutoYouTurn.PerformClick(); + } + else + { + //mf.trk.idx = mf.trk.gArr.Count - 1; + + //make sure selected is visible + if (!mf.trk.gArr[mf.trk.idx].isVisible) + { + bool isOneVis = false; + + foreach (var item in mf.trk.gArr) + { + if (item.isVisible) isOneVis = true; + break; + } + + if (isOneVis) + { + if (mf.trk.gArr.Count > 1) + { + while (true) + { + mf.trk.idx++; + if (mf.trk.idx == mf.trk.gArr.Count) mf.trk.idx = 0; + + if (mf.trk.gArr[mf.trk.idx].isVisible) + { + break; + } + } + } + } + else + { + mf.trk.idx = -1; + } + } + + } + } + else + { + mf.trk.gArr.Clear(); + + foreach (var item in gTemp) + { + mf.trk.gArr.Add(new CTrk(item)); + } + + mf.trk.idx = originalLine; + } + + mf.curve.isCurveValid = false; + mf.ABLine.isABValid = false; + + mf.twoSecondCounter = 100; + + mf.FileSaveTracks(); + } + + private void btnExit_Click(object sender, EventArgs e) + { + isCancel = false; + Close(); + } + + private void btnCancel_Click(object sender, EventArgs e) + { + isCancel = true; + Close(); + } + + private void btnCancelTouch_Click(object sender, EventArgs e) + { + //update the arrays + btnMakeABLine.Enabled = false; + btnMakeCurve.Enabled = false; + start = 99999; end = 99999; + + FixLabelsCurve(); + + mf.curve.desList?.Clear(); + + btnExit.Focus(); + } + + private void FixLabelsCurve() + { + lblNumCu.Text = mf.trk.gArr.Count.ToString(); + + if (mf.trk.idx > -1 && mf.trk.gArr.Count > 0) + { + tboxNameCurve.Text = mf.trk.gArr[mf.trk.idx].name; + tboxNameCurve.Enabled = true; + lblCurveSelected.Text = (mf.trk.idx + 1).ToString(); + cboxIsVisible.Visible = true; + cboxIsVisible.Checked = mf.trk.gArr[mf.trk.idx].isVisible; + if (mf.trk.gArr[mf.trk.idx].isVisible) + cboxIsVisible.Image = Properties.Resources.TrackVisible; + else cboxIsVisible.Image = Properties.Resources.TracksInvisible; + + } + else + { + tboxNameCurve.Text = "***"; + tboxNameCurve.Enabled = false; + lblCurveSelected.Text = "*"; + cboxIsVisible.Visible = false; + } + } + + private void btnSelectCurve_Click(object sender, EventArgs e) + { + if (mf.trk.gArr.Count > 0) + { + mf.trk.idx++; + if (mf.trk.idx > (mf.trk.gArr.Count - 1)) mf.trk.idx = 0; + } + else + { + mf.trk.idx = -1; + } + + FixLabelsCurve(); + + //if (mf.curve.numCurveLines > 0) + //{ + // mf.curve.numCurveLineSelected++; + // if (mf.curve.numCurveLineSelected > mf.curve.numCurveLines) mf.curve.numCurveLineSelected = 1; + //} + //else + //{ + // mf.curve.numCurveLineSelected = 0; + //} + + //FixLabelsCurve(); + } + + private void btnSelectCurveBk_Click(object sender, EventArgs e) + { + if (mf.trk.gArr.Count > 0) + { + mf.trk.idx--; + if (mf.trk.idx < 0) mf.trk.idx = mf.trk.gArr.Count - 1; + } + else + { + mf.trk.idx = -1; + } + + FixLabelsCurve(); + } + + private void cboxIsVisible_Click(object sender, EventArgs e) + { + mf.trk.gArr[mf.trk.idx].isVisible = cboxIsVisible.Checked; + if (mf.trk.gArr[mf.trk.idx].isVisible) + cboxIsVisible.Image = Properties.Resources.TrackVisible; + else cboxIsVisible.Image = Properties.Resources.TracksInvisible; + } + + private void nudDistance_Click(object sender, EventArgs e) + { + mf.KeypadToNUD((NudlessNumericUpDown)sender, this); + btnSelectCurve.Focus(); + } + + private void btnDeleteCurve_Click(object sender, EventArgs e) + { + if (mf.trk.idx > -1) + { + mf.trk.gArr.RemoveAt(mf.trk.idx); + } + + if (mf.trk.gArr.Count > 0) + { + if (mf.trk.idx > mf.trk.gArr.Count - 1) + { + mf.trk.idx = mf.trk.gArr.Count - 1; + } + } + else + { + mf.trk.idx = -1; + } + + FixLabelsCurve(); + } + + private void btnDrawSections_Click(object sender, EventArgs e) + { + isDrawSections = !isDrawSections; + if (isDrawSections) btnDrawSections.Image = Properties.Resources.MappingOn; + else btnDrawSections.Image = Properties.Resources.MappingOff; + } + + private void tboxNameCurve_Leave(object sender, EventArgs e) + { + if (mf.trk.idx > -1) + mf.trk.gArr[mf.trk.idx].name = tboxNameCurve.Text.Trim(); + btnExit.Focus(); + } + + private void tboxNameCurve_Enter(object sender, EventArgs e) + { + + if (mf.isKeyboardOn) + { + mf.KeyboardToText((System.Windows.Forms.TextBox)sender, this); + + if (mf.trk.idx > -1) + mf.trk.gArr[mf.trk.idx].name = tboxNameCurve.Text.Trim(); + btnExit.Focus(); + } + } + + private void btnAddTime_Click(object sender, EventArgs e) + { + if (mf.trk.idx > -1) + { + mf.trk.gArr[mf.trk.idx].name += DateTime.Now.ToString(" hh:mm:ss", CultureInfo.InvariantCulture); + FixLabelsCurve(); + } + } + + private void btnMakeBoundaryCurve_Click(object sender, EventArgs e) + { //count the points from the boundary + for (int q = 0; q < mf.bnd.bndList.Count; q++) + { + int ptCount = mf.bnd.bndList[q].fenceLine.Count; + mf.curve.desList?.Clear(); + + //outside point + vec3 pt3 = new vec3(); + + + for (int i = 0; i < mf.bnd.bndList[bndSelect].fenceLine.Count; i++) + { + //calculate the point inside the boundary + pt3 = mf.bnd.bndList[bndSelect].fenceLine[i]; + + mf.curve.desList.Add(new vec3(pt3)); + } + + mf.trk.gArr.Add(new CTrk()); + //array number is 1 less since it starts at zero + mf.trk.idx = mf.trk.gArr.Count - 1; + + mf.trk.gArr[mf.trk.idx].ptA = new vec2(mf.curve.desList[0].easting, mf.curve.desList[0].northing); + mf.trk.gArr[mf.trk.idx].ptB = new vec2(mf.curve.desList[mf.curve.desList.Count - 1].easting, mf.curve.desList[mf.curve.desList.Count - 1].northing); + + pt3 = new vec3(mf.curve.desList[0]); + mf.curve.desList.Add(pt3); + + int cnt = mf.curve.desList.Count; + if (cnt > 3) + { + pt3 = new vec3(mf.curve.desList[0]); + mf.curve.desList.Add(pt3); + + //make sure point distance isn't too big + mf.curve.MakePointMinimumSpacing(ref mf.curve.desList, 1.6); + mf.curve.CalculateHeadings(ref mf.curve.desList); + + //create a name + mf.trk.gArr[mf.trk.idx].name = "Boundary Curve"; + + if (q > 0) mf.trk.gArr[mf.trk.idx].name = "Inner Boundary Curve " + q.ToString(); + + mf.trk.gArr[mf.trk.idx].heading = 0; + mf.trk.gArr[mf.trk.idx].mode = (int)TrackMode.bndCurve; + + //write out the Curve Points + foreach (vec3 item in mf.curve.desList) + { + mf.trk.gArr[mf.trk.idx].curvePts.Add(item); + } + } + } + + //update the arrays + btnMakeABLine.Enabled = false; + btnMakeCurve.Enabled = false; + start = 99999; end = 99999; + + FixLabelsCurve(); + + mf.curve.desList?.Clear(); + + btnExit.Focus(); + } + + private void BtnMakeCurve_Click(object sender, EventArgs e) + { + bool isLoop = false; + int limit = end; + + if ((Math.Abs(start - end)) > (mf.bnd.bndList[bndSelect].fenceLine.Count * 0.5)) + { + isLoop = true; + if (start < end) + { + (end, start) = (start, end); + } + + limit = end; + end = mf.bnd.bndList[bndSelect].fenceLine.Count; + } + else //normal + { + if (start > end) + { + (end, start) = (start, end); + } + } + + mf.curve.desList?.Clear(); + vec3 pt3 = new vec3(); + + for (int i = start; i < end; i++) + { + //calculate the point inside the boundary + pt3 = mf.bnd.bndList[bndSelect].fenceLine[i]; + + mf.curve.desList.Add(new vec3(pt3)); + + if (isLoop && i == mf.bnd.bndList[bndSelect].fenceLine.Count - 1) + { + i = -1; + isLoop = false; + end = limit; + } + } + + mf.trk.gArr.Add(new CTrk()); + //array number is 1 less since it starts at zero + mf.trk.idx = mf.trk.gArr.Count - 1; + + mf.trk.gArr[mf.trk.idx].ptA = + new vec2(mf.curve.desList[0].easting, mf.curve.desList[0].northing); + mf.trk.gArr[mf.trk.idx].ptB = + new vec2(mf.curve.desList[mf.curve.desList.Count - 1].easting, + mf.curve.desList[mf.curve.desList.Count - 1].northing); + + int cnt = mf.curve.desList.Count; + if (cnt > 3) + { + //make sure point distance isn't too big + mf.curve.MakePointMinimumSpacing(ref mf.curve.desList, 1.6); + mf.curve.CalculateHeadings(ref mf.curve.desList); + + //calculate average heading of line + double x = 0, y = 0; + + foreach (vec3 pt in mf.curve.desList) + { + x += Math.Cos(pt.heading); + y += Math.Sin(pt.heading); + } + x /= mf.curve.desList.Count; + y /= mf.curve.desList.Count; + mf.trk.gArr[mf.trk.idx].heading = Math.Atan2(y, x); + if (mf.trk.gArr[mf.trk.idx].heading < 0) mf.trk.gArr[mf.trk.idx].heading += glm.twoPI; + + //build the tail extensions + mf.curve.AddFirstLastPoints(ref mf.curve.desList); + mf.curve.SmoothAB(2); + mf.curve.CalculateHeadings(ref mf.curve.desList); + + //array number is 1 less since it starts at zero + mf.trk.idx = mf.trk.gArr.Count - 1; + + //create a name + mf.trk.gArr[mf.trk.idx].name = "Cu " + + (Math.Round(glm.toDegrees(mf.trk.gArr[mf.trk.idx].heading), 1)).ToString(CultureInfo.InvariantCulture) + + "\u00B0" ; + + mf.trk.gArr[mf.trk.idx].mode = (int)TrackMode.Curve; + + //write out the Curve Points + foreach (vec3 item in mf.curve.desList) + { + mf.trk.gArr[mf.trk.idx].curvePts.Add(item); + } + + //update the arrays + btnMakeABLine.Enabled = false; + btnMakeCurve.Enabled = false; + start = 99999; end = 99999; + + FixLabelsCurve(); + } + else + { + } + btnExit.Focus(); + mf.curve.desList?.Clear(); + } + + private void BtnMakeABLine_Click(object sender, EventArgs e) + { + //if more then half way around, it crosses start finish + if ((Math.Abs(start - end)) <= (mf.bnd.bndList[bndSelect].fenceLine.Count * 0.5)) + { + if (start < end) + { + (end, start) = (start, end); + } + } + else + { + if (start > end) + { + (end, start) = (start, end); + } + } + + //calculate the AB Heading + double abHead = Math.Atan2( + mf.bnd.bndList[bndSelect].fenceLine[end].easting - mf.bnd.bndList[bndSelect].fenceLine[start].easting, + mf.bnd.bndList[bndSelect].fenceLine[end].northing - mf.bnd.bndList[bndSelect].fenceLine[start].northing); + if (abHead < 0) abHead += glm.twoPI; + + double offset = 0; + + double headingCalc = abHead + glm.PIBy2; + + mf.trk.gArr.Add(new CTrk()); + + mf.trk.idx = mf.trk.gArr.Count - 1; + + mf.trk.gArr[mf.trk.idx].heading = abHead; + mf.trk.gArr[mf.trk.idx].mode = (int)TrackMode.AB; + + //calculate the new points for the reference line and points + mf.trk.gArr[mf.trk.idx].ptA.easting = (Math.Sin(headingCalc) * (offset)) + mf.bnd.bndList[bndSelect].fenceLine[start].easting; + mf.trk.gArr[mf.trk.idx].ptA.northing = (Math.Cos(headingCalc) * (offset)) + mf.bnd.bndList[bndSelect].fenceLine[start].northing; + + mf.trk.gArr[mf.trk.idx].ptB.easting = (Math.Sin(headingCalc) * (offset)) + mf.bnd.bndList[bndSelect].fenceLine[end].easting; + mf.trk.gArr[mf.trk.idx].ptB.northing = (Math.Cos(headingCalc) * (offset)) + mf.bnd.bndList[bndSelect].fenceLine[end].northing; + + //create a name + mf.trk.gArr[mf.trk.idx].name = "AB " + + (Math.Round(glm.toDegrees(mf.trk.gArr[mf.trk.idx].heading), 1)).ToString(CultureInfo.InvariantCulture) + "\u00B0" ; + + //clean up gui + btnMakeABLine.Enabled = false; + btnMakeCurve.Enabled = false; + + start = 99999; end = 99999; + + FixLabelsCurve(); + } + + private void oglSelf_MouseDown(object sender, MouseEventArgs e) + { + btnMakeABLine.Enabled = false; + btnMakeCurve.Enabled = false; + + Point pt = oglSelf.PointToClient(Cursor.Position); + + //Convert to Origin in the center of window, 800 pixels + fixPt.X = pt.X - 500; + fixPt.Y = (1000 - pt.Y - 500); + vec3 plotPt = new vec3 + { + //convert screen coordinates to field coordinates + easting = fixPt.X * mf.maxFieldDistance / 903, + northing = fixPt.Y * mf.maxFieldDistance / 903, + heading = 0 + }; + + plotPt.easting += mf.fieldCenterX; + plotPt.northing += mf.fieldCenterY; + + pint.easting = plotPt.easting; + pint.northing = plotPt.northing; + + if (isA) + { + double minDistA = double.MaxValue; + start = 99999; end = 99999; + + for (int j = 0; j < mf.bnd.bndList.Count; j++) + { + for (int i = 0; i < mf.bnd.bndList[j].fenceLine.Count; i++) + { + double dist = ((pint.easting - mf.bnd.bndList[j].fenceLine[i].easting) * (pint.easting - mf.bnd.bndList[j].fenceLine[i].easting)) + + ((pint.northing - mf.bnd.bndList[j].fenceLine[i].northing) * (pint.northing - mf.bnd.bndList[j].fenceLine[i].northing)); + if (dist < minDistA) + { + minDistA = dist; + bndSelect = j; + start = i; + } + } + } + + isA = false; + } + else + { + double minDistA = double.MaxValue; + int j = bndSelect; + + for (int i = 0; i < mf.bnd.bndList[j].fenceLine.Count; i++) + { + double dist = ((pint.easting - mf.bnd.bndList[j].fenceLine[i].easting) * (pint.easting - mf.bnd.bndList[j].fenceLine[i].easting)) + + ((pint.northing - mf.bnd.bndList[j].fenceLine[i].northing) * (pint.northing - mf.bnd.bndList[j].fenceLine[i].northing)); + if (dist < minDistA) + { + minDistA = dist; + end = i; + } + } + + isA = true; + + btnMakeABLine.Enabled = true; + btnMakeCurve.Enabled = true; + } + } + + private void oglSelf_Paint(object sender, PaintEventArgs e) + { + oglSelf.MakeCurrent(); + + GL.Clear(ClearBufferMask.DepthBufferBit | ClearBufferMask.ColorBufferBit); + GL.LoadIdentity(); // Reset The View + + //back the camera up + GL.Translate(0, 0, -mf.maxFieldDistance); + + //translate to that spot in the world + GL.Translate(-mf.fieldCenterX, -mf.fieldCenterY, 0); + + GL.Color3(1, 1, 1); + + //draw all the boundaries + + GL.LineWidth(1); + + for (int j = 0; j < mf.bnd.bndList.Count; j++) + { + if (j == bndSelect) + GL.Color3(0.25f, 0.5f, 0.50f); + else + GL.Color3(0.2f, 0.35f, 0.35f); + + GL.Begin(PrimitiveType.LineLoop); + for (int i = 0; i < mf.bnd.bndList[j].fenceLineEar.Count; i++) + { + GL.Vertex3(mf.bnd.bndList[j].fenceLineEar[i].easting, mf.bnd.bndList[j].fenceLineEar[i].northing, 0); + } + GL.End(); + } + + //the vehicle + GL.PointSize(16.0f); + GL.Begin(PrimitiveType.Points); + GL.Color3(0.0f, 0.00f, 0.0f); + GL.Vertex3(mf.pivotAxlePos.easting, mf.pivotAxlePos.northing, 0.0); + GL.End(); + + GL.PointSize(8.0f); + GL.Begin(PrimitiveType.Points); + GL.Color3(0.95f, 0.190f, 0.20f); + GL.Vertex3(mf.pivotAxlePos.easting, mf.pivotAxlePos.northing, 0.0); + GL.End(); + + if (isDrawSections) DrawSections(); + + //draw the line building graphics + if (start != 99999 || end != 99999) DrawABTouchPoints(); + + //draw the actual built lines + if (start == 99999 && end == 99999) + { + DrawBuiltLines(); + } + + GL.Flush(); + oglSelf.SwapBuffers(); + } + + private void DrawBuiltLines() + { + GL.LineStipple(1, 0x0707); + for (int i = 0; i < mf.trk.gArr.Count; i++) + { + //AB Lines + if (mf.trk.gArr[i].mode == (int)TrackMode.AB) + { + GL.Enable(EnableCap.LineStipple); + GL.LineWidth(4); + + if (i == mf.trk.idx) + { + GL.LineWidth(8); + GL.Disable(EnableCap.LineStipple); + } + GL.Color3(1.0f, 0.0f, 0.0f); + + GL.Begin(PrimitiveType.Lines); + + GL.Vertex3(mf.trk.gArr[i].ptA.easting - (Math.Sin(mf.trk.gArr[i].heading) * mf.ABLine.abLength), mf.trk.gArr[i].ptA.northing - (Math.Cos(mf.trk.gArr[i].heading) * mf.ABLine.abLength), 0); + GL.Vertex3(mf.trk.gArr[i].ptA.easting + (Math.Sin(mf.trk.gArr[i].heading) * mf.ABLine.abLength), mf.trk.gArr[i].ptA.northing + (Math.Cos(mf.trk.gArr[i].heading) * mf.ABLine.abLength), 0); + + GL.End(); + + GL.Disable(EnableCap.LineStipple); + + //if (mf.ABLine.numABLineSelected > 0) + //{ + // GL.Color3(1.0f, 0.0f, 0.0f); + + // GL.LineWidth(4); + // GL.Begin(PrimitiveType.Lines); + + // GL.Vertex3(mf.trk.gArr[mf.ABLine.numABLineSelected - 1].ptA.easting - (Math.Sin(mf.trk.gArr[mf.ABLine.numABLineSelected - 1].heading) * mf.ABLine.abLength), + // mf.trk.gArr[mf.ABLine.numABLineSelected - 1].ptA.northing - (Math.Cos(mf.trk.gArr[mf.ABLine.numABLineSelected - 1].heading) * mf.ABLine.abLength), 0); + // GL.Vertex3(mf.trk.gArr[mf.ABLine.numABLineSelected - 1].ptA.easting + (Math.Sin(mf.trk.gArr[mf.ABLine.numABLineSelected - 1].heading) * mf.ABLine.abLength), + // mf.trk.gArr[mf.ABLine.numABLineSelected - 1].ptA.northing + (Math.Cos(mf.trk.gArr[mf.ABLine.numABLineSelected - 1].heading) * mf.ABLine.abLength), 0); + + // GL.End(); + //} + + } + + else if (mf.trk.gArr[i].mode == (int)TrackMode.Curve || mf.trk.gArr[i].mode == (int)TrackMode.bndCurve) + { + GL.Enable(EnableCap.LineStipple); + GL.LineWidth(4); + + if (mf.trk.gArr[i].mode == (int)TrackMode.bndCurve) GL.LineStipple(1, 0x0007); + else GL.LineStipple(1, 0x0707); + + + if (i == mf.trk.idx) + { + GL.LineWidth(8); + GL.Disable(EnableCap.LineStipple); + } + + GL.Color3(0.0f, 0.7f, 0.0f); + if (mf.trk.gArr[i].mode == (int)TrackMode.bndCurve) GL.Color3(0.70f, 0.5f, 0.2f); + GL.Begin(PrimitiveType.LineStrip); + foreach (vec3 pts in mf.trk.gArr[i].curvePts) + { + GL.Vertex3(pts.easting, pts.northing, 0); + } + GL.End(); + + GL.Disable(EnableCap.LineStipple); + + if (i == mf.trk.idx) GL.PointSize(24); + else GL.PointSize(12); + + GL.Color3(0, 0, 0); + GL.Begin(PrimitiveType.Points); + + GL.Vertex3(mf.trk.gArr[i].curvePts[0].easting, + mf.trk.gArr[i].curvePts[0].northing, + 0); + + GL.Color3(0, 0, 0); + GL.Vertex3(mf.trk.gArr[i].curvePts[mf.trk.gArr[i].curvePts.Count - 1].easting, + mf.trk.gArr[i].curvePts[mf.trk.gArr[i].curvePts.Count - 1].northing, + 0); + + GL.End(); + + if (i == mf.trk.idx) GL.PointSize(16); + else GL.PointSize(8); + + GL.Color3(1.0f, 0.75f, 0.350f); + GL.Begin(PrimitiveType.Points); + + GL.Vertex3(mf.trk.gArr[i].curvePts[0].easting, + mf.trk.gArr[i].curvePts[0].northing, + 0); + + + GL.Color3(0.5f, 0.5f, 1.0f); + GL.Vertex3(mf.trk.gArr[i].curvePts[mf.trk.gArr[i].curvePts.Count - 1].easting, + mf.trk.gArr[i].curvePts[mf.trk.gArr[i].curvePts.Count - 1].northing, + 0); + GL.End(); + } + } + } + + private void DrawABTouchPoints() + { + GL.Color3(0.65, 0.650, 0.0); + GL.PointSize(24); + GL.Begin(PrimitiveType.Points); + + GL.Color3(0, 0, 0); + if (start != 99999) GL.Vertex3(mf.bnd.bndList[bndSelect].fenceLine[start].easting, mf.bnd.bndList[bndSelect].fenceLine[start].northing, 0); + if (end != 99999) GL.Vertex3(mf.bnd.bndList[bndSelect].fenceLine[end].easting, mf.bnd.bndList[bndSelect].fenceLine[end].northing, 0); + GL.End(); + + GL.PointSize(16); + GL.Begin(PrimitiveType.Points); + + GL.Color3(1.0f, 0.75f, 0.350f); + if (start != 99999) GL.Vertex3(mf.bnd.bndList[bndSelect].fenceLine[start].easting, mf.bnd.bndList[bndSelect].fenceLine[start].northing, 0); + + GL.Color3(0.5f, 0.5f, 1.0f); + if (end != 99999) GL.Vertex3(mf.bnd.bndList[bndSelect].fenceLine[end].easting, mf.bnd.bndList[bndSelect].fenceLine[end].northing, 0); + GL.End(); + } + + private void timer1_Tick(object sender, EventArgs e) + { + oglSelf.Refresh(); + + btnMakeBoundaryCurve.Enabled = true; + for (int i = 0; i < mf.trk.gArr.Count; i++) + { + if (mf.trk.gArr[i].mode == (int)TrackMode.bndCurve) + { + btnMakeBoundaryCurve.Enabled = false; + break; + } + } + + if (mf.trk.idx > -1 && mf.trk.gArr[mf.trk.idx].mode != (int)TrackMode.Curve) + { + btnALength.Enabled = false; + btnBLength.Enabled = false; + } + else + { + btnALength.Enabled = true; + btnBLength.Enabled = true; + } + } + + private void btnALength_Click(object sender, EventArgs e) + { + if (mf.trk.idx > -1 && mf.trk.gArr[mf.trk.idx].mode == (int)TrackMode.Curve) + { + //and the beginning + vec3 start = new vec3(mf.trk.gArr[mf.trk.idx].curvePts[0]); + + for (int i = 1; i < 50; i++) + { + vec3 pt = new vec3(start); + pt.easting -= (Math.Sin(pt.heading) * i); + pt.northing -= (Math.Cos(pt.heading) * i); + mf.trk.gArr[mf.trk.idx].curvePts.Insert(0, pt); + } + } + } + + private void btnBLength_Click(object sender, EventArgs e) + { + if (mf.trk.idx > -1 && mf.trk.gArr[mf.trk.idx].mode == (int)TrackMode.Curve) + { + int ptCnt = mf.trk.gArr[mf.trk.idx].curvePts.Count - 1; + + for (int i = 1; i < 50; i++) + { + vec3 pt = new vec3(mf.trk.gArr[mf.trk.idx].curvePts[ptCnt]); + pt.easting += (Math.Sin(pt.heading) * i); + pt.northing += (Math.Cos(pt.heading) * i); + mf.trk.gArr[mf.trk.idx].curvePts.Add(pt); + } + } + } + + private void oglSelf_Resize(object sender, EventArgs e) + { + oglSelf.MakeCurrent(); + GL.MatrixMode(MatrixMode.Projection); + GL.LoadIdentity(); + + //58 degrees view + Matrix4 mat = Matrix4.CreatePerspectiveFieldOfView(1.01f, 1.0f, 1.0f, 20000); + GL.LoadMatrix(ref mat); + + GL.MatrixMode(MatrixMode.Modelview); + } + + private void oglSelf_Load(object sender, EventArgs e) + { + oglSelf.MakeCurrent(); + GL.Enable(EnableCap.CullFace); + GL.CullFace(CullFaceMode.Back); + GL.ClearColor(1,1,1,1); + } + + private void DrawSections() + { + int cnt, step, patchCount; + int mipmap = 8; + + GL.Color3(0.0, 0.0, 0.352); + + //draw patches j= # of sections + for (int j = 0; j < mf.triStrip.Count; j++) + { + //every time the section turns off and on is a new patch + patchCount = mf.triStrip[j].patchList.Count; + + if (patchCount > 0) + { + //for every new chunk of patch + foreach (System.Collections.Generic.List triList in mf.triStrip[j].patchList) + { + //draw the triangle in each triangle strip + GL.Begin(PrimitiveType.TriangleStrip); + cnt = triList.Count; + + //if large enough patch and camera zoomed out, fake mipmap the patches, skip triangles + if (cnt >= (mipmap)) + { + step = mipmap; + for (int i = 1; i < cnt; i += step) + { + GL.Vertex3(triList[i].easting, triList[i].northing, 0); i++; + GL.Vertex3(triList[i].easting, triList[i].northing, 0); i++; + + //too small to mipmap it + if (cnt - i <= (mipmap + 2)) + step = 0; + } + } + else { for (int i = 1; i < cnt; i++) GL.Vertex3(triList[i].easting, triList[i].northing, 0); } + GL.End(); + } + } + } //end of section patches + } + + #region Help + + private void btnCancelTouch_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_btnCancelTouch, gStr.gsHelp); + } + + private void nudDistance_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_nudDistance, gStr.gsHelp); + } + + private void btnFlipOffset_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_btnFlipOffset, gStr.gsHelp); + } + + private void btnMakeBoundaryCurve_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_btnMakeBoundaryCurve, gStr.gsHelp); + } + + private void btnMakeCurve_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_btnMakeCurve, gStr.gsHelp); + } + + private void btnSelectCurve_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_btnSelectCurve, gStr.gsHelp); + } + + private void btnDeleteCurve_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_btnDeleteCurve, gStr.gsHelp); + } + + private void btnMakeABLine_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_btnMakeABLine, gStr.gsHelp); + } + + private void btnSelectABLine_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_btnSelectABLine, gStr.gsHelp); + } + + private void btnDeleteABLine_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_btnDeleteABLine, gStr.gsHelp); + } + + private void btnDrawSections_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_btnDrawSections, gStr.gsHelp); + } + + private void btnExit_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hh_btnExit, gStr.gsHelp); + } + + private void oglSelf_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_oglSelf, gStr.gsHelp); + } + + private void tboxNameCurve_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_tboxNameLine, gStr.gsHelp); + } + + private void tboxNameLine_HelpRequested(object sender, HelpEventArgs hlpevent) + { + MessageBox.Show(gStr.hd_tboxNameLine, gStr.gsHelp); + } + + #endregion Help + } +} \ No newline at end of file diff --git a/SourceCode/GPS/Forms/Guidance/FormABDraw2.resx b/SourceCode/GPS/Forms/Guidance/FormABDraw2.resx new file mode 100644 index 000000000..9d24b35ed --- /dev/null +++ b/SourceCode/GPS/Forms/Guidance/FormABDraw2.resx @@ -0,0 +1,126 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 17, 17 + + + 56 + + \ No newline at end of file diff --git a/SourceCode/GPS/Forms/Guidance/FormHeadAche.Designer.cs b/SourceCode/GPS/Forms/Guidance/FormHeadAche.Designer.cs index 06e8ade89..c24790fed 100644 --- a/SourceCode/GPS/Forms/Guidance/FormHeadAche.Designer.cs +++ b/SourceCode/GPS/Forms/Guidance/FormHeadAche.Designer.cs @@ -37,7 +37,7 @@ private void InitializeComponent() this.headingGroupBox = new System.Windows.Forms.GroupBox(); this.rbtnLine = new System.Windows.Forms.RadioButton(); this.rbtnCurve = new System.Windows.Forms.RadioButton(); - this.nudSetDistance = new NudlessNumericUpDown(); + this.nudSetDistance = new AgOpenGPS.NudlessNumericUpDown(); this.label11 = new System.Windows.Forms.Label(); this.lblMovedDistance = new System.Windows.Forms.Label(); this.label3 = new System.Windows.Forms.Label(); @@ -62,6 +62,7 @@ private void InitializeComponent() this.btnDeleteCurve = new System.Windows.Forms.Button(); this.btnExit = new System.Windows.Forms.Button(); this.panel1 = new System.Windows.Forms.Panel(); + this.cboxIsZoom = new System.Windows.Forms.CheckBox(); this.headingGroupBox.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.nudSetDistance)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.pboxHelp)).BeginInit(); @@ -245,7 +246,7 @@ private void InitializeComponent() this.label4.AutoSize = true; this.label4.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label4.ForeColor = System.Drawing.Color.Black; - this.label4.Location = new System.Drawing.Point(740, 340); + this.label4.Location = new System.Drawing.Point(842, 340); this.label4.Name = "label4"; this.label4.Size = new System.Drawing.Size(34, 16); this.label4.TabIndex = 508; @@ -297,7 +298,7 @@ private void InitializeComponent() this.label5.AutoSize = true; this.label5.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label5.ForeColor = System.Drawing.Color.Black; - this.label5.Location = new System.Drawing.Point(861, 337); + this.label5.Location = new System.Drawing.Point(945, 337); this.label5.Name = "label5"; this.label5.Size = new System.Drawing.Size(39, 16); this.label5.TabIndex = 523; @@ -353,7 +354,7 @@ private void InitializeComponent() this.button1.Font = new System.Drawing.Font("Tahoma", 14.25F); this.button1.Image = global::AgOpenGPS.Properties.Resources.Help; this.button1.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.button1.Location = new System.Drawing.Point(953, 281); + this.button1.Location = new System.Drawing.Point(721, 586); this.button1.Name = "button1"; this.button1.Size = new System.Drawing.Size(53, 46); this.button1.TabIndex = 528; @@ -445,7 +446,7 @@ private void InitializeComponent() this.btnBndLoop.Font = new System.Drawing.Font("Tahoma", 14.25F); this.btnBndLoop.Image = global::AgOpenGPS.Properties.Resources.HeadlandBuild; this.btnBndLoop.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnBndLoop.Location = new System.Drawing.Point(716, 269); + this.btnBndLoop.Location = new System.Drawing.Point(818, 269); this.btnBndLoop.Name = "btnBndLoop"; this.btnBndLoop.Size = new System.Drawing.Size(76, 70); this.btnBndLoop.TabIndex = 504; @@ -463,7 +464,7 @@ private void InitializeComponent() this.btnDeleteHeadland.Font = new System.Drawing.Font("Tahoma", 14.25F); this.btnDeleteHeadland.Image = global::AgOpenGPS.Properties.Resources.HeadlandReset; this.btnDeleteHeadland.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnDeleteHeadland.Location = new System.Drawing.Point(840, 269); + this.btnDeleteHeadland.Location = new System.Drawing.Point(923, 269); this.btnDeleteHeadland.Name = "btnDeleteHeadland"; this.btnDeleteHeadland.Size = new System.Drawing.Size(76, 70); this.btnDeleteHeadland.TabIndex = 465; @@ -598,12 +599,33 @@ private void InitializeComponent() this.panel1.Size = new System.Drawing.Size(180, 180); this.panel1.TabIndex = 533; // + // cboxIsZoom + // + this.cboxIsZoom.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.cboxIsZoom.Appearance = System.Windows.Forms.Appearance.Button; + this.cboxIsZoom.BackColor = System.Drawing.Color.WhiteSmoke; + this.cboxIsZoom.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.cboxIsZoom.FlatAppearance.CheckedBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(255)))), ((int)(((byte)(160))))); + this.cboxIsZoom.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.cboxIsZoom.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.cboxIsZoom.ForeColor = System.Drawing.SystemColors.ButtonFace; + this.cboxIsZoom.Image = global::AgOpenGPS.Properties.Resources.ZoomOGL; + this.cboxIsZoom.Location = new System.Drawing.Point(717, 269); + this.cboxIsZoom.Name = "cboxIsZoom"; + this.cboxIsZoom.RightToLeft = System.Windows.Forms.RightToLeft.Yes; + this.cboxIsZoom.Size = new System.Drawing.Size(72, 72); + this.cboxIsZoom.TabIndex = 564; + this.cboxIsZoom.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.cboxIsZoom.UseVisualStyleBackColor = false; + this.cboxIsZoom.CheckedChanged += new System.EventHandler(this.cboxIsZoom_CheckedChanged); + // // FormHeadAche // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.BackColor = System.Drawing.Color.WhiteSmoke; this.ClientSize = new System.Drawing.Size(1010, 720); + this.Controls.Add(this.cboxIsZoom); this.Controls.Add(this.panel1); this.Controls.Add(this.pboxHelp); this.Controls.Add(this.oglSelf); @@ -684,5 +706,6 @@ private void InitializeComponent() private System.Windows.Forms.PictureBox pboxHelp; private System.Windows.Forms.Button button1; private System.Windows.Forms.Panel panel1; + private System.Windows.Forms.CheckBox cboxIsZoom; } } \ No newline at end of file diff --git a/SourceCode/GPS/Forms/Guidance/FormHeadAche.cs b/SourceCode/GPS/Forms/Guidance/FormHeadAche.cs index b5045d9e6..d99d7f285 100644 --- a/SourceCode/GPS/Forms/Guidance/FormHeadAche.cs +++ b/SourceCode/GPS/Forms/Guidance/FormHeadAche.cs @@ -19,6 +19,9 @@ public partial class FormHeadAche : Form private int start = 99999, end = 99999; private int bndSelect = 0; + private bool zoomToggle; + private double zoom = 1, sX = 0, sY = 0; + public vec3 pint = new vec3(0.0, 1.0, 0.0); private bool isLinesVisible = true; @@ -131,28 +134,43 @@ private void btnDeleteCurve_Click(object sender, EventArgs e) private void oglSelf_MouseDown(object sender, MouseEventArgs e) { + Point pt = oglSelf.PointToClient(Cursor.Position); + + if (cboxIsZoom.Checked && !zoomToggle) + { + sX = ((350 - (double)pt.X) / 700) * 1.1; + sY = ((350 - (double)pt.Y) / -700) * 1.1; + zoom = 0.1; + zoomToggle = true; + return; + } + + zoomToggle = false; + mf.bnd.bndList[0].hdLine?.Clear(); mf.hdl.idx = -1; - Point ptt = oglSelf.PointToClient(Cursor.Position); - //Convert to Origin in the center of window, 800 pixels - fixPt.X = ptt.X - 350; - fixPt.Y = (700 - ptt.Y - 350); + fixPt.X = pt.X - 350; + fixPt.Y = (700 - pt.Y - 350); vec3 plotPt = new vec3 { //convert screen coordinates to field coordinates - easting = fixPt.X * mf.maxFieldDistance / 632.0, - northing = fixPt.Y * mf.maxFieldDistance / 632.0, + easting = fixPt.X * mf.maxFieldDistance / 632 * zoom, + northing = fixPt.Y * mf.maxFieldDistance / 632 * zoom, heading = 0 }; - plotPt.easting += mf.fieldCenterX; - plotPt.northing += mf.fieldCenterY; + plotPt.easting += mf.fieldCenterX + mf.maxFieldDistance * -sX; + plotPt.northing += mf.fieldCenterY + mf.maxFieldDistance * -sY; pint.easting = plotPt.easting; pint.northing = plotPt.northing; + zoom = 1; + sX = 0; + sY = 0; + if (isA) { double minDistA = double.MaxValue; @@ -280,20 +298,20 @@ private void oglSelf_MouseDown(object sender, MouseEventArgs e) for (int i = 1; i < 30; i++) { - vec3 pt = new vec3(mf.hdl.tracksArr[mf.hdl.idx].trackPts[ptCnt]); - pt.easting += (Math.Sin(pt.heading) * i); - pt.northing += (Math.Cos(pt.heading) * i); - mf.hdl.tracksArr[mf.hdl.idx].trackPts.Add(pt); + vec3 pnt = new vec3(mf.hdl.tracksArr[mf.hdl.idx].trackPts[ptCnt]); + pnt.easting += (Math.Sin(pnt.heading) * i); + pnt.northing += (Math.Cos(pnt.heading) * i); + mf.hdl.tracksArr[mf.hdl.idx].trackPts.Add(pnt); } vec3 stat = new vec3(mf.hdl.tracksArr[mf.hdl.idx].trackPts[0]); for (int i = 1; i < 30; i++) { - vec3 pt = new vec3(stat); - pt.easting -= (Math.Sin(pt.heading) * i); - pt.northing -= (Math.Cos(pt.heading) * i); - mf.hdl.tracksArr[mf.hdl.idx].trackPts.Insert(0, pt); + vec3 pnt = new vec3(stat); + pnt.easting -= (Math.Sin(pnt.heading) * i); + pnt.northing -= (Math.Cos(pnt.heading) * i); + mf.hdl.tracksArr[mf.hdl.idx].trackPts.Insert(0, pnt); } //create a name @@ -367,20 +385,20 @@ private void oglSelf_MouseDown(object sender, MouseEventArgs e) for (int i = 1; i < 30; i++) { - vec3 pt = new vec3(mf.hdl.tracksArr[mf.hdl.idx].trackPts[ptCnt]); - pt.easting += (Math.Sin(pt.heading) * i); - pt.northing += (Math.Cos(pt.heading) * i); - mf.hdl.tracksArr[mf.hdl.idx].trackPts.Add(pt); + vec3 pnt = new vec3(mf.hdl.tracksArr[mf.hdl.idx].trackPts[ptCnt]); + pnt.easting += (Math.Sin(pnt.heading) * i); + pnt.northing += (Math.Cos(pnt.heading) * i); + mf.hdl.tracksArr[mf.hdl.idx].trackPts.Add(pnt); } vec3 stat = new vec3(mf.hdl.tracksArr[mf.hdl.idx].trackPts[0]); for (int i = 1; i < 30; i++) { - vec3 pt = new vec3(stat); - pt.easting -= (Math.Sin(pt.heading) * i); - pt.northing -= (Math.Cos(pt.heading) * i); - mf.hdl.tracksArr[mf.hdl.idx].trackPts.Insert(0, pt); + vec3 pnt = new vec3(stat); + pnt.easting -= (Math.Sin(pnt.heading) * i); + pnt.northing -= (Math.Cos(pnt.heading) * i); + mf.hdl.tracksArr[mf.hdl.idx].trackPts.Insert(0, pnt); } //create a name @@ -459,16 +477,10 @@ private void oglSelf_Paint(object sender, PaintEventArgs e) GL.LoadIdentity(); // Reset The View //back the camera up - GL.Translate(0, 0, -mf.maxFieldDistance); + GL.Translate(0, 0, -mf.maxFieldDistance * zoom); //translate to that spot in the world - GL.Translate(-mf.fieldCenterX, -mf.fieldCenterY, 0); - - GL.Color3(1, 1, 1); - - //GL.Enable(EnableCap.Blend); - - //draw all the boundaries + GL.Translate(-mf.fieldCenterX + sX * mf.maxFieldDistance, -mf.fieldCenterY + sY * mf.maxFieldDistance, 0); GL.LineWidth(2); @@ -887,6 +899,11 @@ private void cboxIsSectionControlled_Click(object sender, EventArgs e) else cboxIsSectionControlled.Image = Properties.Resources.HeadlandSectionOff; } + private void cboxIsZoom_CheckedChanged(object sender, EventArgs e) + { + zoomToggle = false; + } + public int GetLineIntersection(double p0x, double p0y, double p1x, double p1y, double p2x, double p2y, double p3x, double p3y, ref double iEast, ref double iNorth) { diff --git a/SourceCode/GPS/Forms/Guidance/FormHeadLine.Designer.cs b/SourceCode/GPS/Forms/Guidance/FormHeadLine.Designer.cs index 85905968b..4d2a9c3bd 100644 --- a/SourceCode/GPS/Forms/Guidance/FormHeadLine.Designer.cs +++ b/SourceCode/GPS/Forms/Guidance/FormHeadLine.Designer.cs @@ -34,7 +34,7 @@ private void InitializeComponent() this.headingGroupBox = new System.Windows.Forms.GroupBox(); this.rbtnLine = new System.Windows.Forms.RadioButton(); this.rbtnCurve = new System.Windows.Forms.RadioButton(); - this.nudSetDistance = new NudlessNumericUpDown(); + this.nudSetDistance = new AgOpenGPS.NudlessNumericUpDown(); this.label3 = new System.Windows.Forms.Label(); this.label4 = new System.Windows.Forms.Label(); this.label2 = new System.Windows.Forms.Label(); @@ -56,6 +56,7 @@ private void InitializeComponent() this.btnBLength = new System.Windows.Forms.Button(); this.btnExit = new System.Windows.Forms.Button(); this.panel1 = new System.Windows.Forms.Panel(); + this.cboxIsZoom = new System.Windows.Forms.CheckBox(); this.headingGroupBox.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.nudSetDistance)).BeginInit(); this.panel1.SuspendLayout(); @@ -135,7 +136,7 @@ private void InitializeComponent() this.nudSetDistance.BackColor = System.Drawing.Color.AliceBlue; this.nudSetDistance.DecimalPlaces = 1; this.nudSetDistance.Font = new System.Drawing.Font("Tahoma", 24F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.nudSetDistance.Location = new System.Drawing.Point(823, 303); + this.nudSetDistance.Location = new System.Drawing.Point(819, 329); this.nudSetDistance.Maximum = new decimal(new int[] { 200, 0, @@ -159,7 +160,7 @@ private void InitializeComponent() this.label3.AutoSize = true; this.label3.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label3.ForeColor = System.Drawing.Color.Black; - this.label3.Location = new System.Drawing.Point(981, 316); + this.label3.Location = new System.Drawing.Point(977, 342); this.label3.Name = "label3"; this.label3.Size = new System.Drawing.Size(19, 19); this.label3.TabIndex = 505; @@ -172,7 +173,7 @@ private void InitializeComponent() this.label4.AutoSize = true; this.label4.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label4.ForeColor = System.Drawing.Color.Black; - this.label4.Location = new System.Drawing.Point(762, 466); + this.label4.Location = new System.Drawing.Point(762, 480); this.label4.Name = "label4"; this.label4.Size = new System.Drawing.Size(21, 16); this.label4.TabIndex = 508; @@ -185,7 +186,7 @@ private void InitializeComponent() this.label2.AutoSize = true; this.label2.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label2.ForeColor = System.Drawing.Color.Black; - this.label2.Location = new System.Drawing.Point(753, 578); + this.label2.Location = new System.Drawing.Point(753, 590); this.label2.Name = "label2"; this.label2.Size = new System.Drawing.Size(36, 16); this.label2.TabIndex = 515; @@ -197,12 +198,12 @@ private void InitializeComponent() this.lblToolWidth.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.lblToolWidth.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.lblToolWidth.ForeColor = System.Drawing.Color.Black; - this.lblToolWidth.Location = new System.Drawing.Point(723, 270); + this.lblToolWidth.Location = new System.Drawing.Point(729, 339); this.lblToolWidth.Name = "lblToolWidth"; this.lblToolWidth.Size = new System.Drawing.Size(81, 26); this.lblToolWidth.TabIndex = 517; this.lblToolWidth.Text = "3.86"; - this.lblToolWidth.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.lblToolWidth.TextAlign = System.Drawing.ContentAlignment.MiddleRight; // // cboxToolWidths // @@ -224,7 +225,7 @@ private void InitializeComponent() "8", "9", "10"}); - this.cboxToolWidths.Location = new System.Drawing.Point(723, 299); + this.cboxToolWidths.Location = new System.Drawing.Point(851, 270); this.cboxToolWidths.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3); this.cboxToolWidths.Name = "cboxToolWidths"; this.cboxToolWidths.Size = new System.Drawing.Size(88, 53); @@ -237,7 +238,7 @@ private void InitializeComponent() this.label1.AutoSize = true; this.label1.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label1.ForeColor = System.Drawing.Color.Black; - this.label1.Location = new System.Drawing.Point(894, 585); + this.label1.Location = new System.Drawing.Point(894, 597); this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(39, 16); this.label1.TabIndex = 520; @@ -250,7 +251,7 @@ private void InitializeComponent() this.label5.AutoSize = true; this.label5.Font = new System.Drawing.Font("Tahoma", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.label5.ForeColor = System.Drawing.Color.Black; - this.label5.Location = new System.Drawing.Point(896, 469); + this.label5.Location = new System.Drawing.Point(896, 483); this.label5.Name = "label5"; this.label5.Size = new System.Drawing.Size(32, 16); this.label5.TabIndex = 521; @@ -332,7 +333,7 @@ private void InitializeComponent() this.btnSlice.Font = new System.Drawing.Font("Tahoma", 14.25F); this.btnSlice.Image = global::AgOpenGPS.Properties.Resources.HeadlandSlice; this.btnSlice.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnSlice.Location = new System.Drawing.Point(869, 395); + this.btnSlice.Location = new System.Drawing.Point(869, 409); this.btnSlice.Name = "btnSlice"; this.btnSlice.Size = new System.Drawing.Size(81, 71); this.btnSlice.TabIndex = 519; @@ -368,7 +369,7 @@ private void InitializeComponent() this.btnUndo.Font = new System.Drawing.Font("Tahoma", 14.25F); this.btnUndo.Image = global::AgOpenGPS.Properties.Resources.back_button; this.btnUndo.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnUndo.Location = new System.Drawing.Point(727, 515); + this.btnUndo.Location = new System.Drawing.Point(727, 527); this.btnUndo.Name = "btnUndo"; this.btnUndo.Size = new System.Drawing.Size(81, 71); this.btnUndo.TabIndex = 514; @@ -386,7 +387,7 @@ private void InitializeComponent() this.btnDeletePoints.Font = new System.Drawing.Font("Tahoma", 14.25F); this.btnDeletePoints.Image = global::AgOpenGPS.Properties.Resources.HeadlandReset; this.btnDeletePoints.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnDeletePoints.Location = new System.Drawing.Point(869, 515); + this.btnDeletePoints.Location = new System.Drawing.Point(869, 527); this.btnDeletePoints.Name = "btnDeletePoints"; this.btnDeletePoints.Size = new System.Drawing.Size(81, 71); this.btnDeletePoints.TabIndex = 506; @@ -404,7 +405,7 @@ private void InitializeComponent() this.btnBndLoop.Font = new System.Drawing.Font("Tahoma", 14.25F); this.btnBndLoop.Image = global::AgOpenGPS.Properties.Resources.HeadlandBuild; this.btnBndLoop.ImeMode = System.Windows.Forms.ImeMode.NoControl; - this.btnBndLoop.Location = new System.Drawing.Point(730, 395); + this.btnBndLoop.Location = new System.Drawing.Point(730, 409); this.btnBndLoop.Name = "btnBndLoop"; this.btnBndLoop.Size = new System.Drawing.Size(81, 71); this.btnBndLoop.TabIndex = 504; @@ -503,12 +504,33 @@ private void InitializeComponent() this.panel1.Size = new System.Drawing.Size(180, 180); this.panel1.TabIndex = 532; // + // cboxIsZoom + // + this.cboxIsZoom.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); + this.cboxIsZoom.Appearance = System.Windows.Forms.Appearance.Button; + this.cboxIsZoom.BackColor = System.Drawing.Color.WhiteSmoke; + this.cboxIsZoom.FlatAppearance.BorderColor = System.Drawing.Color.Black; + this.cboxIsZoom.FlatAppearance.CheckedBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(180)))), ((int)(((byte)(255)))), ((int)(((byte)(160))))); + this.cboxIsZoom.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.cboxIsZoom.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + this.cboxIsZoom.ForeColor = System.Drawing.SystemColors.ButtonFace; + this.cboxIsZoom.Image = global::AgOpenGPS.Properties.Resources.ZoomOGL; + this.cboxIsZoom.Location = new System.Drawing.Point(727, 232); + this.cboxIsZoom.Name = "cboxIsZoom"; + this.cboxIsZoom.RightToLeft = System.Windows.Forms.RightToLeft.Yes; + this.cboxIsZoom.Size = new System.Drawing.Size(72, 72); + this.cboxIsZoom.TabIndex = 564; + this.cboxIsZoom.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.cboxIsZoom.UseVisualStyleBackColor = false; + this.cboxIsZoom.CheckedChanged += new System.EventHandler(this.cboxIsZoom_CheckedChanged); + // // FormHeadLine // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.BackColor = System.Drawing.Color.WhiteSmoke; this.ClientSize = new System.Drawing.Size(1009, 712); + this.Controls.Add(this.cboxIsZoom); this.Controls.Add(this.panel1); this.Controls.Add(this.label7); this.Controls.Add(this.label6); @@ -576,5 +598,6 @@ private void InitializeComponent() private System.Windows.Forms.Button btnBShrink; private System.Windows.Forms.Label label7; private System.Windows.Forms.Panel panel1; + private System.Windows.Forms.CheckBox cboxIsZoom; } } \ No newline at end of file diff --git a/SourceCode/GPS/Forms/Guidance/FormHeadLine.cs b/SourceCode/GPS/Forms/Guidance/FormHeadLine.cs index 3bcac3b2f..7ab9fe2b0 100644 --- a/SourceCode/GPS/Forms/Guidance/FormHeadLine.cs +++ b/SourceCode/GPS/Forms/Guidance/FormHeadLine.cs @@ -20,6 +20,10 @@ public partial class FormHeadLine : Form public List sliceArr = new List(); public List backupList = new List(); + private bool zoomToggle; + + private double zoom = 1, sX = 0, sY = 0; + public vec3 pint = new vec3(0.0, 1.0, 0.0); public FormHeadLine(Form callingForm) @@ -69,6 +73,8 @@ private void FormHeadLine_Load(object sender, EventArgs e) cboxIsSectionControlled.Checked = Properties.Settings.Default.setHeadland_isSectionControlled; if (cboxIsSectionControlled.Checked) cboxIsSectionControlled.Image = Properties.Resources.HeadlandSectionOn; else cboxIsSectionControlled.Image = Properties.Resources.HeadlandSectionOff; + + cboxIsZoom.Checked = false; } private void FormHeadLine_FormClosing(object sender, FormClosingEventArgs e) @@ -89,6 +95,7 @@ private void FormHeadLine_FormClosing(object sender, FormClosingEventArgs e) private void oglSelf_MouseDown(object sender, MouseEventArgs e) { + if (nudSetDistance.Value == 0 && rbtnCurve.Checked) { mf.TimedMessageBox(3000, "Distance Error", "Distance Set to 0, Nothing to Move"); @@ -97,6 +104,14 @@ private void oglSelf_MouseDown(object sender, MouseEventArgs e) sliceArr?.Clear(); Point ptt = oglSelf.PointToClient(Cursor.Position); + if (cboxIsZoom.Checked && !zoomToggle) + { + sX = ((350 - (double)ptt.X) / 700) * 1.1; + sY = ((350 - (double)ptt.Y) / -700) * 1.1; + zoom = 0.1; + zoomToggle = true; + return; + } //Convert to Origin in the center of window, 800 pixels fixPt.X = ptt.X - 350; @@ -104,17 +119,22 @@ private void oglSelf_MouseDown(object sender, MouseEventArgs e) vec3 plotPt = new vec3 { //convert screen coordinates to field coordinates - easting = fixPt.X * mf.maxFieldDistance / 632.0, - northing = fixPt.Y * mf.maxFieldDistance / 632.0, + easting = fixPt.X * mf.maxFieldDistance / 632 * zoom, + northing = fixPt.Y * mf.maxFieldDistance / 632 * zoom, heading = 0 }; - plotPt.easting += mf.fieldCenterX; - plotPt.northing += mf.fieldCenterY; + plotPt.easting += mf.fieldCenterX + mf.maxFieldDistance * -sX; + plotPt.northing += mf.fieldCenterY + mf.maxFieldDistance * -sY; pint.easting = plotPt.easting; pint.northing = plotPt.northing; + zoomToggle = false; + zoom = 1; + sX = 0; + sY = 0; + if (isA) { double minDistA = double.MaxValue; @@ -295,10 +315,12 @@ private void oglSelf_MouseDown(object sender, MouseEventArgs e) for (int i = 0; i <= (int)(glm.Distance(ptA, ptB)); i++) { - vec3 ptC = new vec3(ptA); - ptC.easting = (Math.Sin(abHead) * i) + ptA.easting; - ptC.northing = (Math.Cos(abHead) * i) + ptA.northing; - ptC.heading = abHead; + vec3 ptC = new vec3(ptA) + { + easting = (Math.Sin(abHead) * i) + ptA.easting, + northing = (Math.Cos(abHead) * i) + ptA.northing, + heading = abHead + }; sliceArr.Add(ptC); } @@ -343,12 +365,10 @@ private void oglSelf_Paint(object sender, PaintEventArgs e) GL.LoadIdentity(); // Reset The View //back the camera up - GL.Translate(0, 0, -mf.maxFieldDistance); + GL.Translate(0, 0, -mf.maxFieldDistance * zoom); //translate to that spot in the world - GL.Translate(-mf.fieldCenterX, -mf.fieldCenterY, 0); - - GL.Color3(1, 1, 1); + GL.Translate(-mf.fieldCenterX + sX * mf.maxFieldDistance, -mf.fieldCenterY + sY * mf.maxFieldDistance, 0); //draw all the boundaries GL.LineWidth(4); @@ -356,11 +376,11 @@ private void oglSelf_Paint(object sender, PaintEventArgs e) for (int j = 0; j < mf.bnd.bndList.Count; j++) { if (j == bndSelect) - GL.Color3(0.25f, 0.5f, 0.20f); + GL.Color3(0.025f, 0.05f, 0.020f); else GL.Color3(0.70f, 0.25f, 0.10f); - GL.Begin(PrimitiveType.Lines); + GL.Begin(PrimitiveType.LineStrip); for (int i = 0; i < mf.bnd.bndList[j].fenceLine.Count; i++) { GL.Vertex3(mf.bnd.bndList[j].fenceLine[i].easting, mf.bnd.bndList[j].fenceLine[i].northing, 0); @@ -368,12 +388,18 @@ private void oglSelf_Paint(object sender, PaintEventArgs e) GL.End(); } - ////the vehicle - //GL.PointSize(8.0f); - //GL.Begin(PrimitiveType.Points); - //GL.Color3(0.95f, 0.90f, 0.0f); - //GL.Vertex3(mf.pivotAxlePos.easting, mf.pivotAxlePos.northing, 0.0); - //GL.End(); + //the vehicle + GL.PointSize(16.0f); + GL.Begin(PrimitiveType.Points); + GL.Color3(0.0f, 0.00f, 0.0f); + GL.Vertex3(mf.pivotAxlePos.easting, mf.pivotAxlePos.northing, 0.0); + GL.End(); + + GL.PointSize(8.0f); + GL.Begin(PrimitiveType.Points); + GL.Color3(0.95f, 0.190f, 0.20f); + GL.Vertex3(mf.pivotAxlePos.easting, mf.pivotAxlePos.northing, 0.0); + GL.End(); //draw the line building graphics if (start != 99999 || end != 99999) DrawABTouchLine(); @@ -402,8 +428,8 @@ private void DrawBuiltLines() } GL.End(); - GL.LineWidth(4); - GL.Color3(0.843f, 0.83f, 0.150f); + GL.LineWidth(2); + GL.Color3(0.943f, 0.083f, 0.9150f); GL.Begin(PrimitiveType.LineLoop); for (int i = 0; i < mf.bnd.bndList[0].hdLine.Count; i++) @@ -533,7 +559,6 @@ private void btnExit_Click(object sender, EventArgs e) vec3 ptEnd = new vec3(hdArr[hdArr.Length - 1].easting, hdArr[hdArr.Length - 1].northing, hdArr[hdArr.Length - 1].heading); mf.bnd.bndList[0].hdLine.Add(ptEnd); - delta = 0; } mf.FileSaveHeadland(); @@ -917,6 +942,11 @@ private void cboxIsSectionControlled_Click(object sender, EventArgs e) else cboxIsSectionControlled.Image = Properties.Resources.HeadlandSectionOff; } + private void cboxIsZoom_CheckedChanged(object sender, EventArgs e) + { + zoomToggle = false; + } + private void btnHeadlandOff_Click(object sender, EventArgs e) { mf.bnd.bndList[0].hdLine?.Clear(); diff --git a/SourceCode/GPS/Forms/OpenGL.Designer.cs b/SourceCode/GPS/Forms/OpenGL.Designer.cs index 75f3a1bc7..1849034e1 100644 --- a/SourceCode/GPS/Forms/OpenGL.Designer.cs +++ b/SourceCode/GPS/Forms/OpenGL.Designer.cs @@ -20,13 +20,14 @@ public partial class FormGPS //data buffer for pixels read from off screen buffer byte[] grnPixels = new byte[150001]; + private bool isHeadlandClose = false; // When oglMain is created private void oglMain_Load(object sender, EventArgs e) { oglMain.MakeCurrent(); LoadGLTextures(); - GL.ClearColor(0.27f, 0.4f, 0.7f, 1.0f); + GL.ClearColor(0.14f, 0.14f, 0.37f, 1.0f); GL.BlendFunc(BlendingFactorSrc.SrcAlpha, BlendingFactorDest.OneMinusSrcAlpha); GL.CullFace(CullFaceMode.Back); SetZoom(); @@ -53,104 +54,7 @@ private void oglMain_Resize(object sender, EventArgs e) StringBuilder sb = new StringBuilder(); private void oglMain_Paint(object sender, PaintEventArgs e) { - if (sentenceCounter > 299) - { - //sentenceCounter = 0; - oglMain.MakeCurrent(); - GL.Enable(EnableCap.Blend); - GL.ClearColor(0.122f, 0.1258f, 0.1275f, 1.0f); - - GL.Clear(ClearBufferMask.DepthBufferBit | ClearBufferMask.ColorBufferBit); - GL.LoadIdentity(); - - //match grid to cam distance and redo perspective - //GL.MatrixMode(MatrixMode.Projection); - //GL.LoadIdentity(); - //Matrix4 mat = Matrix4.CreatePerspectiveFieldOfView(0.7f, oglMain.AspectRatio, 1f, 100); - //GL.LoadMatrix(ref mat); - //GL.MatrixMode(MatrixMode.Modelview); - GL.Translate(0.0, 0.3, -10); - //rotate the camera down to look at fix - //GL.Rotate(20, 1.0, 0.0, 0.0); - GL.Rotate(deadCam, 0.0, 1.0, 0.0); - - deadCam += 5; - - GL.Enable(EnableCap.Texture2D); - GL.Color4(1.25f, 1.25f, 1.275f, 0.75); - GL.BindTexture(TextureTarget.Texture2D, texture[21]); // Select Our Texture - GL.Begin(PrimitiveType.TriangleStrip); // Build Quad From A Triangle Strip - GL.TexCoord2(1, 0); GL.Vertex2(2.5, 2.5); // Top Right - GL.TexCoord2(0, 0); GL.Vertex2(-2.5, 2.5); // Top Left - GL.TexCoord2(1, 1); GL.Vertex2(2.5, -2.5); // Bottom Right - GL.TexCoord2(0, 1); GL.Vertex2(-2.5, -2.5); // Bottom Left - GL.End(); // Done Building Triangle Strip - - GL.Disable(EnableCap.Texture2D); - - - //camHeading = 0; - - //GL.Rotate(deadCam, 0.0, 0.0, 1.0); - //////draw the guide - //GL.Begin(PrimitiveType.Triangles); - //GL.Color3(0.2f, 0.10f, 0.98f); - //GL.Vertex3(0.0f, -1.0f, 0.0f); - //GL.Color3(0.0f, 0.98f, 0.0f); - //GL.Vertex3(-1.0f, 1.0f, 0.0f); - //GL.Color3(0.98f, 0.02f, 0.40f); - //GL.Vertex3(1.0f, -0.0f, 0.0f); - //GL.End(); // Done Drawing Reticle - - - //font.DrawText3DNoGPS(0, 0, " I'm Lost ", 1); - //GL.Color3(0.98f, 0.98f, 0.270f); - - //GL.Rotate(deadCam + 180, 0.0, 0.0, 1.0); - //font.DrawText3DNoGPS(0, 0, " No GPS!", 1); - - // 2D Ortho ---------------------------------------////////------------------------------------------------- - - GL.MatrixMode(MatrixMode.Projection); - GL.PushMatrix(); - GL.LoadIdentity(); - - //negative and positive on width, 0 at top to bottom ortho view - GL.Ortho(-(double)oglMain.Width / 2, (double)oglMain.Width / 2, (double)oglMain.Height, 0, -1, 1); - - - // Create the appropriate modelview matrix. - GL.MatrixMode(MatrixMode.Modelview); - GL.PushMatrix(); - GL.LoadIdentity(); - - GL.Color3(0.98f, 0.98f, 0.70f); - - int edge = -oglMain.Width / 2 + 10; - - font.DrawText(edge, oglMain.Height - 100, "<-- AgIO ?"); - - GL.Flush();//finish openGL commands - GL.PopMatrix();// Pop the modelview. - - ////-------------------------------------------------ORTHO END--------------------------------------- - - // back to the projection and pop it, then back to the model view. - GL.MatrixMode(MatrixMode.Projection); - GL.PopMatrix(); - GL.MatrixMode(MatrixMode.Modelview); - - //reset point size - GL.PointSize(1.0f); - - GL.Flush(); - oglMain.SwapBuffers(); - - lblSpeed.Text = "???"; - lblHz.Text = " ???? \r\n Not Connected"; - - } - else + if (sentenceCounter < 299) { if (isGPSPositionInitialized) { @@ -518,6 +422,7 @@ private void oglMain_Paint(object sender, PaintEventArgs e) p_239.pgn[p_239.geoStop] = mc.isOutOfBounds ? (byte)1 : (byte)0; SendPgnToLoop(p_239.pgn); + if (!tool.isSectionsNotZones) SendPgnToLoop(p_229.pgn); } @@ -533,6 +438,103 @@ private void oglMain_Paint(object sender, PaintEventArgs e) //} } } + else + { + //sentenceCounter = 0; + oglMain.MakeCurrent(); + GL.Enable(EnableCap.Blend); + GL.ClearColor(0.122f, 0.1258f, 0.1275f, 1.0f); + + GL.Clear(ClearBufferMask.DepthBufferBit | ClearBufferMask.ColorBufferBit); + GL.LoadIdentity(); + + //match grid to cam distance and redo perspective + //GL.MatrixMode(MatrixMode.Projection); + //GL.LoadIdentity(); + //Matrix4 mat = Matrix4.CreatePerspectiveFieldOfView(0.7f, oglMain.AspectRatio, 1f, 100); + //GL.LoadMatrix(ref mat); + //GL.MatrixMode(MatrixMode.Modelview); + GL.Translate(0.0, 0.3, -10); + //rotate the camera down to look at fix + //GL.Rotate(20, 1.0, 0.0, 0.0); + GL.Rotate(deadCam, 0.0, 1.0, 0.0); + + deadCam += 5; + + GL.Enable(EnableCap.Texture2D); + GL.Color4(1.25f, 1.25f, 1.275f, 0.75); + GL.BindTexture(TextureTarget.Texture2D, texture[21]); // Select Our Texture + GL.Begin(PrimitiveType.TriangleStrip); // Build Quad From A Triangle Strip + GL.TexCoord2(1, 0); GL.Vertex2(2.5, 2.5); // Top Right + GL.TexCoord2(0, 0); GL.Vertex2(-2.5, 2.5); // Top Left + GL.TexCoord2(1, 1); GL.Vertex2(2.5, -2.5); // Bottom Right + GL.TexCoord2(0, 1); GL.Vertex2(-2.5, -2.5); // Bottom Left + GL.End(); // Done Building Triangle Strip + + GL.Disable(EnableCap.Texture2D); + + + //camHeading = 0; + + //GL.Rotate(deadCam, 0.0, 0.0, 1.0); + //////draw the guide + //GL.Begin(PrimitiveType.Triangles); + //GL.Color3(0.2f, 0.10f, 0.98f); + //GL.Vertex3(0.0f, -1.0f, 0.0f); + //GL.Color3(0.0f, 0.98f, 0.0f); + //GL.Vertex3(-1.0f, 1.0f, 0.0f); + //GL.Color3(0.98f, 0.02f, 0.40f); + //GL.Vertex3(1.0f, -0.0f, 0.0f); + //GL.End(); // Done Drawing Reticle + + + //font.DrawText3DNoGPS(0, 0, " I'm Lost ", 1); + //GL.Color3(0.98f, 0.98f, 0.270f); + + //GL.Rotate(deadCam + 180, 0.0, 0.0, 1.0); + //font.DrawText3DNoGPS(0, 0, " No GPS!", 1); + + // 2D Ortho ---------------------------------------////////------------------------------------------------- + + GL.MatrixMode(MatrixMode.Projection); + GL.PushMatrix(); + GL.LoadIdentity(); + + //negative and positive on width, 0 at top to bottom ortho view + GL.Ortho(-(double)oglMain.Width / 2, (double)oglMain.Width / 2, (double)oglMain.Height, 0, -1, 1); + + + // Create the appropriate modelview matrix. + GL.MatrixMode(MatrixMode.Modelview); + GL.PushMatrix(); + GL.LoadIdentity(); + + GL.Color3(0.98f, 0.98f, 0.70f); + + int edge = -oglMain.Width / 2 + 10; + + font.DrawText(edge, oglMain.Height - 80, "<-- AgIO ?"); + + GL.Flush();//finish openGL commands + GL.PopMatrix();// Pop the modelview. + + ////-------------------------------------------------ORTHO END--------------------------------------- + + // back to the projection and pop it, then back to the model view. + GL.MatrixMode(MatrixMode.Projection); + GL.PopMatrix(); + GL.MatrixMode(MatrixMode.Modelview); + + //reset point size + GL.PointSize(1.0f); + + GL.Flush(); + oglMain.SwapBuffers(); + + lblSpeed.Text = "???"; + lblHz.Text = " ???? \r\n Not Connected"; + + } } private int bbCounter = 0; @@ -558,7 +560,6 @@ private void oglBack_Resize(object sender, EventArgs e) GL.MatrixMode(MatrixMode.Modelview); } - private bool isHeadlandClose = false; private void oglBack_Paint(object sender, PaintEventArgs e) { diff --git a/SourceCode/GPS/GlobalSuppressions.cs b/SourceCode/GPS/GlobalSuppressions.cs new file mode 100644 index 000000000..5afabe799 --- /dev/null +++ b/SourceCode/GPS/GlobalSuppressions.cs @@ -0,0 +1,8 @@ +// This file is used by Code Analysis to maintain SuppressMessage +// attributes that are applied to this project. +// Project-level suppressions either have no target or are given +// a specific target and scoped to a namespace, type, member, etc. + +using System.Diagnostics.CodeAnalysis; + +[assembly: SuppressMessage("Style", "IDE0059:Unnecessary assignment of a value", Justification = "", Scope = "member", Target = "~M:AgOpenGPS.FormHeadLine.oglSelf_MouseDown(System.Object,System.Windows.Forms.MouseEventArgs)")] diff --git a/SourceCode/GPS/Properties/Resources.Designer.cs b/SourceCode/GPS/Properties/Resources.Designer.cs index 96c3076bc..b85969287 100644 --- a/SourceCode/GPS/Properties/Resources.Designer.cs +++ b/SourceCode/GPS/Properties/Resources.Designer.cs @@ -289,6 +289,26 @@ internal static System.Drawing.Bitmap AoG { } } + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap APlusPlusA { + get { + object obj = ResourceManager.GetObject("APlusPlusA", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap APlusPlusB { + get { + object obj = ResourceManager.GetObject("APlusPlusB", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + /// /// Looks up a localized resource of type System.Drawing.Bitmap. /// @@ -479,6 +499,16 @@ internal static System.Drawing.Bitmap BoundaryLoadMultiFromGE { } } + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap BoundaryMakeLine { + get { + object obj = ResourceManager.GetObject("BoundaryMakeLine", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + /// /// Looks up a localized resource of type System.Drawing.Bitmap. /// @@ -519,6 +549,16 @@ internal static System.Drawing.Bitmap BoundaryRecord { } } + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap BoundaryReduce { + get { + object obj = ResourceManager.GetObject("BoundaryReduce", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + /// /// Looks up a localized resource of type System.Drawing.Bitmap. /// @@ -529,6 +569,16 @@ internal static System.Drawing.Bitmap BoundaryRight { } } + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap BoundarySmooth { + get { + object obj = ResourceManager.GetObject("BoundarySmooth", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + /// /// Looks up a localized resource of type System.Drawing.Bitmap. /// @@ -3992,6 +4042,16 @@ internal static System.Drawing.Bitmap ZoomIn48 { } } + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap ZoomOGL { + get { + object obj = ResourceManager.GetObject("ZoomOGL", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + /// /// Looks up a localized resource of type System.Drawing.Bitmap. /// diff --git a/SourceCode/GPS/Properties/Resources.resx b/SourceCode/GPS/Properties/Resources.resx index 1f765f777..1e6bde35f 100644 --- a/SourceCode/GPS/Properties/Resources.resx +++ b/SourceCode/GPS/Properties/Resources.resx @@ -145,9 +145,6 @@ ..\btnImages\Config\ConS_ImplementOffset.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\SemiCircle.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\btnImages\SteerZeroSmall.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -160,6 +157,9 @@ ..\btnImages\FileExplorerWindows.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\BoundaryCenter.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\FileCopy.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -181,6 +181,9 @@ ..\btnImages\Config\ConS_Respnse.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\HeadlandBuild.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\FieldStats.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -232,11 +235,11 @@ ..\btnImages\MappingOn.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\WizSteerDot.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Config\ConSt_Mandatory.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\ColorUnlocked.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Config\ConV_GuidanceLookAhead.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Images\z_Compass.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -268,6 +271,12 @@ ..\btnImages\Config\SectionOnLookAhead.gif;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\ToolChkFront.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\btnImages\RadiusWheelBase4WD.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\SectionOffBoundary.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -280,6 +289,9 @@ ..\btnImages\Config\Tractor\z_TractorValtra.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\ColorUnlocked.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\Config\Con_ImplementMenu.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -295,6 +307,9 @@ ..\btnImages\Config\ToolOffsetNegativeLeft.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Config\Con_SourcesHead.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\SteerDriveOff.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -361,6 +376,9 @@ ..\btnImages\Config\ConSt_InvertRelay.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Config\ConS_ImplementSection.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\Config\Brand\TriangleVehicle.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -370,6 +388,9 @@ ..\btnImages\PointDelete.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Images\z_Tractor.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\DnArrow64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -394,6 +415,9 @@ ..\btnImages\TramAll.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Config\ConV_MaxAngVel.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\ColourPick.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -418,6 +442,9 @@ ..\btnImages\ZoomOut48.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Config\ConS_Brand.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\Steer\Sf_SteerTab.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -463,9 +490,6 @@ ..\btnImages\Config\ConS_SourceFix.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\ABLineCycleBk.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\btnImages\Config\ToolHitchPivotOffsetNeg.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -484,6 +508,9 @@ ..\btnImages\FileNew.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\AutoSteerOff.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\FileSaveAs.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -502,18 +529,12 @@ ..\btnImages\Config\ConS_ImplementSwitch.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Config\ConU_UTurnSmooth.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\btnImages\Config\Brand\Deutz.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Config\con_VehicleFunctionSpeedLimit.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Config\Brand\Case.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\btnImages\SteerLeft.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -523,17 +544,26 @@ ..\btnImages\WindowMaximize.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\SectionMapping.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\TracksInvisible.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\UpArrow64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\boundaryPause.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Config\Brand\Steyr.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\SectionMasterOn.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\ZoomOGL.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\btnImages\Images\z_TramOnOff.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Settings48.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -565,9 +595,6 @@ ..\btnImages\Camera3D64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\FlagYel.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\btnImages\Config\ConS_ImplementHitch.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -577,6 +604,9 @@ ..\btnImages\QR\AgOpenYouTubeChannel.jpg;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\SectionMasterOn.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\Config\SectionLookAheadDelay.gif;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -619,8 +649,8 @@ ..\btnImages\Images\z_Floor.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Sort.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\SectionOffBelow.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\AgIO.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -640,12 +670,12 @@ ..\btnImages\Config\ConSt_TurnSensor.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\BoundarySmooth.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\SectionWidth.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Config\ConD_AutoDayNight.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\btnImages\Images\z_Harvester.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -682,8 +712,8 @@ ..\btnImages\Config\4WD\z_4WDFrontHolder.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Images\z_Tire.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Config\Brand\Case.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Config\ConMa_LiftRaiseTime.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -691,6 +721,9 @@ ..\btnImages\FileDontSave.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Images\z_Tire.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\Images\z_SkyNight.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -712,8 +745,14 @@ ..\btnImages\Config\Con_ModulesMenu.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Config\Con_SourcesHead.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\ABSmooth.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Resources\rtk_lost.wav;System.IO.MemoryStream, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + ..\btnImages\SemiCircle.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\BoundaryLeft.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -730,26 +769,23 @@ ..\btnImages\back-button.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\BoundaryMakeLine.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\Config\Brand\Kubota.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Config\ConDa_RemoveOffset.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Images\z_Font.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\AutoTrackOff.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Images\z_SkyDay.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\ABLatLonLatLon.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\btnImages\MapGray.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\btnImages\Config\ConD_FloorTexture.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\WindowDayMode.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\ColorLocked.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -775,9 +811,6 @@ ..\btnImages\HeadlandSlice.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\LetterBBlue.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\btnImages\Config\ConU_UturnLength.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -793,8 +826,8 @@ ..\btnImages\Images\z_NoGPS.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Config\ConV_GuidanceLookAhead.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Resources\SectionOn.wav;System.IO.MemoryStream, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 ..\btnImages\Config\Brand\Massey.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -847,8 +880,8 @@ ..\btnImages\Config\Tractor\z_TractorClaas.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Config\ConS_Brand.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Config\ConD_FloorTexture.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\TrackOn.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -859,14 +892,11 @@ ..\btnImages\SnapLeft.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Config\Tractor\z_TractorCase.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\Resources\rtk_lost.wav;System.IO.MemoryStream, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + ..\btnImages\Images\z_Font.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Config\ConF_SteerSound.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\ABLatLonLatLon.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\ABTrackCurve.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -910,8 +940,8 @@ ..\btnImages\ToolAcceptChange.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\ABShrinkGrow.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Help.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Config\Tractor\z_TractorNH.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -928,8 +958,8 @@ ..\btnImages\ABTracks.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\SectionOffBelow.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\WizSteerDot.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\WindowNightMode.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -961,12 +991,12 @@ ..\btnImages\BoundaryLoadMultiFromGE.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\BoundaryReduce.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\Config\ConD_FullScreenBegin.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Config\Brand\Fendt.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\btnImages\Config\SectionLookAheadOff.gif;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -976,9 +1006,6 @@ ..\btnImages\JobActive.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\TrackCurve.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\btnImages\AutoTrack.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -988,9 +1015,6 @@ ..\btnImages\HeadlandDeletePoints.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Images\z_4WDRear.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - ..\btnImages\Config\Tractor\z_TractorAoG.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -1060,11 +1084,8 @@ ..\btnImages\SectionMasterOff.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Images\z_Turn.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\btnImages\Config\ConV_MaxAngVel.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Config\Brand\Fendt.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\WizWasZeroReset.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -1072,17 +1093,20 @@ ..\btnImages\WindowClose.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\AutoSteerOff.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Config\ConD_AutoDayNight.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Config\4WD\z_4WDRearCase.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Resources\SectionOff.wav;System.IO.MemoryStream, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + ..\btnImages\YouTurnU.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\UpArrow64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\ABLineCycleBk.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\ModePurePursuit.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -1126,6 +1150,9 @@ ..\btnImages\Config\Brand\Same.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\VideoLink.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\btnImages\OK64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -1141,26 +1168,26 @@ ..\btnImages\Config\ConSt_Danfoss.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Config\ConSt_Mandatory.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Images\z_Turn.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Config\ConD_Sky.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\HeadlandBuild.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Config\ConU_UTurnSmooth.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Config\ConMa_LiftLowerTime.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\ABSmooth.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\MapGray.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Splash.gif;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\WindowDayMode.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\LetterBBlue.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Images\z_TurnCancel.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -1198,14 +1225,14 @@ ..\btnImages\Config\ConS_ModulesMachine.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\ToolChkFront.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\FlagYel.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Next.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\SectionMapping.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Sort.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Cancel64.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -1246,14 +1273,11 @@ ..\btnImages\Steer\Sf_Stanley.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\YouTurnH.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\btnImages\VideoLink.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Config\Tractor\z_TractorCase.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\SnapRight.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Config\ConF_SteerSound.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\HeadlandSectionOn.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -1261,11 +1285,14 @@ ..\btnImages\YouSkipOff.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Images\z_Tractor.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\ABShrinkGrow.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Config\ConS_ImplementSection.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\YouTurnH.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\btnImages\TrackCurve.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\TiltUp.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -1273,14 +1300,14 @@ ..\btnImages\Images\z_Speedo.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\RadiusWheelBase4WD.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\Images\z_4WDRear.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\Config\Tractor\z_TractorFendt.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\Help.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\SnapRight.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a ..\btnImages\pathResumeClose.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a @@ -1288,19 +1315,10 @@ ..\btnImages\pathResumeStart.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\btnImages\BoundaryCenter.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\btnImages\AutoTrackOff.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - ..\Resources\SectionOff.wav;System.IO.MemoryStream, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + ..\btnImages\APlusPlusA.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - ..\Resources\SectionOn.wav;System.IO.MemoryStream, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - ..\btnImages\Images\z_TramOnOff.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\btnImages\APlusPlusB.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a \ No newline at end of file diff --git a/SourceCode/GPS/Properties/Settings.Designer.cs b/SourceCode/GPS/Properties/Settings.Designer.cs index e726d6748..a12923af9 100644 --- a/SourceCode/GPS/Properties/Settings.Designer.cs +++ b/SourceCode/GPS/Properties/Settings.Designer.cs @@ -2771,5 +2771,17 @@ public double setDisplay_camPitch { this["setDisplay_camPitch"] = value; } } + + [global::System.Configuration.UserScopedSettingAttribute()] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Configuration.DefaultSettingValueAttribute("1022, 742")] + public global::System.Drawing.Size setWindow_abDrawSize { + get { + return ((global::System.Drawing.Size)(this["setWindow_abDrawSize"])); + } + set { + this["setWindow_abDrawSize"] = value; + } + } } } diff --git a/SourceCode/GPS/Properties/Settings.settings b/SourceCode/GPS/Properties/Settings.settings index df9d60bfe..1fea3561a 100644 --- a/SourceCode/GPS/Properties/Settings.settings +++ b/SourceCode/GPS/Properties/Settings.settings @@ -689,5 +689,8 @@ -62 + + 1022, 742 + \ No newline at end of file diff --git a/SourceCode/GPS/app.config b/SourceCode/GPS/app.config index 4291cc04b..5be571a93 100644 --- a/SourceCode/GPS/app.config +++ b/SourceCode/GPS/app.config @@ -691,6 +691,9 @@ -62 + + 1022, 742 + diff --git a/SourceCode/GPS/btnImages/APlusPlusA.png b/SourceCode/GPS/btnImages/APlusPlusA.png new file mode 100644 index 0000000000000000000000000000000000000000..9a7942cc0fdacb9ff12aa2c8537bc65e70be245d GIT binary patch literal 853 zcmV-b1FHOqP)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D0_sUbK~!i%?byF- z6hRaR@b@MpF@>GNT`oaHAw*-RpoLfpf`Z21NX!p0mH&bg{0m~GaCd4Yh-tL5vb4}b zK@qXg6qm#(f)EsPH_w;z>zZZfcF)^D*mXWI+(ZzcA2aiDq)p5+%o7Xmkak3$`&ys74`~x~cOOrD`iV4F;tH~4+HM`G z6fYpmjpP<%I)^BcWzJoj#TH1)10&iq+mR;HxhE0kMr?sBH~x8NTCJ9jA;H_eBG}pkd}Z+k(tuP-W5RMDX)5cF6!l8~bzSW_6KPY+6~s&z5r*(& z?FmmUE+ciaY%U?pJZFJqc6YBHt_~s%2+=%3T}g5eVT57H&9%e5g0`-VA__6Iu04$0 zMHHd$u9B1sJCJ6Yvp|;E*&98zIm=bWlq-|9Uc zD?ElUy%pL0_o1PAK`{z;zI~CD^wtBcpPDfUN2s(0Nlw%2@Ian|V7;t@h8Jvtml zm^pu2Ovu?@dc}=xp(f$jIeIeB>~Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D0@q1IK~!i%?by9* z6hRaK@OkU0_)(@%(d;P}`4bcZYMPKs)Jm+x!a^GhQN);Rj?3+#O|&qmg&?HUDunDs z5CsWnW221{g6xSB1-}|i(A#;wySzJ+>|V&`Zi~_PgUP-(Gr1%$b2GcAgb+dqA%qa3 z^?*Z4J$O3m6%i?QGQGw5^V1AlYqb0I}mdN_~%rM8RvWJQTfXd}`5#njz z?H%K6UDAWzJq2)v)0)Hddp+ZLRf(*iC35sfhW-gAiB%xbYFueGLYuQooAy=OY&;%n z$aWrgaA>4h1)`$d_Y0XzB{$=ghI_90Zl+J6KFPz;p#1+7D2ng)J){-&h0_o#2tIOX zq^1j$c8Z4pR2!!u3mfqrhenFG2choV>lBaHnmy?C(>>1v9*%%F=W@pyt}YWKcg!Pt zbVT=YR%Q23bU-TghSR3Z|Jtzq^GNs4N}P74y6Fc#stz=Xj{jvfY5FY|h4!S;mBlet zLIuLNyDvQ7!l}^`DUfBsXlmQ{*X;vd7k3#ekpfi#?59FK*^?dL#XVK1)T>5~r_@Ew zsWqNb7d5BSXgPo5DRoivYK^DV#oMG2j{9!U1ZQezcA{-lIduXob(_1wP~V_?rHh<3 z^iMvERgUmdA#;Z+KgnGobobrKp^;kh7Nh&4mmG!wLOX{>YPvvnc5(;3%sEcO0OvU} zQp^JBEB0V<+R3O$(GX#lLnFm25Wqot?m9)A_}NOMjsrZ>5Y3fbtm0;g;7bwz8Hb-!-HAGw0#=X;hP-G)hQ1<}!;H@!F&O&5rsyUO(C z2VFl?Hrx-2#fqE9>6)gvvBO!zkLI@#*5Nn~-UwIETL1ZNss{jB1 M07*qoM6N<$f`N#Fpa1{> literal 0 HcmV?d00001 diff --git a/SourceCode/GPS/btnImages/BoundaryMakeLine.png b/SourceCode/GPS/btnImages/BoundaryMakeLine.png new file mode 100644 index 0000000000000000000000000000000000000000..bde329358809bf315d7a9db81deb28713ea1e9bf GIT binary patch literal 2303 zcmVPx#1ZP1_K>z@;j|==^1poj532;bRa{vGi!Td5G=eQ{6H6?*YlGIJ&_F?>0b8n4Q2&uu|F9a= z7AZB@T9asPl18l%o1&#wkkUx754$8bW;gqqoyVQI&*S%Z=Wd%wvfXTUcdn2x%pPXu z+}Zu!-|zQ1zjJ2kvNEdG*L{tYQt7jWOH0Shiw$-SZ6wXI=(n%)D+5$M@j?2~mh0*C zYkyAW%qNkKnN}J_AvI0KVR$78(R0RACmRi4Zr?OGX6Tak{OIfH?DH%0M&Gmf?qrOD z@LJt6M}(AL5E?s<8f#ZMll?vBn_;MKdg--t`0^j_Pv)LaG95FmC8nb zuk!0n8a?{G^y+h!S)&}8vh@ggrK8=ED!(fZBZ`BNQ<6JrC<1B%0du&SO=vHFK$ zoAlm~-IIR8xyo#f+Ux(rONtR2CtftH&XV*8P=W@LiYaXP6x3YuW~<~^YJT809t|7K z=cSbH=yTssKjBcu0v5>P}p?IuhtWzi0odNd`!2k ze~v!;Kyuyrlu4t7bzMkFb)W9YyK*Is@~eC@U^WcOmT|B@%RP{fX|lq-G^V^I+~)_Q^f}`mv%2wYm_Ktjt6- ztxEyc9Jh*cO}@Wn6p^LIR7|z8i2Pdg7omwwJkdHmLT~)(!Y$wbDicQM;Dc!X%FK(A ze6LQqK1sSG$e&eI9Sf;B8&6^#xk^YXpL%>WnSU|LOzNU8@6jzWVs~j|cf+I&x;7NK zlYmb(27%Qri#5q=yU|u%sv9&z+;4ZuR$b-?HY0X|pf`(U&L_*j6?B;Yg7 z@QMG1bY0K$E+v|*wnX$S`25^(#ML$;$!W_b{fbH`>(}F1OxeowF4ZKfZK(_R>;!y1 z&+u`&MMBuHIR~GJ;j<0VoLCBztQ9w!!sj}`=Rv!34nC5jOYRwlPmHEOeHHLIx>P1v zD{3@>PfUH-Up{3OQ}`5G@Zq{_mH{6x{srLkV0y`tX~m4r)g>1FLuOuf*@&doA+T{4 z)SQW_F&$wiqFzQMZ|7-C8BNxT7=0T)>S5I4dIt@`Tkxr(E*UrluD;qV?`9xj{p9-3SSluc#I<*`oS<7xTh0jNjq7T`fsmVOHU2)p^loR;e ziHWr?H71T?vz{B{$lF4_$-0do+O$*Cje1{z{WgHn8mi ze7=SE53ZC+){+`c;Zs1TbC}`7gtZtxTC4L(;M0r`pf10iUb13ZGNW_wLFAqUd-i`oISyg?)UoYCGy$Jj0X~SfztSdI zOJX#I&u6eBxx2OPY8`B$7F$gL!w2spWnXEBN!BGBP2sZ^aQWpNe7N)BZ+=>xPXeFs z;{E;YGRe9mqX~QzSxCp)Bf({}$5ez5+JSRMJT2vsi`?pA_&}Y^ZKW${x#t zN!EgnI}eX^BxB&KYfPKA!t57kg&b;1UHf~{q7wr)z0qNkcRHfR1UKvP4`6avR!p)M z^!?~(*I5+$^kF+EzG69ISD}--dx}c-n;{K_A(=kWziWb~%D5SBd=w_P^L5o@cp)Qt zN27;_3*>vM)3n9soFd&>C@HhpqbS!!NxGUsQGYd{urBF9Qy;GqZ9q1+r74(C^VaC@ zZ9UXy#iTcbnr_f1O^5RNPNHIosIy;TROG<0h4Nh!xU?f|-ZUtw`fxCrenNJ1L8H63 zb>pX^zgF#HShUv)Nmm+{BGXo67w{;?2bx`;UL(Pm(t@gq?m$vLfTr;K%8vW8! zGZZL6uh&G?h~rT-1{FT%;e+NV;KMF~x&>(?w0d|ASey1Gy?OjtBRk(NpQU+Ich`Yw zx}nD>X^A?8mB&3SoQnJ)KGM=bVCHK)I zQ^n0xD|gZCctGVbm>m~Xog!-1#i78XKRN}P+Pb%rUYRW|D9fJSK0x)MYsuH`hw{zo z&0RCk=_K?)ifKHG)S*UA?8W+;{O`++kNqDTWj*oDVUoyC^Z1e8VrAC#2Rhc^<&&C0 zlSp3yqv~cvKC8NDZXDT&nq1vM6IdqS{Q>M!>Hrh!GRr0}NqpG#`|YjP@UkxJvX)6i Z{{`;3*Z@hQPS^kd002ovPDHLkV1lb}a3lZ# literal 0 HcmV?d00001 diff --git a/SourceCode/GPS/btnImages/BoundaryReduce.png b/SourceCode/GPS/btnImages/BoundaryReduce.png new file mode 100644 index 0000000000000000000000000000000000000000..bfc58e2e34a5e241579525dd2465d7099122fc86 GIT binary patch literal 3124 zcmV-449oM0P)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGizW@LZzX3P}QzQTY3&}}DK~#8N?VJm6 zR96|tzs*8`LU@Bv9`deKkcL+XBVflmmDXx0YI%ucffgNQYHKT?ZMDU|blPF8q7Oe~=QyvPT3{+5Bm502-tASETNJ2=~|8KLG*=%-`z4tE3w&c(J=RR`x+;hI~ zeBU|eJKrT}@evT)ioL{^VzGEp^a{$$5<7~G#S3Cc^ny(BI`P)Xk-B{-`YG=-;%Kp( zcvhrLKWHc3CVoroFP;|9h_%)cLB&Hq@%ti`{78IBd{HbE-GX=Y74Hy-iuvO6;zrS} zk|}G1__#<}<>GpAw)mb{BevS>bOt&hO2{a-l4cLu6C(~;{{0v2V*gCbEN*XY*G#h8 zmgL${+TF-`R%{~j{-%*5*WBmtlu6l*Rc6!8w(ax#?cnvgZobG~EYfkg_!IGjSR>*o zgcr;e?-5%}x5xd(|3WVWB3+>_m?@xzX<78@*xxwiB3M}Gc-EGh zl(Ju^Sj!f%Mk|S@kQU;?88&4C%BZ}RI)wC3N{L)u0zDm~h|7sGk@w&-D^!;Yg;tbx z&Wf5*ud?u;ty~@Ea4TzBpmQv^%5TKdm?MAZx$v`Rt+2@^%e%h2b?Gxu-s*R92G7|m z|JC2VEp8QED}BhBMa^vZi646W)t7VTJ%hb$nPD2A;|I^8yl8(46vSQ;!nlSB0~L}I7`F@ z*6Q=)0QucM$7apH)yB5|wJk1MYAb%Ld$?J~64yXU{T{S?x5?**?y;E%bWNqP9529a z;7{KWQRsH@F7c|(m4o~x=(r5&xm70 zzwRw-xh-6c{C;6`7V5f-=*!y#-n3;;Qs7E^e!i~p%YJ~sdW$snbK+HE7!oqGuWE=@ zP7L@P?#&r%`~n5g;iwk_wQopvOOW4YTQxOuD=8#;c}PC=JSUy3BU4J;fFIy4_KD1_ z{wapb2I}7DBz(-g3Ut3FcfsFqMSiBw(ZE$PgQQ-#xl{m4mV3y!)YfE>lHT9~2(Ov| zCHzt;1=m&$wOC3zBdic1tre0GQcAgmUu`U?#ZuB4OiqBSMP}M41W5StW!b+@zek^tn>pSf8LxUle~PP7w)eB0PeT ze#QwFsVKISh(|!_EO=R8#VglwS#>tcLh$26Li8*gS@C{V#Ektk+%IrdgkXA#2##yQ z>)E28_BvshXe(v?l4#vh=L+GsvB5wZ?RCSfHa8L{wW9l(!57_43v*&KRGd_ZKtJ1P2w<7&Ks&OmtP zK9L}%6U{v+M#GD;&xvn}1R?(kwOybT=ES zR*p|F*+7WU@5Cc;#?FT0dBs-3nCYs#L<$L%SZO!}@{ygzA9`J+IY4k!l1#|);$ShH zIKf_r$f`eC;0}mOQ4UEHRWegNfO-%#Br42W>KkI*#ET?AJNvG+4PWD8tL-45=_-pQ zkwUs`v26tC>}~t|O*-5nI)2d$$mk%|<~fnHm<8gEqT9F^4g0eAdy#S$i{BN=KlTCy zh|nGuzax@e$X*9q3SPVi?VM3)gWu=Hpwglo5DB_C$l?Qhp<^`<<=VSS&(m!(l_PTMrIP%HbkTQ28qVNNgp?dDH)99jd45L&DTng%#Q%w2>P8u) zjuOQsYJEyvD-tOt6yz3X=Gp9aK^fXAd#muU9o?aOxK>{=K6)Q6VcBRKaU#!Fhql6@M)pMd!f5uX$ZM*c|bD!R2ep645m`$ZznM3<>+ypEMD_$_r|oaCF6KB55%03X6M*gx4qf{@51Harr3GI zHF)hcl!0r-nz0hky)O!mQauMFrHllaw6{-xT;&Co<*eyS#K({i!*d2jh?}7 zk?0jvjHoahS$ACO0B!c845rQ~1K0j5k$SnVTWzKunrJf-9y1vRzwvr8 z)7Ml3>!H`Xbzx}%$pkq*R(WNQ$~yQE$rEZ*NEmtngYun~SN4=DFfekSD$tYsxUl*L zQ}IFKA(1tfXC$Q%Af@n~+_NIn;a8*-SA*3j6_NwvB8y4zkmM9Sg?5dk6%xVS;%Q@zyv*r6{f7k+*Fo<`_?#0vYhG^US!->>==W{Uq@V@c z53}sRPTPHSkX^fUxMgqGJr=o4Q6V{3yt6QYaFG>(NR&F_Zo4x$(Z&S}?9{fKZ3;^A zyoQN}XN7>*?1eEMtlheR1%hjAedwqiFVpqzQI@l=wY74U0#jyX!Ht$T>X7B<4z&K6 z5~8)SRv!+vL3y35BRg+lAxDnU=N$dIp=cmjl;bEWOu46X|F%6>@3QxY>AdlH`-=Ql zW4q5DUcAZj_%wm_ns4}0h|qbKO@Di`jlU*xU0-0uP6xn}VE9}XQv4s=+jXxU7*J&A z8}+xow%-nxO5yMHwjKo;mVrgJ5^=qpb41CtqQpvVqiv~pz@GTIE?E>t=MsB{Uxj>1 zjaoS0=G`*b1_s_z6$|Y2sT>>fs@wmD!?BQqb|hCWC3A~ym)i)P7-EAK%f0NBd!g4} z61IrdaIZ)%CQ*73?IXZPTxpcZb8AFCRUkrK4RU|%iJ%xqNshu=%0jN$X8*Xo)GqX1 zX>WuYTce%%cASB|*8ei2uE0P(wY|05*ULUloQl{#5nTpmw?KG|A$)JLQzTI5=RYiP zfIDM?z_%fD$M_ku|x2leoZmlNOc{3mQr#Q#rUcpaBhNKm*blX8#9rE)$@%`)x}A O0000Px#1ZP1_K>z@;j|==^1poj532;bRa{vGizW@LZzX3P}QzQTY2(w8H%aiKq!GL87M-ThtgU)?6Z@(O4q(nrLDd zd#n*-6e}@^f+E-{$NB&5&bxc}nA!4Xc6WAf|H+Rj?9MFjoAx;y~0;piHpUNVx(9p zz7jWz$Hg*HGpV6@2saXL1G|mBo=8=N48lz>6ekF}9K*?X;x_T1@O_f$Z4<@SVgpWu zqUXIL&Jx_GCXz9dJZN$HQ~V_6hg)}_hdie^gD|8VD{c}z2}b(_ibV1)5J%)qZ-ID$R{H1sfI;rK%X`kpg4orVpus(U|BwF^R3ulM1HXZ;hPQ? zp9zL3bKO4#!=XKlRb4cWAv{%a#od#JGQ!Cc@q8}qs0znUG&EQE{$P9&!`=4c)mk@0cPp=R(+OHz2(fB^W06mSrr_;k8Rpg(WZ_4N zwMA1NN@9?mg_~0l6znF}$sILSwtNjjv_0Yj=#F zE(6R8kMgQxqqqjyQfv|K+uBs%ynV-euE((FPJE#ef??86IPvz*u0}D6+rT7yQ59Rx zC0T?(qR1Qw3ngsfcbJi5M$%smWE8t6uum_zSune2slcQ?U@;+amcm~5<_szO2^=jxgXo8Z zj|O8tok=BMajmVz;et9C$>VJCk|2laH*|OJar*O-{6R`8V3aHy1d)5-GgwE(-~S+( zq)H?E=6VDQ1Pt^LriYn-8K_Da1g%^?A(-0sPM4OSvL;`H;P{Eg zFoX$@u`4bMh1$@j<@7 zLuuulu0}BiavOpMrIA@2O?VpDP^{PbM!2it85hkuE>~QeniU1hy9AS2tXgEXJw3{= zw+w3=I6GO##z1z1GxSgj=hcAg1Pw)`gY$MpDTS~YCr*QyMRJ78lrMf1uIM%N3aZJQ z3F=qmI=rSp_8xVg;u<|}rXnj0TldC5=BZ@6lekP!Hlgw81uTwc?G+PH9NWTxRENpD zsSZ=8dMzYsqKdbt?iL3KyEpK;C&f8}so?U3A8C*oLnDSL<|@ovQU;8`+&N22qr`>y zE^`w24%esHqL%flu&)pFuBQbvi8T?8W8v@5%8-4}@KjFb=J*SqcGnrx3&=4@{G!Cg zD1VT7V@$Uf*`n8cDEPcB@)xFm3%=k|Ma`&|QKDpSOhp%8;I5~l!ExMalsLHl!{S-N z(1c+aULF%qgvYhgjBtz26g4x7xhajo*iVFHx)59HO*rl}oFqdNK8YxcQa(c@iR4ux z$-5_Mh&lQD^Se3K%qX@q!4DiGi0KJKd7>$~fM3p;j3s=Yz`)>zICJR?uxYdI(E-;--2r z2+3vC>PMcIWEI~EDQqNaZFWdp3H7~kR&Ea=s$wZ9LlcYYXheSWm*KhRM3gV!a|8l( zdA?_h9z{O#l*m*MF$#MM%au$|VW=e-vA3iN?s<~xC6*rFa+V;urzN}6)UgMOYk2@3w#jA z?+bbc@0HYj9+QTA4dN^AM*#H0l literal 0 HcmV?d00001 diff --git a/SourceCode/GPS/btnImages/ZoomOGL.png b/SourceCode/GPS/btnImages/ZoomOGL.png new file mode 100644 index 0000000000000000000000000000000000000000..6b2c974d724432d733faa06126fd974a460f3390 GIT binary patch literal 4367 zcmV+q5%BJbP)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!2kdb!2!6DYwZ945Tr>&K~!i%-CAjE zT-S9zGjFyx`_5gYNQ%}*OR{9ilH0^hTdPik#DUWkMgX@cTBCo8wkVn(Erir9P{fX# z260+9faN+)-M9wqNL3s=juX4GBx{LCkra0hIWydbvvT%*rr)_ULoK!xjjRSj4|L|f zci+ADo$sFYK1xBKfd2Atza~2!twyz4qa&)y3Z+Vw&1FlaVlkV^rnB?Ynmv*vZBZ(vc04jxDx@lwilsuKkjUq9E167YHl0on zWzxyvnbF~~6USan*H-zzqgw{_?W6x`HW*Bg$+G+fy}@)q*6UjVic~5Uo+_zQtx&mK zp;Ea_#X^Dd`8)v-C6ftC#Mf8i@%3|PU!R*CIsW#s*HX1r?>yZSprb!H{)oX~{A-KN ze#mUGX|+0;s^~8i@|4TvD3{Gqp_r#qsZ5m$o+uRfr$h^&xMy$xLy<@*8x4m}MnY@P zyzZ8ok~C5JkdnL%=w}oS+egCINsXK$goT z0kjA%SIVT6l%&zhq*80BSSrzaEK0$^N;(n@JbU5&x4tnmHFihM@P>f?^`+Ok0pwdQ zck81LcMEp9LeX#-yBvYgM6%vYMx%vvvVqiWcF;-{h^!)c;>#^CLFSfOJK4N#ZPzIV< zTJ*vnGGw>6QfKF8YHevFo7F-_y^ds^nq;k-bj%tR7_ClAMuU-THWyj#E|L^#T3%hH zbaEZQ^rSbM3BhDgtua^IcR-7N{c=( zG-9FN-g~GO+AZ!2y^aA$3t-}zQi*E~S*$ja)K*#vCMcH-l2(? z4Ir>|Bw~@D#$(}pU5wkNj{ti751;(HyRG91o5LmSebMiy_V#Y-@7+RXqh5ee3a77g zeI65TMV}JAN&pey07@lEB*B+-IvrJ17D}WGlwMx}C};{=tX8W#EOuvQV))!A4iwh_ zdj93tA9K1|o^iLfD^rOC%*;nUoBFA5b029Sm=GA_xaEr)0D{0+2tf@P1UFEMVHlul zXiid4xrza53uSU8O2=2Bc>{pz3CVb0YiG~M?D+6ZZT9Wa2B5Eh=cvnWcRmMG+f;^Q zGnn?44%*V!kKJW$Tmc~D71Gx3lbJH5!MS{evbkF5W=%GpGbxn{XiJ4IB^63lQfW=_ z$rKf`v6??gk{TsOM=qCsGZI|Q)MhnL8-O1D@)LiI(ELY6lUW&9g*m9yv~$}IXhtQ% zF{c+M$i?Yp102(jKUk+9osQG+RDw4R)YGXKQIDyy2@Hz0Rjw$o9(p91;?V%s zEDKE)i-mTy{;81*zo^Y@p4dR>YfnGtl4bqpQ2|J)REm-?x89y!gk+5ns#qe*7HXUU z=fQ}~f*4>ZR-jW0SsM1`=)_!xQt%NrJplsDZS9A!QA)C!WU`s`oOr2o<7Et*ENHX0U?Zw{X9Z@iXWlhfeH{LP#K$$>qyWto+0QVKH-xJr?AgYeOq`?i*c}T@T#~d@ z##}X$Fv_Doi@U>7AJ!B}2S5GrCX?CrXIi~Mj-pQMYHOvg&Ncx^I5wC~EgCP;>7gV| zEo5lU2ll4P<4cjppQKAO35ur*q^On!YpNv_uNj(}4b$XYh-N(@nwkkvAP|Rd8d0dK z5W0DjINDVy2lSEfDtxv8;A%>z;uHz3{|>cCt-`dz$TJ~u5ZBDukPR>lER!#iH=d`3M2uZvg)=L6>V<^x2b7IhlaLyYH;o;Pz;QyfaF`E!A>nbyvs)WdJMFG zvwy$9j2r21z>(e=fgRA z>B)QO3y*9^!C6H{;z5{$dHJFO{(>NnIlKllN5o(>Ngtm1DT-7H8>pnEg_+s0i>JT* zvmYP3Bwo@4DHDnHWImtsaM;x$T(7Q$khKwQt}-{_Pq^nkPKvCt4d&;NxCm3@#0nJR zp8JIfVX_i8+#;9O*29Yhi)#hta~TogWIc8SbIYZoFBuKRSiojU`R1!f<0v~uil`Da z8Z8B52?~WnB6l=^G<-=2&|pj!j34%kLOrpH(m~WrV*L$brE>kp8f&b<#Qljx1n-t$ ziaIJ6iwtn;{Mpm%wGqt`M1`+rGiUR;Y@Qvm1lyRNt3^xJ01seh0XDS7Ejl*@gYOhM zu?j$3`qZLTTOUtYR-8IiU}dp_+U?t~egEi*`wsnPesyu7HmOP40K|0p z;+e6ngZp+M$8Ketj>7cjJoD7o-El)uEF|wf=XDNn%ndMHakHuMHU9_=!_)$6Ycw`~ ziR?}X84LzmTV1AQ@7(c!{>LNFVq_FxFzfc{8bF|;)$SU>QT$UHo!nwJTPeJrq{-=7 zYH?V|VYfo4>(p}<;ovHWLo){fKG`;au+Q*0$+zgodgEln@!M!JQ()Oo%YJ`lcw+v$ zv!iE!##4EX+okIPk#}w)+}_hM2f% zXp6x#4tQ){+!sX^GBrC*ORI}GcDn(_MAK7~6bmfUXFh#M;cji;8rO79`^G+){jI~l zqn`K7@pd##9|6QPbNQmLeN*p*LaE#{6)v(19|Hmwz(dv)S-RU;>{ z1RKte`#fs2wNRL5X6F!OJjijV(p%b)K(*xeF3?Zjd6%k^OkM3Qv~ysy)oHWtBekK& zDCPh3{{075M@B|`_0?{fJ{Azu%;lj4v&DKwrBZE%bp5hyAd}gQ^1nhe-W3|1oFk9d z4}oJ8izg|%o}w5y7>?2M${Nkgdud{3hWyJbRD|km4kuZxR`FK}4gj9%iBlfmS{}z( z$66#VKALRlZgC(79a>%XZhj#DYeG#Dib&+m~ZU~6UJ2x4)bnfIkoBHlap}y*s zl#-P*y3KAw-DRR&sY-!Jf)L9HmPv=g*PyWSa&P!H}M)Mm01xzEiTy@_R zP@U4_LuXGpT<&uS2>D8>V8q$Qp;k!>ygv)XKEtz@-Wg(mgLWo(AIOd6%l zT6uNJH?!pR{BZdE>8D@#mv6p-bwi7Dqtn0tr7x}g-e*7cnR~ZwHk>*CA)P&a22m2l zE^0dXu?+{m2lwpRGj^+>@XDr0{_JC4+3s?;J!r8z_8U!>?Xup`DeH7rwML`nT9C_s zNK_~l3-NqDyOd5Qrel%N#YL~@{2TxE{VA*w@408N=$#%DPCqs_`o&~2^-?aEGy7Ly z%0ojmK0c0;D2n7PBe&U6=NV_Q?vpRS{PO!e=VsI_pa!vKZ4ZC$F}KcOXfd12E>!Af zNu}aXtws1rGMP+7GRb)8trKsAF_w=4{MYb$AiqLKjvU#wyu9?vjvYI93=R%bC={X# z7cS7m#DoCFR=}WOwhOS3CjjbHed@>3?E<=*ppq*^d7W8kPL3k*fp1DXcMcxhwd>v& z_wC!ab^G@1;_Gb#6dyWSQ#P11%-ai4e*jP?>r+2Mx8g&;j97RUngK9#mD~VxjW%vX z!C-I+{x_V-WDde-T;1K>0s#9F{~Z_V7GGpx(i|v${boLOCji|M^85XZ(7;GGo4p^P zTCN9`NF*Ad?09|%pe}zLsJjLbQytVOKs~^k>gnkbk(0kj@n1!*0_9*$A*2rj)HQkP zt^&lwpimfJf>s^`C}#r{YfAj7=Zg8+IZyTV^$kr;O>Ka>>i{v;K@CAuhft~9(5Dc} zt@(U@AHcmEiA172_pSuQ1W-#bze@nMADVDq4T?3z%%%u{T7>qqOG`_WJnyar#MJO9 zM85+tKX=3Y_;VQpT3%jeO?jZHe_vTyS>-u*H6W(C`HesmhoC9pQ)tQO^KrP3Lu3DN z`SN8>wgn!4*8^f=P|(Z}qTIoFJnjOQp`jTh-KUUzk6}m>EE4#gs1$x>geu{{wr$%U z@9*zV;QF28$B$n|H~&|)+xp~nw~z+RM`m?zZ!ecy|DTEIe*yhVwVg5b_Q?PM002ov JPDHLkV1iC+HS_=g literal 0 HcmV?d00001 diff --git a/SourceCode/GPS/gStr.Designer.cs b/SourceCode/GPS/gStr.Designer.cs index 459e8067c..d530b38f8 100644 --- a/SourceCode/GPS/gStr.Designer.cs +++ b/SourceCode/GPS/gStr.Designer.cs @@ -375,6 +375,15 @@ public static string gsDeleteAppliedArea { } } + /// + /// Looks up a localized string similar to This action will delete all the boundaries. Do you want to continue?. + /// + public static string gsDeleteBoundaryMapping { + get { + return ResourceManager.GetString("gsDeleteBoundaryMapping", resourceCulture); + } + } + /// /// Looks up a localized string similar to Delete Contour Paths. /// diff --git a/SourceCode/GPS/gStr.af.resx b/SourceCode/GPS/gStr.af.resx index 6f1d5e465..7b1c76a40 100644 --- a/SourceCode/GPS/gStr.af.resx +++ b/SourceCode/GPS/gStr.af.resx @@ -222,6 +222,9 @@ zDelete Applied Area + + zThis action will delete all the boundaries. Do you want to continue? + zDelete Contour Paths diff --git a/SourceCode/GPS/gStr.hu.resx b/SourceCode/GPS/gStr.hu.resx index 9bc3fbd5b..d01bc795c 100644 --- a/SourceCode/GPS/gStr.hu.resx +++ b/SourceCode/GPS/gStr.hu.resx @@ -222,6 +222,9 @@ Megművelt terület (festés) törlése + + Ez a művelet törli a terület határait. Biztosan akarja? + Kontúrvonalak törlése diff --git a/SourceCode/GPS/gStr.resx b/SourceCode/GPS/gStr.resx index 66e17da39..4f871650a 100644 --- a/SourceCode/GPS/gStr.resx +++ b/SourceCode/GPS/gStr.resx @@ -222,6 +222,9 @@ Delete Applied Area + + This action will delete all the boundaries. Do you want to continue? + Delete Contour Paths