feat: 添加独立的输入系统和平台抽象层
- 新增 Platform 模块:PlatformTypes.h, Window.h, WindowsWindow - 新增 Input 模块:InputTypes, InputEvent, InputAxis, InputModule, InputManager - 新增 WindowsInputModule 处理 Win32 消息转换 - 将 RHI 集成测试从 render_model 迁移到 sphere - 更新 CMakeLists.txt 添加 Platform 和 Input 模块
This commit is contained in:
55
tests/RHI/D3D12/integration/sphere/CMakeLists.txt
Normal file
55
tests/RHI/D3D12/integration/sphere/CMakeLists.txt
Normal file
@@ -0,0 +1,55 @@
|
||||
cmake_minimum_required(VERSION 3.15)
|
||||
|
||||
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
|
||||
|
||||
project(D3D12_Sphere)
|
||||
|
||||
set(ENGINE_ROOT_DIR ${CMAKE_SOURCE_DIR}/engine)
|
||||
|
||||
add_executable(D3D12_Sphere
|
||||
WIN32
|
||||
main.cpp
|
||||
)
|
||||
|
||||
target_include_directories(D3D12_Sphere PRIVATE
|
||||
${CMAKE_CURRENT_SOURCE_DIR}
|
||||
${ENGINE_ROOT_DIR}/include
|
||||
${ENGINE_ROOT_DIR}
|
||||
)
|
||||
|
||||
target_compile_definitions(D3D12_Sphere PRIVATE
|
||||
UNICODE
|
||||
_UNICODE
|
||||
)
|
||||
|
||||
target_link_libraries(D3D12_Sphere PRIVATE
|
||||
d3d12
|
||||
dxgi
|
||||
d3dcompiler
|
||||
winmm
|
||||
XCEngine
|
||||
)
|
||||
|
||||
add_custom_command(TARGET D3D12_Sphere POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_directory
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/Res
|
||||
$<TARGET_FILE_DIR:D3D12_Sphere>/Res
|
||||
)
|
||||
|
||||
add_custom_command(TARGET D3D12_Sphere POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different
|
||||
${CMAKE_SOURCE_DIR}/tests/RHI/D3D12/integration/compare_ppm.py
|
||||
$<TARGET_FILE_DIR:D3D12_Sphere>/
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different
|
||||
${CMAKE_SOURCE_DIR}/tests/RHI/D3D12/integration/run_integration_test.py
|
||||
$<TARGET_FILE_DIR:D3D12_Sphere>/
|
||||
)
|
||||
|
||||
add_test(NAME D3D12_Sphere_Integration
|
||||
COMMAND ${Python3_EXECUTABLE} $<TARGET_FILE_DIR:D3D12_Sphere>/run_integration_test.py
|
||||
$<TARGET_FILE:D3D12_Sphere>
|
||||
screenshot.ppm
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/GT.ppm
|
||||
5
|
||||
WORKING_DIRECTORY $<TARGET_FILE_DIR:D3D12_Sphere>
|
||||
)
|
||||
Reference in New Issue
Block a user