Enhance build system and project documentation

Added LICENSE file with MIT License and copyright notice.
Added preview.png binary file for project assets.
Changed CMakeLists.txt to include asset copying command.
Changed mesh loading in Mesh.c to support smooth normals.
Changed ray origin biasing in PathTracing.c and shadow rays.
Changed ray-triangle intersection logic in RayIntersection.c.
Changed ray_intersect_bvh_count function in Debug.c to static.
Changed rendering functions in Scene.c with TODO for optimization.
Updated README.md with project description and build instructions.
Updated window dimensions in main.c for testing purposes.
This commit is contained in:
2025-04-21 21:03:08 +09:00
parent 6800810369
commit 59941241c3
13 changed files with 194 additions and 184 deletions

View File

@@ -54,15 +54,21 @@ set_target_properties(${PROJECT_NAME} PROPERTIES
)
if(WIN32)
add_custom_command(
TARGET ${PROJECT_NAME} POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy
add_custom_command(
TARGET ${PROJECT_NAME} POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy
$<TARGET_RUNTIME_DLLS:${PROJECT_NAME}>
$<TARGET_FILE_DIR:${PROJECT_NAME}>
VERBATIM
COMMAND_EXPAND_LISTS
VERBATIM
COMMAND_EXPAND_LISTS
)
endif()
# file(COPY ${LIBRARY_PATH}/cglm.dll DESTINATION ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/)
# file(COPY ${LIBRARY_PATH}/assimp-vc143-mt.dll DESTINATION ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/)
add_custom_command(
TARGET ${PROJECT_NAME} PRE_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_directory
${CMAKE_SOURCE_DIR}/assets
$<TARGET_FILE_DIR:${PROJECT_NAME}>/assets
)
file(COPY ${CMAKE_SOURCE_DIR}/assets DESTINATION ${CMAKE_BINARY_DIR})