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

Render-Based Tracking #1467

Draft
wants to merge 86 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
86 commits
Select commit Hold shift + click to select a range
b15541c
Render based tracking module
SamFlt Sep 17, 2024
6affb4b
Add guards for openmp usage, add guards for vpRBKltTracker
SamFlt Sep 18, 2024
aee5e20
Stopped using initClick from vpMbTracker
SamFlt Sep 18, 2024
c604448
Working on visp openmp directive
SamFlt Sep 18, 2024
c5ffc86
Make copy and move assignment operators default for vpRGBa and vpRGBf…
SamFlt Sep 19, 2024
dd16fdc
Removed pragma omp macro as it cannot be reliably used and messes wit…
SamFlt Sep 19, 2024
25635f9
Fix most warnings from the initial commit
SamFlt Sep 19, 2024
635acf8
Added C++17 checks to ensure that vpRGBa and vpRGBf are trivially cop…
SamFlt Sep 19, 2024
9e5c1b7
Moved klt parameters json serialization to vpKltOpencv, working on be…
SamFlt Sep 19, 2024
f14d375
Group classes in doxygen, settings for klt tracker~
SamFlt Sep 19, 2024
90e288f
Update panda3D install documentation
SamFlt Sep 19, 2024
61856bf
Add namespace guards so that compiling with namespace is supported
SamFlt Sep 19, 2024
1ca277f
Try to fix include guards for trivially copyable in vprgba/vprgbf
SamFlt Sep 19, 2024
bf8b14c
Fix serialization issue with klt tracker
SamFlt Sep 19, 2024
f8308a0
More settings getters and setters
SamFlt Sep 19, 2024
2c12e9c
Fix build issues, compiling with Python bindings on
SamFlt Sep 20, 2024
8839bc3
Merge branch 'master' into module_rbt_fs
fspindle Sep 20, 2024
924019a
Merge branch 'cmake_system_include_dirs' into module_rbt_fs
fspindle Sep 20, 2024
b2fb0a0
Fix warning: field 'enableRenderProfiling' will be initialized after …
fspindle Sep 20, 2024
be51bd2
Fix warnings: unused variable and comparison of integers of different…
fspindle Sep 20, 2024
87f4958
Fix warning: delete called on non-final 'vpColorHistogramMask' that h…
fspindle Sep 20, 2024
af259d6
Fix warning: 'loadJsonConfiguration' overrides a member function but …
fspindle Sep 20, 2024
50ab251
Fix warning: private field 'm_normalAcceptanceThresholdDeg' is not used
fspindle Sep 20, 2024
3938d71
Fix warning: delete called on non-final 'vpRBDenseDepthTracker, vpRBF…
fspindle Sep 20, 2024
f2e907b
Update with new headers
fspindle Sep 20, 2024
718ffa3
Covariance computation initial pass
SamFlt Sep 20, 2024
682190e
Remove prints related to covariance
SamFlt Sep 20, 2024
a8bc61f
Introduce plane initialization from a point and the normal of the plane
fspindle Sep 20, 2024
4c85624
Fix doxygen warnings and clean code
fspindle Sep 20, 2024
85d5203
Merge branch 'module_rbt' into module_rbt_fs
fspindle Sep 20, 2024
c6201ab
setup vs code for json formatting
SamFlt Sep 20, 2024
13d596b
Merge pull request #1 from SamFlt/module_rbt_fs
SamFlt Sep 20, 2024
7487929
cleanup ccd tracker
SamFlt Sep 20, 2024
dab15b8
cleanup silhouette point
SamFlt Sep 20, 2024
161d97e
mestimator setting for silhouetteMe
SamFlt Sep 20, 2024
5afaf5b
Merge branch 'master' into module_rbt
fspindle Sep 21, 2024
57793f3
Cleanup klt tracker
SamFlt Sep 23, 2024
52267a9
Fix virtual destructor being private, non const argument in vpColorHi…
SamFlt Sep 23, 2024
c6b4f4a
Python bindings: rbt config, enable parallel LTO when supported by co…
SamFlt Sep 23, 2024
8192170
Trampoline class for feature tracker, initial version
SamFlt Sep 23, 2024
b09b6f1
working on python example
SamFlt Sep 23, 2024
8cbee82
Setup testing rbt module, testing basic configuration/user api
SamFlt Sep 24, 2024
da11d4d
Realsense example works in Python
SamFlt Sep 24, 2024
dff31fd
Fix lto optimization generating cmake errors
SamFlt Sep 24, 2024
4dfd6f3
Fixed trampoline class to avoid copying frames, fixed rendering extra…
SamFlt Sep 24, 2024
d4ecd40
Fix display having wrong override name
SamFlt Sep 24, 2024
86681cf
more testing of json serialization
SamFlt Sep 24, 2024
ba06f4b
Optimize klt by introducing roi
SamFlt Sep 25, 2024
027ca12
working on testing rbt on synthetic sequences, there is an issue with…
SamFlt Sep 26, 2024
60d9a40
Some more cleanup for python
SamFlt Sep 27, 2024
26469c7
Fixed python members export to Python bindings
SamFlt Oct 1, 2024
8d9c56a
Fixed indexing issue in python bindings, Silhouette ccd tracker inver…
SamFlt Oct 1, 2024
45044a2
working on numpy indexing for images (setitem)
SamFlt Oct 2, 2024
004f626
Testing basic setitem
SamFlt Oct 3, 2024
27d9e88
Merge branch 'master' into module_rbt
fspindle Oct 3, 2024
51771ff
Indexing for arrays
SamFlt Oct 3, 2024
3a01432
Merge branch 'module_rbt' of github.com:SamFlt/visp into module_rbt
SamFlt Oct 3, 2024
56fd3fd
remove commented test
SamFlt Oct 3, 2024
5b2bfe5
1D indexing for vectors
SamFlt Oct 3, 2024
a77bc79
Revert changes
fspindle Oct 4, 2024
be6ad2f
Rename rbt test with catch prefix
fspindle Oct 4, 2024
c4bf9c4
Link catch2 only to the tests
fspindle Oct 4, 2024
32a571c
Link dnn module to nlohman json 3rd party
fspindle Oct 4, 2024
62a372f
Remove empty lines
fspindle Oct 4, 2024
0123000
Make shaders as std::string instead of char *
fspindle Oct 4, 2024
f47dabe
Fix wrong catch2 header
fspindle Oct 4, 2024
9d199e9
Create object using std::string
fspindle Oct 4, 2024
2b4106b
Fix wrong indexing exception
SamFlt Oct 4, 2024
8d0a4f2
Update border in ccd tracker
SamFlt Oct 4, 2024
ce86309
Setup trampoline class for visual odometry interface
SamFlt Oct 8, 2024
4b3a38a
Change base settings for dragon, init image
SamFlt Oct 8, 2024
45cf1b6
Merge branch 'module_rbt' of github.com:SamFlt/visp into module_rbt
SamFlt Oct 8, 2024
5aef239
Add VO pointer and call to RBT main class
SamFlt Oct 8, 2024
8c2f966
Fix VO trampoline class
SamFlt Oct 11, 2024
80261ed
Debugging odometry usage, logging times
SamFlt Oct 11, 2024
ff763b8
Move call to odometry
SamFlt Oct 14, 2024
3c7942f
Merge branch 'master' into module_rbt
fspindle Oct 15, 2024
d7c674f
Revert changes related to buildFrom()
fspindle Oct 15, 2024
dc306ad
Add missing visp_sensor module
fspindle Oct 15, 2024
656d4c9
Add missing trampolines
SamFlt Oct 15, 2024
52dbbb0
re enable rendering after call to odometry
SamFlt Oct 15, 2024
d7e577a
remove debug print
SamFlt Oct 15, 2024
c1cf355
Fix warning: ‘void* memset(void*, int, size_t)’ clearing an object of…
fspindle Oct 16, 2024
87ba32d
Restore default ostream precision
fspindle Oct 16, 2024
600bfd2
Fix comment alignment
fspindle Oct 16, 2024
02b4911
Introduce getter/setter/json serialization to handle a verbose mode
fspindle Oct 16, 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
3 changes: 3 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -205,4 +205,7 @@
{"column": 120, "color": "#ffcc00"}
],
"C_Cpp.default.compilerPath": "/usr/bin/g++",
"[json]": {
"editor.defaultFormatter": "vscode.json-language-features"
},
}
63 changes: 63 additions & 0 deletions doc/mainpage.dox.in
Original file line number Diff line number Diff line change
Expand Up @@ -526,6 +526,69 @@ in different ways. This will motivate us to continue the efforts.
\defgroup group_mbt_xml_parser XML parsers
XML parsers dedicated to model-based trackers.
*/


/*******************************************
* Module rbt
*******************************************/
/*!
\ingroup module_tracker
\defgroup module_rbt RBT: Render-Based Tracker module
Render-Based Tracker module
*/

/*!
\ingroup module_rbt
\defgroup group_rbt_core Core Render-Based Tracking functionalities

This group contains the core classes that make Render-Based tracking work. The main interface for Render-Based tracking is vpRBTracker.
*/

/*!
\ingroup module_rbt
\defgroup group_rbt_trackers Trackable features

These classes represent features that can be tracked by the render-based tracker. All trackable features should inherit from vpRBFeatureTracker

*/

/*!
\ingroup module_rbt
\defgroup group_rbt_mask Object segmentation

These classes allow to perform object segmentaiton from rendering information. This segmentation may be used downstream by feature trackers to filter features.
*/

/*!
\ingroup module_rbt
\defgroup group_rbt_drift Drift and divergence detection

These classes allow to detect tracking drift.
*/

/*!
\ingroup module_rbt
\defgroup group_rbt_rendering Rendering

This group contains additional rendering utilities.
*/

/*!
\ingroup module_mbt
\defgroup group_mbt_features Features
Model-based trackers features.
*/
/*!
\ingroup module_mbt
\defgroup group_mbt_faces Faces management
Faces management including visibility.
*/
/*!
\ingroup module_mbt
\defgroup group_mbt_xml_parser XML parsers
XML parsers dedicated to model-based trackers.
*/

/*******************************************
* Module robot
*******************************************/
Expand Down
33 changes: 32 additions & 1 deletion doc/tutorial/rendering/tutorial-panda3d.dox
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,14 @@ vpPanda3DBaseRenderer, which implements basic functions for a panda renderer.
\section tutorial-panda3d-install Panda3D installation
\subsection tutorial-panda3d-install-ubuntu Installation on Ubuntu

- It is recommended to install the assimp package before installing Panda3D. This will allow you to load .obj files, which are a common and easily exportable format.
Without it, you will be restricted to .bam files, which is a panda specific format. To convert to a .bam file, see \ref tutorial-panda3d-file-conversion.

To install assimp, run:
\code{.sh}
$ sudo apt install libassimp-dev
\endcode

- Installer are available for Ubuntu browsing the [download](https://www.panda3d.org/download/) page.

- Hereafter you will find the instructions to build and install Panda3D from source on Ubuntu 22.04
Expand Down Expand Up @@ -90,6 +98,14 @@ vpPanda3DBaseRenderer, which implements basic functions for a panda renderer.

- Hereafter you will find the instructions to build Panda3D from source on macOS.

- It is recommended to install the assimp package before installing Panda3D. This will allow you to load .obj files, which are a common and easily exportable format.
Without it, you will be restricted to .bam files, which is a panda specific format. To convert to a .bam file, see \ref tutorial-panda3d-file-conversion.

To install assimp, run:
\code{.sh}
$ brew install assimp
\endcode

- On macOS, you will need to download a set of precompiled third-party packages in order to compile Panda3D.
Navigate to PandaED [download page](https://www.panda3d.org/download/), select the lastest SDK
(in our case SDK 1.10.14), and under `</> Source Code` section, download
Expand All @@ -113,7 +129,7 @@ vpPanda3DBaseRenderer, which implements basic functions for a panda renderer.
\endcode
- Build Panda3D from source
\code{.sh}
$ python3 makepanda/makepanda.py --everything --installer --no-egl --no-gles --no-gles2 --no-opencv --no-python --threads $(sysctl -n hw.logicalcpu)
$ python3 makepanda/makepanda.py --everything --installer --no-opencv --no-python --threads $(sysctl -n hw.logicalcpu)
\endcode

- At this point you can either
Expand Down Expand Up @@ -165,6 +181,21 @@ vpPanda3DBaseRenderer, which implements basic functions for a panda renderer.

- Installer are available for Windows browsing the [download](https://www.panda3d.org/download/) page.

\section tutorial-panda3d-file-conversion Converting a mesh to Panda's file format

If you did not install assimp before installing Panda, you are fairly restricted in what mesh format you can load with Panda.

Panda's recommended format is .bam, a binary format specific to the engine itself.
If you have Python, you can easily convert your model to a .bam file by doing the following:

1. Installing the panda3D-gltf package: `pip install panda3d-gltf`
2. From your favorite 3D modelling software export your model to GLTF (available in blender)
3. Running the converter tool:
\code{.sh}
$ gltf2bam source.gltf output.bam
\endcode
4. If you encounter issues, check the tool's settings with `gltf2bam -h`

\section tutorial-panda3d-usage Using Panda3D for rendering

An example that shows how to exploit Panda3D in ViSP to render a color image with support for textures and lighting, a
Expand Down
4 changes: 3 additions & 1 deletion modules/ar/include/visp3/ar/vpPanda3DPostProcessFilter.h
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,10 @@ class VISP_EXPORT vpPanda3DPostProcessFilter : public vpPanda3DBaseRenderer
PointerTo<Texture> m_texture;
PointerTo<GraphicsOutput> m_buffer;

static const char *FILTER_VERTEX_SHADER;
static const std::string FILTER_VERTEX_SHADER;
};

END_VISP_NAMESPACE

#endif
#endif
4 changes: 2 additions & 2 deletions modules/ar/include/visp3/ar/vpPanda3DRGBRenderer.h
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,8 @@ class VISP_EXPORT vpPanda3DRGBRenderer : public vpPanda3DBaseRenderer, public vp
bool m_showSpeculars;
PointerTo<Texture> m_colorTexture;
PointerTo<GraphicsOutput> m_colorBuffer;
static const char *COOK_TORRANCE_VERT;
static const char *COOK_TORRANCE_FRAG;
static const std::string COOK_TORRANCE_VERT;
static const std::string COOK_TORRANCE_FRAG;

NodePath m_backgroundImage;
PointerTo<DisplayRegion> m_display2d;
Expand Down
29 changes: 14 additions & 15 deletions modules/ar/src/panda3d-simulator/vpPanda3DPostProcessFilter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,19 +35,18 @@
#include <lightRampAttrib.h>

BEGIN_VISP_NAMESPACE
const char *vpPanda3DPostProcessFilter::FILTER_VERTEX_SHADER = R"shader(
#version 330
in vec4 p3d_Vertex;
uniform mat4 p3d_ModelViewProjectionMatrix;
in vec2 p3d_MultiTexCoord0;
out vec2 texcoords;

void main()
{
gl_Position = p3d_ModelViewProjectionMatrix * p3d_Vertex;
texcoords = p3d_MultiTexCoord0;
}
)shader";
const std::string vpPanda3DPostProcessFilter::FILTER_VERTEX_SHADER =
"#version 330\n"
"in vec4 p3d_Vertex;\n"
"uniform mat4 p3d_ModelViewProjectionMatrix;\n"
"in vec2 p3d_MultiTexCoord0;\n"
"out vec2 texcoords;\n"

"void main()\n"
"{\n"
" gl_Position = p3d_ModelViewProjectionMatrix * p3d_Vertex;\n"
" texcoords = p3d_MultiTexCoord0;\n"
"}\n";

void vpPanda3DPostProcessFilter::setupScene()
{
Expand All @@ -62,8 +61,8 @@ void vpPanda3DPostProcessFilter::setupScene()
"Cannot add a postprocess filter to a renderer that does not define getMainOutputBuffer()");
}
m_shader = Shader::make(Shader::ShaderLanguage::SL_GLSL,
FILTER_VERTEX_SHADER,
m_fragmentShader);
FILTER_VERTEX_SHADER,
m_fragmentShader);
m_renderRoot.set_shader(m_shader);
m_renderRoot.set_shader_input("dp", LVector2f(1.0 / buffer->get_texture()->get_x_size(), 1.0 / buffer->get_texture()->get_y_size()));
m_renderRoot.set_texture(buffer->get_texture());
Expand Down
8 changes: 4 additions & 4 deletions modules/ar/src/panda3d-simulator/vpPanda3DRGBRenderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
#include "texturePool.h"

BEGIN_VISP_NAMESPACE
const char *vpPanda3DRGBRenderer::COOK_TORRANCE_VERT =
const std::string vpPanda3DRGBRenderer::COOK_TORRANCE_VERT =
"#version 330\n"
"in vec3 p3d_Normal;\n"
"in vec4 p3d_Vertex;\n"
Expand Down Expand Up @@ -76,7 +76,7 @@ const char *vpPanda3DRGBRenderer::COOK_TORRANCE_VERT =
" F0 = computeF0(p3d_Material.refractiveIndex, p3d_Material.metallic, p3d_Material.baseColor.xyz);\n"
"}\n";

const char *vpPanda3DRGBRenderer::COOK_TORRANCE_FRAG =
const std::string vpPanda3DRGBRenderer::COOK_TORRANCE_FRAG =
"// Version 330, specified when generating shader\n"
"#define M_PI 3.1415926535897932384626433832795\n"
"in vec3 oNormal;\n"
Expand Down Expand Up @@ -200,8 +200,8 @@ void vpPanda3DRGBRenderer::addNodeToScene(const NodePath &object)
}

PT(Shader) shader = Shader::make(Shader::ShaderLanguage::SL_GLSL,
COOK_TORRANCE_VERT,
makeFragmentShader(hasTexture, m_showSpeculars));
COOK_TORRANCE_VERT,
makeFragmentShader(hasTexture, m_showSpeculars));

objectInScene.set_shader(shader);

Expand Down
2 changes: 2 additions & 0 deletions modules/ar/src/panda3d-simulator/vpPanda3DRendererSet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,8 @@ void vpPanda3DRendererSet::enableSharedDepthBuffer(vpPanda3DBaseRenderer &source
}
}

END_VISP_NAMESPACE

#elif !defined(VISP_BUILD_SHARED_LIBS)
// Work around to avoid warning: libvisp_ar.a(vpPanda3DRendererSet.cpp.o) has no symbols
void dummy_vpPanda3DRendererSet() { };
Expand Down
16 changes: 8 additions & 8 deletions modules/core/include/visp3/core/vpPlane.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,9 @@ BEGIN_VISP_NAMESPACE

\brief This class defines the container for a plane geometrical structure.

A plane is given by the equation \f$Ax + By + Cz + D = 0\f$ where
(x,y,z) are the coordinates of a point and where \f$[A,B,C]^T\f$ is a normal
A plane is given by the equation \f$A*X + B*Y + C*Z + D = 0\f$ where
(X,Y,Z) are the coordinates of a point and where \f$[A,B,C]^T\f$ is the normal
vector of the plane.

*/
class VISP_EXPORT vpPlane
{
Expand All @@ -66,14 +65,15 @@ class VISP_EXPORT vpPlane
vpPlane();
vpPlane(const vpPlane &P);
vpPlane(double A, double B, double C, double D);
vpPlane(const vpPoint &P, const vpColVector &n, vpPlaneFrame frame = camera_frame);
vpPlane(const vpPoint &P, const vpColVector &normal, vpPlaneFrame frame = camera_frame);
vpPlane(const vpPoint &P, const vpPoint &Q, const vpPoint &R, vpPlaneFrame frame = camera_frame);

double computeZ(double x, double y) const;

void init(const vpPoint &P, const vpPoint &Q, const vpPoint &R, vpPlaneFrame frame = camera_frame);
void init(const vpColVector &P, const vpColVector &n);
void init(const vpPlane &P);
vpPlane &init(const vpPoint &P, const vpColVector &normal, vpPlaneFrame frame = camera_frame);
vpPlane &init(const vpPoint &P, const vpPoint &Q, const vpPoint &R, vpPlaneFrame frame = camera_frame);
vpPlane &init(const vpColVector &P, const vpColVector &n);
vpPlane &init(const vpPlane &P);

// SET the parameter
/*! Set plane parameter A. */
Expand Down Expand Up @@ -157,7 +157,7 @@ class VISP_EXPORT vpPlane
friend VISP_EXPORT std::ostream &operator<<(std::ostream &os, const vpPlane &p);

// Operation with Plane
void projectionPointOnPlan(const vpPoint &P, vpPoint &Pproj) const;
void projectionPointOnPlan(const vpPoint &P, vpPoint &Pproj, vpPlaneFrame frame = camera_frame) const;

double rayIntersection(const vpPoint &M0, const vpPoint &M1, vpColVector &H) const;

Expand Down
17 changes: 14 additions & 3 deletions modules/core/include/visp3/core/vpRGBa.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,11 @@
#include <visp3/core/vpConfig.h>
#include <visp3/core/vpColVector.h>

#if ((__cplusplus >= 201703L) || (defined(_MSVC_LANG) && (_MSVC_LANG >= 201703L)))
#include <type_traits>
#endif


BEGIN_VISP_NAMESPACE
/*!
\class vpRGBa
Expand Down Expand Up @@ -123,7 +128,7 @@ class VISP_EXPORT vpRGBa
/*!
Copy constructor.
*/
inline vpRGBa(const vpRGBa &v) : R(v.R), G(v.G), B(v.B), A(v.A) { }
inline vpRGBa(const vpRGBa &v) = default;

/*!
Create a RGBa value from a 4 dimension column vector.
Expand All @@ -143,9 +148,9 @@ class VISP_EXPORT vpRGBa
vpRGBa &operator=(const unsigned char &v);
vpRGBa &operator=(const unsigned int &v);
vpRGBa &operator=(const int &v);
vpRGBa &operator=(const vpRGBa &v);
vpRGBa &operator=(const vpRGBa &v) = default;
#if (VISP_CXX_STANDARD >= VISP_CXX_STANDARD_11)
vpRGBa &operator=(const vpRGBa &&v);
vpRGBa &operator=(vpRGBa &&v) = default;
#endif
vpRGBa &operator=(const vpColVector &v);
bool operator==(const vpRGBa &v) const;
Expand All @@ -171,5 +176,11 @@ class VISP_EXPORT vpRGBa

friend VISP_EXPORT vpRGBa operator*(const double &x, const vpRGBa &rgb);
};

#if ((__cplusplus >= 201703L) || (defined(_MSVC_LANG) && (_MSVC_LANG >= 201703L)))
static_assert(std::is_trivially_assignable_v<vpRGBa, vpRGBa>);
static_assert(std::is_trivially_copyable_v<vpRGBa>);
#endif

END_VISP_NAMESPACE
#endif
17 changes: 14 additions & 3 deletions modules/core/include/visp3/core/vpRGBf.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@
#include <visp3/core/vpConfig.h>
#include <visp3/core/vpColVector.h>

#if ((__cplusplus >= 201703L) || (defined(_MSVC_LANG) && (_MSVC_LANG >= 201703L)))
#include <type_traits>
#endif

BEGIN_VISP_NAMESPACE

/*!
Expand Down Expand Up @@ -103,7 +107,7 @@ class VISP_EXPORT vpRGBf
/*!
Copy constructor.
*/
inline vpRGBf(const vpRGBf &v) : R(v.R), G(v.G), B(v.B) { }
inline vpRGBf(const vpRGBf &v) = default;

/*!
Create a RGB value from a 3 dimensional column vector.
Expand All @@ -116,9 +120,9 @@ class VISP_EXPORT vpRGBf

vpRGBf &operator=(float v);
vpRGBf &operator=(int v);
vpRGBf &operator=(const vpRGBf &v);
vpRGBf &operator=(const vpRGBf &v) = default;
#if (VISP_CXX_STANDARD >= VISP_CXX_STANDARD_11)
vpRGBf &operator=(const vpRGBf &&v);
vpRGBf &operator=(vpRGBf &&v) = default;
#endif
vpRGBf &operator=(const vpColVector &v);
bool operator==(const vpRGBf &v) const;
Expand All @@ -144,5 +148,12 @@ class VISP_EXPORT vpRGBf
friend VISP_EXPORT vpRGBf operator*(double x, const vpRGBf &rgb);
friend VISP_EXPORT vpRGBf operator*(float x, const vpRGBf &rgb);
};

#if ((__cplusplus >= 201703L) || (defined(_MSVC_LANG) && (_MSVC_LANG >= 201703L)))
static_assert(std::is_trivially_assignable_v<vpRGBf, vpRGBf>);
static_assert(std::is_trivially_copyable_v<vpRGBf>);
#endif

END_VISP_NAMESPACE

#endif
Loading
Loading