Commit c589ffb2 by 鲁志-悦动

主页面右下角功能区域垂直方向元素对齐 And 适配算法跟踪到人的数据 And 自动模式下发送标记判断开始标记由不少于2个改为不少于1个

parent 6243e93a
......@@ -37,5 +37,7 @@ namespace VIZ.FGOUT.Domain
/// </summary>
public long timecode { get; set; }
public string bbox_type { get; set; } = "detect";
}
}
......@@ -293,6 +293,45 @@ namespace VIZ.FGOUT.Module
if (info.TimeCode == dse.TimeStamp)
_cam3BInfos.Add(info);
}
#region 算法track到人的情况下跟踪框标红
var info2 = _cam3BInfos[0];
if (info2.BboxType.Equals("track"))
{
var gameName = ApplicationDomainEx.LiteDbContext.ViewConfig
.FindOne(p => p.ViewKey == NDIViewKeys.CAM_1).GameName;
//当双人3m跳水,双人10m跳水,双人速度攀岩时,保存2个入点框
if (gameName.Equals(SportsProjectCodes.SS) || gameName.Equals(SportsProjectCodes.ST) ||
gameName.Equals(SportsProjectCodes.SP))
{
_twoInfos = new List<TrackingBoxInfo>();
foreach (var saveInfo in _cam3BInfos)
{
//更新红色点中框
saveInfo.DrawingBorderColor = this.TRACKING_BOX_BORDER_COLOR;
//把选中框的信息也加到这个集合里
_cam3Infos.Add(saveInfo);
//记录标红框时入点时间戳
_RecordStartTime = saveInfo.TimeCode;
_twoInfos.Add(saveInfo);
}
}
else
{
//单人更新红色点中框
info2.DrawingBorderColor = this.TRACKING_BOX_BORDER_COLOR;
//把选中框的信息也加到这个集合里
_cam3Infos.Add(info2);
//记录标红框时入点时间戳
_RecordStartTime = info2.TimeCode;
_singleInfo = info2;
}
}
#endregion
}
//如果是Start滑块在动
......
using SharpDX.Mathematics.Interop;
using System;
using System.Collections.Generic;
using System.Linq;
using VIZ.FGOUT.Domain;
using VIZ.FGOUT.Storage;
using VIZ.Framework.Common;
......@@ -152,6 +151,7 @@ namespace VIZ.FGOUT.Module
// 检测框在显示目标框时显示,否则采用透明色
info.DrawingBorderColor = this.IsShowAlgorithmTargetBox ? this.DETECT_BOX_BORDER_COLOR : this.DETECT_BOX_BORDER_COLOR_TRANSPARENT;
info.TimeCode = msg.timecode;
info.BboxType = msg.bbox_type;
infos.Add(info);
if (!view.vm.IsReplay)
{
......
......@@ -260,6 +260,8 @@ namespace VIZ.FGOUT.Module
List<List<List<int>>> inPoints = new List<List<List<int>>>();
bool isInPoint = false;
//前三个手拖框、双人项目、单人项目都是判断是否有值
//手拖框
if (nDIView.rectsReplay.Count > 0 && nDIView.rectsReplay[0].Width > 0 && nDIView.rectsReplay[0].Height > 0)
{
......@@ -285,16 +287,36 @@ namespace VIZ.FGOUT.Module
}
}
//单人项目
else
//else
//{
// if(nDIView.saveInfo.SrcRect.Left > 0)
// {
// if (InPointIsMoved()) return; //入点和入点标记框位置不一致,返回
// inPoints = CoordinateTrackingBoxInfo(nDIView.saveInfo.SrcRect, srcWidth, srcHeight);
// isInPoint = true;
// }
//}
else if (nDIView.saveInfo.SrcRect.Left > 0)
{
if(nDIView.saveInfo.SrcRect.Left > 0)
{
if (InPointIsMoved()) return; //入点和入点标记框位置不一致,返回
inPoints = CoordinateTrackingBoxInfo(nDIView.saveInfo.SrcRect, srcWidth, srcHeight);
isInPoint = true;
}
if (InPointIsMoved()) return; //入点和入点标记框位置不一致,返回
inPoints = CoordinateTrackingBoxInfo(nDIView.saveInfo.SrcRect, srcWidth, srcHeight);
isInPoint = true;
}
#region 算法识别到人的情况下
else if (_twoInfos.Count > 0)
{
inPoints = CoordinateTrackingBoxInfos(_twoInfos, srcWidth, srcHeight);
isInPoint = true;
}
else if (_singleInfo.SrcRect.Left > 0)
{
inPoints = CoordinateTrackingBoxInfo(_singleInfo.SrcRect, srcWidth, srcHeight);
isInPoint = true;
}
#endregion
if (!isInPoint)
{
WPFHelper.BeginInvoke(() => { MessageBoxEx.ShowDialog("没有获取到入点跟踪框信息。"); });
......@@ -344,7 +366,10 @@ namespace VIZ.FGOUT.Module
//清除跟踪框的数据
ndiView.saveInfo = new TrackingBoxInfo();
ndiView.saveInfos = new List<TrackingBoxInfo>();
//清除跟踪框
_singleInfo = new TrackingBoxInfo();
_twoInfos = new List<TrackingBoxInfo>();
//清除跟踪框(没啥用)
//ndiView.video.ClearTrackingBox();
}
......@@ -444,6 +469,14 @@ namespace VIZ.FGOUT.Module
public static long _RecordStartTime;
#region Replay算法识别到人的情况下保存跟踪框信息
public static TrackingBoxInfo _singleInfo = new TrackingBoxInfo();
public static List<TrackingBoxInfo> _twoInfos = new List<TrackingBoxInfo>();
#endregion
/// <summary>
/// Replay选中和SliderValueChanged传值共用这一个方法
/// </summary>
......@@ -465,19 +498,37 @@ namespace VIZ.FGOUT.Module
// _autoSend_Timer.Stop();//自动发送计时器取消
//}
//else
if(!IsReplay)
//if(!IsReplay)
//{
// if(this.ViewKey == NDIViewKeys.CAM_3)
// {
// NDIView nDIView = this.GetView<NDIView>();
// if(nDIView == null) return;
// //清除拖框的数据
// nDIView.rectsReplay.Clear();
// nDIView.canvas1.Children.Clear();
// //清除跟踪框的数据
// nDIView.saveInfo = new TrackingBoxInfo();
// nDIView.saveInfos = new List<TrackingBoxInfo>();
// _singleInfo = new TrackingBoxInfo();
// _twoInfos = new List<TrackingBoxInfo>();
// }
//}
//当UnChecked时
if (!IsReplay && this.ViewKey == NDIViewKeys.CAM_3)
{
if(this.ViewKey == NDIViewKeys.CAM_3)
{
NDIView nDIView = this.GetView<NDIView>();
if(nDIView == null) return;
//清除拖框的数据
nDIView.rectsReplay.Clear();
nDIView.canvas1.Children.Clear();
//清除跟踪框的数据
nDIView.saveInfo = new TrackingBoxInfo();
nDIView.saveInfos = new List<TrackingBoxInfo>();
}
NDIView nDIView = this.GetView<NDIView>();
if (nDIView == null) return;
//清除拖框的数据
nDIView.rectsReplay.Clear();
nDIView.canvas1.Children.Clear();
//清除跟踪框的数据
nDIView.saveInfo = new TrackingBoxInfo();
nDIView.saveInfos = new List<TrackingBoxInfo>();
_singleInfo = new TrackingBoxInfo();
_twoInfos = new List<TrackingBoxInfo>();
}
}
......@@ -719,12 +770,12 @@ namespace VIZ.FGOUT.Module
});
return;
}
if (nDIView.polygonsStart.Count < 2)
if (nDIView.polygonsStart.Count < 1)
{
WPFHelper.BeginInvoke(() =>
{
MessageBoxEx.ShowDialog("开始标记不足2个," + message);
});
MessageBoxEx.ShowDialog("开始标记没有数据," + message);
});
return;
}
}
......
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "FECE7EC3BCF545ACA0597EA45D753BB9E33A03F9E1E228A91ECC7BFC72BC6952"
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "4BC8D1A0429685A17E6810578D9774A941940B15D2023C28322D103B8EDBFD70"
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
......@@ -66,7 +66,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 324 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 321 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.RadioButton _ManualMode_;
......@@ -74,7 +74,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 805 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 813 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox _AutoSendIntervalTime_;
......@@ -82,7 +82,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 943 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 959 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox _Matting_interval_;
......@@ -90,7 +90,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 968 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 988 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox _Moving_pixel_;
......@@ -98,7 +98,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 1341 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1397 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam1;
......@@ -106,7 +106,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 1526 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1582 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam2;
......@@ -114,7 +114,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 1541 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1597 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam3;
......@@ -173,7 +173,7 @@ namespace VIZ.FGOUT.Module {
case 3:
this._ManualMode_ = ((System.Windows.Controls.RadioButton)(target));
#line 328 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 325 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
this._ManualMode_.Click += new System.Windows.RoutedEventHandler(this.ManualMode_OnClick);
#line default
......@@ -182,7 +182,7 @@ namespace VIZ.FGOUT.Module {
case 4:
this._AutoSendIntervalTime_ = ((System.Windows.Controls.TextBox)(target));
#line 811 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 819 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
this._AutoSendIntervalTime_.PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.AutoSendIntervalTime_OnPreviewTextInput);
#line default
......@@ -191,7 +191,7 @@ namespace VIZ.FGOUT.Module {
case 5:
this._Matting_interval_ = ((System.Windows.Controls.TextBox)(target));
#line 947 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 962 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
this._Matting_interval_.PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.Matting_interval_OnPreviewTextInput);
#line default
......@@ -200,7 +200,7 @@ namespace VIZ.FGOUT.Module {
case 6:
this._Moving_pixel_ = ((System.Windows.Controls.TextBox)(target));
#line 972 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 991 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
this._Moving_pixel_.PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.Moving_pixel_OnPreviewTextInput);
#line default
......
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "FECE7EC3BCF545ACA0597EA45D753BB9E33A03F9E1E228A91ECC7BFC72BC6952"
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "4BC8D1A0429685A17E6810578D9774A941940B15D2023C28322D103B8EDBFD70"
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
......@@ -66,7 +66,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 324 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 321 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.RadioButton _ManualMode_;
......@@ -74,7 +74,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 805 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 813 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox _AutoSendIntervalTime_;
......@@ -82,7 +82,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 943 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 959 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox _Matting_interval_;
......@@ -90,7 +90,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 968 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 988 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.TextBox _Moving_pixel_;
......@@ -98,7 +98,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 1341 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1397 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam1;
......@@ -106,7 +106,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 1526 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1582 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam2;
......@@ -114,7 +114,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 1541 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1597 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam3;
......@@ -173,7 +173,7 @@ namespace VIZ.FGOUT.Module {
case 3:
this._ManualMode_ = ((System.Windows.Controls.RadioButton)(target));
#line 328 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 325 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
this._ManualMode_.Click += new System.Windows.RoutedEventHandler(this.ManualMode_OnClick);
#line default
......@@ -182,7 +182,7 @@ namespace VIZ.FGOUT.Module {
case 4:
this._AutoSendIntervalTime_ = ((System.Windows.Controls.TextBox)(target));
#line 811 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 819 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
this._AutoSendIntervalTime_.PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.AutoSendIntervalTime_OnPreviewTextInput);
#line default
......@@ -191,7 +191,7 @@ namespace VIZ.FGOUT.Module {
case 5:
this._Matting_interval_ = ((System.Windows.Controls.TextBox)(target));
#line 947 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 962 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
this._Matting_interval_.PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.Matting_interval_OnPreviewTextInput);
#line default
......@@ -200,7 +200,7 @@ namespace VIZ.FGOUT.Module {
case 6:
this._Moving_pixel_ = ((System.Windows.Controls.TextBox)(target));
#line 972 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 991 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
this._Moving_pixel_.PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.Moving_pixel_OnPreviewTextInput);
#line default
......
......@@ -10,11 +10,11 @@ none
false
DEBUG;TRACE
25-429057470
4-1529606353
98391250289
151915249285
25-1434354873
4-699044453
98-1634640143
151674092382
NDIMainView\View\NDIMainView.xaml;NDIPreviewView\View\NDIPreviewView.xaml;NDISettingView\View\AlgorithmSettingPanelView.xaml;NDISettingView\View\Algorithm\AlgorithmCablewayPanelView.xaml;NDISettingView\View\Algorithm\AlgorithmNearPanelView.xaml;NDISettingView\View\Algorithm\AlgorithmSinglePanelView.xaml;NDISettingView\View\Algorithm\AlgorithmSixteenPanelView.xaml;NDISettingView\View\Algorithm\AlgorithmTacticsPanelView.xaml;NDISettingView\View\NDISettingPanelView.xaml;NDISettingView\View\NDISettingView.xaml;NDIView\View\NDIView.xaml;SystemSetting\View\AboutPanelView.xaml;SystemSetting\View\CheckDataPanelView.xaml;SystemSetting\View\HotkeySettingPanelView.xaml;SystemSetting\View\LanguagePanelView.xaml;SystemSetting\View\MattingImagePanelView.xaml;SystemSetting\View\NewWindowView.xaml;SystemSetting\View\PackageSettingPanelView.xaml;SystemSetting\View\PreviewSettingPanelView.xaml;SystemSetting\View\ReplayPanelView.xaml;SystemSetting\View\StyleSettingPanelView.xaml;SystemSetting\View\SystemSettingView.xaml;SystemSetting\View\UEControlPanelView.xaml;SystemSetting\View\UESettingPanelView.xaml;Themes\SliderArrange.xaml;
True
False

C:\Projects\FGOUT\VIZ.FGOUT\VIZ.FGOUT.Module\obj\x64\Debug\GeneratedInternalTypeHelper.g.cs
FC:\Projects\FGOUT\VIZ.FGOUT\VIZ.FGOUT.Module\NDIMainView\View\NDIMainView.xaml;;
FC:\Projects\FGOUT\VIZ.FGOUT\VIZ.FGOUT.Module\NDIPreviewView\View\NDIPreviewView.xaml;;
......
......@@ -36,5 +36,7 @@ namespace VIZ.Framework.Common
/// 时间码
/// </summary>
public long TimeCode { get; set; }
public string BboxType { get; set; } = "detect";
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment