Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
4 changes: 2 additions & 2 deletions apps/texrecon/arguments.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@ Arguments parse_args(int argc, char **argv) {
"\nFirst line: Extrinsics - translation vector and rotation matrix (the transform from world to camera)"
"\nSecond line: Intrinsics - focal length, distortion coefficients, pixel aspect ratio and principal point"
"\nThe focal length is the distance between camera center and image plane normalized by dividing with the larger image dimension."
"\nFor non zero distortion coefficients the image will be undistorted prior to the texturing process."
" If only d0 is non zero the Noah Snavely's distortion model is assumed otherwise the distortion model of VSFM is assumed."
"\nFor non-zero distortion coefficients the image will be undistorted prior to the texturing process."
" If only d0 is non-zero then the radial distortion model of VisualSFM is assumed, otherwise the Bundler distortion model is assumed."
"\nThe pixel aspect ratio is usually 1 or close to 1. If your SfM system doesn't output it, but outputs a different focal length in x and y direction, you have to encode this here."
"\nThe principal point has to be given in unit dimensions (e.g. 0.5 0.5)."
"\n\nBUNDLE_FILE:"
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 @@ -56,7 +56,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
4 changes: 2 additions & 2 deletions 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/OpenDroneMap/mapmap_cpu.git
GIT_TAG 250
GIT_REPOSITORY https://github.com/dthuerck/mapmap_cpu
GIT_TAG fa526e0963ca3e431a02aa7b9e87b85ba8a8e304
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 @@ -6,5 +6,5 @@ add_library(${LIBRARY} STATIC ${SOURCES})
set_property(TARGET ${LIBRARY} PROPERTY INTERPROCEDURAL_OPTIMIZATION True)
add_dependencies(${LIBRARY} ext_rayint ext_eigen ext_mapmap)
include_directories(${TBB_INCLUDE_DIRS})
target_link_libraries(${LIBRARY} ${TBB_LIBRARIES} ${MVE_MVE_LIBRARY} ${MVE_UTIL_LIBRARY} ${JPEG_LIBRARIES} ${PNG_LIBRARIES} ${TIFF_LIBRARIES})
target_link_libraries(${LIBRARY} ${MVE_MVE_LIBRARY} ${MVE_UTIL_LIBRARY} ${JPEG_LIBRARIES} ${PNG_LIBRARIES} ${TIFF_LIBRARIES} TBB::tbb)
install(TARGETS ${LIBRARY} ARCHIVE DESTINATION lib)
6 changes: 3 additions & 3 deletions libs/tex/generate_texture_views.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -83,11 +83,10 @@ from_images_and_camera_files(std::string const & path,

/* Find corresponding image file. */
int step = 1;
for (std::size_t j = i + 1; j < dir.size(); j += step) {
util::fs::File const & img_file = dir[j];
for (std::size_t j = i + 1; ; j += step) {

/* Since the files are sorted we can break - no more files with the same prefix exist. */
if (util::string::left(img_file.name, prefix.size()) != prefix) {
if (j >= dir.size() || util::string::left(dir[j].name, prefix.size()) != prefix) {
if (step == 1) {
j = i;
step = -1;
Expand All @@ -96,6 +95,7 @@ from_images_and_camera_files(std::string const & path,
break;
}
}
util::fs::File const & img_file = dir[j];

/* Image file (based on extension)? */
std::string img_file_ext = util::string::uppercase(util::string::right(img_file.name, 4));
Expand Down