Skip to content

Commit

Permalink
Merge pull request #2 from santerioksanen/feature/tbb-depend
Browse files Browse the repository at this point in the history
Merge santerioksanen:feature/tbb-depend into homee-ai/mvs-texturing:master. Update oneTBB version such that oneTBB is installed automatically.
  • Loading branch information
homee-lion authored Oct 21, 2024
2 parents b3e8fac + cec3715 commit a1a716b
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 301 deletions.
2 changes: 0 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
cmake_minimum_required(VERSION 3.1)

LIST(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/elibs/tbb")

project(Texturing)
include(ExternalProject)

Expand Down
5 changes: 3 additions & 2 deletions apps/texrecon/texrecon.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include <iostream>
#include <fstream>
#include <vector>
#include <tbb/task_scheduler_init.h>
#include <tbb/task_arena.h>
#include <omp.h>

#include <util/timer.h>
Expand Down Expand Up @@ -60,7 +60,8 @@ int main(int argc, char **argv) {
}

// Set the number of threads to use.
tbb::task_scheduler_init schedule(conf.num_threads > 0 ? conf.num_threads : tbb::task_scheduler_init::automatic);
tbb::task_arena arena(conf.num_threads > 0 ? conf.num_threads : tbb::this_task_arena::max_concurrency());

if (conf.num_threads > 0) {
omp_set_dynamic(0);
omp_set_num_threads(conf.num_threads);
Expand Down
2 changes: 1 addition & 1 deletion elibs/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
externalproject_add(ext_mapmap
PREFIX ext_mapmap
GIT_REPOSITORY https://github.com/dthuerck/mapmap_cpu.git
GIT_TAG 55d14fd
GIT_TAG fa526e0
UPDATE_COMMAND ""
SOURCE_DIR ${CMAKE_SOURCE_DIR}/elibs/mapmap
CONFIGURE_COMMAND ""
Expand Down
295 changes: 0 additions & 295 deletions elibs/tbb/FindTBB.cmake

This file was deleted.

2 changes: 1 addition & 1 deletion libs/tex/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ set(LIBRARY tex)
add_library(${LIBRARY} STATIC ${SOURCES})
set_property(TARGET ${LIBRARY} PROPERTY INTERPROCEDURAL_OPTIMIZATION True)
add_dependencies(${LIBRARY} ext_mve ext_rayint ext_eigen ext_mapmap)
target_link_libraries(${LIBRARY} ${TBB_LIBRARIES} -lmve -lmve_util ${JPEG_LIBRARIES} ${PNG_LIBRARIES} ${TIFF_LIBRARIES})
target_link_libraries(${LIBRARY} -lmve -lmve_util ${JPEG_LIBRARIES} ${PNG_LIBRARIES} ${TIFF_LIBRARIES} TBB::tbb)
install(TARGETS ${LIBRARY} ARCHIVE DESTINATION lib)

0 comments on commit a1a716b

Please sign in to comment.