Skip to content

Commit

Permalink
fix demos
Browse files Browse the repository at this point in the history
  • Loading branch information
YukinoHayakawa committed Oct 11, 2021
1 parent 095412c commit b8b704e
Show file tree
Hide file tree
Showing 13 changed files with 199 additions and 220 deletions.
7 changes: 5 additions & 2 deletions DemoEcsFireworks/DemoEcsFireworks.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,10 @@
<ProjectReference Include="..\..\Library\Usagi\Usagi.vcxproj">
<Project>{f9061c06-bce6-416b-9aeb-31351810b7ba}</Project>
</ProjectReference>
<ProjectReference Include="..\..\Modules\Usagi\Modules\Common\Executive\Executive.vcxproj">
<ProjectReference Include="..\..\Modules\Usagi\Modules\Common\Logging\Logging.vcxproj">
<Project>{e13613a3-b719-4bc5-991a-507402d14c25}</Project>
</ProjectReference>
<ProjectReference Include="..\..\Modules\Usagi\Modules\Runtime\Executive\Executive.vcxproj">
<Project>{345cdbb7-1ec3-4e1c-ad4f-856a774430f5}</Project>
</ProjectReference>
<ProjectReference Include="..\..\Modules\Usagi\Modules\Common\Math\Math.vcxproj">
Expand All @@ -100,4 +103,4 @@
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
</Project>
10 changes: 2 additions & 8 deletions DemoEcsFireworks/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,14 @@
// some distance and explode. The sparks fly away from the explosion center
// and gradually disappear.

#ifdef _DEBUG
#pragma comment(lib, "fmtd.lib")
#else
#pragma comment(lib, "fmt.lib")
#endif

// #define NDEBUG

// #define Service_master_clock___ Service_master_clock_default
// #define Service_graphics_gdi___ Service_graphics_gdi
// #define Service_stat___ Service_stat
// #define Service_content_update_flag___ Service_content_update_flag
#include <Usagi/Modules/Common/Executive/SystemTaskList.hpp>
#include <Usagi/Modules/Common/Executive/AppHost.hpp>
#include <Usagi/Modules/Runtime/Executive/SystemTaskList.hpp>
#include <Usagi/Modules/Runtime/Executive/AppHost.hpp>

#include "System_fireworks_spawn.hpp"
#include "System_fireworks_explode.hpp"
Expand Down
2 changes: 1 addition & 1 deletion DemoGraphicsInit/DemoGraphicsInit.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
<ProjectReference Include="..\..\Modules\Usagi\Modules\Platforms\Win10\Win10.vcxproj">
<Project>{ba6b6731-dfa8-4da0-b121-d3d8d584b001}</Project>
</ProjectReference>
<ProjectReference Include="..\..\Modules\Usagi\Modules\Services\Graphics\Graphics.vcxproj">
<ProjectReference Include="..\..\Modules\Usagi\Modules\IO\Graphics\Graphics.vcxproj">
<Project>{5ae8f2da-6b3e-4492-a009-112a62b056be}</Project>
</ProjectReference>
</ItemGroup>
Expand Down
4 changes: 0 additions & 4 deletions DemoGraphicsInit/SystemInitGraphicsService.hpp
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
#pragma once

#include <Usagi/Entity/EntityDatabase.hpp>
#include <Usagi/Modules/Common/Color/Color.hpp>
#include <Usagi/Runtime/Service/Service.hpp>
#include <Usagi/Runtime/Service/LazyInitService.hpp>

#include <Usagi/Modules/Platforms/Vulkan/VulkanGpuDevice.hpp>
#include <Usagi/Modules/Services/Graphics/Enum.hpp>
#include <Usagi/Modules/Services/Windowing/ServiceNativeWindowManager.hpp>

namespace usagi
{
Expand Down
22 changes: 7 additions & 15 deletions DemoGraphicsInit/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,24 +3,16 @@

#define _CRT_SECURE_NO_WARNINGS

// #define NDEBUG

#ifdef _DEBUG
#pragma comment(lib, "fmtd.lib")
#else
#pragma comment(lib, "fmt.lib")
#endif

#include <fmt/ostream.h>

#include <Usagi/Modules/Common/Executive/AppHost.hpp>
#include <Usagi/Modules/Common/Executive/SystemTaskList.hpp>
#include <Usagi/Modules/Runtime/Executive/AppHost.hpp>
#include <Usagi/Modules/Runtime/Executive/SystemTaskList.hpp>
#include <Usagi/Modules/Common/Math/ComponentRegion2D.hpp>
#include <Usagi/Modules/Services/Input/InputEventQueue.hpp>
#include <Usagi/Modules/Services/Input/SystemInputEventPump.hpp>
#include <Usagi/Modules/Services/Windowing/ComponentNativeWindow.hpp>
#include <Usagi/Modules/Services/Windowing/ServiceNativeWindowManager.hpp>
#include <Usagi/Modules/Services/Windowing/SystemNativeWindowCoordinator.hpp>
#include <Usagi/Modules/IO/Input/InputEventQueue.hpp>
#include <Usagi/Modules/IO/Input/SystemInputEventPump.hpp>
#include <Usagi/Modules/IO/Windowing/ComponentNativeWindow.hpp>
#include <Usagi/Modules/IO/Windowing/ServiceNativeWindowManager.hpp>
#include <Usagi/Modules/IO/Windowing/SystemNativeWindowCoordinator.hpp>

#include <Usagi/Modules/Platforms/WinCommon/Input/InputEventSourceWin32RawInput.hpp>
#include <Usagi/Modules/Platforms/WinCommon/Windowing/NativeWindowManagerWin32.hpp>
Expand Down
2 changes: 1 addition & 1 deletion DemoHelloSwapchain/DemoHelloSwapchain.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
<ProjectReference Include="..\..\Modules\Usagi\Modules\Platforms\Win10\Win10.vcxproj">
<Project>{ba6b6731-dfa8-4da0-b121-d3d8d584b001}</Project>
</ProjectReference>
<ProjectReference Include="..\..\Modules\Usagi\Modules\Services\Graphics\Graphics.vcxproj">
<ProjectReference Include="..\..\Modules\Usagi\Modules\IO\Graphics\Graphics.vcxproj">
<Project>{5ae8f2da-6b3e-4492-a009-112a62b056be}</Project>
</ProjectReference>
</ItemGroup>
Expand Down
4 changes: 2 additions & 2 deletions DemoHelloSwapchain/SystemClearSwapchainImage.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
#include <Usagi/Runtime/Service/LazyInitService.hpp>

#include <Usagi/Modules/Platforms/Vulkan/VulkanGpuDevice.hpp>
#include <Usagi/Modules/Services/Graphics/Enum.hpp>
#include <Usagi/Modules/Services/Windowing/ServiceNativeWindowManager.hpp>
#include <Usagi/Modules/IO/Graphics/Enum.hpp>
#include <Usagi/Modules/IO/Windowing/ServiceNativeWindowManager.hpp>

#include "ServiceColorChoice.hpp"

Expand Down
14 changes: 7 additions & 7 deletions DemoHelloSwapchain/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@

#include <fmt/ostream.h>

#include <Usagi/Modules/Common/Executive/AppHost.hpp>
#include <Usagi/Modules/Common/Executive/SystemTaskList.hpp>
#include <Usagi/Modules/Runtime/Executive/AppHost.hpp>
#include <Usagi/Modules/Runtime/Executive/SystemTaskList.hpp>
#include <Usagi/Modules/Common/Math/ComponentRegion2D.hpp>
#include <Usagi/Modules/Services/Input/InputEventQueue.hpp>
#include <Usagi/Modules/Services/Input/SystemInputEventPump.hpp>
#include <Usagi/Modules/Services/Windowing/ComponentNativeWindow.hpp>
#include <Usagi/Modules/Services/Windowing/ServiceNativeWindowManager.hpp>
#include <Usagi/Modules/Services/Windowing/SystemNativeWindowCoordinator.hpp>
#include <Usagi/Modules/IO/Input/InputEventQueue.hpp>
#include <Usagi/Modules/IO/Input/SystemInputEventPump.hpp>
#include <Usagi/Modules/IO/Windowing/ComponentNativeWindow.hpp>
#include <Usagi/Modules/IO/Windowing/ServiceNativeWindowManager.hpp>
#include <Usagi/Modules/IO/Windowing/SystemNativeWindowCoordinator.hpp>

#include <Usagi/Modules/Platforms/WinCommon/Input/InputEventSourceWin32RawInput.hpp>
#include <Usagi/Modules/Platforms/WinCommon/Windowing/NativeWindowManagerWin32.hpp>
Expand Down
4 changes: 2 additions & 2 deletions DemoScripting/DemoScripting.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -64,11 +64,11 @@
<ProjectReference Include="..\..\Modules\Usagi\Modules\Common\Logging\Logging.vcxproj">
<Project>{e13613a3-b719-4bc5-991a-507402d14c25}</Project>
</ProjectReference>
<ProjectReference Include="..\..\Modules\Usagi\Modules\Common\ProgramModule\ProgramModule.vcxproj">
<ProjectReference Include="..\..\Modules\Usagi\Modules\Runtime\ProgramModule\ProgramModule.vcxproj">
<Project>{e5b7e645-8062-4b01-af1c-cf462b608a6b}</Project>
</ProjectReference>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
</Project>
4 changes: 2 additions & 2 deletions DemoScripting/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@

#include <fmt/ostream.h>

#include <Usagi/Modules/Common/ProgramModule/ClangJIT.hpp>
#include <Usagi/Modules/Common/ProgramModule/RuntimeModule.hpp>
#include <Usagi/Modules/Runtime/ProgramModule/ClangJIT.hpp>
#include <Usagi/Modules/Runtime/ProgramModule/RuntimeModule.hpp>

using namespace usagi;

Expand Down
159 changes: 79 additions & 80 deletions DemoSudokuSolver/DemoSudokuSolver.vcxproj
Original file line number Diff line number Diff line change
@@ -1,81 +1,80 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<ItemGroup>
<ClCompile Include="gui.cpp" />
<ClCompile Include="imgui-master\examples\imgui_impl_glfw.cpp" />
<ClCompile Include="imgui-master\examples\imgui_impl_opengl2.cpp" />
<ClCompile Include="imgui-master\imgui.cpp" />
<ClCompile Include="imgui-master\imgui_demo.cpp" />
<ClCompile Include="imgui-master\imgui_draw.cpp" />
<ClCompile Include="imgui-master\imgui_widgets.cpp" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="imgui-master\examples\imgui_impl_opengl2.h" />
<ClInclude Include="sudoku.h" />
</ItemGroup>
<PropertyGroup Label="Globals">
<VCProjectVersion>16.0</VCProjectVersion>
<ProjectGuid>{2d0cb381-dc92-45db-b74b-b772ebed5e46}</ProjectGuid>
<RootNamespace>DemoSudokuSolver</RootNamespace>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>true</WholeProgramOptimization>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="Shared">
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup>
<IncludePath>$(Dir_IncludePath);$(IncludePath)</IncludePath>
<LibraryPath>$(Dir_LibraryPath);$(LibraryPath)</LibraryPath>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
</ItemDefinitionGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<ItemGroup>
<ClCompile Include="gui.cpp" />
<ClCompile Include="imgui-master\examples\imgui_impl_glfw.cpp" />
<ClCompile Include="imgui-master\examples\imgui_impl_opengl2.cpp" />
<ClCompile Include="imgui-master\imgui.cpp" />
<ClCompile Include="imgui-master\imgui_demo.cpp" />
<ClCompile Include="imgui-master\imgui_draw.cpp" />
<ClCompile Include="imgui-master\imgui_widgets.cpp" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="imgui-master\examples\imgui_impl_opengl2.h" />
<ClInclude Include="sudoku.h" />
</ItemGroup>
<PropertyGroup Label="Globals">
<VCProjectVersion>16.0</VCProjectVersion>
<ProjectGuid>{2d0cb381-dc92-45db-b74b-b772ebed5e46}</ProjectGuid>
<RootNamespace>DemoSudokuSolver</RootNamespace>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>true</WholeProgramOptimization>
<PlatformToolset>ClangCL</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="Shared">
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup>
<IncludePath>$(Dir_IncludePath);$(IncludePath)</IncludePath>
<LibraryPath>$(Dir_LibraryPath);$(LibraryPath)</LibraryPath>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
</ItemDefinitionGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
Loading

0 comments on commit b8b704e

Please sign in to comment.