This commit is contained in:
EgorBo 2018-03-02 18:49:13 +03:00
Родитель 8c175ad45b
Коммит 4c839a52dc
7 изменённых файлов: 19 добавлений и 32 удалений

Просмотреть файл

@ -27,7 +27,7 @@ namespace Urho
LastUsedOptions = this;
}
public ApplicationOptions() {}
public ApplicationOptions() : this(null) {}
/// <summary>
/// Desktop only

8
MakeWindowsAll.bat Normal file
Просмотреть файл

@ -0,0 +1,8 @@
set "CONFIG=%~1"
if NOT "%CONFIG%" == "Debug" (set "CONFIG=Release")
call MakeWindows.bat x64 %CONFIG% 2017 OpenGL
call MakeWindows.bat x86 %CONFIG% 2017 OpenGL
call MakeWindows.bat x64 %CONFIG% 2017 DirectX
call MakeWindows.bat x86 %CONFIG% 2017 DirectX

Просмотреть файл

@ -17,9 +17,10 @@ namespace Playgrounds.Console
public static void RunApp()
{
var app = new EarthDemo(
new ApplicationOptions(@"..\..\..\..\..\Samples\HoloLens\02_HelloWorldAdvanced\Data") {
new ApplicationOptions(@"..\..\Samples\HoloLens\02_HelloWorldAdvanced\Data") {
Width = 960,
Height = 720
Height = 720,
UseDirectX11 = false
});
app.Run();
}

Просмотреть файл

@ -17,7 +17,7 @@
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<OutputPath>..\..\..\Bin\Desktop\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
@ -27,7 +27,7 @@
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<OutputPath>..\..\..\Bin\Desktop\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
@ -76,18 +76,6 @@
<ItemGroup>
<Folder Include="HoloScene\Data\" />
</ItemGroup>
<ItemGroup Condition="Exists('..\..\..\Bin\Desktop\Win32\mono-urho-d3d.dll')">
<Content Include="..\..\..\Bin\Desktop\Win32\mono-urho-d3d.dll">
<Link>mono-urho-d3d.dll</Link>
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
</ItemGroup>
<ItemGroup Condition="Exists('..\..\..\Bin\Desktop\Win32\mono-urho.dll')">
<Content Include="..\..\..\Bin\Desktop\Win32\mono-urho.dll">
<Link>mono-urho.dll</Link>
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.

Просмотреть файл

@ -14,7 +14,7 @@ namespace Playgrounds.WinForms
async void restartButton_Click(object sender, EventArgs e)
{
game = await urhoSurface.Show<Game>(new Urho.ApplicationOptions());
game = await urhoSurface.Show<Game>(new Urho.ApplicationOptions() { UseDirectX11 = true });
if (game.IsActive) //in case if user clicks "restart" too quickly
game.Viewport.SetClearColor(Urho.Extensions.WinForms.UrhoSurface.ConvertColor(urhoSurface.BackColor));
}

Просмотреть файл

@ -17,7 +17,7 @@
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<OutputPath>..\..\..\Bin\Desktop\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
@ -26,7 +26,7 @@
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<OutputPath>..\..\..\Bin\Desktop\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
@ -89,22 +89,12 @@
<Name>Urho.Extensions.WinForms</Name>
</ProjectReference>
</ItemGroup>
<ItemGroup Condition="Exists('..\..\..\Bin\Desktop\Win32\mono-urho.dll')">
<None Include="..\..\..\Bin\Desktop\Win32\mono-urho.dll">
<Link>mono-urho.dll</Link>
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
<ItemGroup>
<None Include="..\..\..\Urho3D\CoreData.pak">
<Link>CoreData.pak</Link>
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>
<ItemGroup Condition="Exists('..\..\..\Bin\Desktop\Win32\mono-urho-d3d.dll')">
<None Include="..\..\..\Bin\Desktop\Win32\mono-urho-d3d.dll">
<Link>mono-urho.dll</Link>
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.

Просмотреть файл

@ -17,7 +17,7 @@ namespace Playgrounds.Wpf
async void RestartBtn_Click(object sender, RoutedEventArgs e)
{
app = await UrhoSurface.Show<Game>(new Urho.ApplicationOptions());
app = await UrhoSurface.Show<Game>(new Urho.ApplicationOptions() { UseDirectX11 = true });
if (app.IsActive) //in case if user clicks "restart" too quickly
app.Viewport.SetClearColor(Urho.Extensions.Wpf.UrhoSurface.ConvertColor(((SolidColorBrush)Background).Color));
}