Skip to content

Commit

Permalink
Introduce more fixes detected by IWYU
Browse files Browse the repository at this point in the history
  • Loading branch information
fspindle committed Nov 12, 2024
1 parent 64408b6 commit 94fe282
Show file tree
Hide file tree
Showing 196 changed files with 3,194 additions and 1,918 deletions.
8 changes: 6 additions & 2 deletions apps/calibration/visp-compute-chessboard-poses.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@

#include <visp3/core/vpConfig.h>

#if defined(VISP_HAVE_OPENCV)
#include <opencv2/opencv_modules.hpp> // for HAVE_OPENCV_IMGCODECS, HAVE...
#endif

#if defined(VISP_HAVE_OPENCV) && defined(HAVE_OPENCV_CALIB3D) && defined(VISP_HAVE_PUGIXML)

#include <opencv2/calib3d/calib3d.hpp>
Expand Down Expand Up @@ -228,7 +232,7 @@ int main(int argc, const char **argv)
#elif defined(VISP_HAVE_GTK)
display = new vpDisplayGTK(I);
#endif
}
}
#endif

std::vector<vpPoint> corners_pts;
Expand Down Expand Up @@ -339,7 +343,7 @@ int main(int argc, const char **argv)
}
}
#endif
}
}
catch (const vpException &e) {
std::cout << "Catch an exception: " << e.getMessage() << std::endl;
}
Expand Down
3 changes: 3 additions & 0 deletions demo/wireframe-simulator/servoSimu4Points.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,9 @@
#include <visp3/visual_features/vpFeaturePoint.h>
#include <visp3/vs/vpServo.h>

#if defined(VISP_HAVE_OPENCV)
#include <opencv2/opencv_modules.hpp> // for HAVE_OPENCV_IMGCODECS, HAVE...
#endif
#define GETOPTARGS "dhp"

#if defined(VISP_HAVE_DISPLAY) && (defined(VISP_HAVE_LAPACK) || defined(VISP_HAVE_EIGEN3) || defined(VISP_HAVE_OPENCV))
Expand Down
3 changes: 3 additions & 0 deletions demo/wireframe-simulator/servoSimuCylinder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,9 @@
#include <visp3/visual_features/vpFeatureBuilder.h>
#include <visp3/vs/vpServo.h>

#if defined(VISP_HAVE_OPENCV)
#include <opencv2/opencv_modules.hpp> // for HAVE_OPENCV_IMGCODECS, HAVE...
#endif
#define GETOPTARGS "dhp"

#if defined(VISP_HAVE_DISPLAY) && (defined(VISP_HAVE_LAPACK) || defined(VISP_HAVE_EIGEN3) || defined(VISP_HAVE_OPENCV))
Expand Down
3 changes: 3 additions & 0 deletions demo/wireframe-simulator/servoSimuSphere.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,9 @@
#include <visp3/visual_features/vpFeatureBuilder.h>
#include <visp3/visual_features/vpGenericFeature.h>
#include <visp3/vs/vpServo.h>
#if defined(VISP_HAVE_OPENCV)
#include <opencv2/opencv_modules.hpp> // for HAVE_OPENCV_IMGCODECS, HAVE...
#endif

#define GETOPTARGS "dhp"

Expand Down
5 changes: 4 additions & 1 deletion example/calibration/calibrate-camera.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@

#include <visp3/core/vpConfig.h>

#if defined(VISP_HAVE_OPENCV)
#include <opencv2/opencv_modules.hpp> // for HAVE_OPENCV_IMGCODECS, HAVE...
#endif
#if (VISP_HAVE_OPENCV_VERSION >= 0x030000) && defined(HAVE_OPENCV_CALIB3D) && defined(HAVE_OPENCV_HIGHGUI) && \
defined(HAVE_OPENCV_IMGPROC) && defined(VISP_HAVE_PUGIXML)

Expand Down Expand Up @@ -683,5 +686,5 @@ int main()
std::cout << "pugixml built-in 3rdparty is requested to run the calibration." << std::endl;
#endif
return EXIT_SUCCESS;
}
}
#endif
5 changes: 4 additions & 1 deletion example/device/display/displayOpenCV.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,9 @@
#include <visp3/core/vpConfig.h>
#include <visp3/core/vpDebug.h>

#if defined(VISP_HAVE_OPENCV)
#include <opencv2/opencv_modules.hpp> // for HAVE_OPENCV_IMGCODECS, HAVE...
#endif
#if defined(HAVE_OPENCV_HIGHGUI)

#include <visp3/core/vpImage.h>
Expand Down Expand Up @@ -463,5 +466,5 @@ int main()
std::cout << "Tip:" << std::endl;
std::cout << "- Install OpenCV, configure again ViSP using cmake and build again this example" << std::endl;
return EXIT_SUCCESS;
}
}
#endif
6 changes: 2 additions & 4 deletions example/tracking/mbtEdgeKltTracking.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/****************************************************************************
*
/*
* ViSP, open source Visual Servoing Platform software.
* Copyright (C) 2005 - 2023 by Inria. All rights reserved.
*
Expand Down Expand Up @@ -30,8 +29,7 @@
*
* Description:
* Example of Hybrid Tracking of MBT and MBT KTL.
*
*****************************************************************************/
*/

/*!
\example mbtEdgeKltTracking.cpp
Expand Down
23 changes: 17 additions & 6 deletions modules/ar/include/visp3/ar/vpPanda3DBaseRenderer.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,26 @@
#ifndef VP_PANDA3D_BASE_RENDERER_H
#define VP_PANDA3D_BASE_RENDERER_H

#include <visp3/core/vpConfig.h>
#include <visp3/core/vpConfig.h> // for BEGIN_VISP_NAMESPACE

#if defined(VISP_HAVE_PANDA3D)
#include <visp3/core/vpPoint.h>
#include <visp3/core/vpCameraParameters.h>
#include <visp3/ar/vpPanda3DRenderParameters.h>

#include <pandaFramework.h>
#include <pandaSystem.h>
#include <string> // for string, basic_string
#include <vector> // for vector
#include <memory> // for shared_ptr, __shared...

#include <camera.h> // for Camera
#include <graphicsEngine.h> // for GraphicsEngine
#include <graphicsOutput.h> // for GraphicsOutput
#include <nodePath.h> // for NodePath
#include <pandaFramework.h> // for PandaFramework
#include <pointerTo.h> // for PointerTo
#include <windowFramework.h> // for WindowFramework

#include <visp3/core/vpColVector.h> // for vpColVector
#include <visp3/core/vpHomogeneousMatrix.h> // for vpHomogeneousMatrix
#include <visp3/ar/vpPanda3DRenderParameters.h> // for vpPanda3DRenderParam...


BEGIN_VISP_NAMESPACE
/**
Expand Down
11 changes: 9 additions & 2 deletions modules/ar/include/visp3/ar/vpPanda3DCommonFilters.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,21 @@
#ifndef VP_PANDA3D_COMMON_FILTERS_H
#define VP_PANDA3D_COMMON_FILTERS_H

#include <visp3/core/vpConfig.h>
#include <visp3/core/vpConfig.h> // for VP_OVERRIDE, VISP_E...

#if defined(VISP_HAVE_PANDA3D)

#include <visp3/ar/vpPanda3DPostProcessFilter.h>
#include <memory> // for shared_ptr
#include <string> // for string

#include <visp3/ar/vpPanda3DPostProcessFilter.h> // for vpPanda3DPostProces...

BEGIN_VISP_NAMESPACE

class vpPanda3DBaseRenderer;
class vpPanda3DRGBRenderer;
class vpRGBf;
template <class Type> class vpImage;

/**
* \ingroup group_ar_renderer_panda3d_filters
Expand Down
14 changes: 9 additions & 5 deletions modules/ar/include/visp3/ar/vpPanda3DPostProcessFilter.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,16 +31,20 @@
#ifndef VP_PANDA3D_POST_PROCESS_FILTER_H
#define VP_PANDA3D_POST_PROCESS_FILTER_H

#include <visp3/core/vpConfig.h>
#include <visp3/core/vpConfig.h> // for VP_OVERRIDE, BEGIN_VISP_...

#if defined(VISP_HAVE_PANDA3D)

#include <string>
#include <string> // for basic_string, string
#include <memory> // for shared_ptr, __shared_ptr...

#include <visp3/ar/vpPanda3DBaseRenderer.h>
#include <frameBufferProperties.h> // for FrameBufferProperties
#include <graphicsOutput.h> // for GraphicsOutput
#include <pointerTo.h> // for PointerTo
#include <shader.h> // for Shader
#include <texture.h> // for Texture

#include "cardMaker.h"
#include "orthographicLens.h"
#include <visp3/ar/vpPanda3DBaseRenderer.h> // for vpPanda3DBaseRenderer

BEGIN_VISP_NAMESPACE

Expand Down
19 changes: 14 additions & 5 deletions modules/ar/include/visp3/ar/vpPanda3DRGBRenderer.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,26 @@
#ifndef VP_PANDA3D_RGB_RENDERER_H
#define VP_PANDA3D_RGB_RENDERER_H

#include <visp3/core/vpConfig.h>
#include <visp3/core/vpConfig.h> // for VP_OVERRIDE, BEGIN_VISP_...

#if defined(VISP_HAVE_PANDA3D)

#include <visp3/ar/vpPanda3DBaseRenderer.h>
#include <visp3/ar/vpPanda3DLight.h>
#include <visp3/core/vpImage.h>
#include <string> // for basic_string, string

#include "pointerTo.h"
#include <displayRegion.h> // for DisplayRegion
#include <graphicsOutput.h> // for GraphicsOutput
#include <nodePath.h> // for NodePath
#include <texture.h> // for Texture
#include <pointerTo.h> // for PointerTo

#include <visp3/ar/vpPanda3DBaseRenderer.h> // for vpPanda3DBaseRenderer
#include <visp3/ar/vpPanda3DLight.h> // for vpPanda3DLightableScene

BEGIN_VISP_NAMESPACE

class vpRGBa;
template <class Type> class vpImage;

/**
* \ingroup group_ar_renderer_panda3d_3d
* \brief Implementation of a traditional RGB renderer in Panda3D
Expand Down
8 changes: 6 additions & 2 deletions modules/ar/include/visp3/ar/vpPanda3DRenderParameters.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,14 @@
#ifndef VP_PANDA3D_RENDER_PARAMETERS_H
#define VP_PANDA3D_RENDER_PARAMETERS_H

#include <visp3/core/vpConfig.h>
#include <visp3/core/vpConfig.h> // for BEGIN_VISP_NAMESPACE, END...

#if defined(VISP_HAVE_PANDA3D)
#include <visp3/core/vpCameraParameters.h>

#include <utility> // for swap

#include <visp3/core/vpCameraParameters.h> // for vpCameraParameters, vpCam...
#include <visp3/core/vpException.h> // for vpException

class Camera;

Expand Down
13 changes: 9 additions & 4 deletions modules/ar/include/visp3/ar/vpPanda3DRendererSet.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,16 +31,21 @@
#ifndef VP_PANDA3D_RENDERER_SET_H
#define VP_PANDA3D_RENDERER_SET_H

#include <visp3/core/vpConfig.h>
#include <visp3/core/vpConfig.h> // for VP_OVERRIDE, BEGIN_VISP_...

#if defined(VISP_HAVE_PANDA3D)

#include <vector>
#include <memory> // for shared_ptr, __shared_ptr...
#include <string> // for string, basic_string
#include <vector> // for vector

#include <visp3/ar/vpPanda3DBaseRenderer.h>
#include <visp3/ar/vpPanda3DLight.h>
#include <visp3/ar/vpPanda3DBaseRenderer.h> // for vpPanda3DBaseRenderer
#include <visp3/ar/vpPanda3DLight.h> // for vpPanda3DLightable

BEGIN_VISP_NAMESPACE

class vpPanda3DRenderParameters;

/**
* \ingroup group_ar_renderer_panda3d
*
Expand Down
8 changes: 4 additions & 4 deletions modules/ar/include/visp3/ar/vpSimulatorException.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,12 @@
#ifndef VP_SIMULATOR_EXCEPTION_H
#define VP_SIMULATOR_EXCEPTION_H

#include <visp3/core/vpConfig.h>
#include <visp3/core/vpException.h>
#include <visp3/core/vpConfig.h> // for BEGIN_VISP_NAMESPACE, END_VISP_N...

#ifdef VISP_BUILD_DEPRECATED_FUNCTIONS
#include <iostream> /* Classe std::ostream. */
#include <string> /* Classe string. */

#include <visp3/core/vpException.h> // for vpException
#include <string> // for string

BEGIN_VISP_NAMESPACE
/*!
Expand Down
23 changes: 18 additions & 5 deletions modules/ar/src/panda3d-simulator/vpPanda3DBaseRenderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,29 @@
* WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*/

#include <visp3/ar/vpPanda3DBaseRenderer.h>
#include <visp3/core/vpConfig.h> // for BEGIN_VISP_NAMESPACE

#if defined(VISP_HAVE_PANDA3D)

#include <visp3/core/vpMath.h>
#include <limits> // for numeric_limits
#include <memory> // for shared_ptr, __shared...
#include <string> // for basic_string, string
#include <vector> // for vector

#include "load_prc_file.h"
#include <antialiasAttrib.h>
#include "boundingSphere.h"
#include "boundingBox.h"

#include <boundingBox.h> // for BoundingBox
#include <boundingSphere.h> // for BoundingSphere

#include <visp3/ar/vpPanda3DBaseRenderer.h> // for vpPanda3DBaseRenderer
#include <visp3/ar/vpPanda3DRenderParameters.h> // for vpPanda3DRenderParam...
#include <visp3/core/vpException.h> // for vpException
#include <visp3/core/vpQuaternionVector.h> // for vpQuaternionVector
#include <visp3/core/vpRotationMatrix.h> // for vpRotationMatrix
#include <visp3/core/vpTranslationVector.h> // for vpTranslationVector
#include <visp3/core/vpColVector.h> // for vpColVector
#include <visp3/core/vpHomogeneousMatrix.h> // for vpHomogeneousMatrix
#include <visp3/core/vpMath.h> // for vpMath

BEGIN_VISP_NAMESPACE
const vpHomogeneousMatrix vpPanda3DBaseRenderer::VISP_T_PANDA({
Expand Down
16 changes: 14 additions & 2 deletions modules/ar/src/panda3d-simulator/vpPanda3DCommonFilters.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,24 @@
* WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*/

#include <visp3/ar/vpPanda3DCommonFilters.h>
#include <visp3/ar/vpPanda3DRGBRenderer.h>
#include <visp3/core/vpConfig.h> // for BEGIN_VISP_NAMESPACE

#if defined(VISP_HAVE_PANDA3D)

#include <utility> // for move
#include <memory> // for shared_ptr
#include <string> // for basic_string, string

#include <visp3/ar/vpPanda3DCommonFilters.h>
#include <visp3/ar/vpPanda3DPostProcessFilter.h> // for vpPanda3DPostProces...
#include <visp3/ar/vpPanda3DRGBRenderer.h> // for vpPanda3DRGBRenderer

BEGIN_VISP_NAMESPACE

class vpPanda3DBaseRenderer;
class vpRGBf;
template <class Type> class vpImage;

const std::string vpPanda3DLuminanceFilter::FRAGMENT_SHADER =
"#version 330\n"
"in vec2 texcoords;\n"
Expand Down
15 changes: 13 additions & 2 deletions modules/ar/src/panda3d-simulator/vpPanda3DGeometryRenderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,22 @@
* WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*/

#include <visp3/core/vpConfig.h>
#include <visp3/core/vpConfig.h> // for BEGIN_VISP_NAMESPACE

#if defined(VISP_HAVE_PANDA3D)

#include <visp3/ar/vpPanda3DGeometryRenderer.h>
#include <utility> // for move
#include <vector> // for vector
#include <algorithm> // for max
#include <string> // for basic_string, string

#include <visp3/ar/vpPanda3DBaseRenderer.h> // for vpPanda3DBaseRenderer
#include <visp3/ar/vpPanda3DGeometryRenderer.h> // for vpPanda3DGeometryRen...
#include <visp3/ar/vpPanda3DRenderParameters.h> // for vpPanda3DRenderParam...
#include <visp3/core/vpException.h> // for vpException
#include <visp3/core/vpImage.h> // for vpImage
#include <visp3/core/vpRGBf.h> // for vpRGBf
#include <visp3/core/vpRect.h> // for vpRect

BEGIN_VISP_NAMESPACE

Expand Down
Loading

0 comments on commit 94fe282

Please sign in to comment.