diff --git a/ISCamRecorder/CvCamera.cs b/ISCamRecorder/CvCamera.cs
index b19432f..3c27110 100644
--- a/ISCamRecorder/CvCamera.cs
+++ b/ISCamRecorder/CvCamera.cs
@@ -11,6 +11,10 @@
namespace ISCamRecorder {
+ ///
+ /// 撮影フレーム情報クラス
+ /// 撮影画像と撮影時間をペアで記録
+ ///
struct FrameInfo {
public DateTime FrameTime { get; private set; }
public Mat FrameImage { get; private set; }
@@ -21,7 +25,11 @@
}
}
- internal class CvCamera {
+ ///
+ /// 汎用カメラクラス
+ /// OpenCVカメラで撮影する
+ ///
+ class CvCamera {
VideoCapture camera = null; // カメラオブジェクト
bool _ExitSignal = false; // 終了シグナル
Bitmap[] _Buffer = new Bitmap[2]; // ダブルバッファ
@@ -68,6 +76,12 @@
if (camera != null) camera.Dispose();
}
+ ///
+ /// 記録データをファイルに保存
+ ///
+ ///
+ ///
+ ///
public void SaveToFile(string outDir, string imageType, string recTime) {
if (_RecFrames.Count < 1) return;
var CamID = "CvCam";
diff --git a/ISCamRecorder/MainForm.Designer.cs b/ISCamRecorder/MainForm.Designer.cs
index 6bcb7f1..24b8fa5 100644
--- a/ISCamRecorder/MainForm.Designer.cs
+++ b/ISCamRecorder/MainForm.Designer.cs
@@ -30,6 +30,8 @@
this.ChkTrigger = new System.Windows.Forms.CheckBox();
this.splitContainer1 = new System.Windows.Forms.SplitContainer();
this.splitContainer2 = new System.Windows.Forms.SplitContainer();
+ this.TxtCvCamera = new System.Windows.Forms.TextBox();
+ this.PicCvCamera = new System.Windows.Forms.PictureBox();
this.splitContainer3 = new System.Windows.Forms.SplitContainer();
this.TxtTop = new System.Windows.Forms.TextBox();
this.icTop = new TIS.Imaging.ICImagingControl();
@@ -59,8 +61,6 @@
this.label6 = new System.Windows.Forms.Label();
this.label7 = new System.Windows.Forms.Label();
this.CboImageType = new System.Windows.Forms.ComboBox();
- this.PicCvCamera = new System.Windows.Forms.PictureBox();
- this.TxtCvCamera = new System.Windows.Forms.TextBox();
((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit();
this.splitContainer1.Panel1.SuspendLayout();
this.splitContainer1.Panel2.SuspendLayout();
@@ -69,6 +69,7 @@
this.splitContainer2.Panel1.SuspendLayout();
this.splitContainer2.Panel2.SuspendLayout();
this.splitContainer2.SuspendLayout();
+ ((System.ComponentModel.ISupportInitialize)(this.PicCvCamera)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.splitContainer3)).BeginInit();
this.splitContainer3.Panel1.SuspendLayout();
this.splitContainer3.Panel2.SuspendLayout();
@@ -86,7 +87,6 @@
this.splitContainer5.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.icFront)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.icRight)).BeginInit();
- ((System.ComponentModel.ISupportInitialize)(this.PicCvCamera)).BeginInit();
this.SuspendLayout();
//
// BtnSetProperty
@@ -148,6 +148,30 @@
this.splitContainer2.SplitterDistance = 296;
this.splitContainer2.TabIndex = 0;
//
+ // TxtCvCamera
+ //
+ this.TxtCvCamera.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
+ | System.Windows.Forms.AnchorStyles.Right)));
+ this.TxtCvCamera.BackColor = System.Drawing.Color.SkyBlue;
+ this.TxtCvCamera.Location = new System.Drawing.Point(3, 3);
+ this.TxtCvCamera.Name = "TxtCvCamera";
+ this.TxtCvCamera.ReadOnly = true;
+ this.TxtCvCamera.Size = new System.Drawing.Size(290, 19);
+ this.TxtCvCamera.TabIndex = 3;
+ this.TxtCvCamera.Text = "追加カメラ";
+ //
+ // PicCvCamera
+ //
+ this.PicCvCamera.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.PicCvCamera.Location = new System.Drawing.Point(3, 28);
+ this.PicCvCamera.Name = "PicCvCamera";
+ this.PicCvCamera.Size = new System.Drawing.Size(290, 218);
+ this.PicCvCamera.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
+ this.PicCvCamera.TabIndex = 0;
+ this.PicCvCamera.TabStop = false;
+ //
// splitContainer3
//
this.splitContainer3.Dock = System.Windows.Forms.DockStyle.Fill;
@@ -408,7 +432,7 @@
this.TxtOutputDir.Name = "TxtOutputDir";
this.TxtOutputDir.Size = new System.Drawing.Size(206, 19);
this.TxtOutputDir.TabIndex = 13;
- this.TxtOutputDir.Text = "D:\\usr\\DL";
+ this.TxtOutputDir.Text = "D:\\Data";
//
// label3
//
@@ -507,30 +531,6 @@
this.CboImageType.TabIndex = 21;
this.CboImageType.Text = "JPG";
//
- // PicCvCamera
- //
- this.PicCvCamera.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.PicCvCamera.Location = new System.Drawing.Point(3, 28);
- this.PicCvCamera.Name = "PicCvCamera";
- this.PicCvCamera.Size = new System.Drawing.Size(290, 218);
- this.PicCvCamera.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
- this.PicCvCamera.TabIndex = 0;
- this.PicCvCamera.TabStop = false;
- //
- // TxtCvCamera
- //
- this.TxtCvCamera.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
- this.TxtCvCamera.BackColor = System.Drawing.Color.SkyBlue;
- this.TxtCvCamera.Location = new System.Drawing.Point(3, 3);
- this.TxtCvCamera.Name = "TxtCvCamera";
- this.TxtCvCamera.ReadOnly = true;
- this.TxtCvCamera.Size = new System.Drawing.Size(290, 19);
- this.TxtCvCamera.TabIndex = 3;
- this.TxtCvCamera.Text = "追加カメラ";
- //
// MainForm
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
@@ -571,6 +571,7 @@
this.splitContainer2.Panel2.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.splitContainer2)).EndInit();
this.splitContainer2.ResumeLayout(false);
+ ((System.ComponentModel.ISupportInitialize)(this.PicCvCamera)).EndInit();
this.splitContainer3.Panel1.ResumeLayout(false);
this.splitContainer3.Panel1.PerformLayout();
this.splitContainer3.Panel2.ResumeLayout(false);
@@ -593,7 +594,6 @@
this.splitContainer5.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.icFront)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.icRight)).EndInit();
- ((System.ComponentModel.ISupportInitialize)(this.PicCvCamera)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();