Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doc improvement and vpImage refactoring #1352

Merged
merged 33 commits into from
Mar 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
767187c
Replace all svn export command by the link to github repo
fspindle Mar 15, 2024
5480f8d
Fix typo
fspindle Mar 15, 2024
8e28e92
Fix doxygen doc and add security in getStdev()
fspindle Mar 15, 2024
f4a202d
Refactor vpImage getSum(), getMeanValue() and getStdev()
fspindle Mar 15, 2024
793228a
Update last changes
fspindle Mar 18, 2024
5b12a39
Add -std=c++17, -std=c++11... standard options when cmake is run sing…
fspindle Mar 18, 2024
5b07353
Fix comedi version retrieval
fspindle Mar 18, 2024
45702d7
Remove c++14 standard testing, while introducing c++98
fspindle Mar 18, 2024
ad5ef8e
Fix typo
fspindle Mar 18, 2024
c98dab9
Code indentation
fspindle Mar 18, 2024
14b9fdc
Replace deprecated cmake exec_program() macro
fspindle Mar 18, 2024
e480bc2
Make vpPoseFeature available only if c++ standard >= c++11
fspindle Mar 18, 2024
42511c9
Fix typo
fspindle Mar 19, 2024
e139a24
Remove all references to subversion
fspindle Mar 19, 2024
11c4e87
Attempt to fix sanitizer by setting vm.mmap_rnd_bits=28
fspindle Mar 19, 2024
01f6682
Fix c++98 build
fspindle Mar 19, 2024
e9b762a
Make working directory more explicit
fspindle Mar 19, 2024
3128c65
Fix wrong path since migration to msvc17
fspindle Mar 19, 2024
ea52ade
Add pwd to help debug
fspindle Mar 19, 2024
b2bc4a4
Improve/fix compiler version detection
fspindle Mar 20, 2024
065750b
Update changes with Python bindings
fspindle Mar 20, 2024
dc6112a
Improve package version detection when pkg-config not installed
fspindle Mar 20, 2024
dafaa39
Remove distutils usage to detect numpy include dirs
fspindle Mar 20, 2024
73fa608
Merge remote-tracking branch 'upstream/master' into fix_svn_export
fspindle Mar 20, 2024
9daef7b
Update changes with python bindings tutorial
fspindle Mar 20, 2024
bc77d8a
Fix various warnings detected with msvc17 around cast
fspindle Mar 20, 2024
7900bcd
Fix more warnings around cast
fspindle Mar 20, 2024
40e98bb
Fix doxygen warning
fspindle Mar 20, 2024
2f6c095
Remove gforge forum and cite github discussions forum
fspindle Mar 20, 2024
045094d
Updated Dockerfile in ci/docker folder for Ubuntu 18.04, 20.04 and 22…
fspindle Mar 20, 2024
1fae635
Clean cmake material
fspindle Mar 20, 2024
7ff4042
Introduce mask in equalizeHistogram()
fspindle Mar 20, 2024
1e5455c
Fix sanitizer github action
fspindle Mar 20, 2024
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: 1 addition & 1 deletion .github/workflows/ubuntu-contrib.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
- name: Print compiler information
run: dpkg --list | grep compiler

- name: Install dependencies for ubuntu 18.04 and 20.04
- name: Install dependencies for ubuntu 20.04
if: matrix.os != 'ubuntu-22.04'
run: sudo apt-get update && sudo apt-get install -y libx11-dev libdc1394-22-dev libv4l-dev liblapack-dev libopenblas-dev libeigen3-dev libopencv-dev nlohmann-json3-dev

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ubuntu-dep-apt.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
matrix:
os: [ubuntu-20.04, ubuntu-22.04]
compiler: [ {CC: /usr/bin/gcc-9, CXX: /usr/bin/g++-9}, {CC: /usr/bin/gcc-10, CXX: /usr/bin/g++-10}, {CC: /usr/bin/clang, CXX: /usr/bin/clang++} ]
standard: [ 11, 14, 17 ]
standard: [ 98, 11, 17 ]

steps:
- name: Checkout repository
Expand Down
10 changes: 9 additions & 1 deletion .github/workflows/ubuntu-sanitizers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,4 +82,12 @@ jobs:
# SUMMARY: AddressSanitizer: odr-violation: global 'ALIGNMENT' at /home/runner/work/visp/visp/3rdparty/simdlib/Simd/SimdLib.cpp:82:18
ASAN_OPTIONS: detect_odr_violation=0
working-directory: build
run: ctest -j$(nproc) --output-on-failure -V
# When running ctest we got a lot of segfault
# This seems a bug reported in
# - https://stackoverflow.com/questions/77894856/possible-bug-in-gcc-sanitizers
# - https://stackoverflow.com/questions/77850769/fatal-threadsanitizer-unexpected-memory-mapping-when-running-on-linux-kernels
# The workaround seems to be to set vm.mmap_rnd_bits=28
run: |
sudo cat /proc/sys/vm/mmap_rnd_bits
sudo sysctl vm.mmap_rnd_bits=28
ctest -j$(nproc) --output-on-failure -V
10 changes: 6 additions & 4 deletions .github/workflows/windows-clang.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,27 +51,29 @@ jobs:
cd build
cmake .. -G "Visual Studio 17 2022" -T "ClangCl" -A "x64"
type ViSP-third-party.txt
pwd

- name: Build ViSP
working-directory: build
working-directory: ${{ github.workspace }}\build
run: |
pwd
cmake --build . --config Release

- name: Install ViSP
working-directory: build
working-directory: ${{ github.workspace }}\build
run: |
cmake --build . --config Release --target install

- name: Check installation folder
working-directory: build
working-directory: ${{ github.workspace }}\build
run: |
dir ${{ github.workspace }}\build\install\
dir ${{ github.workspace }}\build\install\x64\
dir ${{ github.workspace }}\build\install\x64\vc17\
dir ${{ github.workspace }}\build\install\x64\vc17\bin

- name: Test ViSP
working-directory: build
working-directory: ${{ github.workspace }}\build
run: |
set VISP_INPUT_IMAGE_PATH=${{ env.VISP_INPUT_IMAGE_PATH }}
echo "VISP_INPUT_IMAGE_PATH: "
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/windows-msvc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:

include:
- name: windows-latest
os: windows-2019
os: windows-2022

steps:
- name: Checkout repository
Expand All @@ -47,31 +47,31 @@ jobs:
echo %VISP_INPUT_IMAGE_PATH%
mkdir build
cd build
cmake .. -G "Visual Studio 16 2019" -A "x64"
cmake .. -G "Visual Studio 17 2022" -A "x64"
type ViSP-third-party.txt

- name: Build ViSP
working-directory: build
working-directory: ${{ github.workspace }}\build
run: |
cmake --build . --config Release

- name: Install ViSP
working-directory: build
working-directory: ${{ github.workspace }}\build
run: |
cmake --build . --config Release --target install

- name: Check installation folder
working-directory: build
working-directory: ${{ github.workspace }}\build
run: |
dir ${{ github.workspace }}\build\install\x64\vc16\bin
dir ${{ github.workspace }}\build\install\x64\vc17\bin

- name: Test ViSP
working-directory: build
working-directory: ${{ github.workspace }}\build
run: |
set VISP_INPUT_IMAGE_PATH=${{ env.VISP_INPUT_IMAGE_PATH }}
echo "VISP_INPUT_IMAGE_PATH: "
echo %VISP_INPUT_IMAGE_PATH%
set PATH=%PATH%;${{ github.workspace }}\build\install\x64\vc16\bin
set PATH=%PATH%;${{ github.workspace }}\build\install\x64\vc17\bin
echo "PATH: "
echo %PATH%
ctest --output-on-failure -C Release -V
14 changes: 5 additions & 9 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,9 @@ endif()
if(POLICY CMP0075)
cmake_policy(SET CMP0075 NEW) # For check_include_file and cmake 3.12.0
endif()
if(POLICY CMP0146)
cmake_policy(SET CMP0146 OLD) # The ``FindCUDA`` module deprecated since CMake 3.10
endif()

if(APPLE)
# Fix following errors for libpng and libjpeg detection:
Expand All @@ -127,11 +130,7 @@ project(VISP C CXX)
list(APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake")

include(cmake/VISPUtils.cmake)
include(cmake/VISPDetectCXXStandard.cmake) # Set cxx standard to 11 by default

if (CMAKE_VERSION VERSION_LESS 3.0.0)
vp_clear_vars(VISPModules_TARGETS)
endif()
include(cmake/VISPDetectCXXStandard.cmake) # Set cxx standard to 17 by default

#-----------------------------------------------------------------------------
# VISP version number. An even minor number corresponds to releases.
Expand All @@ -146,8 +145,7 @@ set(VISP_REVISION "1")
#-----------------------------------------------------------------------------
# TO BE CHECKED BEFORE NEXT RELEASE
#
# see here: https://github.com/PointCloudLibrary/pcl/issues/3680
# when this is fixed, we can remove the following 3 lines.
# Remove following 3 next lines and check if pcl produces a CMP0144 complain around CMake variable FLANN_ROOT set to /opt/homebrew
if(NOT DEFINED CMAKE_SUPPRESS_DEVELOPER_WARNINGS)
set(CMAKE_SUPPRESS_DEVELOPER_WARNINGS 1 CACHE INTERNAL "No dev warnings")
endif()
Expand Down Expand Up @@ -1152,8 +1150,6 @@ VP_SET(VISP_HAVE_VICON TRUE IF (BUILD_MODULE_visp_sensor AND USE_VICON))
VP_SET(VISP_BUILD_SHARED_LIBS TRUE IF BUILD_SHARED_LIBS) # for header vpConfig.h
VP_SET(VISP_HAVE_DC1394_CAMERA_ENUMERATE TRUE IF (USE_DC1394 AND DC1394_CAMERA_ENUMERATE_FOUND)) # for header vpConfig.h
VP_SET(VISP_HAVE_DC1394_FIND_CAMERAS TRUE IF (USE_DC1394 AND DC1394_FIND_CAMERAS_FOUND)) # for header vpConfig.h
VP_SET(VISP_HAVE_D3D9 TRUE IF USE_DIRECT3D) # for header vpConfig.h
VP_SET(VISP_HAVE_GTK TRUE IF USE_GTK2) # for header vpConfig.h
VP_SET(VISP_HAVE_XRANDR TRUE IF XRANDR) # for header vpConfig.h
VP_SET(VISP_HAVE_NULLPTR TRUE IF HAVE_NULLPTR) # for header vpConfig.h

Expand Down
67 changes: 28 additions & 39 deletions CTestConfig.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -91,52 +91,42 @@ else()
endif()

# Find out the version of gcc being used.
if(CMAKE_COMPILER_IS_GNUCC)
exec_program(${CMAKE_CXX_COMPILER}
ARGS -dumpversion
OUTPUT_VARIABLE COMPILER_VERSION
)
#message("COMPILER_VERSION 1: ${COMPILER_VERSION}")
string(REGEX REPLACE ".* ([0-9])\\.([0-9])\\.[0-9].*" "\\1\\2"
COMPILER_VERSION ${COMPILER_VERSION})
#message("COMPILER_VERSION 2: ${COMPILER_VERSION}")

set(BUILDNAME "${BUILDNAME}${COMPILER_VERSION}")

endif(CMAKE_COMPILER_IS_GNUCC)
if(CMAKE_CXX_COMPILER_VERSION)
set(BUILDNAME "${BUILDNAME}-${CMAKE_CXX_COMPILER_VERSION}")
endif()

# Add the type of library generation, e.g. "Dynamic or Static"
if(BUILD_SHARED_LIBS)
set(BUILDNAME "${BUILDNAME}-Dyn")
else(BUILD_SHARED_LIBS)
set(BUILDNAME "${BUILDNAME}-Sta")
endif(BUILD_SHARED_LIBS)
endif()

# Add the build type, e.g. "Debug, Release..."
if(CMAKE_BUILD_TYPE)
set(BUILDNAME "${BUILDNAME}-${CMAKE_BUILD_TYPE}")
endif(CMAKE_BUILD_TYPE)
endif()

#---- Robots ----
# Add specific Afma4 robots
if(VISP_HAVE_AFMA4)
set(BUILDNAME "${BUILDNAME}-Afma4")
endif(VISP_HAVE_AFMA4)
endif()

# Add specific Afma6 robots
if(VISP_HAVE_AFMA6)
set(BUILDNAME "${BUILDNAME}-Afma6")
endif(VISP_HAVE_AFMA6)
endif()

# Add specific Ptu46 robots
if(VISP_HAVE_PTU46)
set(BUILDNAME "${BUILDNAME}-Ptu46")
endif(VISP_HAVE_PTU46)
endif()

# Add specific Biclops robots
if(VISP_HAVE_BICLOPS)
set(BUILDNAME "${BUILDNAME}-Biclops")
endif(VISP_HAVE_BICLOPS)
endif()

# Add specific Pioneer robots
if(VISP_HAVE_PIONEER)
Expand All @@ -152,18 +142,18 @@ endif()
# Firewire dc1394-2.x
if(VISP_HAVE_DC1394)
set(BUILDNAME "${BUILDNAME}-dc1394")
endif(VISP_HAVE_DC1394)
endif()
# Video 4 linux 2 (V4L2)
if(VISP_HAVE_V4L2)
set(BUILDNAME "${BUILDNAME}-v4l2")
endif(VISP_HAVE_V4L2)
endif()
# Directshow
if(VISP_HAVE_DIRECTSHOW)
set(BUILDNAME "${BUILDNAME}-dshow")
endif(VISP_HAVE_DIRECTSHOW)
endif()
if(VISP_HAVE_CMU1394)
set(BUILDNAME "${BUILDNAME}-CMU1394")
endif(VISP_HAVE_CMU1394)
endif()
if(VISP_HAVE_LIBFREENECT)
set(BUILDNAME "${BUILDNAME}-freenect")
endif()
Expand Down Expand Up @@ -196,19 +186,19 @@ endif()
# X11
if(VISP_HAVE_X11)
set(BUILDNAME "${BUILDNAME}-X11")
endif(VISP_HAVE_X11)
endif()
# GTK
if(VISP_HAVE_GTK)
set(BUILDNAME "${BUILDNAME}-gtk")
endif(VISP_HAVE_GTK)
endif()
# GDI (Windows Graphics Device Interface)
if(VISP_HAVE_GDI)
set(BUILDNAME "${BUILDNAME}-gdi")
endif(VISP_HAVE_GDI)
endif()
# D3D (Direct3D9)
if(VISP_HAVE_D3D9)
set(BUILDNAME "${BUILDNAME}-Direct3D")
endif(VISP_HAVE_D3D9)
endif()
# OpenCV
if(VISP_HAVE_OPENCV)
if(OpenCV_VERSION)
Expand All @@ -220,7 +210,7 @@ if(VISP_HAVE_OPENCV)
else()
set(BUILDNAME "${BUILDNAME}-OpenCV")
endif()
endif(VISP_HAVE_OPENCV)
endif()

#---- Mathematics ----
# Lapack (Linear Algebra PACKage)
Expand All @@ -246,34 +236,31 @@ endif()
# Coin
if(VISP_HAVE_COIN3D)
set(BUILDNAME "${BUILDNAME}-Coin")
endif(VISP_HAVE_COIN3D)
endif()
# SoQt
if(VISP_HAVE_SOQT)
set(BUILDNAME "${BUILDNAME}-SoQt")
endif(VISP_HAVE_SOQT)
endif()
# Qt
if(VISP_HAVE_QT)
set(BUILDNAME "${BUILDNAME}-Qt${DESIRED_QT_VERSION}")
endif(VISP_HAVE_QT)
endif()
# SoWin
if(VISP_HAVE_SOWIN)
set(BUILDNAME "${BUILDNAME}-SoWin")
endif(VISP_HAVE_SOWIN)
endif()
# SoXt
if(VISP_HAVE_SOXT)
set(BUILDNAME "${BUILDNAME}-SoXt")
endif(VISP_HAVE_SOXT)
endif()

#---- Images ----
if(VISP_HAVE_JPEG)
set(BUILDNAME "${BUILDNAME}-jpeg")
endif(VISP_HAVE_JPEG)
endif()
if(VISP_HAVE_PNG)
set(BUILDNAME "${BUILDNAME}-png")
endif(VISP_HAVE_PNG)
#if(VISP_HAVE_ZLIB)
# set(BUILDNAME "${BUILDNAME}-zlib")
#endif()
endif()

#---- Misc ----
# XML
Expand Down Expand Up @@ -306,7 +293,9 @@ endif()
if(ACTIVATE_WARNING_FLOAT_EQUAL)
set(BUILDNAME "${BUILDNAME}-Weq")
endif()
if(VISP_CXX_STANDARD EQUAL VISP_CXX_STANDARD_11)
if(VISP_CXX_STANDARD EQUAL VISP_CXX_STANDARD_98)
set(BUILDNAME "${BUILDNAME}-c98")
elseif(VISP_CXX_STANDARD EQUAL VISP_CXX_STANDARD_11)
set(BUILDNAME "${BUILDNAME}-c11")
elseif(VISP_CXX_STANDARD EQUAL VISP_CXX_STANDARD_14)
set(BUILDNAME "${BUILDNAME}-c14")
Expand Down
12 changes: 11 additions & 1 deletion ChangeLog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,24 @@ ViSP 3.x.x (Version in development)
. vpPololu and vpRobotPololuPtu to control respectively a servo motor using a pololu maestro board or a 3D printed
2 dof pan-tilt unit. Visual servoing example provided in example/servo-pololu-ptu. Tests available in
modules/robot/test/servo-pololu/
. vpStatisticalTestAbstract, vpStatisticalTestEWMA, vpStatisticalTestHinkley, vpStatisticalTestMeanAdjustedCUSUM
vpStatisticalTestShewhart and vpStatisticalTestSigma: classes implementing Statistical Control Process methods to
detect mean drift / jump of a signal
- Deprecated
. vpPlanarObjectDetector, vpFernClassifier deprecated classes are removed
. End of supporting c++98 standard. As a consequence, ViSP is no more compatible with Ubuntu 12.04
. vpDisplay::displayCharString() is marked deprecated. Use vpDisplay::displayText() instead
. vpHinkley class is deprecated, in favor of vpStatisticalTestHinkley
- New features and improvements
. Introduce Python bindings for most of ViSP modules and classes (see corresponding tutorial)
. Updated Dockerfile in ci/docker folder for Ubuntu 18.04, 20.04 and 22.04. Corresponding images are also available
ready to use on DockerHub https://hub.docker.com/repository/docker/vispci/vispci/general
. OpenCV 2.4.8 is the minimal supported version
. Introduce applications in apps folder, a collection of useful tools that
have a dependency to the install target
. Bump minimal c++ standard to c++11
. Speed up build by including only opencv2/opencv_modules.hpp instead of opencv2/opencv.hpp header in vpConfig.h
. In imgproc module, implementation of automatic gamma factor computation methods for gamma correction.
. Eliminate the use of pthread in favour of std::thread
- Applications
. Migrate eye-to-hand tutorials in apps
- Tutorials
Expand All @@ -33,6 +41,8 @@ ViSP 3.x.x (Version in development)
https://visp-doc.inria.fr/doxygen/visp-daily/tutorial-install-conda-package.html
. New tutorial: Using Statistical Process Control to monitor your signal
https://visp-doc.inria.fr/doxygen/visp-daily/tutorial-spc.html
. New tutorial: Installing ViSP Python bindings
https://visp-doc.inria.fr/doxygen/visp-daily/tutorial-install-python-bindings.html
- Bug fixed
. [#1251] Bug in vpDisplay::displayFrame()
. [#1270] Build issue around std::clamp and optional header which are not found with cxx17
Expand Down
Loading
Loading