Skip to content

Commit

Permalink
Update for new architectures
Browse files Browse the repository at this point in the history
  • Loading branch information
sergeneren committed May 16, 2021
1 parent 8bfe574 commit 1ca8b4c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions source/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -127,15 +127,15 @@ _COMPILEPTX ( SOURCES ${CUDA_SOURCES}
TARGET_PATH ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
GENERATED CUDA_PTX GENPATHS CUDA_PTX_PATHS
INCLUDE "${CMAKE_CURRENT_SOURCE_DIR},${_VCPKG_INCLUDE_DIR},${CMAKE_CURRENT_SOURCE_DIR}/common, ${THIRDPARTY_DIR}/cuda-noise/include, ${CMAKE_CURRENT_SOURCE_DIR}/gpu_vdb"
OPTIONS -arch=compute_30 -code=sm_30 --ptxas-options=-v -O3 --use_fast_math --maxrregcount=128)
OPTIONS -arch=compute_61 -code=sm_61 --ptxas-options=-v -O3 --use_fast_math --maxrregcount=128)

###################################################################

###################################################################
add_executable(vpt ${SOURCE_FILES})
target_link_libraries(vpt PRIVATE glfw imgui::imgui cudart cuda openvdb ${OIDN_LIBRARIES})
target_compile_options(vpt PRIVATE $<$<COMPILE_LANGUAGE:CUDA>:-gencode arch=compute_30,code=sm_30>)
set_target_properties(vpt PROPERTIES VS_GLOBAL_VcpkgEnabled true)
set_target_properties(vpt PROPERTIES CUDA_ARCHITECTURES "61;75;86")

include_directories(${_VCPKG_INCLUDE_DIR})
include_directories(${CMAKE_SOURCE_DIR})
Expand Down
2 changes: 1 addition & 1 deletion source/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -528,7 +528,7 @@ static void handle_key(GLFWwindow *window, int key, int scancode, int action, in
static void handle_mouse_button(GLFWwindow *window, int button, int action, int mods)
{
Window_context *ctx = static_cast<Window_context *>(glfwGetWindowUserPointer(window));
bool imgui_hover = ImGui::IsAnyWindowHovered();
bool imgui_hover = ImGui::IsWindowHovered(ImGuiHoveredFlags_AnyWindow);

if (button == GLFW_MOUSE_BUTTON_LEFT && !imgui_hover) {
if (action == GLFW_PRESS) {
Expand Down

0 comments on commit 1ca8b4c

Please sign in to comment.