From 5b2a551b9a913754c37e6f9fd4600daeceb59e4f Mon Sep 17 00:00:00 2001 From: rainerosion Date: Fri, 13 Jan 2023 07:42:12 +0800 Subject: [PATCH] ui --- Tech.sln.DotSettings.user | 3 +- Tech/Form1.Designer.cs | 17 ++- Tech/Form1.cs | 6 + Tech/PlayerView.Designer.cs | 228 ++++++++++++++++++++++++++++++++---- Tech/PlayerView.cs | 44 +++++++ Tech/PlayerView.resx | 96 +++++++++++++++ Tech/UCOverview.Designer.cs | 2 +- 7 files changed, 365 insertions(+), 31 deletions(-) diff --git a/Tech.sln.DotSettings.user b/Tech.sln.DotSettings.user index 48e2470..0e59c12 100644 --- a/Tech.sln.DotSettings.user +++ b/Tech.sln.DotSettings.user @@ -1,6 +1,7 @@  True True - True + False True + False True \ No newline at end of file diff --git a/Tech/Form1.Designer.cs b/Tech/Form1.Designer.cs index 24cf6e1..46ddbf1 100644 --- a/Tech/Form1.Designer.cs +++ b/Tech/Form1.Designer.cs @@ -59,7 +59,7 @@ this.panel1.Dock = System.Windows.Forms.DockStyle.Left; this.panel1.Location = new System.Drawing.Point(0, 30); this.panel1.Name = "panel1"; - this.panel1.Size = new System.Drawing.Size(60, 520); + this.panel1.Size = new System.Drawing.Size(60, 670); this.panel1.TabIndex = 0; // // button4 @@ -70,7 +70,7 @@ this.button4.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.button4.ForeColor = System.Drawing.Color.White; this.button4.Image = ((System.Drawing.Image)(resources.GetObject("button4.Image"))); - this.button4.Location = new System.Drawing.Point(0, 462); + this.button4.Location = new System.Drawing.Point(0, 612); this.button4.Name = "button4"; this.button4.Size = new System.Drawing.Size(60, 58); this.button4.TabIndex = 4; @@ -131,7 +131,7 @@ this.panelContainer.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); this.panelContainer.Location = new System.Drawing.Point(60, 30); this.panelContainer.Name = "panelContainer"; - this.panelContainer.Size = new System.Drawing.Size(1098, 520); + this.panelContainer.Size = new System.Drawing.Size(1000, 670); this.panelContainer.TabIndex = 1; // // panel2 @@ -146,7 +146,7 @@ this.panel2.Dock = System.Windows.Forms.DockStyle.Top; this.panel2.Location = new System.Drawing.Point(0, 0); this.panel2.Name = "panel2"; - this.panel2.Size = new System.Drawing.Size(1158, 30); + this.panel2.Size = new System.Drawing.Size(1060, 30); this.panel2.TabIndex = 5; this.panel2.Paint += new System.Windows.Forms.PaintEventHandler(this.panel2_Paint); this.panel2.MouseDown += new System.Windows.Forms.MouseEventHandler(this.TopPanel_MouseDown); @@ -157,7 +157,7 @@ this.pictureBox4.ErrorImage = ((System.Drawing.Image)(resources.GetObject("pictureBox4.ErrorImage"))); this.pictureBox4.Image = ((System.Drawing.Image)(resources.GetObject("pictureBox4.Image"))); this.pictureBox4.InitialImage = ((System.Drawing.Image)(resources.GetObject("pictureBox4.InitialImage"))); - this.pictureBox4.Location = new System.Drawing.Point(1068, 0); + this.pictureBox4.Location = new System.Drawing.Point(970, 0); this.pictureBox4.Name = "pictureBox4"; this.pictureBox4.Padding = new System.Windows.Forms.Padding(8); this.pictureBox4.Size = new System.Drawing.Size(30, 30); @@ -172,7 +172,7 @@ this.pictureBox3.ErrorImage = ((System.Drawing.Image)(resources.GetObject("pictureBox3.ErrorImage"))); this.pictureBox3.Image = ((System.Drawing.Image)(resources.GetObject("pictureBox3.Image"))); this.pictureBox3.InitialImage = ((System.Drawing.Image)(resources.GetObject("pictureBox3.InitialImage"))); - this.pictureBox3.Location = new System.Drawing.Point(1098, 0); + this.pictureBox3.Location = new System.Drawing.Point(1000, 0); this.pictureBox3.Name = "pictureBox3"; this.pictureBox3.Padding = new System.Windows.Forms.Padding(8); this.pictureBox3.Size = new System.Drawing.Size(30, 30); @@ -187,7 +187,7 @@ this.closeBtn.ErrorImage = ((System.Drawing.Image)(resources.GetObject("closeBtn.ErrorImage"))); this.closeBtn.Image = ((System.Drawing.Image)(resources.GetObject("closeBtn.Image"))); this.closeBtn.InitialImage = ((System.Drawing.Image)(resources.GetObject("closeBtn.InitialImage"))); - this.closeBtn.Location = new System.Drawing.Point(1128, 0); + this.closeBtn.Location = new System.Drawing.Point(1030, 0); this.closeBtn.Name = "closeBtn"; this.closeBtn.Padding = new System.Windows.Forms.Padding(8); this.closeBtn.Size = new System.Drawing.Size(30, 30); @@ -196,7 +196,6 @@ this.closeBtn.TabStop = false; this.closeBtn.Click += new System.EventHandler(this.pictureBox2_Click); this.closeBtn.MouseLeave += new System.EventHandler(this.closeBtn_MouseLeave); - this.closeBtn.MouseHover += new System.EventHandler(this.closeBtn_MouseHover); this.closeBtn.MouseMove += new System.Windows.Forms.MouseEventHandler(this.closeBtn_MouseMove); // // label1 @@ -228,7 +227,7 @@ // this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None; this.BackColor = System.Drawing.Color.White; - this.ClientSize = new System.Drawing.Size(1158, 550); + this.ClientSize = new System.Drawing.Size(1060, 700); this.Controls.Add(this.panelContainer); this.Controls.Add(this.panel1); this.Controls.Add(this.panel2); diff --git a/Tech/Form1.cs b/Tech/Form1.cs index 938d329..3f5f919 100644 --- a/Tech/Form1.cs +++ b/Tech/Form1.cs @@ -43,6 +43,11 @@ namespace PlumByteUI_Learn private void button1_Click(object sender, EventArgs e) { var playerView = new PlayerView(); + playerView.Dock = DockStyle.Fill; + foreach (Control container in this.panelContainer.Controls) + { + container.Dispose(); + } this.panelContainer.Controls.Clear(); this.panelContainer.Controls.Add(playerView); } @@ -93,6 +98,7 @@ namespace PlumByteUI_Learn private void pictureBox3_Click(object sender, EventArgs e) { this.WindowState = this.WindowState == FormWindowState.Maximized ? FormWindowState.Normal : FormWindowState.Maximized; + this.panelContainer.Refresh(); } private void pictureBox4_Click(object sender, EventArgs e) diff --git a/Tech/PlayerView.Designer.cs b/Tech/PlayerView.Designer.cs index 2d2e097..1f92a6d 100644 --- a/Tech/PlayerView.Designer.cs +++ b/Tech/PlayerView.Designer.cs @@ -31,10 +31,19 @@ namespace PlumByteUI_Learn /// private void InitializeComponent() { + System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(PlayerView)); this.panel1 = new System.Windows.Forms.Panel(); - this.playBtn = new System.Windows.Forms.Button(); + this.button6 = new System.Windows.Forms.Button(); + this.button5 = new System.Windows.Forms.Button(); + this.button4 = new System.Windows.Forms.Button(); + this.button3 = new System.Windows.Forms.Button(); + this.button2 = new System.Windows.Forms.Button(); + this.button1 = new System.Windows.Forms.Button(); this.panel2 = new System.Windows.Forms.Panel(); this.vlcControl = new Vlc.DotNet.Forms.VlcControl(); + this.button7 = new System.Windows.Forms.Button(); + this.button8 = new System.Windows.Forms.Button(); + this.button9 = new System.Windows.Forms.Button(); this.panel1.SuspendLayout(); this.panel2.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.vlcControl)).BeginInit(); @@ -43,39 +52,150 @@ namespace PlumByteUI_Learn // panel1 // this.panel1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(46)))), ((int)(((byte)(57)))), ((int)(((byte)(75))))); - this.panel1.Controls.Add(this.playBtn); + this.panel1.Controls.Add(this.button9); + this.panel1.Controls.Add(this.button8); + this.panel1.Controls.Add(this.button7); + this.panel1.Controls.Add(this.button6); + this.panel1.Controls.Add(this.button5); + this.panel1.Controls.Add(this.button4); + this.panel1.Controls.Add(this.button3); + this.panel1.Controls.Add(this.button2); + this.panel1.Controls.Add(this.button1); this.panel1.Dock = System.Windows.Forms.DockStyle.Bottom; - this.panel1.Location = new System.Drawing.Point(0, 460); + this.panel1.Location = new System.Drawing.Point(0, 610); this.panel1.Name = "panel1"; - this.panel1.Size = new System.Drawing.Size(921, 90); + this.panel1.Size = new System.Drawing.Size(1000, 60); this.panel1.TabIndex = 1; // - // playBtn + // button6 // - this.playBtn.Location = new System.Drawing.Point(301, 39); - this.playBtn.Name = "playBtn"; - this.playBtn.Size = new System.Drawing.Size(75, 23); - this.playBtn.TabIndex = 0; - this.playBtn.Text = "button1"; - this.playBtn.UseVisualStyleBackColor = true; - this.playBtn.Click += new System.EventHandler(this.playBtn_Click); + this.button6.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); + this.button6.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(46)))), ((int)(((byte)(57)))), ((int)(((byte)(75))))); + this.button6.FlatAppearance.BorderSize = 0; + this.button6.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.button6.Font = new System.Drawing.Font("宋体", 7.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.button6.ForeColor = System.Drawing.Color.White; + this.button6.Image = ((System.Drawing.Image)(resources.GetObject("button6.Image"))); + this.button6.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft; + this.button6.Location = new System.Drawing.Point(12, 14); + this.button6.Name = "button6"; + this.button6.RightToLeft = System.Windows.Forms.RightToLeft.No; + this.button6.Size = new System.Drawing.Size(39, 40); + this.button6.TabIndex = 5; + this.button6.Text = "1号"; + this.button6.UseVisualStyleBackColor = false; + this.button6.Click += new System.EventHandler(this.button6_Click); + // + // button5 + // + this.button5.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); + this.button5.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(46)))), ((int)(((byte)(57)))), ((int)(((byte)(75))))); + this.button5.FlatAppearance.BorderSize = 0; + this.button5.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.button5.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.button5.ForeColor = System.Drawing.Color.White; + this.button5.Image = ((System.Drawing.Image)(resources.GetObject("button5.Image"))); + this.button5.ImageAlign = System.Drawing.ContentAlignment.TopCenter; + this.button5.Location = new System.Drawing.Point(773, 3); + this.button5.Name = "button5"; + this.button5.Size = new System.Drawing.Size(50, 57); + this.button5.TabIndex = 4; + this.button5.Text = "单画面"; + this.button5.TextAlign = System.Drawing.ContentAlignment.BottomCenter; + this.button5.UseVisualStyleBackColor = false; + this.button5.Click += new System.EventHandler(this.button5_Click); + // + // button4 + // + this.button4.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); + this.button4.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(46)))), ((int)(((byte)(57)))), ((int)(((byte)(75))))); + this.button4.FlatAppearance.BorderSize = 0; + this.button4.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.button4.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.button4.ForeColor = System.Drawing.Color.White; + this.button4.Image = ((System.Drawing.Image)(resources.GetObject("button4.Image"))); + this.button4.ImageAlign = System.Drawing.ContentAlignment.TopCenter; + this.button4.Location = new System.Drawing.Point(823, 3); + this.button4.Name = "button4"; + this.button4.Size = new System.Drawing.Size(62, 57); + this.button4.TabIndex = 3; + this.button4.Text = "复合画面"; + this.button4.TextAlign = System.Drawing.ContentAlignment.BottomCenter; + this.button4.UseVisualStyleBackColor = false; + this.button4.Click += new System.EventHandler(this.button4_Click); + // + // button3 + // + this.button3.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); + this.button3.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(46)))), ((int)(((byte)(57)))), ((int)(((byte)(75))))); + this.button3.FlatAppearance.BorderSize = 0; + this.button3.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.button3.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.button3.ForeColor = System.Drawing.Color.White; + this.button3.Image = ((System.Drawing.Image)(resources.GetObject("button3.Image"))); + this.button3.ImageAlign = System.Drawing.ContentAlignment.TopCenter; + this.button3.Location = new System.Drawing.Point(507, 0); + this.button3.Name = "button3"; + this.button3.Size = new System.Drawing.Size(47, 57); + this.button3.TabIndex = 2; + this.button3.Text = "抓拍"; + this.button3.TextAlign = System.Drawing.ContentAlignment.BottomCenter; + this.button3.UseVisualStyleBackColor = false; + // + // button2 + // + this.button2.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); + this.button2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(46)))), ((int)(((byte)(57)))), ((int)(((byte)(75))))); + this.button2.FlatAppearance.BorderSize = 0; + this.button2.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.button2.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.button2.ForeColor = System.Drawing.Color.White; + this.button2.Image = ((System.Drawing.Image)(resources.GetObject("button2.Image"))); + this.button2.ImageAlign = System.Drawing.ContentAlignment.TopCenter; + this.button2.Location = new System.Drawing.Point(454, 0); + this.button2.Name = "button2"; + this.button2.Size = new System.Drawing.Size(47, 57); + this.button2.TabIndex = 1; + this.button2.Text = "标记"; + this.button2.TextAlign = System.Drawing.ContentAlignment.BottomCenter; + this.button2.UseVisualStyleBackColor = false; + // + // button1 + // + this.button1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); + this.button1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(46)))), ((int)(((byte)(57)))), ((int)(((byte)(75))))); + this.button1.FlatAppearance.BorderSize = 0; + this.button1.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.button1.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.button1.ForeColor = System.Drawing.Color.White; + this.button1.Image = ((System.Drawing.Image)(resources.GetObject("button1.Image"))); + this.button1.ImageAlign = System.Drawing.ContentAlignment.TopCenter; + this.button1.Location = new System.Drawing.Point(401, 0); + this.button1.Name = "button1"; + this.button1.RightToLeft = System.Windows.Forms.RightToLeft.No; + this.button1.Size = new System.Drawing.Size(47, 57); + this.button1.TabIndex = 0; + this.button1.Text = "录制"; + this.button1.TextAlign = System.Drawing.ContentAlignment.BottomCenter; + this.button1.UseVisualStyleBackColor = false; + this.button1.Click += new System.EventHandler(this.button1_Click_1); // // panel2 // + this.panel2.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); this.panel2.Controls.Add(this.vlcControl); - this.panel2.Dock = System.Windows.Forms.DockStyle.Top; this.panel2.Location = new System.Drawing.Point(0, 0); this.panel2.Name = "panel2"; - this.panel2.Size = new System.Drawing.Size(921, 460); + this.panel2.Size = new System.Drawing.Size(1000, 610); this.panel2.TabIndex = 2; // // vlcControl // - this.vlcControl.Anchor = System.Windows.Forms.AnchorStyles.None; this.vlcControl.BackColor = System.Drawing.Color.WhiteSmoke; + this.vlcControl.Dock = System.Windows.Forms.DockStyle.Fill; this.vlcControl.Location = new System.Drawing.Point(0, 0); this.vlcControl.Name = "vlcControl"; - this.vlcControl.Size = new System.Drawing.Size(921, 460); + this.vlcControl.Size = new System.Drawing.Size(1000, 610); this.vlcControl.Spu = -1; this.vlcControl.TabIndex = 0; this.vlcControl.Text = "vlcControl1"; @@ -83,13 +203,67 @@ namespace PlumByteUI_Learn this.vlcControl.VlcMediaplayerOptions = null; this.vlcControl.VlcLibDirectoryNeeded += new System.EventHandler(this.vlcControl_VlcLibDirectoryNeeded); // + // button7 + // + this.button7.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); + this.button7.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(46)))), ((int)(((byte)(57)))), ((int)(((byte)(75))))); + this.button7.FlatAppearance.BorderSize = 0; + this.button7.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.button7.Font = new System.Drawing.Font("宋体", 7.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.button7.ForeColor = System.Drawing.Color.White; + this.button7.Image = ((System.Drawing.Image)(resources.GetObject("button7.Image"))); + this.button7.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft; + this.button7.Location = new System.Drawing.Point(57, 14); + this.button7.Name = "button7"; + this.button7.RightToLeft = System.Windows.Forms.RightToLeft.No; + this.button7.Size = new System.Drawing.Size(39, 40); + this.button7.TabIndex = 6; + this.button7.Text = "2号"; + this.button7.UseVisualStyleBackColor = false; + // + // button8 + // + this.button8.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); + this.button8.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(46)))), ((int)(((byte)(57)))), ((int)(((byte)(75))))); + this.button8.FlatAppearance.BorderSize = 0; + this.button8.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.button8.Font = new System.Drawing.Font("宋体", 7.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.button8.ForeColor = System.Drawing.Color.White; + this.button8.Image = ((System.Drawing.Image)(resources.GetObject("button8.Image"))); + this.button8.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft; + this.button8.Location = new System.Drawing.Point(102, 14); + this.button8.Name = "button8"; + this.button8.RightToLeft = System.Windows.Forms.RightToLeft.No; + this.button8.Size = new System.Drawing.Size(39, 40); + this.button8.TabIndex = 7; + this.button8.Text = "3号"; + this.button8.UseVisualStyleBackColor = false; + // + // button9 + // + this.button9.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); + this.button9.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(46)))), ((int)(((byte)(57)))), ((int)(((byte)(75))))); + this.button9.FlatAppearance.BorderSize = 0; + this.button9.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.button9.Font = new System.Drawing.Font("宋体", 7.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.button9.ForeColor = System.Drawing.Color.White; + this.button9.Image = ((System.Drawing.Image)(resources.GetObject("button9.Image"))); + this.button9.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft; + this.button9.Location = new System.Drawing.Point(147, 14); + this.button9.Name = "button9"; + this.button9.RightToLeft = System.Windows.Forms.RightToLeft.No; + this.button9.Size = new System.Drawing.Size(39, 40); + this.button9.TabIndex = 8; + this.button9.Text = "4号"; + this.button9.UseVisualStyleBackColor = false; + // // PlayerView // - this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None; + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Inherit; this.Controls.Add(this.panel2); this.Controls.Add(this.panel1); this.Name = "PlayerView"; - this.Size = new System.Drawing.Size(921, 550); + this.Size = new System.Drawing.Size(1000, 670); this.Load += new System.EventHandler(this.PlayerView_Load); this.panel1.ResumeLayout(false); this.panel2.ResumeLayout(false); @@ -97,12 +271,26 @@ namespace PlumByteUI_Learn this.ResumeLayout(false); } + private System.Windows.Forms.Button button7; + private System.Windows.Forms.Button button8; + private System.Windows.Forms.Button button9; + + private System.Windows.Forms.Button button6; + + private System.Windows.Forms.Button button5; + + private System.Windows.Forms.Button button4; + + private System.Windows.Forms.Button button3; + + private System.Windows.Forms.Button button2; + + private System.Windows.Forms.Button button1; + private Vlc.DotNet.Forms.VlcControl vlcControl; private System.Windows.Forms.Panel panel2; - private System.Windows.Forms.Button playBtn; - private System.Windows.Forms.Panel panel1; #endregion diff --git a/Tech/PlayerView.cs b/Tech/PlayerView.cs index e44aae3..5d2adfa 100644 --- a/Tech/PlayerView.cs +++ b/Tech/PlayerView.cs @@ -70,5 +70,49 @@ namespace PlumByteUI_Learn vlcControl.Play(videoUri, options); Console.WriteLine("播放rtsp视频"); } + + private void button1_Click(object sender, EventArgs e) + { + // this.vlcControl.Dock = DockStyle.Left; + // this.vlcControl.Width = this.panel2.Width / 3 * 2; + // if (this.panel2.Controls.Count == 1) + // { + // var ucOverview = new UCOverview(); + // ucOverview.Dock = DockStyle.Right; + // ucOverview.Width = this.panel2.Width / 3 * 1; + // this.panel2.Controls.Add(ucOverview); + // + // } + this.panel2.Refresh(); + Console.WriteLine("按钮被点击了"); + } + + private void button1_Click_1(object sender, EventArgs e) + { + + } + + private void button4_Click(object sender, EventArgs e) + { + throw new System.NotImplementedException(); + } + + private void button5_Click(object sender, EventArgs e) + { + throw new System.NotImplementedException(); + } + + private void button6_Click(object sender, EventArgs e) + { + string[] options = { ":network-caching=10", ":rtsp-tcp"};// { ":network-caching=100", ":rtsp -tcp", ":no-audio" }; // --avcodec-hw={any,d3d11va,dxva2,none} + var videoUri = new Uri(@"rtsp://127.0.0.1:8554/rains"); + vlcControl.Play(videoUri, options); + Console.WriteLine("播放rtsp视频"); + } + + private void vlcControl_Click_1(object sender, EventArgs e) + { + throw new System.NotImplementedException(); + } } } \ No newline at end of file diff --git a/Tech/PlayerView.resx b/Tech/PlayerView.resx index 1af7de1..44cc32a 100644 --- a/Tech/PlayerView.resx +++ b/Tech/PlayerView.resx @@ -117,4 +117,100 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + + iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAMpJREFUWEdj + GAWjYBT8//+/AYj3AzEtAMjcBqhV2AFQwRWwUtqBK1CrsAOoIhDQggpRBYDMgxj7/z9UCDuAqsGviEwA + NRpuNpDJC8TFQHwUiM8DsRFdHAAEckA8FYjfg3kIcJteDkAG14EYlPDBgJ4O2AjEgVAphL1QmtYOMIUK + wQFUnD4OgHJRAFRq1AEjxAFAMLCJEAoGNBsigwEpiKSAuB6I34B5CECfohjKBfG5gDgbiDErIyAYsOp4 + wBskA9skGwWjYIQDBgYA0e6AMEO35ngAAAAASUVORK5CYII= + + + + + iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAMpJREFUWEdj + GAWjYBT8//+/AYj3AzEtAMjcBqhV2AFQwRWwUtqBK1CrsAOoIhDQggpRBYDMgxj7/z9UCDuAqsGviEwA + NRpuNpDJC8TFQHwUiM8DsRFdHAAEckA8FYjfg3kIcJteDkAG14EYlPDBgJ4O2AjEgVAphL1QmtYOMIUK + wQFUnD4OgHJRAFRq1AEjxAFAMLCJEAoGNBsigwEpiKSAuB6I34B5CECfohjKBfG5gDgbiDErIyAYsOp4 + wBskA9skGwWjYIQDBgYA0e6AMEO35ngAAAAASUVORK5CYII= + + + + + iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAMpJREFUWEdj + GAWjYBT8//+/AYj3AzEtAMjcBqhV2AFQwRWwUtqBK1CrsAOoIhDQggpRBYDMgxj7/z9UCDuAqsGviEwA + NRpuNpDJC8TFQHwUiM8DsRFdHAAEckA8FYjfg3kIcJteDkAG14EYlPDBgJ4O2AjEgVAphL1QmtYOMIUK + wQFUnD4OgHJRAFRq1AEjxAFAMLCJEAoGNBsigwEpiKSAuB6I34B5CECfohjKBfG5gDgbiDErIyAYsOp4 + wBskA9skGwWjYIQDBgYA0e6AMEO35ngAAAAASUVORK5CYII= + + + + + iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAMpJREFUWEdj + GAWjYBT8//+/AYj3AzEtAMjcBqhV2AFQwRWwUtqBK1CrsAOoIhDQggpRBYDMgxj7/z9UCDuAqsGviEwA + NRpuNpDJC8TFQHwUiM8DsRFdHAAEckA8FYjfg3kIcJteDkAG14EYlPDBgJ4O2AjEgVAphL1QmtYOMIUK + wQFUnD4OgHJRAFRq1AEjxAFAMLCJEAoGNBsigwEpiKSAuB6I34B5CECfohjKBfG5gDgbiDErIyAYsOp4 + wBskA9skGwWjYIQDBgYA0e6AMEO35ngAAAAASUVORK5CYII= + + + + + iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAEtJREFUWEft + zrEVACAIxFD2X1qbbCAoPJOOhvth61HMNwJwlsdcYwBnerwfBOA8jncCBAgQIEDAQEB2vB8AqI65hoDb + Md8AYJ8XsQEeCXrMMcQfZQAAAABJRU5ErkJggg== + + + + + iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAaNJREFUWEft + lzFLw1AUhTs6isW9i7+gox1cdRAROjgIncXBn9DfIDiIQ3FxEB0UnLupQ0EEB6FIJhdH/0A897yTx2ss + bdI0xkI/OJB7b+67p2kS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yB9NhGk+d5ZKp2ArSZWbLMZEuANjVLoKP2HjQ5VCIjtROg + bc2SZStbArSRWQI9tfewaVpgqHYCND7zEhvZEqDxyI5kP4B/BM9qJ0Dj5itR3IzQOC8i2UfgN+FK7Szy + JEjOAtkPq/zdAYKf9cWhQ6BzM3I/sIqbjzALFVmonQKRl4nIk9oXwyyLDIzVToFYPYprT8ASzLCowPGj + mMDgh9G72o1hhkUFjg8jAhPHsb8FXWscM7PeFQ1GXsU8HKm1JyO9WuM572qGBbkrGadacUhRk6dKs28R + C3k187ejCAcLz3Yeryy+9sMmwrX1rmIlEPB713IPwvhc+Vj8naEKNXqu98ckB97g5/+a/VFarU+MaQYc + sop2UgAAAABJRU5ErkJggg== + + \ No newline at end of file diff --git a/Tech/UCOverview.Designer.cs b/Tech/UCOverview.Designer.cs index 4c15e91..ef986c6 100644 --- a/Tech/UCOverview.Designer.cs +++ b/Tech/UCOverview.Designer.cs @@ -151,7 +151,7 @@ // // UCOverview // - this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None; + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Inherit; this.BackColor = System.Drawing.Color.White; this.Controls.Add(this.button4); this.Controls.Add(this.button2);