if(GLUT_FOUND AND OPENGL_FOUND) include_directories(${GLUT_INCLUDE_DIR}) add_definitions(-DGLUT_FOUND -DGLUT_NO_LIB_PRAGMA) # Tag interop_native_CUDA.cu for OBJ format intead of PTX (which is the default for # OPTIX_add_test_executable). Do this before calling OPTIX_add_test_executable. set_source_files_properties(${CMAKE_CURRENT_SOURCE_DIR}/funcs_CUDA.cu PROPERTIES CUDA_SOURCE_PROPERTY_FORMAT OBJ ) # See top level CMakeLists.txt file for documentation of OPTIX_add_sample_executable. OPTIX_add_sample_executable( sample6 sample6.cpp # These files are common among multiple samples accum_camera.cu ambocc.cu commonStructs.h constantbg.cu helpers.h normal_shader.cu one_bounce_diffuse.cu orthographic_camera.cu parallelogram.cu pinhole_camera.cu funcs_CUDA.cu random.h ) target_link_libraries( sample6 ${CUDA_LIBRARIES} ${CUDA_TOOLKIT_RPATH_FLAG} ) else() # GLUT or OpenGL not found message("Disabling sample6, which requires glut and opengl.") endif()