And cones !

This commit is contained in:
Godzil
2020-02-23 02:31:30 +00:00
parent 0650ac7b44
commit f226664fe3
9 changed files with 509 additions and 3 deletions

View File

@@ -5,7 +5,7 @@ find_package(Threads REQUIRED)
set(TESTS_SRC math_test.cpp tuple_test.cpp colour_test.cpp canvas_test.cpp matrix_test.cpp transformation_test.cpp
ray_test.cpp intersect_test.cpp sphere_test.cpp light_test.cpp material_test.cpp world_test.cpp camera_test.cpp
shape_test.cpp plane_test.cpp pattern_test.cpp cube_test.cpp cylinder_test.cpp)
shape_test.cpp plane_test.cpp pattern_test.cpp cube_test.cpp cylinder_test.cpp cone_test.cpp)
add_executable(testMyRays)
target_include_directories(testMyRays PUBLIC ${gtest_SOURCE_DIR}/include ${gtest_SOURCE_DIR})
@@ -74,6 +74,11 @@ target_include_directories(ch13_test PUBLIC ../source/include)
target_sources(ch13_test PRIVATE ch13_test.cpp)
target_link_libraries(ch13_test rayonnement)
add_executable(ch13_cone)
target_include_directories(ch13_cone PUBLIC ../source/include)
target_sources(ch13_cone PRIVATE ch13_cone.cpp)
target_link_libraries(ch13_cone rayonnement)
add_test(NAME Chapter05_Test COMMAND $<TARGET_FILE:ch5_test>)
add_test(NAME Chapter06_Test COMMAND $<TARGET_FILE:ch6_test>)
add_test(NAME Chapter07_Test COMMAND $<TARGET_FILE:ch7_test>)
@@ -84,4 +89,5 @@ add_test(NAME Chapter11_Refraction COMMAND $<TARGET_FILE:ch11_refraction>)
add_test(NAME Chapter11_Test COMMAND $<TARGET_FILE:ch11_test>)
add_test(NAME Chapter12_Test COMMAND $<TARGET_FILE:ch12_test>)
add_test(NAME Chapter13_Test COMMAND $<TARGET_FILE:ch13_test>)
add_test(NAME Chapter13_ConeBonus COMMAND $<TARGET_FILE:ch13_cone>)
add_test(NAME Hw3Render COMMAND $<TARGET_FILE:hw3render> ${CMAKE_CURRENT_SOURCE_DIR}/test.hw3scene)