Commit 1592684e by 鲁志-悦动

Replay滑动条刻度变大 And 添加新窗口加号按钮

parent 1fd4c769
......@@ -119,6 +119,7 @@
<ItemGroup>
<Resource Include="Icons\ai_close_24x24.png" />
<Resource Include="Icons\ai_refresh_24x24.png" />
<Resource Include="Icons\ai_add_32x32.png" />
<Content Include="Icons\area_24x24.png" />
<Resource Include="Icons\area_over_24x24.png" />
<Resource Include="Icons\center_24x24.png" />
......
......@@ -368,25 +368,6 @@
Content="音视频停止命令"
Style="{StaticResource ButtonStyle}" />-->
<ToggleButton
Grid.Row="0"
Grid.Column="6"
Width="100"
Height="40"
Margin="0,10,0,0"
Content="Replay"
IsChecked="{Binding ReplayIsChecked, Mode=TwoWay}"
Style="{StaticResource ToggleButtonStyle}">
<b:Interaction.Triggers>
<b:EventTrigger EventName="Checked">
<b:InvokeCommandAction Command="{Binding ReplayCheckedCommand}" />
</b:EventTrigger>
<b:EventTrigger EventName="Unchecked">
<b:InvokeCommandAction Command="{Binding ReplayUncheckedCommand}" />
</b:EventTrigger>
</b:Interaction.Triggers>
</ToggleButton>
<CheckBox
Grid.Row="0"
Grid.Column="4"
......@@ -410,7 +391,7 @@
Content="Live"
Style="{StaticResource ButtonStyle}" />-->
<Button
<!--<Button
Grid.Row="0"
Grid.Column="5"
Width="100"
......@@ -418,7 +399,7 @@
Margin="10,10,0,0"
Command="{Binding Path=NewWindowCommand}"
Content="New Window"
Style="{StaticResource ButtonStyle}" />
Style="{StaticResource ButtonStyle}" />-->
<ToggleButton
Grid.Row="1"
......@@ -670,7 +651,7 @@
Content="发送"
Style="{StaticResource ButtonStyle}" />-->
<Button
<!--<Button
Grid.Row="3"
Grid.Column="1"
Width="100"
......@@ -690,11 +671,11 @@
Command="{Binding Path=OutPointCommand}"
Content="Out Point"
Style="{StaticResource ButtonStyle}"
Visibility="{Binding ReplaySendVisibility, Mode=TwoWay}" />
Visibility="{Binding ReplaySendVisibility, Mode=TwoWay}" />-->
<Button
Grid.Row="3"
Grid.Column="3"
Grid.Column="2"
Width="100"
Height="40"
Margin="10"
......@@ -705,7 +686,7 @@
<Button
Grid.Row="3"
Grid.Column="4"
Grid.Column="3"
Width="100"
Height="40"
Margin="10"
......@@ -714,11 +695,30 @@
Style="{StaticResource ButtonStyle}"
Visibility="{Binding ReplaySendVisibility, Mode=TwoWay}" />
<Button
<ToggleButton
Grid.Row="3"
Grid.Column="0"
Width="100"
Height="40"
Margin="0,10,0,0"
Content="Replay"
IsChecked="{Binding ReplayIsChecked, Mode=TwoWay}"
Style="{StaticResource ToggleButtonStyle}">
<b:Interaction.Triggers>
<b:EventTrigger EventName="Checked">
<b:InvokeCommandAction Command="{Binding ReplayCheckedCommand}" />
</b:EventTrigger>
<b:EventTrigger EventName="Unchecked">
<b:InvokeCommandAction Command="{Binding ReplayUncheckedCommand}" />
</b:EventTrigger>
</b:Interaction.Triggers>
</ToggleButton>
<Button
Grid.Row="3"
Grid.Column="1"
Width="100"
Height="40"
Margin="10"
Command="{Binding Path=CleanInPointCommand}"
Content="Clean Points"
......
......@@ -432,6 +432,21 @@
Grid.Row="1"
VerticalAlignment="Bottom"
Orientation="Vertical">
<!-- 新窗口 -->
<Border ToolTip="新窗口">
<Button
x:Name="_NewWindowBtn_"
Width="32"
Height="32"
Command="{Binding NewWindowCommand}"
Style="{StaticResource ButtonStyle}"
Visibility="Collapsed">
<Image
Width="24"
Height="24"
Source="/VIZ.FGOUT.Module.Resource;component/Icons/ai_add_32x32.png" />
</Button>
</Border>
<!-- 重启算法 -->
<Border ToolTip="重启算法">
<Button
......
......@@ -156,6 +156,33 @@ namespace VIZ.FGOUT.Module
{
//_DetectBtn_.Visibility =
_RestartBtn_.Visibility = _StopBtn_.Visibility = Visibility.Collapsed;
_NewWindowBtn_.Visibility = Visibility.Visible;
}
}
#endregion
#region IsCam4
public static readonly DependencyProperty IsCam4Property =
DependencyProperty.Register(nameof(IsCam4), typeof(bool), typeof(NDIView), new PropertyMetadata(false, OnIsCam4EnabledChanged));
public bool IsCam4
{
get => (bool)GetValue(IsCam4Property);
set => SetValue(IsCam4Property, value);
}
static void OnIsCam4EnabledChanged(DependencyObject sender, DependencyPropertyChangedEventArgs args)
{
((NDIView)sender).IsCam4EnabledChanged(args);
}
protected void IsCam4EnabledChanged(DependencyPropertyChangedEventArgs e)
{
if ((bool)e.NewValue)
{
_RestartBtn_.Visibility = _StopBtn_.Visibility = Visibility.Collapsed;
}
}
......
......@@ -3,9 +3,11 @@ using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using VIZ.FGOUT.Domain;
using VIZ.FGOUT.Module.SystemSetting.View;
using VIZ.FGOUT.Storage;
using VIZ.Framework.Common;
using VIZ.Framework.Core;
using VIZ.Framework.Domain;
namespace VIZ.FGOUT.Module
{
......@@ -354,6 +356,18 @@ namespace VIZ.FGOUT.Module
#endregion
#region NewWindowCommand -- 新窗口命令
public VCommand NewWindowCommand { get; set; }
private void NewWindow()
{
var newWindowModel = new NewWindowModel();
ApplicationDomain.MessageManager.Send(newWindowModel);
}
#endregion
#region RestartCommand -- 算法重启命令
/// <summary>
......
......@@ -285,8 +285,11 @@ namespace VIZ.FGOUT.Module
var view3 = this.FindChild<NDIView>(Application.Current.MainWindow, NDIViewKeys.cam3);
if (view3 != null)
{
//WPFHelper.Invoke(() =>
//{
// 更新视频流
view3.video.UpdateVideoFrame(dsExtend, true);
//});
// 更新视频控件跟踪框信息
if (_cam3Infos.Count > 0)
{
......@@ -314,7 +317,10 @@ namespace VIZ.FGOUT.Module
_cam3Infos.Add(view3.saveInfo);
}
}
//WPFHelper.Invoke(() =>
//{
view3.video.UpdateTrackingBox(_cam3Infos);
//});
}
}
}
......
......@@ -87,6 +87,7 @@ namespace VIZ.FGOUT.Module
this.SettingCommand = new VCommand<string>(this.Setting);
//目标检测命令
this.DetectCommand = new VCommand(this.Detect);
this.NewWindowCommand = new VCommand(this.NewWindow);
this.RestartCommand = new VCommand(this.Restart);
this.StopCommand = new VCommand(this.Stop);
this.IsBorderShowChangedCommand = new VCommand(this.IsBorderShowChanged);
......
......@@ -13,8 +13,8 @@
mc:Ignorable="d">
<Grid Background="#2C333B">
<local:NDIView
IsCam2="True"
IsCam4="True"
NDIKey="{x:Static Member=domain:NDIViewKeys.CAM_4}"
VideoBorderBrush="#B85069" />
VideoBorderBrush="red" />
</Grid>
</Window>
......@@ -14,7 +14,7 @@ namespace VIZ.FGOUT.Module
private static int _height = 30; // 高度
private static int _min = 0; // 最小值
private static int _max = 500; // 最大值
private static int _freq = 1; // 出现刻度的间距
private static int _freq = 10; // 出现刻度的间距
#endregion
......
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "B3844A2B1C255A8777FBAF2CF55118D580EB3828BE185CD94EF48DC215051450"
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "44D2D6FF666CA5C1C73C69DE4E677A39716FB44BF411BF5A33DE466303B66E9B"
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
......
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "B3844A2B1C255A8777FBAF2CF55118D580EB3828BE185CD94EF48DC215051450"
#pragma checksum "..\..\..\..\..\NDIMainView\View\NDIMainView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "44D2D6FF666CA5C1C73C69DE4E677A39716FB44BF411BF5A33DE466303B66E9B"
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
......
#pragma checksum "..\..\..\..\..\NDIView\View\NDIView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "568BA73618BA1F6479483D3784A685B7578E494CFE9DEEF6DFC5B9866AC947B6"
#pragma checksum "..\..\..\..\..\NDIView\View\NDIView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "18EC0AAB488F408F99345878E03BD10BC03FB9C42B926B3C11A07DBCD9CB00C5"
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
......@@ -94,13 +94,21 @@ namespace VIZ.FGOUT.Module {
#line 438 "..\..\..\..\..\NDIView\View\NDIView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button _NewWindowBtn_;
#line default
#line hidden
#line 453 "..\..\..\..\..\NDIView\View\NDIView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button _RestartBtn_;
#line default
#line hidden
#line 452 "..\..\..\..\..\NDIView\View\NDIView.xaml"
#line 467 "..\..\..\..\..\NDIView\View\NDIView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button _StopBtn_;
......@@ -177,9 +185,12 @@ namespace VIZ.FGOUT.Module {
this._Setting_ = ((System.Windows.Controls.Button)(target));
return;
case 6:
this._RestartBtn_ = ((System.Windows.Controls.Button)(target));
this._NewWindowBtn_ = ((System.Windows.Controls.Button)(target));
return;
case 7:
this._RestartBtn_ = ((System.Windows.Controls.Button)(target));
return;
case 8:
this._StopBtn_ = ((System.Windows.Controls.Button)(target));
return;
}
......
#pragma checksum "..\..\..\..\..\NDIView\View\NDIView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "568BA73618BA1F6479483D3784A685B7578E494CFE9DEEF6DFC5B9866AC947B6"
#pragma checksum "..\..\..\..\..\NDIView\View\NDIView.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "18EC0AAB488F408F99345878E03BD10BC03FB9C42B926B3C11A07DBCD9CB00C5"
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
......@@ -94,13 +94,21 @@ namespace VIZ.FGOUT.Module {
#line 438 "..\..\..\..\..\NDIView\View\NDIView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button _NewWindowBtn_;
#line default
#line hidden
#line 453 "..\..\..\..\..\NDIView\View\NDIView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button _RestartBtn_;
#line default
#line hidden
#line 452 "..\..\..\..\..\NDIView\View\NDIView.xaml"
#line 467 "..\..\..\..\..\NDIView\View\NDIView.xaml"
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
internal System.Windows.Controls.Button _StopBtn_;
......@@ -177,9 +185,12 @@ namespace VIZ.FGOUT.Module {
this._Setting_ = ((System.Windows.Controls.Button)(target));
return;
case 6:
this._RestartBtn_ = ((System.Windows.Controls.Button)(target));
this._NewWindowBtn_ = ((System.Windows.Controls.Button)(target));
return;
case 7:
this._RestartBtn_ = ((System.Windows.Controls.Button)(target));
return;
case 8:
this._StopBtn_ = ((System.Windows.Controls.Button)(target));
return;
}
......
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -10,11 +10,11 @@ none
false
DEBUG;TRACE
C:\Projects\FGOUT\VIZ.FGOUT\VIZ.FGOUT\App.xaml
21265083526
2-1347366880
6-790135758
421356718200
6968741766
43-1958993781
CloseAlgorithmWindow.xaml;MainWindow.xaml;
True
False
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