Commit a3583e62 by 鲁志-悦动

裁切框数据发送数据验证宽和高 And 间隔帧率、间隔像素互斥开始做

parent 6b9432ff
......@@ -10,7 +10,8 @@ namespace VIZ.FGOUT.Connection
public string type { get; set; }
public Point point { get; set; }
//public Point point { get; set; }
public int[] point { get; set; }
/// <summary>
/// 宽度
......
......@@ -268,6 +268,7 @@
Height="40"
Click="AutoMode_OnClick"
Content="{DynamicResource Auto}"
GroupName="_AutoOrManual_"
IsChecked="{Binding Path=IsAutoEnable, Mode=TwoWay}"
Style="{StaticResource RadioButton_NdiMainViewBlue}" />
......@@ -329,6 +330,7 @@
Height="40"
Click="ManualMode_OnClick"
Content="{DynamicResource Manual}"
GroupName="_AutoOrManual_"
IsChecked="{Binding Path=IsEnableTarget, Mode=TwoWay}"
Style="{StaticResource RadioButton_NdiMainViewBlue}" />
<!--<CheckBox
......@@ -947,13 +949,20 @@
Grid.Column="1"
HorizontalAlignment="Center"
Orientation="Horizontal">
<TextBlock
<!--<TextBlock
Margin="0,0,3,0"
HorizontalAlignment="Right"
VerticalAlignment="Center"
FontSize="14"
Foreground="White"
Text="{DynamicResource IntervalFrame}" />
Text="{DynamicResource IntervalFrame}" />-->
<RadioButton
Width="100"
Height="40"
Content="{DynamicResource IntervalFrame}"
GroupName="_FrameOrPixel_"
IsChecked="{Binding Path=IsIntervalFrame, Mode=TwoWay}"
Style="{StaticResource RadioButton_NdiMainViewBlue}" />
<TextBox
Width="57"
InputMethod.IsInputMethodEnabled="False"
......@@ -975,13 +984,20 @@
Grid.Column="2"
HorizontalAlignment="Center"
Orientation="Horizontal">
<TextBlock
<!--<TextBlock
Margin="0,0,3,0"
HorizontalAlignment="Right"
VerticalAlignment="Center"
FontSize="14"
Foreground="White"
Text="{DynamicResource IntervalPixel}" />
Text="{DynamicResource IntervalPixel}" />-->
<RadioButton
Width="100"
Height="40"
Content="{DynamicResource IntervalPixel}"
GroupName="_FrameOrPixel_"
IsChecked="{Binding Path=IsIntervalPixel, Mode=TwoWay}"
Style="{StaticResource RadioButton_NdiMainViewBlue}" />
<TextBox
Width="57"
InputMethod.IsInputMethodEnabled="False"
......
......@@ -36,7 +36,7 @@ namespace VIZ.FGOUT.Module
/// <param name="e"></param>
private void ManualMode_OnClick(object sender, RoutedEventArgs e)
{
_ManualMode_.IsChecked = true;
//_ManualMode_.IsChecked = true;
}
/// <summary>
......@@ -46,7 +46,7 @@ namespace VIZ.FGOUT.Module
/// <param name="e"></param>
private void AutoMode_OnClick(object sender, RoutedEventArgs e)
{
_AutoMode_.IsChecked = true;
//_AutoMode_.IsChecked = true;
}
private void OnPreviewTextInputCommon(object sender, TextCompositionEventArgs e)
......
......@@ -868,11 +868,15 @@ namespace VIZ.FGOUT.Module
isAutoEnable = value;
RaisePropertyChanged(nameof(IsAutoEnable));
//自动
if(value && !_flagAutoValue)
if (value)
{
_flagAutoValue = true;
_flagManualValue = false;
IsEnableTarget = false;
//if(value && !_flagAutoValue)
//{
// _flagAutoValue = true;
// _flagManualValue = false;
//IsEnableTarget = false;
IsStartImaget = false;
SendIsManual(AlgorithmPackageSignal.auto_mode);
manualConfig.IsManual = false;
......@@ -899,11 +903,15 @@ namespace VIZ.FGOUT.Module
isEnableTarget = value;
this.RaisePropertyChanged(nameof(IsEnableTarget));
//手动
if(value && !_flagManualValue)
if (value)
{
_flagAutoValue = false;
_flagManualValue = true;
IsAutoEnable = false;
//if(value && !_flagManualValue)
//{
// _flagAutoValue = false;
// _flagManualValue = true;
// IsAutoEnable = false;
SendIsManual(AlgorithmPackageSignal.manual_mode);
//manualConfig.IsManual = false;
manualConfig.IsManual = true;
......
......@@ -1216,11 +1216,22 @@ namespace VIZ.FGOUT.Module
int dx = Convert.ToInt32(rect.X / xp);
int dy = Convert.ToInt32(rect.Y / xy);
int width = Convert.ToInt32(rect.Width / xp);
//int height2 = Convert.ToInt32(rect.Height / xy);
if (width + dx > resWith)
{
width = resWith - dx;
}
int height = Convert.ToInt32(width * 9 / 16);
//int height2 = Convert.ToInt32(rect.Height / xy);
if (height + dy > resHeight)
{
height = resHeight - dy;
width = height * 16 / 9;
}
return new CutPackage() { point = new Point(dx, dy), width = width, height = height };
//return new CutPackage() { point = new Point(dx, dy), width = width, height = height };
return new CutPackage() { point = new int[]{dx, dy}, width = width, height = height };
}
private List<List<List<int>>> CoordinateTrackingBoxInfo(RawRectangleF rect, double srcWidth, double srcHeight)
......
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "72019AA88A2EFE0C59DFBF453A7E27C8FD19969111F82637DAEAAD62684F11D5"
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "15CC284A83D045D69995604731E50F83B95A9914DD5852260594F13D2AC94FF3"
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
......@@ -66,7 +66,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 326 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 327 "..\..\..\..\..\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 1436 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1452 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam1;
......@@ -82,7 +82,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 1621 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1637 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam2;
......@@ -90,7 +90,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 1636 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1652 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam3;
......@@ -149,7 +149,7 @@ namespace VIZ.FGOUT.Module {
case 3:
this._ManualMode_ = ((System.Windows.Controls.RadioButton)(target));
#line 330 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 331 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
this._ManualMode_.Click += new System.Windows.RoutedEventHandler(this.ManualMode_OnClick);
#line default
......@@ -157,7 +157,7 @@ namespace VIZ.FGOUT.Module {
return;
case 4:
#line 823 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 825 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
((System.Windows.Controls.TextBox)(target)).PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.OnPreviewTextInputCommon);
#line default
......@@ -165,7 +165,7 @@ namespace VIZ.FGOUT.Module {
return;
case 5:
#line 960 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 969 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
((System.Windows.Controls.TextBox)(target)).PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.OnPreviewTextInputCommon);
#line default
......@@ -173,7 +173,7 @@ namespace VIZ.FGOUT.Module {
return;
case 6:
#line 988 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1004 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
((System.Windows.Controls.TextBox)(target)).PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.OnPreviewTextInputCommon);
#line default
......@@ -181,7 +181,7 @@ namespace VIZ.FGOUT.Module {
return;
case 7:
#line 1016 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1032 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
((System.Windows.Controls.TextBox)(target)).PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.OnPreviewTextInputCommon);
#line default
......
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "72019AA88A2EFE0C59DFBF453A7E27C8FD19969111F82637DAEAAD62684F11D5"
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "15CC284A83D045D69995604731E50F83B95A9914DD5852260594F13D2AC94FF3"
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
......@@ -66,7 +66,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 326 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 327 "..\..\..\..\..\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 1436 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1452 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam1;
......@@ -82,7 +82,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 1621 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1637 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam2;
......@@ -90,7 +90,7 @@ namespace VIZ.FGOUT.Module {
#line hidden
#line 1636 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1652 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal VIZ.FGOUT.Module.NDIView cam3;
......@@ -149,7 +149,7 @@ namespace VIZ.FGOUT.Module {
case 3:
this._ManualMode_ = ((System.Windows.Controls.RadioButton)(target));
#line 330 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 331 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
this._ManualMode_.Click += new System.Windows.RoutedEventHandler(this.ManualMode_OnClick);
#line default
......@@ -157,7 +157,7 @@ namespace VIZ.FGOUT.Module {
return;
case 4:
#line 823 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 825 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
((System.Windows.Controls.TextBox)(target)).PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.OnPreviewTextInputCommon);
#line default
......@@ -165,7 +165,7 @@ namespace VIZ.FGOUT.Module {
return;
case 5:
#line 960 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 969 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
((System.Windows.Controls.TextBox)(target)).PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.OnPreviewTextInputCommon);
#line default
......@@ -173,7 +173,7 @@ namespace VIZ.FGOUT.Module {
return;
case 6:
#line 988 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1004 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
((System.Windows.Controls.TextBox)(target)).PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.OnPreviewTextInputCommon);
#line default
......@@ -181,7 +181,7 @@ namespace VIZ.FGOUT.Module {
return;
case 7:
#line 1016 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
#line 1032 "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml"
((System.Windows.Controls.TextBox)(target)).PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.OnPreviewTextInputCommon);
#line default
......
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