Zivid C++ API 2.10.1+50b274e8-7
Defining the Future of 3D Machine Vision
Settings.h
Go to the documentation of this file.
1
2
3/*******************************************************************************
4
5 * This file is part of the Zivid 3D Camera API
6
7 *
8
9 * Copyright 2015-2023 (C) Zivid AS
10
11 * All rights reserved.
12
13 *
14
15 * Zivid Software License, v1.0
16
17 *
18
19 * Redistribution and use in source and binary forms, with or without
20
21 * modification, are permitted provided that the following conditions are met:
22
23 *
24
25 * 1. Redistributions of source code must retain the above copyright notice,
26
27 * this list of conditions and the following disclaimer.
28
29 *
30
31 * 2. Redistributions in binary form must reproduce the above copyright notice,
32
33 * this list of conditions and the following disclaimer in the documentation
34
35 * and/or other materials provided with the distribution.
36
37 *
38
39 * 3. Neither the name of Zivid AS nor the names of its contributors may be used
40
41 * to endorse or promote products derived from this software without specific
42
43 * prior written permission.
44
45 *
46
47 * 4. This software, with or without modification, must not be used with any
48
49 * other 3D camera than from Zivid AS.
50
51 *
52
53 * 5. Any software provided in binary form under this license must not be
54
55 * reverse engineered, decompiled, modified and/or disassembled.
56
57 *
58
59 * THIS SOFTWARE IS PROVIDED BY ZIVID AS "AS IS" AND ANY EXPRESS OR IMPLIED
60
61 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
62
63 * MERCHANTABILITY, NONINFRINGEMENT, AND FITNESS FOR A PARTICULAR PURPOSE ARE
64
65 * DISCLAIMED. IN NO EVENT SHALL ZIVID AS OR CONTRIBUTORS BE LIABLE FOR ANY
66
67 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
68
69 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
70
71 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
72
73 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
74
75 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
76
77 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
78
79 *
80
81 * Contact: Zivid Customer Success Team <customersuccess@zivid.com>
82
83 * Info: http://www.zivid.com
84
85 ******************************************************************************/
86
87
88
89#pragma once
90
91#include <array>
92#include <chrono>
93#include <cmath>
94#include <ctime>
95#include <iomanip>
96#include <memory>
97#include <set>
98#include <sstream>
99#include <string>
100#include <tuple>
101#include <utility>
102#include <vector>
103
109#include "Zivid/Point.h"
110#include "Zivid/Range.h"
111
112#ifdef _MSC_VER
113# pragma warning(push)
114# pragma warning(disable : 4251) // "X needs to have dll-interface to be used by clients of class Y."
115#endif
116
117namespace Zivid
118{
119
121
122 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
124 {
125 public:
128
130 static constexpr const char *path{ "" };
131
133 static constexpr const char *name{ "Settings" };
134
136 static constexpr const char *description{
137 R"description(Settings used when capturing with a Zivid camera)description"
138 };
139
140 static constexpr size_t version{ 21 };
141
142#ifndef NO_DOC
143 template<size_t>
144 struct Version;
145
146 using LatestVersion = Zivid::Settings;
147
148 // Short identifier. This value is not guaranteed to be universally unique
149 // Todo(ZIVID-2808): Move this to internal DataModelExt header
150 static constexpr std::array<uint8_t, 3> binaryId{ 's', 'e', 't' };
151
152#endif
153
155
156 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
158 {
159 public:
162
164 static constexpr const char *path{ "Acquisition" };
165
167 static constexpr const char *name{ "Acquisition" };
168
170 static constexpr const char *description{ R"description(Settings for a single acquisition)description" };
171
175
176 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
178 {
179 public:
182
184 static constexpr const char *path{ "Acquisition/Aperture" };
185
187 static constexpr const char *name{ "Aperture" };
188
190 static constexpr const char *description{
191 R"description(Aperture setting for the camera. Specified as an f-number (the ratio of lens focal length to
192the effective aperture diameter).
193)description"
194 };
195
197 using ValueType = double;
198
200 static constexpr Range<double> validRange()
201 {
202 return { 1.4, 32.0 };
203 }
204
206 Aperture() = default;
207
209 explicit constexpr Aperture(double value)
210 : m_opt{ verifyValue(value) }
211 {}
212
217 double value() const;
218
220 bool hasValue() const;
221
223 void reset();
224
226 std::string toString() const;
227
229 bool operator==(const Aperture &other) const
230 {
231 return m_opt == other.m_opt;
232 }
233
235 bool operator!=(const Aperture &other) const
236 {
237 return m_opt != other.m_opt;
238 }
239
241 bool operator<(const Aperture &other) const
242 {
243 return m_opt < other.m_opt;
244 }
245
247 bool operator>(const Aperture &other) const
248 {
249 return m_opt > other.m_opt;
250 }
251
253 bool operator<=(const Aperture &other) const
254 {
255 return m_opt <= other.m_opt;
256 }
257
259 bool operator>=(const Aperture &other) const
260 {
261 return m_opt >= other.m_opt;
262 }
263
265 friend std::ostream &operator<<(std::ostream &stream, const Aperture &value)
266 {
267 return stream << value.toString();
268 }
269
270 private:
271 void setFromString(const std::string &value);
272
273 constexpr ValueType static verifyValue(const ValueType &value)
274 {
275 return validRange().isInRange(value)
276 ? value
277 : throw std::out_of_range{ "Aperture{ " + std::to_string(value) + " } is not in range ["
278 + std::to_string(validRange().min()) + ", "
279 + std::to_string(validRange().max()) + "]" };
280 }
281
282 Zivid::DataModel::Detail::Optional<double> m_opt;
283
284 friend struct DataModel::Detail::Befriend<Aperture>;
285 };
286
298
299 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
301 {
302 public:
305
307 static constexpr const char *path{ "Acquisition/Brightness" };
308
310 static constexpr const char *name{ "Brightness" };
311
313 static constexpr const char *description{
314 R"description(Brightness controls the light output from the projector.
315
316Brightness above 1.0 may be needed when the distance between the camera and the scene is large,
317or in case of high levels of ambient lighting.
318
319When brightness is above 1.0 the duty cycle of the camera (the percentage of time the camera
320can capture) will be reduced. The duty cycle in boost mode is 50%. The duty cycle is calculated
321over a 10 second period. This limitation is enforced automatically by the camera. Calling capture
322when the duty cycle limit has been reached will cause the camera to first wait (sleep) for a
323duration of time to cool down, before capture will start.
324)description"
325 };
326
328 using ValueType = double;
329
331 static constexpr Range<double> validRange()
332 {
333 return { 0, 2.5 };
334 }
335
337 Brightness() = default;
338
340 explicit constexpr Brightness(double value)
341 : m_opt{ verifyValue(value) }
342 {}
343
348 double value() const;
349
351 bool hasValue() const;
352
354 void reset();
355
357 std::string toString() const;
358
360 bool operator==(const Brightness &other) const
361 {
362 return m_opt == other.m_opt;
363 }
364
366 bool operator!=(const Brightness &other) const
367 {
368 return m_opt != other.m_opt;
369 }
370
372 bool operator<(const Brightness &other) const
373 {
374 return m_opt < other.m_opt;
375 }
376
378 bool operator>(const Brightness &other) const
379 {
380 return m_opt > other.m_opt;
381 }
382
384 bool operator<=(const Brightness &other) const
385 {
386 return m_opt <= other.m_opt;
387 }
388
390 bool operator>=(const Brightness &other) const
391 {
392 return m_opt >= other.m_opt;
393 }
394
396 friend std::ostream &operator<<(std::ostream &stream, const Brightness &value)
397 {
398 return stream << value.toString();
399 }
400
401 private:
402 void setFromString(const std::string &value);
403
404 constexpr ValueType static verifyValue(const ValueType &value)
405 {
406 return validRange().isInRange(value)
407 ? value
408 : throw std::out_of_range{ "Brightness{ " + std::to_string(value)
409 + " } is not in range [" + std::to_string(validRange().min())
410 + ", " + std::to_string(validRange().max()) + "]" };
411 }
412
413 Zivid::DataModel::Detail::Optional<double> m_opt;
414
415 friend struct DataModel::Detail::Befriend<Brightness>;
416 };
417
419
420 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
422 {
423 public:
426
428 static constexpr const char *path{ "Acquisition/ExposureTime" };
429
431 static constexpr const char *name{ "ExposureTime" };
432
434 static constexpr const char *description{
435 R"description(Exposure time for each single image in the measurement. Affects frame rate.)description"
436 };
437
439 using ValueType = std::chrono::microseconds;
440
443 {
444 return { std::chrono::microseconds{ 1677 }, std::chrono::microseconds{ 100000 } };
445 }
446
448 ExposureTime() = default;
449
451 explicit constexpr ExposureTime(std::chrono::microseconds value)
452 : m_opt{ verifyValue(value) }
453 {}
454
459 std::chrono::microseconds value() const;
460
462 bool hasValue() const;
463
465 void reset();
466
468 std::string toString() const;
469
471 bool operator==(const ExposureTime &other) const
472 {
473 return m_opt == other.m_opt;
474 }
475
477 bool operator!=(const ExposureTime &other) const
478 {
479 return m_opt != other.m_opt;
480 }
481
483 bool operator<(const ExposureTime &other) const
484 {
485 return m_opt < other.m_opt;
486 }
487
489 bool operator>(const ExposureTime &other) const
490 {
491 return m_opt > other.m_opt;
492 }
493
495 bool operator<=(const ExposureTime &other) const
496 {
497 return m_opt <= other.m_opt;
498 }
499
501 bool operator>=(const ExposureTime &other) const
502 {
503 return m_opt >= other.m_opt;
504 }
505
507 friend std::ostream &operator<<(std::ostream &stream, const ExposureTime &value)
508 {
509 return stream << value.toString();
510 }
511
512 private:
513 void setFromString(const std::string &value);
514
515 constexpr ValueType static verifyValue(const ValueType &value)
516 {
517 return validRange().isInRange(value)
518 ? value
519 : throw std::out_of_range{ "ExposureTime{ " + std::to_string(value.count())
520 + " } is not in range ["
521 + std::to_string(validRange().min().count()) + ", "
522 + std::to_string(validRange().max().count()) + "]" };
523 }
524
525 Zivid::DataModel::Detail::Optional<std::chrono::microseconds> m_opt;
526
527 friend struct DataModel::Detail::Befriend<ExposureTime>;
528 };
529
531
532 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
534 {
535 public:
538
540 static constexpr const char *path{ "Acquisition/Gain" };
541
543 static constexpr const char *name{ "Gain" };
544
546 static constexpr const char *description{ R"description(Analog gain in the camera)description" };
547
549 using ValueType = double;
550
552 static constexpr Range<double> validRange()
553 {
554 return { 1, 16 };
555 }
556
558 Gain() = default;
559
561 explicit constexpr Gain(double value)
562 : m_opt{ verifyValue(value) }
563 {}
564
569 double value() const;
570
572 bool hasValue() const;
573
575 void reset();
576
578 std::string toString() const;
579
581 bool operator==(const Gain &other) const
582 {
583 return m_opt == other.m_opt;
584 }
585
587 bool operator!=(const Gain &other) const
588 {
589 return m_opt != other.m_opt;
590 }
591
593 bool operator<(const Gain &other) const
594 {
595 return m_opt < other.m_opt;
596 }
597
599 bool operator>(const Gain &other) const
600 {
601 return m_opt > other.m_opt;
602 }
603
605 bool operator<=(const Gain &other) const
606 {
607 return m_opt <= other.m_opt;
608 }
609
611 bool operator>=(const Gain &other) const
612 {
613 return m_opt >= other.m_opt;
614 }
615
617 friend std::ostream &operator<<(std::ostream &stream, const Gain &value)
618 {
619 return stream << value.toString();
620 }
621
622 private:
623 void setFromString(const std::string &value);
624
625 constexpr ValueType static verifyValue(const ValueType &value)
626 {
627 return validRange().isInRange(value)
628 ? value
629 : throw std::out_of_range{ "Gain{ " + std::to_string(value) + " } is not in range ["
630 + std::to_string(validRange().min()) + ", "
631 + std::to_string(validRange().max()) + "]" };
632 }
633
634 Zivid::DataModel::Detail::Optional<double> m_opt;
635
636 friend struct DataModel::Detail::Befriend<Gain>;
637 };
638
639 using Descendants = std::tuple<
644
647
662#ifndef NO_DOC
663 template<
664 typename... Args,
665 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
666 typename std::enable_if<
667 Zivid::Detail::TypeTraits::AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::
668 value,
669 int>::type = 0>
670#else
671 template<typename... Args>
672#endif
673 explicit Acquisition(Args &&...args)
674 {
675 using namespace Zivid::Detail::TypeTraits;
676
677 static_assert(
678 AllArgsDecayedAreUnique<Args...>::value,
679 "Found duplicate types among the arguments passed to Acquisition(...). "
680 "Types should be listed at most once.");
681
682 set(std::forward<Args>(args)...);
683 }
684
698#ifndef NO_DOC
699 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
700#else
701 template<typename... Args>
702#endif
703 void set(Args &&...args)
704 {
705 using namespace Zivid::Detail::TypeTraits;
706
707 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
708 static_assert(
709 AllArgsAreDescendantNodes::value, "All arguments passed to set(...) must be descendant nodes.");
710
711 static_assert(
712 AllArgsDecayedAreUnique<Args...>::value,
713 "Found duplicate types among the arguments passed to set(...). "
714 "Types should be listed at most once.");
715
716 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
717 }
718
733#ifndef NO_DOC
734 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
735#else
736 template<typename... Args>
737#endif
738 Acquisition copyWith(Args &&...args) const
739 {
740 using namespace Zivid::Detail::TypeTraits;
741
742 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
743 static_assert(
744 AllArgsAreDescendantNodes::value,
745 "All arguments passed to copyWith(...) must be descendant nodes.");
746
747 static_assert(
748 AllArgsDecayedAreUnique<Args...>::value,
749 "Found duplicate types among the arguments passed to copyWith(...). "
750 "Types should be listed at most once.");
751
752 auto copy{ *this };
753 copy.set(std::forward<Args>(args)...);
754 return copy;
755 }
756
758 const Aperture &aperture() const
759 {
760 return m_aperture;
761 }
762
765 {
766 return m_aperture;
767 }
768
770 Acquisition &set(const Aperture &value)
771 {
772 m_aperture = value;
773 return *this;
774 }
775
777 const Brightness &brightness() const
778 {
779 return m_brightness;
780 }
781
784 {
785 return m_brightness;
786 }
787
790 {
791 m_brightness = value;
792 return *this;
793 }
794
797 {
798 return m_exposureTime;
799 }
800
803 {
804 return m_exposureTime;
805 }
806
809 {
810 m_exposureTime = value;
811 return *this;
812 }
813
815 const Gain &gain() const
816 {
817 return m_gain;
818 }
819
822 {
823 return m_gain;
824 }
825
827 Acquisition &set(const Gain &value)
828 {
829 m_gain = value;
830 return *this;
831 }
832
833 template<
834 typename T,
835 typename std::enable_if<std::is_same<T, Settings::Acquisition::Aperture>::value, int>::type = 0>
837 {
838 return m_aperture;
839 }
840
841 template<
842 typename T,
843 typename std::enable_if<std::is_same<T, Settings::Acquisition::Brightness>::value, int>::type = 0>
845 {
846 return m_brightness;
847 }
848
849 template<
850 typename T,
851 typename std::enable_if<std::is_same<T, Settings::Acquisition::ExposureTime>::value, int>::type = 0>
853 {
854 return m_exposureTime;
855 }
856
857 template<
858 typename T,
859 typename std::enable_if<std::is_same<T, Settings::Acquisition::Gain>::value, int>::type = 0>
861 {
862 return m_gain;
863 }
864
865 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
867 {
868 return m_aperture;
869 }
870
871 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
873 {
874 return m_brightness;
875 }
876
877 template<size_t i, typename std::enable_if<i == 2, int>::type = 0>
879 {
880 return m_exposureTime;
881 }
882
883 template<size_t i, typename std::enable_if<i == 3, int>::type = 0>
885 {
886 return m_gain;
887 }
888
890 template<typename F>
891 void forEach(const F &f) const
892 {
893 f(m_aperture);
894 f(m_brightness);
895 f(m_exposureTime);
896 f(m_gain);
897 }
898
900 template<typename F>
901 void forEach(const F &f)
902 {
903 f(m_aperture);
904 f(m_brightness);
905 f(m_exposureTime);
906 f(m_gain);
907 }
908
910 bool operator==(const Acquisition &other) const;
911
913 bool operator!=(const Acquisition &other) const;
914
916 std::string toString() const;
917
919 friend std::ostream &operator<<(std::ostream &stream, const Acquisition &value)
920 {
921 return stream << value.toString();
922 }
923
924 private:
925 void setFromString(const std::string &value);
926
927 void setFromString(const std::string &fullPath, const std::string &value);
928
929 std::string getString(const std::string &fullPath) const;
930
931 Aperture m_aperture;
932 Brightness m_brightness;
933 ExposureTime m_exposureTime;
934 Gain m_gain;
935
936 friend struct DataModel::Detail::Befriend<Acquisition>;
937 };
938
940
941 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
943 {
944 public:
947
949 static constexpr const char *path{ "Acquisitions" };
950
952 static constexpr const char *name{ "Acquisitions" };
953
955 static constexpr const char *description{ R"description(List of Acquisition objects)description" };
956
958 using ValueType = std::vector<Settings::Acquisition>;
959
962 {
963 return { 0, std::numeric_limits<ValueType::size_type>::max() };
964 }
965
967 Acquisitions() = default;
968
970 explicit Acquisitions(std::vector<Settings::Acquisition> value)
971 : m_value{ std::move(value) }
972 {}
973
975 explicit Acquisitions(std::initializer_list<Settings::Acquisition> value)
976 : Acquisitions{ ValueType{ value } }
977 {}
978
980 const std::vector<Settings::Acquisition> &value() const;
981
983 std::string toString() const;
984
986 std::size_t size() const noexcept;
987
989 bool isEmpty() const noexcept;
990
996 template<typename... Args>
997 void emplaceBack(Args &&...args)
998 {
999 m_value.emplace_back(std::forward<Args>(args)...);
1000 }
1001
1007 Settings::Acquisition &at(std::size_t pos);
1008
1014 const Settings::Acquisition &at(std::size_t pos) const;
1015
1022
1028 const Settings::Acquisition &operator[](std::size_t pos) const;
1029
1031 template<typename F>
1032 void forEach(const F &f)
1033 {
1034 for(auto &child : m_value)
1035 {
1036 f(child);
1037 }
1038 }
1039
1041 template<typename F>
1042 void forEach(const F &f) const
1043 {
1044 for(const auto &child : m_value)
1045 {
1046 f(child);
1047 }
1048 }
1049
1051 using Iterator = std::vector<Settings::Acquisition>::iterator;
1052
1054 Iterator begin() noexcept;
1055
1057 Iterator end() noexcept;
1058
1060 using ConstIterator = std::vector<Settings::Acquisition>::const_iterator;
1061
1063 ConstIterator begin() const noexcept;
1064
1066 ConstIterator end() const noexcept;
1067
1069 ConstIterator cbegin() const noexcept;
1070
1072 ConstIterator cend() const noexcept;
1073
1075 bool operator==(const Acquisitions &other) const
1076 {
1077 return m_value == other.m_value;
1078 }
1079
1081 bool operator!=(const Acquisitions &other) const
1082 {
1083 return m_value != other.m_value;
1084 }
1085
1087 friend std::ostream &operator<<(std::ostream &stream, const Acquisitions &value)
1088 {
1089 return stream << value.toString();
1090 }
1091
1092 private:
1093 void setFromString(const std::string &value);
1094
1095 std::vector<Settings::Acquisition> m_value{};
1096
1097 friend struct DataModel::Detail::Befriend<Acquisitions>;
1098 };
1099
1107
1108 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
1110 {
1111 public:
1114
1116 static constexpr const char *path{ "Diagnostics" };
1117
1119 static constexpr const char *name{ "Diagnostics" };
1120
1122 static constexpr const char *description{
1123 R"description(When Diagnostics is enabled, extra diagnostic information is recorded during capture. This extra
1124information is included when saving the frame to a .zdf file, and will help Zivid's support team
1125to provide better assistance.
1126
1127Enabling Diagnostics increases the capture time and the RAM usage. It will also increase the size of the
1128.zdf file. It is recommended to enable Diagnostics only when reporting issues to Zivid's support team.
1129)description"
1130 };
1131
1133
1134 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
1136 {
1137 public:
1140
1142 static constexpr const char *path{ "Diagnostics/Enabled" };
1143
1145 static constexpr const char *name{ "Enabled" };
1146
1148 static constexpr const char *description{ R"description(Enable diagnostics)description" };
1149
1151 using ValueType = bool;
1152 static const Enabled yes;
1153 static const Enabled no;
1154
1156 static std::set<bool> validValues()
1157 {
1158 return { false, true };
1159 }
1160
1162 Enabled() = default;
1163
1165 explicit constexpr Enabled(bool value)
1166 : m_opt{ value }
1167 {}
1168
1173 bool value() const;
1174
1176 bool hasValue() const;
1177
1179 void reset();
1180
1182 std::string toString() const;
1183
1185 bool operator==(const Enabled &other) const
1186 {
1187 return m_opt == other.m_opt;
1188 }
1189
1191 bool operator!=(const Enabled &other) const
1192 {
1193 return m_opt != other.m_opt;
1194 }
1195
1197 friend std::ostream &operator<<(std::ostream &stream, const Enabled &value)
1198 {
1199 return stream << value.toString();
1200 }
1201
1202 private:
1203 void setFromString(const std::string &value);
1204
1205 Zivid::DataModel::Detail::Optional<bool> m_opt;
1206
1207 friend struct DataModel::Detail::Befriend<Enabled>;
1208 };
1209
1210 using Descendants = std::tuple<Settings::Diagnostics::Enabled>;
1211
1214
1226#ifndef NO_DOC
1227 template<
1228 typename... Args,
1229 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
1230 typename std::enable_if<
1231 Zivid::Detail::TypeTraits::AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::
1232 value,
1233 int>::type = 0>
1234#else
1235 template<typename... Args>
1236#endif
1237 explicit Diagnostics(Args &&...args)
1238 {
1239 using namespace Zivid::Detail::TypeTraits;
1240
1241 static_assert(
1242 AllArgsDecayedAreUnique<Args...>::value,
1243 "Found duplicate types among the arguments passed to Diagnostics(...). "
1244 "Types should be listed at most once.");
1245
1246 set(std::forward<Args>(args)...);
1247 }
1248
1259#ifndef NO_DOC
1260 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
1261#else
1262 template<typename... Args>
1263#endif
1264 void set(Args &&...args)
1265 {
1266 using namespace Zivid::Detail::TypeTraits;
1267
1268 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
1269 static_assert(
1270 AllArgsAreDescendantNodes::value, "All arguments passed to set(...) must be descendant nodes.");
1271
1272 static_assert(
1273 AllArgsDecayedAreUnique<Args...>::value,
1274 "Found duplicate types among the arguments passed to set(...). "
1275 "Types should be listed at most once.");
1276
1277 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
1278 }
1279
1291#ifndef NO_DOC
1292 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
1293#else
1294 template<typename... Args>
1295#endif
1296 Diagnostics copyWith(Args &&...args) const
1297 {
1298 using namespace Zivid::Detail::TypeTraits;
1299
1300 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
1301 static_assert(
1302 AllArgsAreDescendantNodes::value,
1303 "All arguments passed to copyWith(...) must be descendant nodes.");
1304
1305 static_assert(
1306 AllArgsDecayedAreUnique<Args...>::value,
1307 "Found duplicate types among the arguments passed to copyWith(...). "
1308 "Types should be listed at most once.");
1309
1310 auto copy{ *this };
1311 copy.set(std::forward<Args>(args)...);
1312 return copy;
1313 }
1314
1316 const Enabled &isEnabled() const
1317 {
1318 return m_enabled;
1319 }
1320
1323 {
1324 return m_enabled;
1325 }
1326
1328 Diagnostics &set(const Enabled &value)
1329 {
1330 m_enabled = value;
1331 return *this;
1332 }
1333
1334 template<
1335 typename T,
1336 typename std::enable_if<std::is_same<T, Settings::Diagnostics::Enabled>::value, int>::type = 0>
1338 {
1339 return m_enabled;
1340 }
1341
1342 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
1344 {
1345 return m_enabled;
1346 }
1347
1349 template<typename F>
1350 void forEach(const F &f) const
1351 {
1352 f(m_enabled);
1353 }
1354
1356 template<typename F>
1357 void forEach(const F &f)
1358 {
1359 f(m_enabled);
1360 }
1361
1363 bool operator==(const Diagnostics &other) const;
1364
1366 bool operator!=(const Diagnostics &other) const;
1367
1369 std::string toString() const;
1370
1372 friend std::ostream &operator<<(std::ostream &stream, const Diagnostics &value)
1373 {
1374 return stream << value.toString();
1375 }
1376
1377 private:
1378 void setFromString(const std::string &value);
1379
1380 void setFromString(const std::string &fullPath, const std::string &value);
1381
1382 std::string getString(const std::string &fullPath) const;
1383
1384 Enabled m_enabled;
1385
1386 friend struct DataModel::Detail::Befriend<Diagnostics>;
1387 };
1388
1390
1391 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
1393 {
1394 public:
1397
1399 static constexpr const char *path{ "Experimental" };
1400
1402 static constexpr const char *name{ "Experimental" };
1403
1405 static constexpr const char *description{
1406 R"description(Experimental features. These settings may be changed, renamed, moved or deleted in the future.)description"
1407 };
1408
1429
1430 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
1432 {
1433 public:
1436
1438 static constexpr const char *path{ "Experimental/Engine" };
1439
1441 static constexpr const char *name{ "Engine" };
1442
1444 static constexpr const char *description{ R"description(Set the Zivid Vision Engine to use.
1445
1446The Phase Engine is the fastest choice in terms of both acquisition time and total capture
1447time, and is a good compromise between quality and speed. The Phase Engine is recommended for
1448objects that are diffuse, opaque, and slightly specular, and is suitable for applications in
1449logistics such as parcel induction.
1450
1451The Stripe Engine is built for exceptional point cloud quality in scenes with highly specular
1452reflective objects. This makes the engine suitable for applications such as factory automation,
1453manufacturing, and bin picking. Additional acquisition and processing time are required for
1454the Stripe Engine.
1455
1456The Omni Engine is built for exceptional point cloud quality on all scenes, including scenes
1457with extremely specular reflective objects, as well as transparent objects. This makes the Omni
1458Engine suitable for applications such as piece picking. Same as for the Stripe Engine, it trades
1459off speed for quality. The Omni Engine is only available for Zivid 2+.
1460
1461The Stripe and Omni engines are currently experimental, and may be changed and improved
1462in the future.
1463)description" };
1464
1466 enum class ValueType
1467 {
1468 phase,
1469 stripe,
1470 omni
1471 };
1472 static const Engine phase;
1473 static const Engine stripe;
1474 static const Engine omni;
1475
1477 static std::set<ValueType> validValues()
1478 {
1479 return { ValueType::phase, ValueType::stripe, ValueType::omni };
1480 }
1481
1483 Engine() = default;
1484
1486 explicit constexpr Engine(ValueType value)
1487 : m_opt{ verifyValue(value) }
1488 {}
1489
1495
1497 bool hasValue() const;
1498
1500 void reset();
1501
1503 std::string toString() const;
1504
1506 friend std::ostream &operator<<(std::ostream &stream, const Engine::ValueType &value)
1507 {
1508 return stream << Engine{ value }.toString();
1509 }
1510
1512 bool operator==(const Engine &other) const
1513 {
1514 return m_opt == other.m_opt;
1515 }
1516
1518 bool operator!=(const Engine &other) const
1519 {
1520 return m_opt != other.m_opt;
1521 }
1522
1524 friend std::ostream &operator<<(std::ostream &stream, const Engine &value)
1525 {
1526 return stream << value.toString();
1527 }
1528
1529 private:
1530 void setFromString(const std::string &value);
1531
1532 constexpr ValueType static verifyValue(const ValueType &value)
1533 {
1534 return value == ValueType::phase || value == ValueType::stripe || value == ValueType::omni
1535 ? value
1536 : throw std::invalid_argument{
1537 "Invalid value: Engine{ "
1538 + std::to_string(static_cast<std::underlying_type<ValueType>::type>(value)) + " }"
1539 };
1540 }
1541
1542 Zivid::DataModel::Detail::Optional<ValueType> m_opt;
1543
1544 friend struct DataModel::Detail::Befriend<Engine>;
1545 };
1546
1547 using Descendants = std::tuple<Settings::Experimental::Engine>;
1548
1551
1563#ifndef NO_DOC
1564 template<
1565 typename... Args,
1566 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
1567 typename std::enable_if<
1568 Zivid::Detail::TypeTraits::AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::
1569 value,
1570 int>::type = 0>
1571#else
1572 template<typename... Args>
1573#endif
1574 explicit Experimental(Args &&...args)
1575 {
1576 using namespace Zivid::Detail::TypeTraits;
1577
1578 static_assert(
1579 AllArgsDecayedAreUnique<Args...>::value,
1580 "Found duplicate types among the arguments passed to Experimental(...). "
1581 "Types should be listed at most once.");
1582
1583 set(std::forward<Args>(args)...);
1584 }
1585
1596#ifndef NO_DOC
1597 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
1598#else
1599 template<typename... Args>
1600#endif
1601 void set(Args &&...args)
1602 {
1603 using namespace Zivid::Detail::TypeTraits;
1604
1605 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
1606 static_assert(
1607 AllArgsAreDescendantNodes::value, "All arguments passed to set(...) must be descendant nodes.");
1608
1609 static_assert(
1610 AllArgsDecayedAreUnique<Args...>::value,
1611 "Found duplicate types among the arguments passed to set(...). "
1612 "Types should be listed at most once.");
1613
1614 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
1615 }
1616
1628#ifndef NO_DOC
1629 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
1630#else
1631 template<typename... Args>
1632#endif
1633 Experimental copyWith(Args &&...args) const
1634 {
1635 using namespace Zivid::Detail::TypeTraits;
1636
1637 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
1638 static_assert(
1639 AllArgsAreDescendantNodes::value,
1640 "All arguments passed to copyWith(...) must be descendant nodes.");
1641
1642 static_assert(
1643 AllArgsDecayedAreUnique<Args...>::value,
1644 "Found duplicate types among the arguments passed to copyWith(...). "
1645 "Types should be listed at most once.");
1646
1647 auto copy{ *this };
1648 copy.set(std::forward<Args>(args)...);
1649 return copy;
1650 }
1651
1653 const Engine &engine() const
1654 {
1655 return m_engine;
1656 }
1657
1660 {
1661 return m_engine;
1662 }
1663
1665 Experimental &set(const Engine &value)
1666 {
1667 m_engine = value;
1668 return *this;
1669 }
1670
1671 template<
1672 typename T,
1673 typename std::enable_if<std::is_same<T, Settings::Experimental::Engine>::value, int>::type = 0>
1675 {
1676 return m_engine;
1677 }
1678
1679 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
1681 {
1682 return m_engine;
1683 }
1684
1686 template<typename F>
1687 void forEach(const F &f) const
1688 {
1689 f(m_engine);
1690 }
1691
1693 template<typename F>
1694 void forEach(const F &f)
1695 {
1696 f(m_engine);
1697 }
1698
1700 bool operator==(const Experimental &other) const;
1701
1703 bool operator!=(const Experimental &other) const;
1704
1706 std::string toString() const;
1707
1709 friend std::ostream &operator<<(std::ostream &stream, const Experimental &value)
1710 {
1711 return stream << value.toString();
1712 }
1713
1714 private:
1715 void setFromString(const std::string &value);
1716
1717 void setFromString(const std::string &fullPath, const std::string &value);
1718
1719 std::string getString(const std::string &fullPath) const;
1720
1721 Engine m_engine;
1722
1723 friend struct DataModel::Detail::Befriend<Experimental>;
1724 };
1725
1727
1728 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
1730 {
1731 public:
1734
1736 static constexpr const char *path{ "Processing" };
1737
1739 static constexpr const char *name{ "Processing" };
1740
1742 static constexpr const char *description{
1743 R"description(Settings related to processing of a capture, including filters and color balance)description"
1744 };
1745
1747
1748 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
1750 {
1751 public:
1754
1756 static constexpr const char *path{ "Processing/Color" };
1757
1759 static constexpr const char *name{ "Color" };
1760
1762 static constexpr const char *description{ R"description(Color settings)description" };
1763
1765
1766 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
1768 {
1769 public:
1772
1774 static constexpr const char *path{ "Processing/Color/Balance" };
1775
1777 static constexpr const char *name{ "Balance" };
1778
1780 static constexpr const char *description{ R"description(Color balance settings)description" };
1781
1783
1784 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
1786 {
1787 public:
1790
1792 static constexpr const char *path{ "Processing/Color/Balance/Blue" };
1793
1795 static constexpr const char *name{ "Blue" };
1796
1798 static constexpr const char *description{
1799 R"description(Digital gain applied to blue channel)description"
1800 };
1801
1803 using ValueType = double;
1804
1806 static constexpr Range<double> validRange()
1807 {
1808 return { 1.0, 8.0 };
1809 }
1810
1812 Blue() = default;
1813
1815 explicit constexpr Blue(double value)
1816 : m_opt{ verifyValue(value) }
1817 {}
1818
1823 double value() const;
1824
1826 bool hasValue() const;
1827
1829 void reset();
1830
1832 std::string toString() const;
1833
1835 bool operator==(const Blue &other) const
1836 {
1837 return m_opt == other.m_opt;
1838 }
1839
1841 bool operator!=(const Blue &other) const
1842 {
1843 return m_opt != other.m_opt;
1844 }
1845
1847 bool operator<(const Blue &other) const
1848 {
1849 return m_opt < other.m_opt;
1850 }
1851
1853 bool operator>(const Blue &other) const
1854 {
1855 return m_opt > other.m_opt;
1856 }
1857
1859 bool operator<=(const Blue &other) const
1860 {
1861 return m_opt <= other.m_opt;
1862 }
1863
1865 bool operator>=(const Blue &other) const
1866 {
1867 return m_opt >= other.m_opt;
1868 }
1869
1871 friend std::ostream &operator<<(std::ostream &stream, const Blue &value)
1872 {
1873 return stream << value.toString();
1874 }
1875
1876 private:
1877 void setFromString(const std::string &value);
1878
1879 constexpr ValueType static verifyValue(const ValueType &value)
1880 {
1881 return validRange().isInRange(value)
1882 ? value
1883 : throw std::out_of_range{ "Blue{ " + std::to_string(value)
1884 + " } is not in range ["
1885 + std::to_string(validRange().min()) + ", "
1886 + std::to_string(validRange().max()) + "]" };
1887 }
1888
1889 Zivid::DataModel::Detail::Optional<double> m_opt;
1890
1891 friend struct DataModel::Detail::Befriend<Blue>;
1892 };
1893
1895
1896 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
1898 {
1899 public:
1902
1904 static constexpr const char *path{ "Processing/Color/Balance/Green" };
1905
1907 static constexpr const char *name{ "Green" };
1908
1910 static constexpr const char *description{
1911 R"description(Digital gain applied to green channel)description"
1912 };
1913
1915 using ValueType = double;
1916
1918 static constexpr Range<double> validRange()
1919 {
1920 return { 1.0, 8.0 };
1921 }
1922
1924 Green() = default;
1925
1927 explicit constexpr Green(double value)
1928 : m_opt{ verifyValue(value) }
1929 {}
1930
1935 double value() const;
1936
1938 bool hasValue() const;
1939
1941 void reset();
1942
1944 std::string toString() const;
1945
1947 bool operator==(const Green &other) const
1948 {
1949 return m_opt == other.m_opt;
1950 }
1951
1953 bool operator!=(const Green &other) const
1954 {
1955 return m_opt != other.m_opt;
1956 }
1957
1959 bool operator<(const Green &other) const
1960 {
1961 return m_opt < other.m_opt;
1962 }
1963
1965 bool operator>(const Green &other) const
1966 {
1967 return m_opt > other.m_opt;
1968 }
1969
1971 bool operator<=(const Green &other) const
1972 {
1973 return m_opt <= other.m_opt;
1974 }
1975
1977 bool operator>=(const Green &other) const
1978 {
1979 return m_opt >= other.m_opt;
1980 }
1981
1983 friend std::ostream &operator<<(std::ostream &stream, const Green &value)
1984 {
1985 return stream << value.toString();
1986 }
1987
1988 private:
1989 void setFromString(const std::string &value);
1990
1991 constexpr ValueType static verifyValue(const ValueType &value)
1992 {
1993 return validRange().isInRange(value)
1994 ? value
1995 : throw std::out_of_range{ "Green{ " + std::to_string(value)
1996 + " } is not in range ["
1997 + std::to_string(validRange().min()) + ", "
1998 + std::to_string(validRange().max()) + "]" };
1999 }
2000
2001 Zivid::DataModel::Detail::Optional<double> m_opt;
2002
2003 friend struct DataModel::Detail::Befriend<Green>;
2004 };
2005
2007
2008 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
2010 {
2011 public:
2014
2016 static constexpr const char *path{ "Processing/Color/Balance/Red" };
2017
2019 static constexpr const char *name{ "Red" };
2020
2022 static constexpr const char *description{
2023 R"description(Digital gain applied to red channel)description"
2024 };
2025
2027 using ValueType = double;
2028
2030 static constexpr Range<double> validRange()
2031 {
2032 return { 1.0, 8.0 };
2033 }
2034
2036 Red() = default;
2037
2039 explicit constexpr Red(double value)
2040 : m_opt{ verifyValue(value) }
2041 {}
2042
2047 double value() const;
2048
2050 bool hasValue() const;
2051
2053 void reset();
2054
2056 std::string toString() const;
2057
2059 bool operator==(const Red &other) const
2060 {
2061 return m_opt == other.m_opt;
2062 }
2063
2065 bool operator!=(const Red &other) const
2066 {
2067 return m_opt != other.m_opt;
2068 }
2069
2071 bool operator<(const Red &other) const
2072 {
2073 return m_opt < other.m_opt;
2074 }
2075
2077 bool operator>(const Red &other) const
2078 {
2079 return m_opt > other.m_opt;
2080 }
2081
2083 bool operator<=(const Red &other) const
2084 {
2085 return m_opt <= other.m_opt;
2086 }
2087
2089 bool operator>=(const Red &other) const
2090 {
2091 return m_opt >= other.m_opt;
2092 }
2093
2095 friend std::ostream &operator<<(std::ostream &stream, const Red &value)
2096 {
2097 return stream << value.toString();
2098 }
2099
2100 private:
2101 void setFromString(const std::string &value);
2102
2103 constexpr ValueType static verifyValue(const ValueType &value)
2104 {
2105 return validRange().isInRange(value)
2106 ? value
2107 : throw std::out_of_range{ "Red{ " + std::to_string(value)
2108 + " } is not in range ["
2109 + std::to_string(validRange().min()) + ", "
2110 + std::to_string(validRange().max()) + "]" };
2111 }
2112
2113 Zivid::DataModel::Detail::Optional<double> m_opt;
2114
2115 friend struct DataModel::Detail::Befriend<Red>;
2116 };
2117
2118 using Descendants = std::tuple<
2122
2125
2139#ifndef NO_DOC
2140 template<
2141 typename... Args,
2142 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
2143 typename std::enable_if<
2144 Zivid::Detail::TypeTraits::
2145 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
2146 int>::type = 0>
2147#else
2148 template<typename... Args>
2149#endif
2150 explicit Balance(Args &&...args)
2151 {
2152 using namespace Zivid::Detail::TypeTraits;
2153
2154 static_assert(
2155 AllArgsDecayedAreUnique<Args...>::value,
2156 "Found duplicate types among the arguments passed to Balance(...). "
2157 "Types should be listed at most once.");
2158
2159 set(std::forward<Args>(args)...);
2160 }
2161
2174#ifndef NO_DOC
2175 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
2176#else
2177 template<typename... Args>
2178#endif
2179 void set(Args &&...args)
2180 {
2181 using namespace Zivid::Detail::TypeTraits;
2182
2183 using AllArgsAreDescendantNodes =
2184 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
2185 static_assert(
2186 AllArgsAreDescendantNodes::value,
2187 "All arguments passed to set(...) must be descendant nodes.");
2188
2189 static_assert(
2190 AllArgsDecayedAreUnique<Args...>::value,
2191 "Found duplicate types among the arguments passed to set(...). "
2192 "Types should be listed at most once.");
2193
2194 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
2195 }
2196
2210#ifndef NO_DOC
2211 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
2212#else
2213 template<typename... Args>
2214#endif
2215 Balance copyWith(Args &&...args) const
2216 {
2217 using namespace Zivid::Detail::TypeTraits;
2218
2219 using AllArgsAreDescendantNodes =
2220 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
2221 static_assert(
2222 AllArgsAreDescendantNodes::value,
2223 "All arguments passed to copyWith(...) must be descendant nodes.");
2224
2225 static_assert(
2226 AllArgsDecayedAreUnique<Args...>::value,
2227 "Found duplicate types among the arguments passed to copyWith(...). "
2228 "Types should be listed at most once.");
2229
2230 auto copy{ *this };
2231 copy.set(std::forward<Args>(args)...);
2232 return copy;
2233 }
2234
2236 const Blue &blue() const
2237 {
2238 return m_blue;
2239 }
2240
2243 {
2244 return m_blue;
2245 }
2246
2248 Balance &set(const Blue &value)
2249 {
2250 m_blue = value;
2251 return *this;
2252 }
2253
2255 const Green &green() const
2256 {
2257 return m_green;
2258 }
2259
2262 {
2263 return m_green;
2264 }
2265
2267 Balance &set(const Green &value)
2268 {
2269 m_green = value;
2270 return *this;
2271 }
2272
2274 const Red &red() const
2275 {
2276 return m_red;
2277 }
2278
2281 {
2282 return m_red;
2283 }
2284
2286 Balance &set(const Red &value)
2287 {
2288 m_red = value;
2289 return *this;
2290 }
2291
2292 template<
2293 typename T,
2294 typename std::enable_if<
2295 std::is_same<T, Settings::Processing::Color::Balance::Blue>::value,
2296 int>::type = 0>
2298 {
2299 return m_blue;
2300 }
2301
2302 template<
2303 typename T,
2304 typename std::enable_if<
2305 std::is_same<T, Settings::Processing::Color::Balance::Green>::value,
2306 int>::type = 0>
2308 {
2309 return m_green;
2310 }
2311
2312 template<
2313 typename T,
2314 typename std::
2315 enable_if<std::is_same<T, Settings::Processing::Color::Balance::Red>::value, int>::type = 0>
2317 {
2318 return m_red;
2319 }
2320
2321 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
2323 {
2324 return m_blue;
2325 }
2326
2327 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
2329 {
2330 return m_green;
2331 }
2332
2333 template<size_t i, typename std::enable_if<i == 2, int>::type = 0>
2335 {
2336 return m_red;
2337 }
2338
2340 template<typename F>
2341 void forEach(const F &f) const
2342 {
2343 f(m_blue);
2344 f(m_green);
2345 f(m_red);
2346 }
2347
2349 template<typename F>
2350 void forEach(const F &f)
2351 {
2352 f(m_blue);
2353 f(m_green);
2354 f(m_red);
2355 }
2356
2358 bool operator==(const Balance &other) const;
2359
2361 bool operator!=(const Balance &other) const;
2362
2364 std::string toString() const;
2365
2367 friend std::ostream &operator<<(std::ostream &stream, const Balance &value)
2368 {
2369 return stream << value.toString();
2370 }
2371
2372 private:
2373 void setFromString(const std::string &value);
2374
2375 void setFromString(const std::string &fullPath, const std::string &value);
2376
2377 std::string getString(const std::string &fullPath) const;
2378
2379 Blue m_blue;
2380 Green m_green;
2381 Red m_red;
2382
2383 friend struct DataModel::Detail::Befriend<Balance>;
2384 };
2385
2387
2388 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
2390 {
2391 public:
2394
2396 static constexpr const char *path{ "Processing/Color/Experimental" };
2397
2399 static constexpr const char *name{ "Experimental" };
2400
2402 static constexpr const char *description{
2403 R"description(Experimental color settings. These may be renamed, moved or deleted in the future.)description"
2404 };
2405
2428
2429 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
2431 {
2432 public:
2435
2437 static constexpr const char *path{ "Processing/Color/Experimental/Mode" };
2438
2440 static constexpr const char *name{ "Mode" };
2441
2443 static constexpr const char *description{
2444 R"description(This setting controls how the color image is computed.
2445
2446`automatic` is the default option. `automatic` is identical to `useFirstAcquisition` for
2447single-acquisition captures and multi-acquisition captures when all the acquisitions have
2448identical (duplicated) acquisition settings. `automatic` is identical to `toneMapping` for
2449multi-acquisition HDR captures with differing acquisition settings.
2450
2451`useFirstAcquisition` uses the color data acquired from the first acquisition provided. If
2452the capture consists of more than one acquisition, then the remaining acquisitions are not used
2453for the color image. No tone mapping is performed. This option provides the most control of
2454the color image, and the color values will be consistent over repeated captures with the same
2455settings.
2456
2457`toneMapping` uses all the acquisitions to create one merged and normalized color image. For
2458HDR captures the dynamic range of the captured images is usually higher than the 8-bit color
2459image range. `toneMapping` will map the HDR color data to the 8-bit color output range by
2460applying a scaling factor. `toneMapping` can also be used for single-acquisition captures to
2461normalize the captured color image to the full 8-bit output. Note that when using `toneMapping`
2462mode the color values can be inconsistent over repeated captures if you move, add or remove
2463objects in the scene. For the most control over the colors, select the `useFirstAcquisition`
2464mode.
2465)description"
2466 };
2467
2469 enum class ValueType
2470 {
2471 automatic,
2472 useFirstAcquisition,
2473 toneMapping
2474 };
2475 static const Mode automatic;
2477 static const Mode toneMapping;
2478
2480 static std::set<ValueType> validValues()
2481 {
2482 return { ValueType::automatic, ValueType::useFirstAcquisition, ValueType::toneMapping };
2483 }
2484
2486 Mode() = default;
2487
2489 explicit constexpr Mode(ValueType value)
2490 : m_opt{ verifyValue(value) }
2491 {}
2492
2498
2500 bool hasValue() const;
2501
2503 void reset();
2504
2506 std::string toString() const;
2507
2509 friend std::ostream &operator<<(std::ostream &stream, const Mode::ValueType &value)
2510 {
2511 return stream << Mode{ value }.toString();
2512 }
2513
2515 bool operator==(const Mode &other) const
2516 {
2517 return m_opt == other.m_opt;
2518 }
2519
2521 bool operator!=(const Mode &other) const
2522 {
2523 return m_opt != other.m_opt;
2524 }
2525
2527 friend std::ostream &operator<<(std::ostream &stream, const Mode &value)
2528 {
2529 return stream << value.toString();
2530 }
2531
2532 private:
2533 void setFromString(const std::string &value);
2534
2535 constexpr ValueType static verifyValue(const ValueType &value)
2536 {
2537 return value == ValueType::automatic || value == ValueType::useFirstAcquisition
2538 || value == ValueType::toneMapping
2539 ? value
2540 : throw std::invalid_argument{
2541 "Invalid value: Mode{ "
2542 + std::to_string(static_cast<std::underlying_type<ValueType>::type>(value))
2543 + " }"
2544 };
2545 }
2546
2547 Zivid::DataModel::Detail::Optional<ValueType> m_opt;
2548
2549 friend struct DataModel::Detail::Befriend<Mode>;
2550 };
2551
2552 using Descendants = std::tuple<Settings::Processing::Color::Experimental::Mode>;
2553
2556
2568#ifndef NO_DOC
2569 template<
2570 typename... Args,
2571 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
2572 typename std::enable_if<
2573 Zivid::Detail::TypeTraits::
2574 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
2575 int>::type = 0>
2576#else
2577 template<typename... Args>
2578#endif
2579 explicit Experimental(Args &&...args)
2580 {
2581 using namespace Zivid::Detail::TypeTraits;
2582
2583 static_assert(
2584 AllArgsDecayedAreUnique<Args...>::value,
2585 "Found duplicate types among the arguments passed to Experimental(...). "
2586 "Types should be listed at most once.");
2587
2588 set(std::forward<Args>(args)...);
2589 }
2590
2601#ifndef NO_DOC
2602 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
2603#else
2604 template<typename... Args>
2605#endif
2606 void set(Args &&...args)
2607 {
2608 using namespace Zivid::Detail::TypeTraits;
2609
2610 using AllArgsAreDescendantNodes =
2611 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
2612 static_assert(
2613 AllArgsAreDescendantNodes::value,
2614 "All arguments passed to set(...) must be descendant nodes.");
2615
2616 static_assert(
2617 AllArgsDecayedAreUnique<Args...>::value,
2618 "Found duplicate types among the arguments passed to set(...). "
2619 "Types should be listed at most once.");
2620
2621 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
2622 }
2623
2635#ifndef NO_DOC
2636 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
2637#else
2638 template<typename... Args>
2639#endif
2640 Experimental copyWith(Args &&...args) const
2641 {
2642 using namespace Zivid::Detail::TypeTraits;
2643
2644 using AllArgsAreDescendantNodes =
2645 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
2646 static_assert(
2647 AllArgsAreDescendantNodes::value,
2648 "All arguments passed to copyWith(...) must be descendant nodes.");
2649
2650 static_assert(
2651 AllArgsDecayedAreUnique<Args...>::value,
2652 "Found duplicate types among the arguments passed to copyWith(...). "
2653 "Types should be listed at most once.");
2654
2655 auto copy{ *this };
2656 copy.set(std::forward<Args>(args)...);
2657 return copy;
2658 }
2659
2661 const Mode &mode() const
2662 {
2663 return m_mode;
2664 }
2665
2668 {
2669 return m_mode;
2670 }
2671
2673 Experimental &set(const Mode &value)
2674 {
2675 m_mode = value;
2676 return *this;
2677 }
2678
2679 template<
2680 typename T,
2681 typename std::enable_if<
2682 std::is_same<T, Settings::Processing::Color::Experimental::Mode>::value,
2683 int>::type = 0>
2685 {
2686 return m_mode;
2687 }
2688
2689 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
2691 {
2692 return m_mode;
2693 }
2694
2696 template<typename F>
2697 void forEach(const F &f) const
2698 {
2699 f(m_mode);
2700 }
2701
2703 template<typename F>
2704 void forEach(const F &f)
2705 {
2706 f(m_mode);
2707 }
2708
2710 bool operator==(const Experimental &other) const;
2711
2713 bool operator!=(const Experimental &other) const;
2714
2716 std::string toString() const;
2717
2719 friend std::ostream &operator<<(std::ostream &stream, const Experimental &value)
2720 {
2721 return stream << value.toString();
2722 }
2723
2724 private:
2725 void setFromString(const std::string &value);
2726
2727 void setFromString(const std::string &fullPath, const std::string &value);
2728
2729 std::string getString(const std::string &fullPath) const;
2730
2731 Mode m_mode;
2732
2733 friend struct DataModel::Detail::Befriend<Experimental>;
2734 };
2735
2739
2740 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
2742 {
2743 public:
2746
2748 static constexpr const char *path{ "Processing/Color/Gamma" };
2749
2751 static constexpr const char *name{ "Gamma" };
2752
2754 static constexpr const char *description{
2755 R"description(Gamma applied to the color values. Gamma less than 1 makes the colors brighter, while gamma
2756greater than 1 makes the colors darker.
2757)description"
2758 };
2759
2761 using ValueType = double;
2762
2764 static constexpr Range<double> validRange()
2765 {
2766 return { 0.25, 1.5 };
2767 }
2768
2770 Gamma() = default;
2771
2773 explicit constexpr Gamma(double value)
2774 : m_opt{ verifyValue(value) }
2775 {}
2776
2781 double value() const;
2782
2784 bool hasValue() const;
2785
2787 void reset();
2788
2790 std::string toString() const;
2791
2793 bool operator==(const Gamma &other) const
2794 {
2795 return m_opt == other.m_opt;
2796 }
2797
2799 bool operator!=(const Gamma &other) const
2800 {
2801 return m_opt != other.m_opt;
2802 }
2803
2805 bool operator<(const Gamma &other) const
2806 {
2807 return m_opt < other.m_opt;
2808 }
2809
2811 bool operator>(const Gamma &other) const
2812 {
2813 return m_opt > other.m_opt;
2814 }
2815
2817 bool operator<=(const Gamma &other) const
2818 {
2819 return m_opt <= other.m_opt;
2820 }
2821
2823 bool operator>=(const Gamma &other) const
2824 {
2825 return m_opt >= other.m_opt;
2826 }
2827
2829 friend std::ostream &operator<<(std::ostream &stream, const Gamma &value)
2830 {
2831 return stream << value.toString();
2832 }
2833
2834 private:
2835 void setFromString(const std::string &value);
2836
2837 constexpr ValueType static verifyValue(const ValueType &value)
2838 {
2839 return validRange().isInRange(value)
2840 ? value
2841 : throw std::out_of_range{ "Gamma{ " + std::to_string(value) + " } is not in range ["
2842 + std::to_string(validRange().min()) + ", "
2843 + std::to_string(validRange().max()) + "]" };
2844 }
2845
2846 Zivid::DataModel::Detail::Optional<double> m_opt;
2847
2848 friend struct DataModel::Detail::Befriend<Gamma>;
2849 };
2850
2851 using Descendants = std::tuple<
2859
2862
2880#ifndef NO_DOC
2881 template<
2882 typename... Args,
2883 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
2884 typename std::enable_if<
2885 Zivid::Detail::TypeTraits::AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::
2886 value,
2887 int>::type = 0>
2888#else
2889 template<typename... Args>
2890#endif
2891 explicit Color(Args &&...args)
2892 {
2893 using namespace Zivid::Detail::TypeTraits;
2894
2895 static_assert(
2896 AllArgsDecayedAreUnique<Args...>::value,
2897 "Found duplicate types among the arguments passed to Color(...). "
2898 "Types should be listed at most once.");
2899
2900 set(std::forward<Args>(args)...);
2901 }
2902
2919#ifndef NO_DOC
2920 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
2921#else
2922 template<typename... Args>
2923#endif
2924 void set(Args &&...args)
2925 {
2926 using namespace Zivid::Detail::TypeTraits;
2927
2928 using AllArgsAreDescendantNodes =
2929 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
2930 static_assert(
2931 AllArgsAreDescendantNodes::value, "All arguments passed to set(...) must be descendant nodes.");
2932
2933 static_assert(
2934 AllArgsDecayedAreUnique<Args...>::value,
2935 "Found duplicate types among the arguments passed to set(...). "
2936 "Types should be listed at most once.");
2937
2938 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
2939 }
2940
2958#ifndef NO_DOC
2959 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
2960#else
2961 template<typename... Args>
2962#endif
2963 Color copyWith(Args &&...args) const
2964 {
2965 using namespace Zivid::Detail::TypeTraits;
2966
2967 using AllArgsAreDescendantNodes =
2968 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
2969 static_assert(
2970 AllArgsAreDescendantNodes::value,
2971 "All arguments passed to copyWith(...) must be descendant nodes.");
2972
2973 static_assert(
2974 AllArgsDecayedAreUnique<Args...>::value,
2975 "Found duplicate types among the arguments passed to copyWith(...). "
2976 "Types should be listed at most once.");
2977
2978 auto copy{ *this };
2979 copy.set(std::forward<Args>(args)...);
2980 return copy;
2981 }
2982
2984 const Balance &balance() const
2985 {
2986 return m_balance;
2987 }
2988
2991 {
2992 return m_balance;
2993 }
2994
2996 Color &set(const Balance &value)
2997 {
2998 m_balance = value;
2999 return *this;
3000 }
3001
3003 Color &set(const Balance::Blue &value)
3004 {
3005 m_balance.set(value);
3006 return *this;
3007 }
3008
3010 Color &set(const Balance::Green &value)
3011 {
3012 m_balance.set(value);
3013 return *this;
3014 }
3015
3017 Color &set(const Balance::Red &value)
3018 {
3019 m_balance.set(value);
3020 return *this;
3021 }
3022
3025 {
3026 return m_experimental;
3027 }
3028
3031 {
3032 return m_experimental;
3033 }
3034
3036 Color &set(const Experimental &value)
3037 {
3038 m_experimental = value;
3039 return *this;
3040 }
3041
3044 {
3045 m_experimental.set(value);
3046 return *this;
3047 }
3048
3050 const Gamma &gamma() const
3051 {
3052 return m_gamma;
3053 }
3054
3057 {
3058 return m_gamma;
3059 }
3060
3062 Color &set(const Gamma &value)
3063 {
3064 m_gamma = value;
3065 return *this;
3066 }
3067
3068 template<
3069 typename T,
3070 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Balance>::value, int>::type =
3071 0>
3073 {
3074 return m_balance;
3075 }
3076
3077 template<
3078 typename T,
3079 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Balance::Blue>::value, int>::
3080 type = 0>
3082 {
3083 return m_balance.get<Settings::Processing::Color::Balance::Blue>();
3084 }
3085
3086 template<
3087 typename T,
3088 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Balance::Green>::value, int>::
3089 type = 0>
3091 {
3092 return m_balance.get<Settings::Processing::Color::Balance::Green>();
3093 }
3094
3095 template<
3096 typename T,
3097 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Balance::Red>::value, int>::
3098 type = 0>
3100 {
3101 return m_balance.get<Settings::Processing::Color::Balance::Red>();
3102 }
3103
3104 template<
3105 typename T,
3106 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Experimental>::value, int>::
3107 type = 0>
3109 {
3110 return m_experimental;
3111 }
3112
3113 template<
3114 typename T,
3115 typename std::enable_if<
3116 std::is_same<T, Settings::Processing::Color::Experimental::Mode>::value,
3117 int>::type = 0>
3119 {
3120 return m_experimental.get<Settings::Processing::Color::Experimental::Mode>();
3121 }
3122
3123 template<
3124 typename T,
3125 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Gamma>::value, int>::type = 0>
3127 {
3128 return m_gamma;
3129 }
3130
3131 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
3133 {
3134 return m_balance;
3135 }
3136
3137 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
3139 {
3140 return m_experimental;
3141 }
3142
3143 template<size_t i, typename std::enable_if<i == 2, int>::type = 0>
3145 {
3146 return m_gamma;
3147 }
3148
3150 template<typename F>
3151 void forEach(const F &f) const
3152 {
3153 f(m_balance);
3154 f(m_experimental);
3155 f(m_gamma);
3156 }
3157
3159 template<typename F>
3160 void forEach(const F &f)
3161 {
3162 f(m_balance);
3163 f(m_experimental);
3164 f(m_gamma);
3165 }
3166
3168 bool operator==(const Color &other) const;
3169
3171 bool operator!=(const Color &other) const;
3172
3174 std::string toString() const;
3175
3177 friend std::ostream &operator<<(std::ostream &stream, const Color &value)
3178 {
3179 return stream << value.toString();
3180 }
3181
3182 private:
3183 void setFromString(const std::string &value);
3184
3185 void setFromString(const std::string &fullPath, const std::string &value);
3186
3187 std::string getString(const std::string &fullPath) const;
3188
3189 Balance m_balance;
3190 Experimental m_experimental;
3191 Gamma m_gamma;
3192
3193 friend struct DataModel::Detail::Befriend<Color>;
3194 };
3195
3197
3198 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
3200 {
3201 public:
3204
3206 static constexpr const char *path{ "Processing/Filters" };
3207
3209 static constexpr const char *name{ "Filters" };
3210
3212 static constexpr const char *description{ R"description(Filters)description" };
3213
3216
3217 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
3219 {
3220 public:
3223
3225 static constexpr const char *path{ "Processing/Filters/Cluster" };
3226
3228 static constexpr const char *name{ "Cluster" };
3229
3231 static constexpr const char *description{
3232 R"description(Removes floating points and isolated clusters from the point cloud.
3233)description"
3234 };
3235
3237
3238 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
3240 {
3241 public:
3244
3246 static constexpr const char *path{ "Processing/Filters/Cluster/Removal" };
3247
3249 static constexpr const char *name{ "Removal" };
3250
3252 static constexpr const char *description{ R"description(Removal)description" };
3253
3255
3256 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
3258 {
3259 public:
3262
3264 static constexpr const char *path{ "Processing/Filters/Cluster/Removal/Enabled" };
3265
3267 static constexpr const char *name{ "Enabled" };
3268
3270 static constexpr const char *description{ R"description(Enabled)description" };
3271
3273 using ValueType = bool;
3274 static const Enabled yes;
3275 static const Enabled no;
3276
3278 static std::set<bool> validValues()
3279 {
3280 return { false, true };
3281 }
3282
3284 Enabled() = default;
3285
3287 explicit constexpr Enabled(bool value)
3288 : m_opt{ value }
3289 {}
3290
3295 bool value() const;
3296
3298 bool hasValue() const;
3299
3301 void reset();
3302
3304 std::string toString() const;
3305
3307 bool operator==(const Enabled &other) const
3308 {
3309 return m_opt == other.m_opt;
3310 }
3311
3313 bool operator!=(const Enabled &other) const
3314 {
3315 return m_opt != other.m_opt;
3316 }
3317
3319 friend std::ostream &operator<<(std::ostream &stream, const Enabled &value)
3320 {
3321 return stream << value.toString();
3322 }
3323
3324 private:
3325 void setFromString(const std::string &value);
3326
3327 Zivid::DataModel::Detail::Optional<bool> m_opt;
3328
3329 friend struct DataModel::Detail::Befriend<Enabled>;
3330 };
3331
3336
3337 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
3339 {
3340 public:
3343
3345 static constexpr const char *path{
3346 "Processing/Filters/Cluster/Removal/MaxNeighborDistance"
3347 };
3348
3350 static constexpr const char *name{ "MaxNeighborDistance" };
3351
3353 static constexpr const char *description{
3354 R"description(Maximum normalized distance between neighboring points that are still classified as
3355belonging to the same cluster. The default value is optimal for most scenes. On messy
3356scenes turning this setting down helps removing more bad points.
3357)description"
3358 };
3359
3361 using ValueType = double;
3362
3364 static constexpr Range<double> validRange()
3365 {
3366 return { 2.0, 10.0 };
3367 }
3368
3371
3373 explicit constexpr MaxNeighborDistance(double value)
3374 : m_opt{ verifyValue(value) }
3375 {}
3376
3381 double value() const;
3382
3384 bool hasValue() const;
3385
3387 void reset();
3388
3390 std::string toString() const;
3391
3393 bool operator==(const MaxNeighborDistance &other) const
3394 {
3395 return m_opt == other.m_opt;
3396 }
3397
3399 bool operator!=(const MaxNeighborDistance &other) const
3400 {
3401 return m_opt != other.m_opt;
3402 }
3403
3405 bool operator<(const MaxNeighborDistance &other) const
3406 {
3407 return m_opt < other.m_opt;
3408 }
3409
3411 bool operator>(const MaxNeighborDistance &other) const
3412 {
3413 return m_opt > other.m_opt;
3414 }
3415
3417 bool operator<=(const MaxNeighborDistance &other) const
3418 {
3419 return m_opt <= other.m_opt;
3420 }
3421
3423 bool operator>=(const MaxNeighborDistance &other) const
3424 {
3425 return m_opt >= other.m_opt;
3426 }
3427
3429 friend std::ostream &operator<<(std::ostream &stream, const MaxNeighborDistance &value)
3430 {
3431 return stream << value.toString();
3432 }
3433
3434 private:
3435 void setFromString(const std::string &value);
3436
3437 constexpr ValueType static verifyValue(const ValueType &value)
3438 {
3439 return validRange().isInRange(value)
3440 ? value
3441 : throw std::out_of_range{ "MaxNeighborDistance{ " + std::to_string(value)
3442 + " } is not in range ["
3443 + std::to_string(validRange().min()) + ", "
3444 + std::to_string(validRange().max()) + "]" };
3445 }
3446
3447 Zivid::DataModel::Detail::Optional<double> m_opt;
3448
3449 friend struct DataModel::Detail::Befriend<MaxNeighborDistance>;
3450 };
3451
3455
3456 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
3458 {
3459 public:
3462
3464 static constexpr const char *path{ "Processing/Filters/Cluster/Removal/MinArea" };
3465
3467 static constexpr const char *name{ "MinArea" };
3468
3470 static constexpr const char *description{
3471 R"description(Clusters with area below this threshold are removed by the filter.
3472The area is given in mm^2.
3473)description"
3474 };
3475
3477 using ValueType = double;
3478
3480 static constexpr Range<double> validRange()
3481 {
3482 return { 0.0, 1500.0 };
3483 }
3484
3486 MinArea() = default;
3487
3489 explicit constexpr MinArea(double value)
3490 : m_opt{ verifyValue(value) }
3491 {}
3492
3497 double value() const;
3498
3500 bool hasValue() const;
3501
3503 void reset();
3504
3506 std::string toString() const;
3507
3509 bool operator==(const MinArea &other) const
3510 {
3511 return m_opt == other.m_opt;
3512 }
3513
3515 bool operator!=(const MinArea &other) const
3516 {
3517 return m_opt != other.m_opt;
3518 }
3519
3521 bool operator<(const MinArea &other) const
3522 {
3523 return m_opt < other.m_opt;
3524 }
3525
3527 bool operator>(const MinArea &other) const
3528 {
3529 return m_opt > other.m_opt;
3530 }
3531
3533 bool operator<=(const MinArea &other) const
3534 {
3535 return m_opt <= other.m_opt;
3536 }
3537
3539 bool operator>=(const MinArea &other) const
3540 {
3541 return m_opt >= other.m_opt;
3542 }
3543
3545 friend std::ostream &operator<<(std::ostream &stream, const MinArea &value)
3546 {
3547 return stream << value.toString();
3548 }
3549
3550 private:
3551 void setFromString(const std::string &value);
3552
3553 constexpr ValueType static verifyValue(const ValueType &value)
3554 {
3555 return validRange().isInRange(value)
3556 ? value
3557 : throw std::out_of_range{ "MinArea{ " + std::to_string(value)
3558 + " } is not in range ["
3559 + std::to_string(validRange().min()) + ", "
3560 + std::to_string(validRange().max()) + "]" };
3561 }
3562
3563 Zivid::DataModel::Detail::Optional<double> m_opt;
3564
3565 friend struct DataModel::Detail::Befriend<MinArea>;
3566 };
3567
3568 using Descendants = std::tuple<
3572
3575
3589#ifndef NO_DOC
3590 template<
3591 typename... Args,
3592 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
3593 typename std::enable_if<
3594 Zivid::Detail::TypeTraits::
3595 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
3596 int>::type = 0>
3597#else
3598 template<typename... Args>
3599#endif
3600 explicit Removal(Args &&...args)
3601 {
3602 using namespace Zivid::Detail::TypeTraits;
3603
3604 static_assert(
3605 AllArgsDecayedAreUnique<Args...>::value,
3606 "Found duplicate types among the arguments passed to Removal(...). "
3607 "Types should be listed at most once.");
3608
3609 set(std::forward<Args>(args)...);
3610 }
3611
3624#ifndef NO_DOC
3625 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
3626#else
3627 template<typename... Args>
3628#endif
3629 void set(Args &&...args)
3630 {
3631 using namespace Zivid::Detail::TypeTraits;
3632
3633 using AllArgsAreDescendantNodes =
3634 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
3635 static_assert(
3636 AllArgsAreDescendantNodes::value,
3637 "All arguments passed to set(...) must be descendant nodes.");
3638
3639 static_assert(
3640 AllArgsDecayedAreUnique<Args...>::value,
3641 "Found duplicate types among the arguments passed to set(...). "
3642 "Types should be listed at most once.");
3643
3644 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
3645 }
3646
3660#ifndef NO_DOC
3661 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
3662#else
3663 template<typename... Args>
3664#endif
3665 Removal copyWith(Args &&...args) const
3666 {
3667 using namespace Zivid::Detail::TypeTraits;
3668
3669 using AllArgsAreDescendantNodes =
3670 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
3671 static_assert(
3672 AllArgsAreDescendantNodes::value,
3673 "All arguments passed to copyWith(...) must be descendant nodes.");
3674
3675 static_assert(
3676 AllArgsDecayedAreUnique<Args...>::value,
3677 "Found duplicate types among the arguments passed to copyWith(...). "
3678 "Types should be listed at most once.");
3679
3680 auto copy{ *this };
3681 copy.set(std::forward<Args>(args)...);
3682 return copy;
3683 }
3684
3686 const Enabled &isEnabled() const
3687 {
3688 return m_enabled;
3689 }
3690
3693 {
3694 return m_enabled;
3695 }
3696
3698 Removal &set(const Enabled &value)
3699 {
3700 m_enabled = value;
3701 return *this;
3702 }
3703
3706 {
3707 return m_maxNeighborDistance;
3708 }
3709
3712 {
3713 return m_maxNeighborDistance;
3714 }
3715
3718 {
3719 m_maxNeighborDistance = value;
3720 return *this;
3721 }
3722
3724 const MinArea &minArea() const
3725 {
3726 return m_minArea;
3727 }
3728
3731 {
3732 return m_minArea;
3733 }
3734
3736 Removal &set(const MinArea &value)
3737 {
3738 m_minArea = value;
3739 return *this;
3740 }
3741
3742 template<
3743 typename T,
3744 typename std::enable_if<
3745 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::Enabled>::value,
3746 int>::type = 0>
3748 {
3749 return m_enabled;
3750 }
3751
3752 template<
3753 typename T,
3754 typename std::enable_if<
3755 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance>::
3756 value,
3757 int>::type = 0>
3759 {
3760 return m_maxNeighborDistance;
3761 }
3762
3763 template<
3764 typename T,
3765 typename std::enable_if<
3766 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::MinArea>::value,
3767 int>::type = 0>
3769 {
3770 return m_minArea;
3771 }
3772
3773 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
3775 {
3776 return m_enabled;
3777 }
3778
3779 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
3781 {
3782 return m_maxNeighborDistance;
3783 }
3784
3785 template<size_t i, typename std::enable_if<i == 2, int>::type = 0>
3787 {
3788 return m_minArea;
3789 }
3790
3792 template<typename F>
3793 void forEach(const F &f) const
3794 {
3795 f(m_enabled);
3796 f(m_maxNeighborDistance);
3797 f(m_minArea);
3798 }
3799
3801 template<typename F>
3802 void forEach(const F &f)
3803 {
3804 f(m_enabled);
3805 f(m_maxNeighborDistance);
3806 f(m_minArea);
3807 }
3808
3810 bool operator==(const Removal &other) const;
3811
3813 bool operator!=(const Removal &other) const;
3814
3816 std::string toString() const;
3817
3819 friend std::ostream &operator<<(std::ostream &stream, const Removal &value)
3820 {
3821 return stream << value.toString();
3822 }
3823
3824 private:
3825 void setFromString(const std::string &value);
3826
3827 void setFromString(const std::string &fullPath, const std::string &value);
3828
3829 std::string getString(const std::string &fullPath) const;
3830
3831 Enabled m_enabled;
3832 MaxNeighborDistance m_maxNeighborDistance;
3833 MinArea m_minArea;
3834
3835 friend struct DataModel::Detail::Befriend<Removal>;
3836 };
3837
3838 using Descendants = std::tuple<
3843
3846
3861#ifndef NO_DOC
3862 template<
3863 typename... Args,
3864 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
3865 typename std::enable_if<
3866 Zivid::Detail::TypeTraits::
3867 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
3868 int>::type = 0>
3869#else
3870 template<typename... Args>
3871#endif
3872 explicit Cluster(Args &&...args)
3873 {
3874 using namespace Zivid::Detail::TypeTraits;
3875
3876 static_assert(
3877 AllArgsDecayedAreUnique<Args...>::value,
3878 "Found duplicate types among the arguments passed to Cluster(...). "
3879 "Types should be listed at most once.");
3880
3881 set(std::forward<Args>(args)...);
3882 }
3883
3897#ifndef NO_DOC
3898 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
3899#else
3900 template<typename... Args>
3901#endif
3902 void set(Args &&...args)
3903 {
3904 using namespace Zivid::Detail::TypeTraits;
3905
3906 using AllArgsAreDescendantNodes =
3907 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
3908 static_assert(
3909 AllArgsAreDescendantNodes::value,
3910 "All arguments passed to set(...) must be descendant nodes.");
3911
3912 static_assert(
3913 AllArgsDecayedAreUnique<Args...>::value,
3914 "Found duplicate types among the arguments passed to set(...). "
3915 "Types should be listed at most once.");
3916
3917 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
3918 }
3919
3934#ifndef NO_DOC
3935 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
3936#else
3937 template<typename... Args>
3938#endif
3939 Cluster copyWith(Args &&...args) const
3940 {
3941 using namespace Zivid::Detail::TypeTraits;
3942
3943 using AllArgsAreDescendantNodes =
3944 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
3945 static_assert(
3946 AllArgsAreDescendantNodes::value,
3947 "All arguments passed to copyWith(...) must be descendant nodes.");
3948
3949 static_assert(
3950 AllArgsDecayedAreUnique<Args...>::value,
3951 "Found duplicate types among the arguments passed to copyWith(...). "
3952 "Types should be listed at most once.");
3953
3954 auto copy{ *this };
3955 copy.set(std::forward<Args>(args)...);
3956 return copy;
3957 }
3958
3960 const Removal &removal() const
3961 {
3962 return m_removal;
3963 }
3964
3967 {
3968 return m_removal;
3969 }
3970
3972 Cluster &set(const Removal &value)
3973 {
3974 m_removal = value;
3975 return *this;
3976 }
3977
3980 {
3981 m_removal.set(value);
3982 return *this;
3983 }
3984
3987 {
3988 m_removal.set(value);
3989 return *this;
3990 }
3991
3994 {
3995 m_removal.set(value);
3996 return *this;
3997 }
3998
3999 template<
4000 typename T,
4001 typename std::enable_if<
4002 std::is_same<T, Settings::Processing::Filters::Cluster::Removal>::value,
4003 int>::type = 0>
4005 {
4006 return m_removal;
4007 }
4008
4009 template<
4010 typename T,
4011 typename std::enable_if<
4012 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::Enabled>::value,
4013 int>::type = 0>
4015 {
4017 }
4018
4019 template<
4020 typename T,
4021 typename std::enable_if<
4022 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance>::
4023 value,
4024 int>::type = 0>
4026 {
4028 }
4029
4030 template<
4031 typename T,
4032 typename std::enable_if<
4033 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::MinArea>::value,
4034 int>::type = 0>
4036 {
4038 }
4039
4040 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
4042 {
4043 return m_removal;
4044 }
4045
4047 template<typename F>
4048 void forEach(const F &f) const
4049 {
4050 f(m_removal);
4051 }
4052
4054 template<typename F>
4055 void forEach(const F &f)
4056 {
4057 f(m_removal);
4058 }
4059
4061 bool operator==(const Cluster &other) const;
4062
4064 bool operator!=(const Cluster &other) const;
4065
4067 std::string toString() const;
4068
4070 friend std::ostream &operator<<(std::ostream &stream, const Cluster &value)
4071 {
4072 return stream << value.toString();
4073 }
4074
4075 private:
4076 void setFromString(const std::string &value);
4077
4078 void setFromString(const std::string &fullPath, const std::string &value);
4079
4080 std::string getString(const std::string &fullPath) const;
4081
4082 Removal m_removal;
4083
4084 friend struct DataModel::Detail::Befriend<Cluster>;
4085 };
4086
4088
4089 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
4091 {
4092 public:
4095
4097 static constexpr const char *path{ "Processing/Filters/Experimental" };
4098
4100 static constexpr const char *name{ "Experimental" };
4101
4103 static constexpr const char *description{
4104 R"description(Experimental filters. These may be renamed, moved or deleted in the future.)description"
4105 };
4106
4112
4113 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
4115 {
4116 public:
4119
4121 static constexpr const char *path{ "Processing/Filters/Experimental/ContrastDistortion" };
4122
4124 static constexpr const char *name{ "ContrastDistortion" };
4125
4127 static constexpr const char *description{
4128 R"description(Corrects artifacts that appear when imaging scenes with large texture gradients
4129or high contrast. These artifacts are caused by blurring in the lens. The filter
4130works best when aperture values are chosen such that the camera has quite good focus.
4131The filter also supports removing the points that experience a large correction.
4132)description"
4133 };
4134
4136
4137 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
4139 {
4140 public:
4143
4145 static constexpr const char *path{
4146 "Processing/Filters/Experimental/ContrastDistortion/Correction"
4147 };
4148
4150 static constexpr const char *name{ "Correction" };
4151
4153 static constexpr const char *description{ R"description(Correction)description" };
4154
4156
4157 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
4159 {
4160 public:
4163
4165 static constexpr const char *path{
4166 "Processing/Filters/Experimental/ContrastDistortion/Correction/Enabled"
4167 };
4168
4170 static constexpr const char *name{ "Enabled" };
4171
4173 static constexpr const char *description{ R"description(Enabled)description" };
4174
4176 using ValueType = bool;
4177 static const Enabled yes;
4178 static const Enabled no;
4179
4181 static std::set<bool> validValues()
4182 {
4183 return { false, true };
4184 }
4185
4187 Enabled() = default;
4188
4190 explicit constexpr Enabled(bool value)
4191 : m_opt{ value }
4192 {}
4193
4198 bool value() const;
4199
4201 bool hasValue() const;
4202
4204 void reset();
4205
4207 std::string toString() const;
4208
4210 bool operator==(const Enabled &other) const
4211 {
4212 return m_opt == other.m_opt;
4213 }
4214
4216 bool operator!=(const Enabled &other) const
4217 {
4218 return m_opt != other.m_opt;
4219 }
4220
4222 friend std::ostream &operator<<(std::ostream &stream, const Enabled &value)
4223 {
4224 return stream << value.toString();
4225 }
4226
4227 private:
4228 void setFromString(const std::string &value);
4229
4230 Zivid::DataModel::Detail::Optional<bool> m_opt;
4231
4232 friend struct DataModel::Detail::Befriend<Enabled>;
4233 };
4234
4236
4237 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
4239 {
4240 public:
4243
4245 static constexpr const char *path{
4246 "Processing/Filters/Experimental/ContrastDistortion/Correction/Strength"
4247 };
4248
4250 static constexpr const char *name{ "Strength" };
4251
4253 static constexpr const char *description{
4254 R"description(Higher values gives more correction.)description"
4255 };
4256
4258 using ValueType = double;
4259
4261 static constexpr Range<double> validRange()
4262 {
4263 return { 0.0, 1.0 };
4264 }
4265
4267 Strength() = default;
4268
4270 explicit constexpr Strength(double value)
4271 : m_opt{ verifyValue(value) }
4272 {}
4273
4278 double value() const;
4279
4281 bool hasValue() const;
4282
4284 void reset();
4285
4287 std::string toString() const;
4288
4290 bool operator==(const Strength &other) const
4291 {
4292 return m_opt == other.m_opt;
4293 }
4294
4296 bool operator!=(const Strength &other) const
4297 {
4298 return m_opt != other.m_opt;
4299 }
4300
4302 bool operator<(const Strength &other) const
4303 {
4304 return m_opt < other.m_opt;
4305 }
4306
4308 bool operator>(const Strength &other) const
4309 {
4310 return m_opt > other.m_opt;
4311 }
4312
4314 bool operator<=(const Strength &other) const
4315 {
4316 return m_opt <= other.m_opt;
4317 }
4318
4320 bool operator>=(const Strength &other) const
4321 {
4322 return m_opt >= other.m_opt;
4323 }
4324
4326 friend std::ostream &operator<<(std::ostream &stream, const Strength &value)
4327 {
4328 return stream << value.toString();
4329 }
4330
4331 private:
4332 void setFromString(const std::string &value);
4333
4334 constexpr ValueType static verifyValue(const ValueType &value)
4335 {
4336 return validRange().isInRange(value)
4337 ? value
4338 : throw std::out_of_range{ "Strength{ " + std::to_string(value)
4339 + " } is not in range ["
4340 + std::to_string(validRange().min()) + ", "
4341 + std::to_string(validRange().max()) + "]" };
4342 }
4343
4344 Zivid::DataModel::Detail::Optional<double> m_opt;
4345
4346 friend struct DataModel::Detail::Befriend<Strength>;
4347 };
4348
4349 using Descendants = std::tuple<
4352
4355
4368#ifndef NO_DOC
4369 template<
4370 typename... Args,
4371 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
4372 typename std::enable_if<
4373 Zivid::Detail::TypeTraits::
4374 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
4375 int>::type = 0>
4376#else
4377 template<typename... Args>
4378#endif
4379 explicit Correction(Args &&...args)
4380 {
4381 using namespace Zivid::Detail::TypeTraits;
4382
4383 static_assert(
4384 AllArgsDecayedAreUnique<Args...>::value,
4385 "Found duplicate types among the arguments passed to Correction(...). "
4386 "Types should be listed at most once.");
4387
4388 set(std::forward<Args>(args)...);
4389 }
4390
4402#ifndef NO_DOC
4403 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
4404#else
4405 template<typename... Args>
4406#endif
4407 void set(Args &&...args)
4408 {
4409 using namespace Zivid::Detail::TypeTraits;
4410
4411 using AllArgsAreDescendantNodes =
4412 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
4413 static_assert(
4414 AllArgsAreDescendantNodes::value,
4415 "All arguments passed to set(...) must be descendant nodes.");
4416
4417 static_assert(
4418 AllArgsDecayedAreUnique<Args...>::value,
4419 "Found duplicate types among the arguments passed to set(...). "
4420 "Types should be listed at most once.");
4421
4422 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
4423 }
4424
4437#ifndef NO_DOC
4438 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
4439#else
4440 template<typename... Args>
4441#endif
4442 Correction copyWith(Args &&...args) const
4443 {
4444 using namespace Zivid::Detail::TypeTraits;
4445
4446 using AllArgsAreDescendantNodes =
4447 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
4448 static_assert(
4449 AllArgsAreDescendantNodes::value,
4450 "All arguments passed to copyWith(...) must be descendant nodes.");
4451
4452 static_assert(
4453 AllArgsDecayedAreUnique<Args...>::value,
4454 "Found duplicate types among the arguments passed to copyWith(...). "
4455 "Types should be listed at most once.");
4456
4457 auto copy{ *this };
4458 copy.set(std::forward<Args>(args)...);
4459 return copy;
4460 }
4461
4463 const Enabled &isEnabled() const
4464 {
4465 return m_enabled;
4466 }
4467
4470 {
4471 return m_enabled;
4472 }
4473
4475 Correction &set(const Enabled &value)
4476 {
4477 m_enabled = value;
4478 return *this;
4479 }
4480
4482 const Strength &strength() const
4483 {
4484 return m_strength;
4485 }
4486
4489 {
4490 return m_strength;
4491 }
4492
4494 Correction &set(const Strength &value)
4495 {
4496 m_strength = value;
4497 return *this;
4498 }
4499
4500 template<
4501 typename T,
4502 typename std::enable_if<
4503 std::is_same<
4504 T,
4505 Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::
4506 Enabled>::value,
4507 int>::type = 0>
4509 get() const
4510 {
4511 return m_enabled;
4512 }
4513
4514 template<
4515 typename T,
4516 typename std::enable_if<
4517 std::is_same<
4518 T,
4519 Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::
4520 Strength>::value,
4521 int>::type = 0>
4523 &
4524 get() const
4525 {
4526 return m_strength;
4527 }
4528
4529 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
4531 get() const
4532 {
4533 return m_enabled;
4534 }
4535
4536 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
4538 &
4539 get() const
4540 {
4541 return m_strength;
4542 }
4543
4545 template<typename F>
4546 void forEach(const F &f) const
4547 {
4548 f(m_enabled);
4549 f(m_strength);
4550 }
4551
4553 template<typename F>
4554 void forEach(const F &f)
4555 {
4556 f(m_enabled);
4557 f(m_strength);
4558 }
4559
4561 bool operator==(const Correction &other) const;
4562
4564 bool operator!=(const Correction &other) const;
4565
4567 std::string toString() const;
4568
4570 friend std::ostream &operator<<(std::ostream &stream, const Correction &value)
4571 {
4572 return stream << value.toString();
4573 }
4574
4575 private:
4576 void setFromString(const std::string &value);
4577
4578 void setFromString(const std::string &fullPath, const std::string &value);
4579
4580 std::string getString(const std::string &fullPath) const;
4581
4582 Enabled m_enabled;
4583 Strength m_strength;
4584
4585 friend struct DataModel::Detail::Befriend<Correction>;
4586 };
4587
4589
4590 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
4592 {
4593 public:
4596
4598 static constexpr const char *path{
4599 "Processing/Filters/Experimental/ContrastDistortion/Removal"
4600 };
4601
4603 static constexpr const char *name{ "Removal" };
4604
4606 static constexpr const char *description{ R"description(Removal)description" };
4607
4609
4610 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
4612 {
4613 public:
4616
4618 static constexpr const char *path{
4619 "Processing/Filters/Experimental/ContrastDistortion/Removal/Enabled"
4620 };
4621
4623 static constexpr const char *name{ "Enabled" };
4624
4626 static constexpr const char *description{ R"description(Enabled)description" };
4627
4629 using ValueType = bool;
4630 static const Enabled yes;
4631 static const Enabled no;
4632
4634 static std::set<bool> validValues()
4635 {
4636 return { false, true };
4637 }
4638
4640 Enabled() = default;
4641
4643 explicit constexpr Enabled(bool value)
4644 : m_opt{ value }
4645 {}
4646
4651 bool value() const;
4652
4654 bool hasValue() const;
4655
4657 void reset();
4658
4660 std::string toString() const;
4661
4663 bool operator==(const Enabled &other) const
4664 {
4665 return m_opt == other.m_opt;
4666 }
4667
4669 bool operator!=(const Enabled &other) const
4670 {
4671 return m_opt != other.m_opt;
4672 }
4673
4675 friend std::ostream &operator<<(std::ostream &stream, const Enabled &value)
4676 {
4677 return stream << value.toString();
4678 }
4679
4680 private:
4681 void setFromString(const std::string &value);
4682
4683 Zivid::DataModel::Detail::Optional<bool> m_opt;
4684
4685 friend struct DataModel::Detail::Befriend<Enabled>;
4686 };
4687
4689
4690 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
4692 {
4693 public:
4696
4698 static constexpr const char *path{
4699 "Processing/Filters/Experimental/ContrastDistortion/Removal/Threshold"
4700 };
4701
4703 static constexpr const char *name{ "Threshold" };
4704
4706 static constexpr const char *description{
4707 R"description(Higher values remove more points.)description"
4708 };
4709
4711 using ValueType = double;
4712
4714 static constexpr Range<double> validRange()
4715 {
4716 return { 0.0, 1.0 };
4717 }
4718
4720 Threshold() = default;
4721
4723 explicit constexpr Threshold(double value)
4724 : m_opt{ verifyValue(value) }
4725 {}
4726
4731 double value() const;
4732
4734 bool hasValue() const;
4735
4737 void reset();
4738
4740 std::string toString() const;
4741
4743 bool operator==(const Threshold &other) const
4744 {
4745 return m_opt == other.m_opt;
4746 }
4747
4749 bool operator!=(const Threshold &other) const
4750 {
4751 return m_opt != other.m_opt;
4752 }
4753
4755 bool operator<(const Threshold &other) const
4756 {
4757 return m_opt < other.m_opt;
4758 }
4759
4761 bool operator>(const Threshold &other) const
4762 {
4763 return m_opt > other.m_opt;
4764 }
4765
4767 bool operator<=(const Threshold &other) const
4768 {
4769 return m_opt <= other.m_opt;
4770 }
4771
4773 bool operator>=(const Threshold &other) const
4774 {
4775 return m_opt >= other.m_opt;
4776 }
4777
4779 friend std::ostream &operator<<(std::ostream &stream, const Threshold &value)
4780 {
4781 return stream << value.toString();
4782 }
4783
4784 private:
4785 void setFromString(const std::string &value);
4786
4787 constexpr ValueType static verifyValue(const ValueType &value)
4788 {
4789 return validRange().isInRange(value)
4790 ? value
4791 : throw std::out_of_range{ "Threshold{ " + std::to_string(value)
4792 + " } is not in range ["
4793 + std::to_string(validRange().min()) + ", "
4794 + std::to_string(validRange().max()) + "]" };
4795 }
4796
4797 Zivid::DataModel::Detail::Optional<double> m_opt;
4798
4799 friend struct DataModel::Detail::Befriend<Threshold>;
4800 };
4801
4802 using Descendants = std::tuple<
4805
4808
4821#ifndef NO_DOC
4822 template<
4823 typename... Args,
4824 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
4825 typename std::enable_if<
4826 Zivid::Detail::TypeTraits::
4827 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
4828 int>::type = 0>
4829#else
4830 template<typename... Args>
4831#endif
4832 explicit Removal(Args &&...args)
4833 {
4834 using namespace Zivid::Detail::TypeTraits;
4835
4836 static_assert(
4837 AllArgsDecayedAreUnique<Args...>::value,
4838 "Found duplicate types among the arguments passed to Removal(...). "
4839 "Types should be listed at most once.");
4840
4841 set(std::forward<Args>(args)...);
4842 }
4843
4855#ifndef NO_DOC
4856 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
4857#else
4858 template<typename... Args>
4859#endif
4860 void set(Args &&...args)
4861 {
4862 using namespace Zivid::Detail::TypeTraits;
4863
4864 using AllArgsAreDescendantNodes =
4865 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
4866 static_assert(
4867 AllArgsAreDescendantNodes::value,
4868 "All arguments passed to set(...) must be descendant nodes.");
4869
4870 static_assert(
4871 AllArgsDecayedAreUnique<Args...>::value,
4872 "Found duplicate types among the arguments passed to set(...). "
4873 "Types should be listed at most once.");
4874
4875 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
4876 }
4877
4890#ifndef NO_DOC
4891 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
4892#else
4893 template<typename... Args>
4894#endif
4895 Removal copyWith(Args &&...args) const
4896 {
4897 using namespace Zivid::Detail::TypeTraits;
4898
4899 using AllArgsAreDescendantNodes =
4900 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
4901 static_assert(
4902 AllArgsAreDescendantNodes::value,
4903 "All arguments passed to copyWith(...) must be descendant nodes.");
4904
4905 static_assert(
4906 AllArgsDecayedAreUnique<Args...>::value,
4907 "Found duplicate types among the arguments passed to copyWith(...). "
4908 "Types should be listed at most once.");
4909
4910 auto copy{ *this };
4911 copy.set(std::forward<Args>(args)...);
4912 return copy;
4913 }
4914
4916 const Enabled &isEnabled() const
4917 {
4918 return m_enabled;
4919 }
4920
4923 {
4924 return m_enabled;
4925 }
4926
4928 Removal &set(const Enabled &value)
4929 {
4930 m_enabled = value;
4931 return *this;
4932 }
4933
4935 const Threshold &threshold() const
4936 {
4937 return m_threshold;
4938 }
4939
4942 {
4943 return m_threshold;
4944 }
4945
4947 Removal &set(const Threshold &value)
4948 {
4949 m_threshold = value;
4950 return *this;
4951 }
4952
4953 template<
4954 typename T,
4955 typename std::enable_if<
4956 std::is_same<
4957 T,
4958 Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::
4959 Enabled>::value,
4960 int>::type = 0>
4962 get() const
4963 {
4964 return m_enabled;
4965 }
4966
4967 template<
4968 typename T,
4969 typename std::enable_if<
4970 std::is_same<
4971 T,
4972 Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::
4973 Threshold>::value,
4974 int>::type = 0>
4976 get() const
4977 {
4978 return m_threshold;
4979 }
4980
4981 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
4983 get() const
4984 {
4985 return m_enabled;
4986 }
4987
4988 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
4990 get() const
4991 {
4992 return m_threshold;
4993 }
4994
4996 template<typename F>
4997 void forEach(const F &f) const
4998 {
4999 f(m_enabled);
5000 f(m_threshold);
5001 }
5002
5004 template<typename F>
5005 void forEach(const F &f)
5006 {
5007 f(m_enabled);
5008 f(m_threshold);
5009 }
5010
5012 bool operator==(const Removal &other) const;
5013
5015 bool operator!=(const Removal &other) const;
5016
5018 std::string toString() const;
5019
5021 friend std::ostream &operator<<(std::ostream &stream, const Removal &value)
5022 {
5023 return stream << value.toString();
5024 }
5025
5026 private:
5027 void setFromString(const std::string &value);
5028
5029 void setFromString(const std::string &fullPath, const std::string &value);
5030
5031 std::string getString(const std::string &fullPath) const;
5032
5033 Enabled m_enabled;
5034 Threshold m_threshold;
5035
5036 friend struct DataModel::Detail::Befriend<Removal>;
5037 };
5038
5039 using Descendants = std::tuple<
5046
5049
5066#ifndef NO_DOC
5067 template<
5068 typename... Args,
5069 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
5070 typename std::enable_if<
5071 Zivid::Detail::TypeTraits::
5072 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
5073 int>::type = 0>
5074#else
5075 template<typename... Args>
5076#endif
5077 explicit ContrastDistortion(Args &&...args)
5078 {
5079 using namespace Zivid::Detail::TypeTraits;
5080
5081 static_assert(
5082 AllArgsDecayedAreUnique<Args...>::value,
5083 "Found duplicate types among the arguments passed to ContrastDistortion(...). "
5084 "Types should be listed at most once.");
5085
5086 set(std::forward<Args>(args)...);
5087 }
5088
5104#ifndef NO_DOC
5105 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
5106#else
5107 template<typename... Args>
5108#endif
5109 void set(Args &&...args)
5110 {
5111 using namespace Zivid::Detail::TypeTraits;
5112
5113 using AllArgsAreDescendantNodes =
5114 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
5115 static_assert(
5116 AllArgsAreDescendantNodes::value,
5117 "All arguments passed to set(...) must be descendant nodes.");
5118
5119 static_assert(
5120 AllArgsDecayedAreUnique<Args...>::value,
5121 "Found duplicate types among the arguments passed to set(...). "
5122 "Types should be listed at most once.");
5123
5124 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
5125 }
5126
5143#ifndef NO_DOC
5144 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
5145#else
5146 template<typename... Args>
5147#endif
5148 ContrastDistortion copyWith(Args &&...args) const
5149 {
5150 using namespace Zivid::Detail::TypeTraits;
5151
5152 using AllArgsAreDescendantNodes =
5153 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
5154 static_assert(
5155 AllArgsAreDescendantNodes::value,
5156 "All arguments passed to copyWith(...) must be descendant nodes.");
5157
5158 static_assert(
5159 AllArgsDecayedAreUnique<Args...>::value,
5160 "Found duplicate types among the arguments passed to copyWith(...). "
5161 "Types should be listed at most once.");
5162
5163 auto copy{ *this };
5164 copy.set(std::forward<Args>(args)...);
5165 return copy;
5166 }
5167
5169 const Correction &correction() const
5170 {
5171 return m_correction;
5172 }
5173
5176 {
5177 return m_correction;
5178 }
5179
5182 {
5183 m_correction = value;
5184 return *this;
5185 }
5186
5189 {
5190 m_correction.set(value);
5191 return *this;
5192 }
5193
5196 {
5197 m_correction.set(value);
5198 return *this;
5199 }
5200
5202 const Removal &removal() const
5203 {
5204 return m_removal;
5205 }
5206
5209 {
5210 return m_removal;
5211 }
5212
5215 {
5216 m_removal = value;
5217 return *this;
5218 }
5219
5222 {
5223 m_removal.set(value);
5224 return *this;
5225 }
5226
5229 {
5230 m_removal.set(value);
5231 return *this;
5232 }
5233
5234 template<
5235 typename T,
5236 typename std::enable_if<
5237 std::is_same<
5238 T,
5240 int>::type = 0>
5242 {
5243 return m_correction;
5244 }
5245
5246 template<
5247 typename T,
5248 typename std::enable_if<
5249 std::is_same<
5250 T,
5251 Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::
5252 Enabled>::value,
5253 int>::type = 0>
5255 get() const
5256 {
5257 return m_correction.get<
5259 }
5260
5261 template<
5262 typename T,
5263 typename std::enable_if<
5264 std::is_same<
5265 T,
5266 Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::
5267 Strength>::value,
5268 int>::type = 0>
5270 get() const
5271 {
5272 return m_correction.get<Settings::Processing::Filters::Experimental::ContrastDistortion::
5273 Correction::Strength>();
5274 }
5275
5276 template<
5277 typename T,
5278 typename std::enable_if<
5279 std::is_same<
5280 T,
5282 int>::type = 0>
5284 {
5285 return m_removal;
5286 }
5287
5288 template<
5289 typename T,
5290 typename std::enable_if<
5291 std::is_same<
5292 T,
5294 value,
5295 int>::type = 0>
5297 const
5298 {
5299 return m_removal.get<
5301 }
5302
5303 template<
5304 typename T,
5305 typename std::enable_if<
5306 std::is_same<
5307 T,
5308 Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::
5309 Threshold>::value,
5310 int>::type = 0>
5312 const
5313 {
5314 return m_removal.get<
5316 }
5317
5318 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
5320 {
5321 return m_correction;
5322 }
5323
5324 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
5326 {
5327 return m_removal;
5328 }
5329
5331 template<typename F>
5332 void forEach(const F &f) const
5333 {
5334 f(m_correction);
5335 f(m_removal);
5336 }
5337
5339 template<typename F>
5340 void forEach(const F &f)
5341 {
5342 f(m_correction);
5343 f(m_removal);
5344 }
5345
5347 bool operator==(const ContrastDistortion &other) const;
5348
5350 bool operator!=(const ContrastDistortion &other) const;
5351
5353 std::string toString() const;
5354
5356 friend std::ostream &operator<<(std::ostream &stream, const ContrastDistortion &value)
5357 {
5358 return stream << value.toString();
5359 }
5360
5361 private:
5362 void setFromString(const std::string &value);
5363
5364 void setFromString(const std::string &fullPath, const std::string &value);
5365
5366 std::string getString(const std::string &fullPath) const;
5367
5368 Correction m_correction;
5369 Removal m_removal;
5370
5371 friend struct DataModel::Detail::Befriend<ContrastDistortion>;
5372 };
5373
5376
5377 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
5379 {
5380 public:
5383
5385 static constexpr const char *path{ "Processing/Filters/Experimental/HoleFilling" };
5386
5388 static constexpr const char *name{ "HoleFilling" };
5389
5391 static constexpr const char *description{
5392 R"description(Fills in removed points by interpolating remaining surrounding points.
5393)description"
5394 };
5395
5397
5398 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
5400 {
5401 public:
5404
5406 static constexpr const char *path{ "Processing/Filters/Experimental/HoleFilling/Enabled" };
5407
5409 static constexpr const char *name{ "Enabled" };
5410
5412 static constexpr const char *description{ R"description(Enabled)description" };
5413
5415 using ValueType = bool;
5416 static const Enabled yes;
5417 static const Enabled no;
5418
5420 static std::set<bool> validValues()
5421 {
5422 return { false, true };
5423 }
5424
5426 Enabled() = default;
5427
5429 explicit constexpr Enabled(bool value)
5430 : m_opt{ value }
5431 {}
5432
5437 bool value() const;
5438
5440 bool hasValue() const;
5441
5443 void reset();
5444
5446 std::string toString() const;
5447
5449 bool operator==(const Enabled &other) const
5450 {
5451 return m_opt == other.m_opt;
5452 }
5453
5455 bool operator!=(const Enabled &other) const
5456 {
5457 return m_opt != other.m_opt;
5458 }
5459
5461 friend std::ostream &operator<<(std::ostream &stream, const Enabled &value)
5462 {
5463 return stream << value.toString();
5464 }
5465
5466 private:
5467 void setFromString(const std::string &value);
5468
5469 Zivid::DataModel::Detail::Optional<bool> m_opt;
5470
5471 friend struct DataModel::Detail::Befriend<Enabled>;
5472 };
5473
5478
5479 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
5481 {
5482 public:
5485
5487 static constexpr const char *path{ "Processing/Filters/Experimental/HoleFilling/HoleSize" };
5488
5490 static constexpr const char *name{ "HoleSize" };
5491
5493 static constexpr const char *description{
5494 R"description(Relative diameter of holes to fill. Increasing this will fill more points, but require more
5495computation time. The maximum allowed hole size scales with distance, so that we allow
5496filling larger holes at greater distances, measured in mm.
5497)description"
5498 };
5499
5501 using ValueType = double;
5502
5504 static constexpr Range<double> validRange()
5505 {
5506 return { 0.0, 1.0 };
5507 }
5508
5510 HoleSize() = default;
5511
5513 explicit constexpr HoleSize(double value)
5514 : m_opt{ verifyValue(value) }
5515 {}
5516
5521 double value() const;
5522
5524 bool hasValue() const;
5525
5527 void reset();
5528
5530 std::string toString() const;
5531
5533 bool operator==(const HoleSize &other) const
5534 {
5535 return m_opt == other.m_opt;
5536 }
5537
5539 bool operator!=(const HoleSize &other) const
5540 {
5541 return m_opt != other.m_opt;
5542 }
5543
5545 bool operator<(const HoleSize &other) const
5546 {
5547 return m_opt < other.m_opt;
5548 }
5549
5551 bool operator>(const HoleSize &other) const
5552 {
5553 return m_opt > other.m_opt;
5554 }
5555
5557 bool operator<=(const HoleSize &other) const
5558 {
5559 return m_opt <= other.m_opt;
5560 }
5561
5563 bool operator>=(const HoleSize &other) const
5564 {
5565 return m_opt >= other.m_opt;
5566 }
5567
5569 friend std::ostream &operator<<(std::ostream &stream, const HoleSize &value)
5570 {
5571 return stream << value.toString();
5572 }
5573
5574 private:
5575 void setFromString(const std::string &value);
5576
5577 constexpr ValueType static verifyValue(const ValueType &value)
5578 {
5579 return validRange().isInRange(value)
5580 ? value
5581 : throw std::out_of_range{ "HoleSize{ " + std::to_string(value)
5582 + " } is not in range ["
5583 + std::to_string(validRange().min()) + ", "
5584 + std::to_string(validRange().max()) + "]" };
5585 }
5586
5587 Zivid::DataModel::Detail::Optional<double> m_opt;
5588
5589 friend struct DataModel::Detail::Befriend<HoleSize>;
5590 };
5591
5597
5598 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
5600 {
5601 public:
5604
5606 static constexpr const char *path{
5607 "Processing/Filters/Experimental/HoleFilling/Strictness"
5608 };
5609
5611 static constexpr const char *name{ "Strictness" };
5612
5614 static constexpr const char *description{
5615 R"description(Level of strictness when considering if a point should be filled. A higher level of
5616strictness requires a missing point to be surrounded by valid points on more sides in
5617order to be filled. Increasing this will fill fewer points, but it will be less likely to
5618fill gaps that are not circular, for example between two edges.
5619)description"
5620 };
5621
5623 using ValueType = int32_t;
5624
5626 static constexpr Range<int32_t> validRange()
5627 {
5628 return { 1, 4 };
5629 }
5630
5632 Strictness() = default;
5633
5635 explicit constexpr Strictness(int32_t value)
5636 : m_opt{ verifyValue(value) }
5637 {}
5638
5643 int32_t value() const;
5644
5646 bool hasValue() const;
5647
5649 void reset();
5650
5652 std::string toString() const;
5653
5655 bool operator==(const Strictness &other) const
5656 {
5657 return m_opt == other.m_opt;
5658 }
5659
5661 bool operator!=(const Strictness &other) const
5662 {
5663 return m_opt != other.m_opt;
5664 }
5665
5667 bool operator<(const Strictness &other) const
5668 {
5669 return m_opt < other.m_opt;
5670 }
5671
5673 bool operator>(const Strictness &other) const
5674 {
5675 return m_opt > other.m_opt;
5676 }
5677
5679 bool operator<=(const Strictness &other) const
5680 {
5681 return m_opt <= other.m_opt;
5682 }
5683
5685 bool operator>=(const Strictness &other) const
5686 {
5687 return m_opt >= other.m_opt;
5688 }
5689
5691 friend std::ostream &operator<<(std::ostream &stream, const Strictness &value)
5692 {
5693 return stream << value.toString();
5694 }
5695
5696 private:
5697 void setFromString(const std::string &value);
5698
5699 constexpr ValueType static verifyValue(const ValueType &value)
5700 {
5701 return validRange().isInRange(value)
5702 ? value
5703 : throw std::out_of_range{ "Strictness{ " + std::to_string(value)
5704 + " } is not in range ["
5705 + std::to_string(validRange().min()) + ", "
5706 + std::to_string(validRange().max()) + "]" };
5707 }
5708
5709 Zivid::DataModel::Detail::Optional<int32_t> m_opt;
5710
5711 friend struct DataModel::Detail::Befriend<Strictness>;
5712 };
5713
5714 using Descendants = std::tuple<
5718
5721
5735#ifndef NO_DOC
5736 template<
5737 typename... Args,
5738 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
5739 typename std::enable_if<
5740 Zivid::Detail::TypeTraits::
5741 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
5742 int>::type = 0>
5743#else
5744 template<typename... Args>
5745#endif
5746 explicit HoleFilling(Args &&...args)
5747 {
5748 using namespace Zivid::Detail::TypeTraits;
5749
5750 static_assert(
5751 AllArgsDecayedAreUnique<Args...>::value,
5752 "Found duplicate types among the arguments passed to HoleFilling(...). "
5753 "Types should be listed at most once.");
5754
5755 set(std::forward<Args>(args)...);
5756 }
5757
5770#ifndef NO_DOC
5771 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
5772#else
5773 template<typename... Args>
5774#endif
5775 void set(Args &&...args)
5776 {
5777 using namespace Zivid::Detail::TypeTraits;
5778
5779 using AllArgsAreDescendantNodes =
5780 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
5781 static_assert(
5782 AllArgsAreDescendantNodes::value,
5783 "All arguments passed to set(...) must be descendant nodes.");
5784
5785 static_assert(
5786 AllArgsDecayedAreUnique<Args...>::value,
5787 "Found duplicate types among the arguments passed to set(...). "
5788 "Types should be listed at most once.");
5789
5790 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
5791 }
5792
5806#ifndef NO_DOC
5807 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
5808#else
5809 template<typename... Args>
5810#endif
5811 HoleFilling copyWith(Args &&...args) const
5812 {
5813 using namespace Zivid::Detail::TypeTraits;
5814
5815 using AllArgsAreDescendantNodes =
5816 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
5817 static_assert(
5818 AllArgsAreDescendantNodes::value,
5819 "All arguments passed to copyWith(...) must be descendant nodes.");
5820
5821 static_assert(
5822 AllArgsDecayedAreUnique<Args...>::value,
5823 "Found duplicate types among the arguments passed to copyWith(...). "
5824 "Types should be listed at most once.");
5825
5826 auto copy{ *this };
5827 copy.set(std::forward<Args>(args)...);
5828 return copy;
5829 }
5830
5832 const Enabled &isEnabled() const
5833 {
5834 return m_enabled;
5835 }
5836
5839 {
5840 return m_enabled;
5841 }
5842
5844 HoleFilling &set(const Enabled &value)
5845 {
5846 m_enabled = value;
5847 return *this;
5848 }
5849
5851 const HoleSize &holeSize() const
5852 {
5853 return m_holeSize;
5854 }
5855
5858 {
5859 return m_holeSize;
5860 }
5861
5863 HoleFilling &set(const HoleSize &value)
5864 {
5865 m_holeSize = value;
5866 return *this;
5867 }
5868
5870 const Strictness &strictness() const
5871 {
5872 return m_strictness;
5873 }
5874
5877 {
5878 return m_strictness;
5879 }
5880
5883 {
5884 m_strictness = value;
5885 return *this;
5886 }
5887
5888 template<
5889 typename T,
5890 typename std::enable_if<
5891 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::Enabled>::
5892 value,
5893 int>::type = 0>
5895 {
5896 return m_enabled;
5897 }
5898
5899 template<
5900 typename T,
5901 typename std::enable_if<
5902 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::HoleSize>::
5903 value,
5904 int>::type = 0>
5906 {
5907 return m_holeSize;
5908 }
5909
5910 template<
5911 typename T,
5912 typename std::enable_if<
5913 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::Strictness>::
5914 value,
5915 int>::type = 0>
5917 {
5918 return m_strictness;
5919 }
5920
5921 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
5923 {
5924 return m_enabled;
5925 }
5926
5927 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
5929 {
5930 return m_holeSize;
5931 }
5932
5933 template<size_t i, typename std::enable_if<i == 2, int>::type = 0>
5935 {
5936 return m_strictness;
5937 }
5938
5940 template<typename F>
5941 void forEach(const F &f) const
5942 {
5943 f(m_enabled);
5944 f(m_holeSize);
5945 f(m_strictness);
5946 }
5947
5949 template<typename F>
5950 void forEach(const F &f)
5951 {
5952 f(m_enabled);
5953 f(m_holeSize);
5954 f(m_strictness);
5955 }
5956
5958 bool operator==(const HoleFilling &other) const;
5959
5961 bool operator!=(const HoleFilling &other) const;
5962
5964 std::string toString() const;
5965
5967 friend std::ostream &operator<<(std::ostream &stream, const HoleFilling &value)
5968 {
5969 return stream << value.toString();
5970 }
5971
5972 private:
5973 void setFromString(const std::string &value);
5974
5975 void setFromString(const std::string &fullPath, const std::string &value);
5976
5977 std::string getString(const std::string &fullPath) const;
5978
5979 Enabled m_enabled;
5980 HoleSize m_holeSize;
5981 Strictness m_strictness;
5982
5983 friend struct DataModel::Detail::Befriend<HoleFilling>;
5984 };
5985
5986 using Descendants = std::tuple<
5998
6001
6023#ifndef NO_DOC
6024 template<
6025 typename... Args,
6026 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
6027 typename std::enable_if<
6028 Zivid::Detail::TypeTraits::
6029 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
6030 int>::type = 0>
6031#else
6032 template<typename... Args>
6033#endif
6034 explicit Experimental(Args &&...args)
6035 {
6036 using namespace Zivid::Detail::TypeTraits;
6037
6038 static_assert(
6039 AllArgsDecayedAreUnique<Args...>::value,
6040 "Found duplicate types among the arguments passed to Experimental(...). "
6041 "Types should be listed at most once.");
6042
6043 set(std::forward<Args>(args)...);
6044 }
6045
6066#ifndef NO_DOC
6067 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
6068#else
6069 template<typename... Args>
6070#endif
6071 void set(Args &&...args)
6072 {
6073 using namespace Zivid::Detail::TypeTraits;
6074
6075 using AllArgsAreDescendantNodes =
6076 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
6077 static_assert(
6078 AllArgsAreDescendantNodes::value,
6079 "All arguments passed to set(...) must be descendant nodes.");
6080
6081 static_assert(
6082 AllArgsDecayedAreUnique<Args...>::value,
6083 "Found duplicate types among the arguments passed to set(...). "
6084 "Types should be listed at most once.");
6085
6086 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
6087 }
6088
6110#ifndef NO_DOC
6111 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
6112#else
6113 template<typename... Args>
6114#endif
6115 Experimental copyWith(Args &&...args) const
6116 {
6117 using namespace Zivid::Detail::TypeTraits;
6118
6119 using AllArgsAreDescendantNodes =
6120 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
6121 static_assert(
6122 AllArgsAreDescendantNodes::value,
6123 "All arguments passed to copyWith(...) must be descendant nodes.");
6124
6125 static_assert(
6126 AllArgsDecayedAreUnique<Args...>::value,
6127 "Found duplicate types among the arguments passed to copyWith(...). "
6128 "Types should be listed at most once.");
6129
6130 auto copy{ *this };
6131 copy.set(std::forward<Args>(args)...);
6132 return copy;
6133 }
6134
6137 {
6138 return m_contrastDistortion;
6139 }
6140
6143 {
6144 return m_contrastDistortion;
6145 }
6146
6149 {
6150 m_contrastDistortion = value;
6151 return *this;
6152 }
6153
6156 {
6157 m_contrastDistortion.set(value);
6158 return *this;
6159 }
6160
6163 {
6164 m_contrastDistortion.set(value);
6165 return *this;
6166 }
6167
6170 {
6171 m_contrastDistortion.set(value);
6172 return *this;
6173 }
6174
6177 {
6178 m_contrastDistortion.set(value);
6179 return *this;
6180 }
6181
6184 {
6185 m_contrastDistortion.set(value);
6186 return *this;
6187 }
6188
6191 {
6192 m_contrastDistortion.set(value);
6193 return *this;
6194 }
6195
6198 {
6199 return m_holeFilling;
6200 }
6201
6204 {
6205 return m_holeFilling;
6206 }
6207
6210 {
6211 m_holeFilling = value;
6212 return *this;
6213 }
6214
6217 {
6218 m_holeFilling.set(value);
6219 return *this;
6220 }
6221
6224 {
6225 m_holeFilling.set(value);
6226 return *this;
6227 }
6228
6231 {
6232 m_holeFilling.set(value);
6233 return *this;
6234 }
6235
6236 template<
6237 typename T,
6238 typename std::enable_if<
6239 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion>::value,
6240 int>::type = 0>
6242 {
6243 return m_contrastDistortion;
6244 }
6245
6246 template<
6247 typename T,
6248 typename std::enable_if<
6249 std::is_same<
6250 T,
6252 int>::type = 0>
6254 {
6255 return m_contrastDistortion
6257 }
6258
6259 template<
6260 typename T,
6261 typename std::enable_if<
6262 std::is_same<
6263 T,
6265 value,
6266 int>::type = 0>
6268 const
6269 {
6270 return m_contrastDistortion.get<
6272 }
6273
6274 template<
6275 typename T,
6276 typename std::enable_if<
6277 std::is_same<
6278 T,
6280 value,
6281 int>::type = 0>
6283 const
6284 {
6285 return m_contrastDistortion.get<
6287 }
6288
6289 template<
6290 typename T,
6291 typename std::enable_if<
6292 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal>::
6293 value,
6294 int>::type = 0>
6296 {
6297 return m_contrastDistortion
6299 }
6300
6301 template<
6302 typename T,
6303 typename std::enable_if<
6304 std::is_same<
6305 T,
6307 value,
6308 int>::type = 0>
6310 {
6311 return m_contrastDistortion
6313 }
6314
6315 template<
6316 typename T,
6317 typename std::enable_if<
6318 std::is_same<
6319 T,
6321 value,
6322 int>::type = 0>
6324 const
6325 {
6326 return m_contrastDistortion
6328 }
6329
6330 template<
6331 typename T,
6332 typename std::enable_if<
6333 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling>::value,
6334 int>::type = 0>
6336 {
6337 return m_holeFilling;
6338 }
6339
6340 template<
6341 typename T,
6342 typename std::enable_if<
6343 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::Enabled>::value,
6344 int>::type = 0>
6346 {
6348 }
6349
6350 template<
6351 typename T,
6352 typename std::enable_if<
6353 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::HoleSize>::value,
6354 int>::type = 0>
6356 {
6358 }
6359
6360 template<
6361 typename T,
6362 typename std::enable_if<
6363 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::Strictness>::
6364 value,
6365 int>::type = 0>
6367 {
6368 return m_holeFilling
6370 }
6371
6372 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
6374 {
6375 return m_contrastDistortion;
6376 }
6377
6378 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
6380 {
6381 return m_holeFilling;
6382 }
6383
6385 template<typename F>
6386 void forEach(const F &f) const
6387 {
6388 f(m_contrastDistortion);
6389 f(m_holeFilling);
6390 }
6391
6393 template<typename F>
6394 void forEach(const F &f)
6395 {
6396 f(m_contrastDistortion);
6397 f(m_holeFilling);
6398 }
6399
6401 bool operator==(const Experimental &other) const;
6402
6404 bool operator!=(const Experimental &other) const;
6405
6407 std::string toString() const;
6408
6410 friend std::ostream &operator<<(std::ostream &stream, const Experimental &value)
6411 {
6412 return stream << value.toString();
6413 }
6414
6415 private:
6416 void setFromString(const std::string &value);
6417
6418 void setFromString(const std::string &fullPath, const std::string &value);
6419
6420 std::string getString(const std::string &fullPath) const;
6421
6422 ContrastDistortion m_contrastDistortion;
6423 HoleFilling m_holeFilling;
6424
6425 friend struct DataModel::Detail::Befriend<Experimental>;
6426 };
6427
6429
6430 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
6432 {
6433 public:
6436
6438 static constexpr const char *path{ "Processing/Filters/Noise" };
6439
6441 static constexpr const char *name{ "Noise" };
6442
6444 static constexpr const char *description{
6445 R"description(Contains filters that can be used to clean up a noisy point cloud)description"
6446 };
6447
6449
6450 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
6452 {
6453 public:
6456
6458 static constexpr const char *path{ "Processing/Filters/Noise/Removal" };
6459
6461 static constexpr const char *name{ "Removal" };
6462
6464 static constexpr const char *description{
6465 R"description(Discard points with signal-to-noise ratio (SNR) values below a threshold)description"
6466 };
6467
6469
6470 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
6472 {
6473 public:
6476
6478 static constexpr const char *path{ "Processing/Filters/Noise/Removal/Enabled" };
6479
6481 static constexpr const char *name{ "Enabled" };
6482
6484 static constexpr const char *description{
6485 R"description(Enable or disable the SNR filter)description"
6486 };
6487
6489 using ValueType = bool;
6490 static const Enabled yes;
6491 static const Enabled no;
6492
6494 static std::set<bool> validValues()
6495 {
6496 return { false, true };
6497 }
6498
6500 Enabled() = default;
6501
6503 explicit constexpr Enabled(bool value)
6504 : m_opt{ value }
6505 {}
6506
6511 bool value() const;
6512
6514 bool hasValue() const;
6515
6517 void reset();
6518
6520 std::string toString() const;
6521
6523 bool operator==(const Enabled &other) const
6524 {
6525 return m_opt == other.m_opt;
6526 }
6527
6529 bool operator!=(const Enabled &other) const
6530 {
6531 return m_opt != other.m_opt;
6532 }
6533
6535 friend std::ostream &operator<<(std::ostream &stream, const Enabled &value)
6536 {
6537 return stream << value.toString();
6538 }
6539
6540 private:
6541 void setFromString(const std::string &value);
6542
6543 Zivid::DataModel::Detail::Optional<bool> m_opt;
6544
6545 friend struct DataModel::Detail::Befriend<Enabled>;
6546 };
6547
6549
6550 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
6552 {
6553 public:
6556
6558 static constexpr const char *path{ "Processing/Filters/Noise/Removal/Threshold" };
6559
6561 static constexpr const char *name{ "Threshold" };
6562
6564 static constexpr const char *description{
6565 R"description(Discard points with signal-to-noise ratio (SNR) below the given value)description"
6566 };
6567
6569 using ValueType = double;
6570
6572 static constexpr Range<double> validRange()
6573 {
6574 return { 0.0, 100.0 };
6575 }
6576
6578 Threshold() = default;
6579
6581 explicit constexpr Threshold(double value)
6582 : m_opt{ verifyValue(value) }
6583 {}
6584
6589 double value() const;
6590
6592 bool hasValue() const;
6593
6595 void reset();
6596
6598 std::string toString() const;
6599
6601 bool operator==(const Threshold &other) const
6602 {
6603 return m_opt == other.m_opt;
6604 }
6605
6607 bool operator!=(const Threshold &other) const
6608 {
6609 return m_opt != other.m_opt;
6610 }
6611
6613 bool operator<(const Threshold &other) const
6614 {
6615 return m_opt < other.m_opt;
6616 }
6617
6619 bool operator>(const Threshold &other) const
6620 {
6621 return m_opt > other.m_opt;
6622 }
6623
6625 bool operator<=(const Threshold &other) const
6626 {
6627 return m_opt <= other.m_opt;
6628 }
6629
6631 bool operator>=(const Threshold &other) const
6632 {
6633 return m_opt >= other.m_opt;
6634 }
6635
6637 friend std::ostream &operator<<(std::ostream &stream, const Threshold &value)
6638 {
6639 return stream << value.toString();
6640 }
6641
6642 private:
6643 void setFromString(const std::string &value);
6644
6645 constexpr ValueType static verifyValue(const ValueType &value)
6646 {
6647 return validRange().isInRange(value)
6648 ? value
6649 : throw std::out_of_range{ "Threshold{ " + std::to_string(value)
6650 + " } is not in range ["
6651 + std::to_string(validRange().min()) + ", "
6652 + std::to_string(validRange().max()) + "]" };
6653 }
6654
6655 Zivid::DataModel::Detail::Optional<double> m_opt;
6656
6657 friend struct DataModel::Detail::Befriend<Threshold>;
6658 };
6659
6660 using Descendants = std::tuple<
6663
6666
6679#ifndef NO_DOC
6680 template<
6681 typename... Args,
6682 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
6683 typename std::enable_if<
6684 Zivid::Detail::TypeTraits::
6685 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
6686 int>::type = 0>
6687#else
6688 template<typename... Args>
6689#endif
6690 explicit Removal(Args &&...args)
6691 {
6692 using namespace Zivid::Detail::TypeTraits;
6693
6694 static_assert(
6695 AllArgsDecayedAreUnique<Args...>::value,
6696 "Found duplicate types among the arguments passed to Removal(...). "
6697 "Types should be listed at most once.");
6698
6699 set(std::forward<Args>(args)...);
6700 }
6701
6713#ifndef NO_DOC
6714 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
6715#else
6716 template<typename... Args>
6717#endif
6718 void set(Args &&...args)
6719 {
6720 using namespace Zivid::Detail::TypeTraits;
6721
6722 using AllArgsAreDescendantNodes =
6723 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
6724 static_assert(
6725 AllArgsAreDescendantNodes::value,
6726 "All arguments passed to set(...) must be descendant nodes.");
6727
6728 static_assert(
6729 AllArgsDecayedAreUnique<Args...>::value,
6730 "Found duplicate types among the arguments passed to set(...). "
6731 "Types should be listed at most once.");
6732
6733 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
6734 }
6735
6748#ifndef NO_DOC
6749 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
6750#else
6751 template<typename... Args>
6752#endif
6753 Removal copyWith(Args &&...args) const
6754 {
6755 using namespace Zivid::Detail::TypeTraits;
6756
6757 using AllArgsAreDescendantNodes =
6758 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
6759 static_assert(
6760 AllArgsAreDescendantNodes::value,
6761 "All arguments passed to copyWith(...) must be descendant nodes.");
6762
6763 static_assert(
6764 AllArgsDecayedAreUnique<Args...>::value,
6765 "Found duplicate types among the arguments passed to copyWith(...). "
6766 "Types should be listed at most once.");
6767
6768 auto copy{ *this };
6769 copy.set(std::forward<Args>(args)...);
6770 return copy;
6771 }
6772
6774 const Enabled &isEnabled() const
6775 {
6776 return m_enabled;
6777 }
6778
6781 {
6782 return m_enabled;
6783 }
6784
6786 Removal &set(const Enabled &value)
6787 {
6788 m_enabled = value;
6789 return *this;
6790 }
6791
6793 const Threshold &threshold() const
6794 {
6795 return m_threshold;
6796 }
6797
6800 {
6801 return m_threshold;
6802 }
6803
6805 Removal &set(const Threshold &value)
6806 {
6807 m_threshold = value;
6808 return *this;
6809 }
6810
6811 template<
6812 typename T,
6813 typename std::enable_if<
6814 std::is_same<T, Settings::Processing::Filters::Noise::Removal::Enabled>::value,
6815 int>::type = 0>
6817 {
6818 return m_enabled;
6819 }
6820
6821 template<
6822 typename T,
6823 typename std::enable_if<
6824 std::is_same<T, Settings::Processing::Filters::Noise::Removal::Threshold>::value,
6825 int>::type = 0>
6827 {
6828 return m_threshold;
6829 }
6830
6831 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
6833 {
6834 return m_enabled;
6835 }
6836
6837 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
6839 {
6840 return m_threshold;
6841 }
6842
6844 template<typename F>
6845 void forEach(const F &f) const
6846 {
6847 f(m_enabled);
6848 f(m_threshold);
6849 }
6850
6852 template<typename F>
6853 void forEach(const F &f)
6854 {
6855 f(m_enabled);
6856 f(m_threshold);
6857 }
6858
6860 bool operator==(const Removal &other) const;
6861
6863 bool operator!=(const Removal &other) const;
6864
6866 std::string toString() const;
6867
6869 friend std::ostream &operator<<(std::ostream &stream, const Removal &value)
6870 {
6871 return stream << value.toString();
6872 }
6873
6874 private:
6875 void setFromString(const std::string &value);
6876
6877 void setFromString(const std::string &fullPath, const std::string &value);
6878
6879 std::string getString(const std::string &fullPath) const;
6880
6881 Enabled m_enabled;
6882 Threshold m_threshold;
6883
6884 friend struct DataModel::Detail::Befriend<Removal>;
6885 };
6886
6891
6892 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
6894 {
6895 public:
6898
6900 static constexpr const char *path{ "Processing/Filters/Noise/Repair" };
6901
6903 static constexpr const char *name{ "Repair" };
6904
6906 static constexpr const char *description{
6907 R"description(Get better surface coverage by repairing regions of missing data due to noisy points.
6908Consider disabling this filter if you require all points in your point cloud to be of
6909high confidence.
6910)description"
6911 };
6912
6914
6915 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
6917 {
6918 public:
6921
6923 static constexpr const char *path{ "Processing/Filters/Noise/Repair/Enabled" };
6924
6926 static constexpr const char *name{ "Enabled" };
6927
6929 static constexpr const char *description{
6930 R"description(Enable or disable noise repair)description"
6931 };
6932
6934 using ValueType = bool;
6935 static const Enabled yes;
6936 static const Enabled no;
6937
6939 static std::set<bool> validValues()
6940 {
6941 return { false, true };
6942 }
6943
6945 Enabled() = default;
6946
6948 explicit constexpr Enabled(bool value)
6949 : m_opt{ value }
6950 {}
6951
6956 bool value() const;
6957
6959 bool hasValue() const;
6960
6962 void reset();
6963
6965 std::string toString() const;
6966
6968 bool operator==(const Enabled &other) const
6969 {
6970 return m_opt == other.m_opt;
6971 }
6972
6974 bool operator!=(const Enabled &other) const
6975 {
6976 return m_opt != other.m_opt;
6977 }
6978
6980 friend std::ostream &operator<<(std::ostream &stream, const Enabled &value)
6981 {
6982 return stream << value.toString();
6983 }
6984
6985 private:
6986 void setFromString(const std::string &value);
6987
6988 Zivid::DataModel::Detail::Optional<bool> m_opt;
6989
6990 friend struct DataModel::Detail::Befriend<Enabled>;
6991 };
6992
6993 using Descendants = std::tuple<Settings::Processing::Filters::Noise::Repair::Enabled>;
6994
6997
7009#ifndef NO_DOC
7010 template<
7011 typename... Args,
7012 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
7013 typename std::enable_if<
7014 Zivid::Detail::TypeTraits::
7015 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
7016 int>::type = 0>
7017#else
7018 template<typename... Args>
7019#endif
7020 explicit Repair(Args &&...args)
7021 {
7022 using namespace Zivid::Detail::TypeTraits;
7023
7024 static_assert(
7025 AllArgsDecayedAreUnique<Args...>::value,
7026 "Found duplicate types among the arguments passed to Repair(...). "
7027 "Types should be listed at most once.");
7028
7029 set(std::forward<Args>(args)...);
7030 }
7031
7042#ifndef NO_DOC
7043 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
7044#else
7045 template<typename... Args>
7046#endif
7047 void set(Args &&...args)
7048 {
7049 using namespace Zivid::Detail::TypeTraits;
7050
7051 using AllArgsAreDescendantNodes =
7052 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
7053 static_assert(
7054 AllArgsAreDescendantNodes::value,
7055 "All arguments passed to set(...) must be descendant nodes.");
7056
7057 static_assert(
7058 AllArgsDecayedAreUnique<Args...>::value,
7059 "Found duplicate types among the arguments passed to set(...). "
7060 "Types should be listed at most once.");
7061
7062 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
7063 }
7064
7076#ifndef NO_DOC
7077 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
7078#else
7079 template<typename... Args>
7080#endif
7081 Repair copyWith(Args &&...args) const
7082 {
7083 using namespace Zivid::Detail::TypeTraits;
7084
7085 using AllArgsAreDescendantNodes =
7086 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
7087 static_assert(
7088 AllArgsAreDescendantNodes::value,
7089 "All arguments passed to copyWith(...) must be descendant nodes.");
7090
7091 static_assert(
7092 AllArgsDecayedAreUnique<Args...>::value,
7093 "Found duplicate types among the arguments passed to copyWith(...). "
7094 "Types should be listed at most once.");
7095
7096 auto copy{ *this };
7097 copy.set(std::forward<Args>(args)...);
7098 return copy;
7099 }
7100
7102 const Enabled &isEnabled() const
7103 {
7104 return m_enabled;
7105 }
7106
7109 {
7110 return m_enabled;
7111 }
7112
7114 Repair &set(const Enabled &value)
7115 {
7116 m_enabled = value;
7117 return *this;
7118 }
7119
7120 template<
7121 typename T,
7122 typename std::enable_if<
7123 std::is_same<T, Settings::Processing::Filters::Noise::Repair::Enabled>::value,
7124 int>::type = 0>
7126 {
7127 return m_enabled;
7128 }
7129
7130 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
7132 {
7133 return m_enabled;
7134 }
7135
7137 template<typename F>
7138 void forEach(const F &f) const
7139 {
7140 f(m_enabled);
7141 }
7142
7144 template<typename F>
7145 void forEach(const F &f)
7146 {
7147 f(m_enabled);
7148 }
7149
7151 bool operator==(const Repair &other) const;
7152
7154 bool operator!=(const Repair &other) const;
7155
7157 std::string toString() const;
7158
7160 friend std::ostream &operator<<(std::ostream &stream, const Repair &value)
7161 {
7162 return stream << value.toString();
7163 }
7164
7165 private:
7166 void setFromString(const std::string &value);
7167
7168 void setFromString(const std::string &fullPath, const std::string &value);
7169
7170 std::string getString(const std::string &fullPath) const;
7171
7172 Enabled m_enabled;
7173
7174 friend struct DataModel::Detail::Befriend<Repair>;
7175 };
7176
7181
7182 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
7184 {
7185 public:
7188
7190 static constexpr const char *path{ "Processing/Filters/Noise/Suppression" };
7191
7193 static constexpr const char *name{ "Suppression" };
7194
7196 static constexpr const char *description{
7197 R"description(Reduce noise and outliers in the point cloud. This filter can also be used to reduce
7198ripple effects caused by interreflections. Consider disabling this filter if you need to
7199distinguish very fine details and thus need to avoid any smoothing effects.
7200)description"
7201 };
7202
7204
7205 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
7207 {
7208 public:
7211
7213 static constexpr const char *path{ "Processing/Filters/Noise/Suppression/Enabled" };
7214
7216 static constexpr const char *name{ "Enabled" };
7217
7219 static constexpr const char *description{
7220 R"description(Enable or disable noise suppression)description"
7221 };
7222
7224 using ValueType = bool;
7225 static const Enabled yes;
7226 static const Enabled no;
7227
7229 static std::set<bool> validValues()
7230 {
7231 return { false, true };
7232 }
7233
7235 Enabled() = default;
7236
7238 explicit constexpr Enabled(bool value)
7239 : m_opt{ value }
7240 {}
7241
7246 bool value() const;
7247
7249 bool hasValue() const;
7250
7252 void reset();
7253
7255 std::string toString() const;
7256
7258 bool operator==(const Enabled &other) const
7259 {
7260 return m_opt == other.m_opt;
7261 }
7262
7264 bool operator!=(const Enabled &other) const
7265 {
7266 return m_opt != other.m_opt;
7267 }
7268
7270 friend std::ostream &operator<<(std::ostream &stream, const Enabled &value)
7271 {
7272 return stream << value.toString();
7273 }
7274
7275 private:
7276 void setFromString(const std::string &value);
7277
7278 Zivid::DataModel::Detail::Optional<bool> m_opt;
7279
7280 friend struct DataModel::Detail::Befriend<Enabled>;
7281 };
7282
7283 using Descendants = std::tuple<Settings::Processing::Filters::Noise::Suppression::Enabled>;
7284
7287
7299#ifndef NO_DOC
7300 template<
7301 typename... Args,
7302 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
7303 typename std::enable_if<
7304 Zivid::Detail::TypeTraits::
7305 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
7306 int>::type = 0>
7307#else
7308 template<typename... Args>
7309#endif
7310 explicit Suppression(Args &&...args)
7311 {
7312 using namespace Zivid::Detail::TypeTraits;
7313
7314 static_assert(
7315 AllArgsDecayedAreUnique<Args...>::value,
7316 "Found duplicate types among the arguments passed to Suppression(...). "
7317 "Types should be listed at most once.");
7318
7319 set(std::forward<Args>(args)...);
7320 }
7321
7332#ifndef NO_DOC
7333 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
7334#else
7335 template<typename... Args>
7336#endif
7337 void set(Args &&...args)
7338 {
7339 using namespace Zivid::Detail::TypeTraits;
7340
7341 using AllArgsAreDescendantNodes =
7342 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
7343 static_assert(
7344 AllArgsAreDescendantNodes::value,
7345 "All arguments passed to set(...) must be descendant nodes.");
7346
7347 static_assert(
7348 AllArgsDecayedAreUnique<Args...>::value,
7349 "Found duplicate types among the arguments passed to set(...). "
7350 "Types should be listed at most once.");
7351
7352 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
7353 }
7354
7366#ifndef NO_DOC
7367 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
7368#else
7369 template<typename... Args>
7370#endif
7371 Suppression copyWith(Args &&...args) const
7372 {
7373 using namespace Zivid::Detail::TypeTraits;
7374
7375 using AllArgsAreDescendantNodes =
7376 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
7377 static_assert(
7378 AllArgsAreDescendantNodes::value,
7379 "All arguments passed to copyWith(...) must be descendant nodes.");
7380
7381 static_assert(
7382 AllArgsDecayedAreUnique<Args...>::value,
7383 "Found duplicate types among the arguments passed to copyWith(...). "
7384 "Types should be listed at most once.");
7385
7386 auto copy{ *this };
7387 copy.set(std::forward<Args>(args)...);
7388 return copy;
7389 }
7390
7392 const Enabled &isEnabled() const
7393 {
7394 return m_enabled;
7395 }
7396
7399 {
7400 return m_enabled;
7401 }
7402
7404 Suppression &set(const Enabled &value)
7405 {
7406 m_enabled = value;
7407 return *this;
7408 }
7409
7410 template<
7411 typename T,
7412 typename std::enable_if<
7413 std::is_same<T, Settings::Processing::Filters::Noise::Suppression::Enabled>::value,
7414 int>::type = 0>
7416 {
7417 return m_enabled;
7418 }
7419
7420 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
7422 {
7423 return m_enabled;
7424 }
7425
7427 template<typename F>
7428 void forEach(const F &f) const
7429 {
7430 f(m_enabled);
7431 }
7432
7434 template<typename F>
7435 void forEach(const F &f)
7436 {
7437 f(m_enabled);
7438 }
7439
7441 bool operator==(const Suppression &other) const;
7442
7444 bool operator!=(const Suppression &other) const;
7445
7447 std::string toString() const;
7448
7450 friend std::ostream &operator<<(std::ostream &stream, const Suppression &value)
7451 {
7452 return stream << value.toString();
7453 }
7454
7455 private:
7456 void setFromString(const std::string &value);
7457
7458 void setFromString(const std::string &fullPath, const std::string &value);
7459
7460 std::string getString(const std::string &fullPath) const;
7461
7462 Enabled m_enabled;
7463
7464 friend struct DataModel::Detail::Befriend<Suppression>;
7465 };
7466
7467 using Descendants = std::tuple<
7475
7478
7496#ifndef NO_DOC
7497 template<
7498 typename... Args,
7499 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
7500 typename std::enable_if<
7501 Zivid::Detail::TypeTraits::
7502 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
7503 int>::type = 0>
7504#else
7505 template<typename... Args>
7506#endif
7507 explicit Noise(Args &&...args)
7508 {
7509 using namespace Zivid::Detail::TypeTraits;
7510
7511 static_assert(
7512 AllArgsDecayedAreUnique<Args...>::value,
7513 "Found duplicate types among the arguments passed to Noise(...). "
7514 "Types should be listed at most once.");
7515
7516 set(std::forward<Args>(args)...);
7517 }
7518
7535#ifndef NO_DOC
7536 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
7537#else
7538 template<typename... Args>
7539#endif
7540 void set(Args &&...args)
7541 {
7542 using namespace Zivid::Detail::TypeTraits;
7543
7544 using AllArgsAreDescendantNodes =
7545 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
7546 static_assert(
7547 AllArgsAreDescendantNodes::value,
7548 "All arguments passed to set(...) must be descendant nodes.");
7549
7550 static_assert(
7551 AllArgsDecayedAreUnique<Args...>::value,
7552 "Found duplicate types among the arguments passed to set(...). "
7553 "Types should be listed at most once.");
7554
7555 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
7556 }
7557
7575#ifndef NO_DOC
7576 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
7577#else
7578 template<typename... Args>
7579#endif
7580 Noise copyWith(Args &&...args) const
7581 {
7582 using namespace Zivid::Detail::TypeTraits;
7583
7584 using AllArgsAreDescendantNodes =
7585 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
7586 static_assert(
7587 AllArgsAreDescendantNodes::value,
7588 "All arguments passed to copyWith(...) must be descendant nodes.");
7589
7590 static_assert(
7591 AllArgsDecayedAreUnique<Args...>::value,
7592 "Found duplicate types among the arguments passed to copyWith(...). "
7593 "Types should be listed at most once.");
7594
7595 auto copy{ *this };
7596 copy.set(std::forward<Args>(args)...);
7597 return copy;
7598 }
7599
7601 const Removal &removal() const
7602 {
7603 return m_removal;
7604 }
7605
7608 {
7609 return m_removal;
7610 }
7611
7613 Noise &set(const Removal &value)
7614 {
7615 m_removal = value;
7616 return *this;
7617 }
7618
7621 {
7622 m_removal.set(value);
7623 return *this;
7624 }
7625
7628 {
7629 m_removal.set(value);
7630 return *this;
7631 }
7632
7634 const Repair &repair() const
7635 {
7636 return m_repair;
7637 }
7638
7641 {
7642 return m_repair;
7643 }
7644
7646 Noise &set(const Repair &value)
7647 {
7648 m_repair = value;
7649 return *this;
7650 }
7651
7654 {
7655 m_repair.set(value);
7656 return *this;
7657 }
7658
7661 {
7662 return m_suppression;
7663 }
7664
7667 {
7668 return m_suppression;
7669 }
7670
7672 Noise &set(const Suppression &value)
7673 {
7674 m_suppression = value;
7675 return *this;
7676 }
7677
7680 {
7681 m_suppression.set(value);
7682 return *this;
7683 }
7684
7685 template<
7686 typename T,
7687 typename std::enable_if<
7688 std::is_same<T, Settings::Processing::Filters::Noise::Removal>::value,
7689 int>::type = 0>
7691 {
7692 return m_removal;
7693 }
7694
7695 template<
7696 typename T,
7697 typename std::enable_if<
7698 std::is_same<T, Settings::Processing::Filters::Noise::Removal::Enabled>::value,
7699 int>::type = 0>
7701 {
7703 }
7704
7705 template<
7706 typename T,
7707 typename std::enable_if<
7708 std::is_same<T, Settings::Processing::Filters::Noise::Removal::Threshold>::value,
7709 int>::type = 0>
7711 {
7713 }
7714
7715 template<
7716 typename T,
7717 typename std::enable_if<
7718 std::is_same<T, Settings::Processing::Filters::Noise::Repair>::value,
7719 int>::type = 0>
7721 {
7722 return m_repair;
7723 }
7724
7725 template<
7726 typename T,
7727 typename std::enable_if<
7728 std::is_same<T, Settings::Processing::Filters::Noise::Repair::Enabled>::value,
7729 int>::type = 0>
7731 {
7733 }
7734
7735 template<
7736 typename T,
7737 typename std::enable_if<
7738 std::is_same<T, Settings::Processing::Filters::Noise::Suppression>::value,
7739 int>::type = 0>
7741 {
7742 return m_suppression;
7743 }
7744
7745 template<
7746 typename T,
7747 typename std::enable_if<
7748 std::is_same<T, Settings::Processing::Filters::Noise::Suppression::Enabled>::value,
7749 int>::type = 0>
7751 {
7753 }
7754
7755 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
7757 {
7758 return m_removal;
7759 }
7760
7761 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
7763 {
7764 return m_repair;
7765 }
7766
7767 template<size_t i, typename std::enable_if<i == 2, int>::type = 0>
7769 {
7770 return m_suppression;
7771 }
7772
7774 template<typename F>
7775 void forEach(const F &f) const
7776 {
7777 f(m_removal);
7778 f(m_repair);
7779 f(m_suppression);
7780 }
7781
7783 template<typename F>
7784 void forEach(const F &f)
7785 {
7786 f(m_removal);
7787 f(m_repair);
7788 f(m_suppression);
7789 }
7790
7792 bool operator==(const Noise &other) const;
7793
7795 bool operator!=(const Noise &other) const;
7796
7798 std::string toString() const;
7799
7801 friend std::ostream &operator<<(std::ostream &stream, const Noise &value)
7802 {
7803 return stream << value.toString();
7804 }
7805
7806 private:
7807 void setFromString(const std::string &value);
7808
7809 void setFromString(const std::string &fullPath, const std::string &value);
7810
7811 std::string getString(const std::string &fullPath) const;
7812
7813 Removal m_removal;
7814 Repair m_repair;
7815 Suppression m_suppression;
7816
7817 friend struct DataModel::Detail::Befriend<Noise>;
7818 };
7819
7821
7822 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
7824 {
7825 public:
7828
7830 static constexpr const char *path{ "Processing/Filters/Outlier" };
7831
7833 static constexpr const char *name{ "Outlier" };
7834
7836 static constexpr const char *description{
7837 R"description(Contains a filter that removes points with large Euclidean distance to neighboring points)description"
7838 };
7839
7841
7842 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
7844 {
7845 public:
7848
7850 static constexpr const char *path{ "Processing/Filters/Outlier/Removal" };
7851
7853 static constexpr const char *name{ "Removal" };
7854
7856 static constexpr const char *description{
7857 R"description(Discard point if Euclidean distance to neighboring points is above a threshold)description"
7858 };
7859
7861
7862 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
7864 {
7865 public:
7868
7870 static constexpr const char *path{ "Processing/Filters/Outlier/Removal/Enabled" };
7871
7873 static constexpr const char *name{ "Enabled" };
7874
7876 static constexpr const char *description{
7877 R"description(Enable or disable the outlier filter)description"
7878 };
7879
7881 using ValueType = bool;
7882 static const Enabled yes;
7883 static const Enabled no;
7884
7886 static std::set<bool> validValues()
7887 {
7888 return { false, true };
7889 }
7890
7892 Enabled() = default;
7893
7895 explicit constexpr Enabled(bool value)
7896 : m_opt{ value }
7897 {}
7898
7903 bool value() const;
7904
7906 bool hasValue() const;
7907
7909 void reset();
7910
7912 std::string toString() const;
7913
7915 bool operator==(const Enabled &other) const
7916 {
7917 return m_opt == other.m_opt;
7918 }
7919
7921 bool operator!=(const Enabled &other) const
7922 {
7923 return m_opt != other.m_opt;
7924 }
7925
7927 friend std::ostream &operator<<(std::ostream &stream, const Enabled &value)
7928 {
7929 return stream << value.toString();
7930 }
7931
7932 private:
7933 void setFromString(const std::string &value);
7934
7935 Zivid::DataModel::Detail::Optional<bool> m_opt;
7936
7937 friend struct DataModel::Detail::Befriend<Enabled>;
7938 };
7939
7941
7942 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
7944 {
7945 public:
7948
7950 static constexpr const char *path{ "Processing/Filters/Outlier/Removal/Threshold" };
7951
7953 static constexpr const char *name{ "Threshold" };
7954
7956 static constexpr const char *description{
7957 R"description(Discard point if Euclidean distance to neighboring points is above the given value)description"
7958 };
7959
7961 using ValueType = double;
7962
7964 static constexpr Range<double> validRange()
7965 {
7966 return { 0.0, 100.0 };
7967 }
7968
7970 Threshold() = default;
7971
7973 explicit constexpr Threshold(double value)
7974 : m_opt{ verifyValue(value) }
7975 {}
7976
7981 double value() const;
7982
7984 bool hasValue() const;
7985
7987 void reset();
7988
7990 std::string toString() const;
7991
7993 bool operator==(const Threshold &other) const
7994 {
7995 return m_opt == other.m_opt;
7996 }
7997
7999 bool operator!=(const Threshold &other) const
8000 {
8001 return m_opt != other.m_opt;
8002 }
8003
8005 bool operator<(const Threshold &other) const
8006 {
8007 return m_opt < other.m_opt;
8008 }
8009
8011 bool operator>(const Threshold &other) const
8012 {
8013 return m_opt > other.m_opt;
8014 }
8015
8017 bool operator<=(const Threshold &other) const
8018 {
8019 return m_opt <= other.m_opt;
8020 }
8021
8023 bool operator>=(const Threshold &other) const
8024 {
8025 return m_opt >= other.m_opt;
8026 }
8027
8029 friend std::ostream &operator<<(std::ostream &stream, const Threshold &value)
8030 {
8031 return stream << value.toString();
8032 }
8033
8034 private:
8035 void setFromString(const std::string &value);
8036
8037 constexpr ValueType static verifyValue(const ValueType &value)
8038 {
8039 return validRange().isInRange(value)
8040 ? value
8041 : throw std::out_of_range{ "Threshold{ " + std::to_string(value)
8042 + " } is not in range ["
8043 + std::to_string(validRange().min()) + ", "
8044 + std::to_string(validRange().max()) + "]" };
8045 }
8046
8047 Zivid::DataModel::Detail::Optional<double> m_opt;
8048
8049 friend struct DataModel::Detail::Befriend<Threshold>;
8050 };
8051
8052 using Descendants = std::tuple<
8055
8058
8071#ifndef NO_DOC
8072 template<
8073 typename... Args,
8074 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
8075 typename std::enable_if<
8076 Zivid::Detail::TypeTraits::
8077 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
8078 int>::type = 0>
8079#else
8080 template<typename... Args>
8081#endif
8082 explicit Removal(Args &&...args)
8083 {
8084 using namespace Zivid::Detail::TypeTraits;
8085
8086 static_assert(
8087 AllArgsDecayedAreUnique<Args...>::value,
8088 "Found duplicate types among the arguments passed to Removal(...). "
8089 "Types should be listed at most once.");
8090
8091 set(std::forward<Args>(args)...);
8092 }
8093
8105#ifndef NO_DOC
8106 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
8107#else
8108 template<typename... Args>
8109#endif
8110 void set(Args &&...args)
8111 {
8112 using namespace Zivid::Detail::TypeTraits;
8113
8114 using AllArgsAreDescendantNodes =
8115 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
8116 static_assert(
8117 AllArgsAreDescendantNodes::value,
8118 "All arguments passed to set(...) must be descendant nodes.");
8119
8120 static_assert(
8121 AllArgsDecayedAreUnique<Args...>::value,
8122 "Found duplicate types among the arguments passed to set(...). "
8123 "Types should be listed at most once.");
8124
8125 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
8126 }
8127
8140#ifndef NO_DOC
8141 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
8142#else
8143 template<typename... Args>
8144#endif
8145 Removal copyWith(Args &&...args) const
8146 {
8147 using namespace Zivid::Detail::TypeTraits;
8148
8149 using AllArgsAreDescendantNodes =
8150 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
8151 static_assert(
8152 AllArgsAreDescendantNodes::value,
8153 "All arguments passed to copyWith(...) must be descendant nodes.");
8154
8155 static_assert(
8156 AllArgsDecayedAreUnique<Args...>::value,
8157 "Found duplicate types among the arguments passed to copyWith(...). "
8158 "Types should be listed at most once.");
8159
8160 auto copy{ *this };
8161 copy.set(std::forward<Args>(args)...);
8162 return copy;
8163 }
8164
8166 const Enabled &isEnabled() const
8167 {
8168 return m_enabled;
8169 }
8170
8173 {
8174 return m_enabled;
8175 }
8176
8178 Removal &set(const Enabled &value)
8179 {
8180 m_enabled = value;
8181 return *this;
8182 }
8183
8185 const Threshold &threshold() const
8186 {
8187 return m_threshold;
8188 }
8189
8192 {
8193 return m_threshold;
8194 }
8195
8197 Removal &set(const Threshold &value)
8198 {
8199 m_threshold = value;
8200 return *this;
8201 }
8202
8203 template<
8204 typename T,
8205 typename std::enable_if<
8206 std::is_same<T, Settings::Processing::Filters::Outlier::Removal::Enabled>::value,
8207 int>::type = 0>
8209 {
8210 return m_enabled;
8211 }
8212
8213 template<
8214 typename T,
8215 typename std::enable_if<
8216 std::is_same<T, Settings::Processing::Filters::Outlier::Removal::Threshold>::value,
8217 int>::type = 0>
8219 {
8220 return m_threshold;
8221 }
8222
8223 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
8225 {
8226 return m_enabled;
8227 }
8228
8229 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
8231 {
8232 return m_threshold;
8233 }
8234
8236 template<typename F>
8237 void forEach(const F &f) const
8238 {
8239 f(m_enabled);
8240 f(m_threshold);
8241 }
8242
8244 template<typename F>
8245 void forEach(const F &f)
8246 {
8247 f(m_enabled);
8248 f(m_threshold);
8249 }
8250
8252 bool operator==(const Removal &other) const;
8253
8255 bool operator!=(const Removal &other) const;
8256
8258 std::string toString() const;
8259
8261 friend std::ostream &operator<<(std::ostream &stream, const Removal &value)
8262 {
8263 return stream << value.toString();
8264 }
8265
8266 private:
8267 void setFromString(const std::string &value);
8268
8269 void setFromString(const std::string &fullPath, const std::string &value);
8270
8271 std::string getString(const std::string &fullPath) const;
8272
8273 Enabled m_enabled;
8274 Threshold m_threshold;
8275
8276 friend struct DataModel::Detail::Befriend<Removal>;
8277 };
8278
8279 using Descendants = std::tuple<
8283
8286
8300#ifndef NO_DOC
8301 template<
8302 typename... Args,
8303 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
8304 typename std::enable_if<
8305 Zivid::Detail::TypeTraits::
8306 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
8307 int>::type = 0>
8308#else
8309 template<typename... Args>
8310#endif
8311 explicit Outlier(Args &&...args)
8312 {
8313 using namespace Zivid::Detail::TypeTraits;
8314
8315 static_assert(
8316 AllArgsDecayedAreUnique<Args...>::value,
8317 "Found duplicate types among the arguments passed to Outlier(...). "
8318 "Types should be listed at most once.");
8319
8320 set(std::forward<Args>(args)...);
8321 }
8322
8335#ifndef NO_DOC
8336 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
8337#else
8338 template<typename... Args>
8339#endif
8340 void set(Args &&...args)
8341 {
8342 using namespace Zivid::Detail::TypeTraits;
8343
8344 using AllArgsAreDescendantNodes =
8345 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
8346 static_assert(
8347 AllArgsAreDescendantNodes::value,
8348 "All arguments passed to set(...) must be descendant nodes.");
8349
8350 static_assert(
8351 AllArgsDecayedAreUnique<Args...>::value,
8352 "Found duplicate types among the arguments passed to set(...). "
8353 "Types should be listed at most once.");
8354
8355 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
8356 }
8357
8371#ifndef NO_DOC
8372 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
8373#else
8374 template<typename... Args>
8375#endif
8376 Outlier copyWith(Args &&...args) const
8377 {
8378 using namespace Zivid::Detail::TypeTraits;
8379
8380 using AllArgsAreDescendantNodes =
8381 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
8382 static_assert(
8383 AllArgsAreDescendantNodes::value,
8384 "All arguments passed to copyWith(...) must be descendant nodes.");
8385
8386 static_assert(
8387 AllArgsDecayedAreUnique<Args...>::value,
8388 "Found duplicate types among the arguments passed to copyWith(...). "
8389 "Types should be listed at most once.");
8390
8391 auto copy{ *this };
8392 copy.set(std::forward<Args>(args)...);
8393 return copy;
8394 }
8395
8397 const Removal &removal() const
8398 {
8399 return m_removal;
8400 }
8401
8404 {
8405 return m_removal;
8406 }
8407
8409 Outlier &set(const Removal &value)
8410 {
8411 m_removal = value;
8412 return *this;
8413 }
8414
8417 {
8418 m_removal.set(value);
8419 return *this;
8420 }
8421
8424 {
8425 m_removal.set(value);
8426 return *this;
8427 }
8428
8429 template<
8430 typename T,
8431 typename std::enable_if<
8432 std::is_same<T, Settings::Processing::Filters::Outlier::Removal>::value,
8433 int>::type = 0>
8435 {
8436 return m_removal;
8437 }
8438
8439 template<
8440 typename T,
8441 typename std::enable_if<
8442 std::is_same<T, Settings::Processing::Filters::Outlier::Removal::Enabled>::value,
8443 int>::type = 0>
8445 {
8447 }
8448
8449 template<
8450 typename T,
8451 typename std::enable_if<
8452 std::is_same<T, Settings::Processing::Filters::Outlier::Removal::Threshold>::value,
8453 int>::type = 0>
8455 {
8457 }
8458
8459 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
8461 {
8462 return m_removal;
8463 }
8464
8466 template<typename F>
8467 void forEach(const F &f) const
8468 {
8469 f(m_removal);
8470 }
8471
8473 template<typename F>
8474 void forEach(const F &f)
8475 {
8476 f(m_removal);
8477 }
8478
8480 bool operator==(const Outlier &other) const;
8481
8483 bool operator!=(const Outlier &other) const;
8484
8486 std::string toString() const;
8487
8489 friend std::ostream &operator<<(std::ostream &stream, const Outlier &value)
8490 {
8491 return stream << value.toString();
8492 }
8493
8494 private:
8495 void setFromString(const std::string &value);
8496
8497 void setFromString(const std::string &fullPath, const std::string &value);
8498
8499 std::string getString(const std::string &fullPath) const;
8500
8501 Removal m_removal;
8502
8503 friend struct DataModel::Detail::Befriend<Outlier>;
8504 };
8505
8507
8508 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
8510 {
8511 public:
8514
8516 static constexpr const char *path{ "Processing/Filters/Reflection" };
8517
8519 static constexpr const char *name{ "Reflection" };
8520
8522 static constexpr const char *description{
8523 R"description(Contains a filter that removes points likely introduced by reflections (useful for shiny materials))description"
8524 };
8525
8527
8528 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
8530 {
8531 public:
8534
8536 static constexpr const char *path{ "Processing/Filters/Reflection/Removal" };
8537
8539 static constexpr const char *name{ "Removal" };
8540
8542 static constexpr const char *description{
8543 R"description(Discard points likely introduced by reflections (useful for shiny materials))description"
8544 };
8545
8547
8548 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
8550 {
8551 public:
8554
8556 static constexpr const char *path{ "Processing/Filters/Reflection/Removal/Enabled" };
8557
8559 static constexpr const char *name{ "Enabled" };
8560
8562 static constexpr const char *description{
8563 R"description(Enable or disable the reflection filter. Note that this filter is computationally intensive and may affect the frame rate)description"
8564 };
8565
8567 using ValueType = bool;
8568 static const Enabled yes;
8569 static const Enabled no;
8570
8572 static std::set<bool> validValues()
8573 {
8574 return { false, true };
8575 }
8576
8578 Enabled() = default;
8579
8581 explicit constexpr Enabled(bool value)
8582 : m_opt{ value }
8583 {}
8584
8589 bool value() const;
8590
8592 bool hasValue() const;
8593
8595 void reset();
8596
8598 std::string toString() const;
8599
8601 bool operator==(const Enabled &other) const
8602 {
8603 return m_opt == other.m_opt;
8604 }
8605
8607 bool operator!=(const Enabled &other) const
8608 {
8609 return m_opt != other.m_opt;
8610 }
8611
8613 friend std::ostream &operator<<(std::ostream &stream, const Enabled &value)
8614 {
8615 return stream << value.toString();
8616 }
8617
8618 private:
8619 void setFromString(const std::string &value);
8620
8621 Zivid::DataModel::Detail::Optional<bool> m_opt;
8622
8623 friend struct DataModel::Detail::Befriend<Enabled>;
8624 };
8625
8627
8628 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
8630 {
8631 public:
8634
8636 static constexpr const char *path{ "Processing/Filters/Reflection/Removal/Experimental" };
8637
8639 static constexpr const char *name{ "Experimental" };
8640
8642 static constexpr const char *description{
8643 R"description(Experimental reflection filter related settings)description"
8644 };
8645
8654
8655 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
8657 {
8658 public:
8661
8663 static constexpr const char *path{
8664 "Processing/Filters/Reflection/Removal/Experimental/Mode"
8665 };
8666
8668 static constexpr const char *name{ "Mode" };
8669
8671 static constexpr const char *description{
8672 R"description(The reflection filter has two modes: Local and Global. Local mode preserves more 3D data
8673on thinner objects, generally removes more reflection artifacts and processes faster than
8674the Global filter. The Global filter is generally better at removing outlier points in
8675the point cloud. It is advised to use the Outlier filter together with the Local
8676Reflection filter.
8677
8678Global mode was introduced in SDK 1.0 and Local mode was introduced in SDK 2.7.
8679)description"
8680 };
8681
8683 enum class ValueType
8684 {
8685 global,
8686 local
8687 };
8688 static const Mode global;
8689 static const Mode local;
8690
8692 static std::set<ValueType> validValues()
8693 {
8694 return { ValueType::global, ValueType::local };
8695 }
8696
8698 Mode() = default;
8699
8701 explicit constexpr Mode(ValueType value)
8702 : m_opt{ verifyValue(value) }
8703 {}
8704
8710
8712 bool hasValue() const;
8713
8715 void reset();
8716
8718 std::string toString() const;
8719
8721 friend std::ostream &operator<<(std::ostream &stream, const Mode::ValueType &value)
8722 {
8723 return stream << Mode{ value }.toString();
8724 }
8725
8727 bool operator==(const Mode &other) const
8728 {
8729 return m_opt == other.m_opt;
8730 }
8731
8733 bool operator!=(const Mode &other) const
8734 {
8735 return m_opt != other.m_opt;
8736 }
8737
8739 friend std::ostream &operator<<(std::ostream &stream, const Mode &value)
8740 {
8741 return stream << value.toString();
8742 }
8743
8744 private:
8745 void setFromString(const std::string &value);
8746
8747 constexpr ValueType static verifyValue(const ValueType &value)
8748 {
8749 return value == ValueType::global || value == ValueType::local
8750 ? value
8751 : throw std::invalid_argument{
8752 "Invalid value: Mode{ "
8753 + std::to_string(
8754 static_cast<std::underlying_type<ValueType>::type>(value))
8755 + " }"
8756 };
8757 }
8758
8759 Zivid::DataModel::Detail::Optional<ValueType> m_opt;
8760
8761 friend struct DataModel::Detail::Befriend<Mode>;
8762 };
8763
8765 std::tuple<Settings::Processing::Filters::Reflection::Removal::Experimental::Mode>;
8766
8769
8781#ifndef NO_DOC
8782 template<
8783 typename... Args,
8784 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
8785 typename std::enable_if<
8786 Zivid::Detail::TypeTraits::
8787 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
8788 int>::type = 0>
8789#else
8790 template<typename... Args>
8791#endif
8792 explicit Experimental(Args &&...args)
8793 {
8794 using namespace Zivid::Detail::TypeTraits;
8795
8796 static_assert(
8797 AllArgsDecayedAreUnique<Args...>::value,
8798 "Found duplicate types among the arguments passed to Experimental(...). "
8799 "Types should be listed at most once.");
8800
8801 set(std::forward<Args>(args)...);
8802 }
8803
8814#ifndef NO_DOC
8815 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
8816#else
8817 template<typename... Args>
8818#endif
8819 void set(Args &&...args)
8820 {
8821 using namespace Zivid::Detail::TypeTraits;
8822
8823 using AllArgsAreDescendantNodes =
8824 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
8825 static_assert(
8826 AllArgsAreDescendantNodes::value,
8827 "All arguments passed to set(...) must be descendant nodes.");
8828
8829 static_assert(
8830 AllArgsDecayedAreUnique<Args...>::value,
8831 "Found duplicate types among the arguments passed to set(...). "
8832 "Types should be listed at most once.");
8833
8834 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
8835 }
8836
8848#ifndef NO_DOC
8849 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
8850#else
8851 template<typename... Args>
8852#endif
8853 Experimental copyWith(Args &&...args) const
8854 {
8855 using namespace Zivid::Detail::TypeTraits;
8856
8857 using AllArgsAreDescendantNodes =
8858 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
8859 static_assert(
8860 AllArgsAreDescendantNodes::value,
8861 "All arguments passed to copyWith(...) must be descendant nodes.");
8862
8863 static_assert(
8864 AllArgsDecayedAreUnique<Args...>::value,
8865 "Found duplicate types among the arguments passed to copyWith(...). "
8866 "Types should be listed at most once.");
8867
8868 auto copy{ *this };
8869 copy.set(std::forward<Args>(args)...);
8870 return copy;
8871 }
8872
8874 const Mode &mode() const
8875 {
8876 return m_mode;
8877 }
8878
8881 {
8882 return m_mode;
8883 }
8884
8886 Experimental &set(const Mode &value)
8887 {
8888 m_mode = value;
8889 return *this;
8890 }
8891
8892 template<
8893 typename T,
8894 typename std::enable_if<
8895 std::is_same<
8896 T,
8898 int>::type = 0>
8900 {
8901 return m_mode;
8902 }
8903
8904 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
8906 {
8907 return m_mode;
8908 }
8909
8911 template<typename F>
8912 void forEach(const F &f) const
8913 {
8914 f(m_mode);
8915 }
8916
8918 template<typename F>
8919 void forEach(const F &f)
8920 {
8921 f(m_mode);
8922 }
8923
8925 bool operator==(const Experimental &other) const;
8926
8928 bool operator!=(const Experimental &other) const;
8929
8931 std::string toString() const;
8932
8934 friend std::ostream &operator<<(std::ostream &stream, const Experimental &value)
8935 {
8936 return stream << value.toString();
8937 }
8938
8939 private:
8940 void setFromString(const std::string &value);
8941
8942 void setFromString(const std::string &fullPath, const std::string &value);
8943
8944 std::string getString(const std::string &fullPath) const;
8945
8946 Mode m_mode;
8947
8948 friend struct DataModel::Detail::Befriend<Experimental>;
8949 };
8950
8951 using Descendants = std::tuple<
8955
8958
8972#ifndef NO_DOC
8973 template<
8974 typename... Args,
8975 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
8976 typename std::enable_if<
8977 Zivid::Detail::TypeTraits::
8978 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
8979 int>::type = 0>
8980#else
8981 template<typename... Args>
8982#endif
8983 explicit Removal(Args &&...args)
8984 {
8985 using namespace Zivid::Detail::TypeTraits;
8986
8987 static_assert(
8988 AllArgsDecayedAreUnique<Args...>::value,
8989 "Found duplicate types among the arguments passed to Removal(...). "
8990 "Types should be listed at most once.");
8991
8992 set(std::forward<Args>(args)...);
8993 }
8994
9007#ifndef NO_DOC
9008 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
9009#else
9010 template<typename... Args>
9011#endif
9012 void set(Args &&...args)
9013 {
9014 using namespace Zivid::Detail::TypeTraits;
9015
9016 using AllArgsAreDescendantNodes =
9017 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
9018 static_assert(
9019 AllArgsAreDescendantNodes::value,
9020 "All arguments passed to set(...) must be descendant nodes.");
9021
9022 static_assert(
9023 AllArgsDecayedAreUnique<Args...>::value,
9024 "Found duplicate types among the arguments passed to set(...). "
9025 "Types should be listed at most once.");
9026
9027 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
9028 }
9029
9043#ifndef NO_DOC
9044 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
9045#else
9046 template<typename... Args>
9047#endif
9048 Removal copyWith(Args &&...args) const
9049 {
9050 using namespace Zivid::Detail::TypeTraits;
9051
9052 using AllArgsAreDescendantNodes =
9053 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
9054 static_assert(
9055 AllArgsAreDescendantNodes::value,
9056 "All arguments passed to copyWith(...) must be descendant nodes.");
9057
9058 static_assert(
9059 AllArgsDecayedAreUnique<Args...>::value,
9060 "Found duplicate types among the arguments passed to copyWith(...). "
9061 "Types should be listed at most once.");
9062
9063 auto copy{ *this };
9064 copy.set(std::forward<Args>(args)...);
9065 return copy;
9066 }
9067
9069 const Enabled &isEnabled() const
9070 {
9071 return m_enabled;
9072 }
9073
9076 {
9077 return m_enabled;
9078 }
9079
9081 Removal &set(const Enabled &value)
9082 {
9083 m_enabled = value;
9084 return *this;
9085 }
9086
9089 {
9090 return m_experimental;
9091 }
9092
9095 {
9096 return m_experimental;
9097 }
9098
9100 Removal &set(const Experimental &value)
9101 {
9102 m_experimental = value;
9103 return *this;
9104 }
9105
9108 {
9109 m_experimental.set(value);
9110 return *this;
9111 }
9112
9113 template<
9114 typename T,
9115 typename std::enable_if<
9116 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Enabled>::value,
9117 int>::type = 0>
9119 {
9120 return m_enabled;
9121 }
9122
9123 template<
9124 typename T,
9125 typename std::enable_if<
9126 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Experimental>::
9127 value,
9128 int>::type = 0>
9130 {
9131 return m_experimental;
9132 }
9133
9134 template<
9135 typename T,
9136 typename std::enable_if<
9137 std::is_same<
9138 T,
9140 int>::type = 0>
9142 {
9143 return m_experimental
9145 }
9146
9147 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
9149 {
9150 return m_enabled;
9151 }
9152
9153 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
9155 {
9156 return m_experimental;
9157 }
9158
9160 template<typename F>
9161 void forEach(const F &f) const
9162 {
9163 f(m_enabled);
9164 f(m_experimental);
9165 }
9166
9168 template<typename F>
9169 void forEach(const F &f)
9170 {
9171 f(m_enabled);
9172 f(m_experimental);
9173 }
9174
9176 bool operator==(const Removal &other) const;
9177
9179 bool operator!=(const Removal &other) const;
9180
9182 std::string toString() const;
9183
9185 friend std::ostream &operator<<(std::ostream &stream, const Removal &value)
9186 {
9187 return stream << value.toString();
9188 }
9189
9190 private:
9191 void setFromString(const std::string &value);
9192
9193 void setFromString(const std::string &fullPath, const std::string &value);
9194
9195 std::string getString(const std::string &fullPath) const;
9196
9197 Enabled m_enabled;
9198 Experimental m_experimental;
9199
9200 friend struct DataModel::Detail::Befriend<Removal>;
9201 };
9202
9203 using Descendants = std::tuple<
9208
9211
9226#ifndef NO_DOC
9227 template<
9228 typename... Args,
9229 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
9230 typename std::enable_if<
9231 Zivid::Detail::TypeTraits::
9232 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
9233 int>::type = 0>
9234#else
9235 template<typename... Args>
9236#endif
9237 explicit Reflection(Args &&...args)
9238 {
9239 using namespace Zivid::Detail::TypeTraits;
9240
9241 static_assert(
9242 AllArgsDecayedAreUnique<Args...>::value,
9243 "Found duplicate types among the arguments passed to Reflection(...). "
9244 "Types should be listed at most once.");
9245
9246 set(std::forward<Args>(args)...);
9247 }
9248
9262#ifndef NO_DOC
9263 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
9264#else
9265 template<typename... Args>
9266#endif
9267 void set(Args &&...args)
9268 {
9269 using namespace Zivid::Detail::TypeTraits;
9270
9271 using AllArgsAreDescendantNodes =
9272 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
9273 static_assert(
9274 AllArgsAreDescendantNodes::value,
9275 "All arguments passed to set(...) must be descendant nodes.");
9276
9277 static_assert(
9278 AllArgsDecayedAreUnique<Args...>::value,
9279 "Found duplicate types among the arguments passed to set(...). "
9280 "Types should be listed at most once.");
9281
9282 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
9283 }
9284
9299#ifndef NO_DOC
9300 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
9301#else
9302 template<typename... Args>
9303#endif
9304 Reflection copyWith(Args &&...args) const
9305 {
9306 using namespace Zivid::Detail::TypeTraits;
9307
9308 using AllArgsAreDescendantNodes =
9309 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
9310 static_assert(
9311 AllArgsAreDescendantNodes::value,
9312 "All arguments passed to copyWith(...) must be descendant nodes.");
9313
9314 static_assert(
9315 AllArgsDecayedAreUnique<Args...>::value,
9316 "Found duplicate types among the arguments passed to copyWith(...). "
9317 "Types should be listed at most once.");
9318
9319 auto copy{ *this };
9320 copy.set(std::forward<Args>(args)...);
9321 return copy;
9322 }
9323
9325 const Removal &removal() const
9326 {
9327 return m_removal;
9328 }
9329
9332 {
9333 return m_removal;
9334 }
9335
9337 Reflection &set(const Removal &value)
9338 {
9339 m_removal = value;
9340 return *this;
9341 }
9342
9345 {
9346 m_removal.set(value);
9347 return *this;
9348 }
9349
9352 {
9353 m_removal.set(value);
9354 return *this;
9355 }
9356
9359 {
9360 m_removal.set(value);
9361 return *this;
9362 }
9363
9364 template<
9365 typename T,
9366 typename std::enable_if<
9367 std::is_same<T, Settings::Processing::Filters::Reflection::Removal>::value,
9368 int>::type = 0>
9370 {
9371 return m_removal;
9372 }
9373
9374 template<
9375 typename T,
9376 typename std::enable_if<
9377 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Enabled>::value,
9378 int>::type = 0>
9380 {
9382 }
9383
9384 template<
9385 typename T,
9386 typename std::enable_if<
9387 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Experimental>::value,
9388 int>::type = 0>
9390 {
9392 }
9393
9394 template<
9395 typename T,
9396 typename std::enable_if<
9397 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Experimental::Mode>::
9398 value,
9399 int>::type = 0>
9401 {
9403 }
9404
9405 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
9407 {
9408 return m_removal;
9409 }
9410
9412 template<typename F>
9413 void forEach(const F &f) const
9414 {
9415 f(m_removal);
9416 }
9417
9419 template<typename F>
9420 void forEach(const F &f)
9421 {
9422 f(m_removal);
9423 }
9424
9426 bool operator==(const Reflection &other) const;
9427
9429 bool operator!=(const Reflection &other) const;
9430
9432 std::string toString() const;
9433
9435 friend std::ostream &operator<<(std::ostream &stream, const Reflection &value)
9436 {
9437 return stream << value.toString();
9438 }
9439
9440 private:
9441 void setFromString(const std::string &value);
9442
9443 void setFromString(const std::string &fullPath, const std::string &value);
9444
9445 std::string getString(const std::string &fullPath) const;
9446
9447 Removal m_removal;
9448
9449 friend struct DataModel::Detail::Befriend<Reflection>;
9450 };
9451
9453
9454 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
9456 {
9457 public:
9460
9462 static constexpr const char *path{ "Processing/Filters/Smoothing" };
9463
9465 static constexpr const char *name{ "Smoothing" };
9466
9468 static constexpr const char *description{ R"description(Smoothing filters)description" };
9469
9471
9472 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
9474 {
9475 public:
9478
9480 static constexpr const char *path{ "Processing/Filters/Smoothing/Gaussian" };
9481
9483 static constexpr const char *name{ "Gaussian" };
9484
9486 static constexpr const char *description{
9487 R"description(Gaussian smoothing of the point cloud)description"
9488 };
9489
9491
9492 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
9494 {
9495 public:
9498
9500 static constexpr const char *path{ "Processing/Filters/Smoothing/Gaussian/Enabled" };
9501
9503 static constexpr const char *name{ "Enabled" };
9504
9506 static constexpr const char *description{
9507 R"description(Enable or disable the smoothing filter)description"
9508 };
9509
9511 using ValueType = bool;
9512 static const Enabled yes;
9513 static const Enabled no;
9514
9516 static std::set<bool> validValues()
9517 {
9518 return { false, true };
9519 }
9520
9522 Enabled() = default;
9523
9525 explicit constexpr Enabled(bool value)
9526 : m_opt{ value }
9527 {}
9528
9533 bool value() const;
9534
9536 bool hasValue() const;
9537
9539 void reset();
9540
9542 std::string toString() const;
9543
9545 bool operator==(const Enabled &other) const
9546 {
9547 return m_opt == other.m_opt;
9548 }
9549
9551 bool operator!=(const Enabled &other) const
9552 {
9553 return m_opt != other.m_opt;
9554 }
9555
9557 friend std::ostream &operator<<(std::ostream &stream, const Enabled &value)
9558 {
9559 return stream << value.toString();
9560 }
9561
9562 private:
9563 void setFromString(const std::string &value);
9564
9565 Zivid::DataModel::Detail::Optional<bool> m_opt;
9566
9567 friend struct DataModel::Detail::Befriend<Enabled>;
9568 };
9569
9571
9572 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
9574 {
9575 public:
9578
9580 static constexpr const char *path{ "Processing/Filters/Smoothing/Gaussian/Sigma" };
9581
9583 static constexpr const char *name{ "Sigma" };
9584
9586 static constexpr const char *description{
9587 R"description(Higher values result in smoother point clouds (Standard deviation of the filter coefficients))description"
9588 };
9589
9591 using ValueType = double;
9592
9594 static constexpr Range<double> validRange()
9595 {
9596 return { 0.5, 5 };
9597 }
9598
9600 Sigma() = default;
9601
9603 explicit constexpr Sigma(double value)
9604 : m_opt{ verifyValue(value) }
9605 {}
9606
9611 double value() const;
9612
9614 bool hasValue() const;
9615
9617 void reset();
9618
9620 std::string toString() const;
9621
9623 bool operator==(const Sigma &other) const
9624 {
9625 return m_opt == other.m_opt;
9626 }
9627
9629 bool operator!=(const Sigma &other) const
9630 {
9631 return m_opt != other.m_opt;
9632 }
9633
9635 bool operator<(const Sigma &other) const
9636 {
9637 return m_opt < other.m_opt;
9638 }
9639
9641 bool operator>(const Sigma &other) const
9642 {
9643 return m_opt > other.m_opt;
9644 }
9645
9647 bool operator<=(const Sigma &other) const
9648 {
9649 return m_opt <= other.m_opt;
9650 }
9651
9653 bool operator>=(const Sigma &other) const
9654 {
9655 return m_opt >= other.m_opt;
9656 }
9657
9659 friend std::ostream &operator<<(std::ostream &stream, const Sigma &value)
9660 {
9661 return stream << value.toString();
9662 }
9663
9664 private:
9665 void setFromString(const std::string &value);
9666
9667 constexpr ValueType static verifyValue(const ValueType &value)
9668 {
9669 return validRange().isInRange(value)
9670 ? value
9671 : throw std::out_of_range{ "Sigma{ " + std::to_string(value)
9672 + " } is not in range ["
9673 + std::to_string(validRange().min()) + ", "
9674 + std::to_string(validRange().max()) + "]" };
9675 }
9676
9677 Zivid::DataModel::Detail::Optional<double> m_opt;
9678
9679 friend struct DataModel::Detail::Befriend<Sigma>;
9680 };
9681
9682 using Descendants = std::tuple<
9685
9688
9701#ifndef NO_DOC
9702 template<
9703 typename... Args,
9704 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
9705 typename std::enable_if<
9706 Zivid::Detail::TypeTraits::
9707 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
9708 int>::type = 0>
9709#else
9710 template<typename... Args>
9711#endif
9712 explicit Gaussian(Args &&...args)
9713 {
9714 using namespace Zivid::Detail::TypeTraits;
9715
9716 static_assert(
9717 AllArgsDecayedAreUnique<Args...>::value,
9718 "Found duplicate types among the arguments passed to Gaussian(...). "
9719 "Types should be listed at most once.");
9720
9721 set(std::forward<Args>(args)...);
9722 }
9723
9735#ifndef NO_DOC
9736 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
9737#else
9738 template<typename... Args>
9739#endif
9740 void set(Args &&...args)
9741 {
9742 using namespace Zivid::Detail::TypeTraits;
9743
9744 using AllArgsAreDescendantNodes =
9745 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
9746 static_assert(
9747 AllArgsAreDescendantNodes::value,
9748 "All arguments passed to set(...) must be descendant nodes.");
9749
9750 static_assert(
9751 AllArgsDecayedAreUnique<Args...>::value,
9752 "Found duplicate types among the arguments passed to set(...). "
9753 "Types should be listed at most once.");
9754
9755 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
9756 }
9757
9770#ifndef NO_DOC
9771 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
9772#else
9773 template<typename... Args>
9774#endif
9775 Gaussian copyWith(Args &&...args) const
9776 {
9777 using namespace Zivid::Detail::TypeTraits;
9778
9779 using AllArgsAreDescendantNodes =
9780 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
9781 static_assert(
9782 AllArgsAreDescendantNodes::value,
9783 "All arguments passed to copyWith(...) must be descendant nodes.");
9784
9785 static_assert(
9786 AllArgsDecayedAreUnique<Args...>::value,
9787 "Found duplicate types among the arguments passed to copyWith(...). "
9788 "Types should be listed at most once.");
9789
9790 auto copy{ *this };
9791 copy.set(std::forward<Args>(args)...);
9792 return copy;
9793 }
9794
9796 const Enabled &isEnabled() const
9797 {
9798 return m_enabled;
9799 }
9800
9803 {
9804 return m_enabled;
9805 }
9806
9808 Gaussian &set(const Enabled &value)
9809 {
9810 m_enabled = value;
9811 return *this;
9812 }
9813
9815 const Sigma &sigma() const
9816 {
9817 return m_sigma;
9818 }
9819
9822 {
9823 return m_sigma;
9824 }
9825
9827 Gaussian &set(const Sigma &value)
9828 {
9829 m_sigma = value;
9830 return *this;
9831 }
9832
9833 template<
9834 typename T,
9835 typename std::enable_if<
9836 std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian::Enabled>::value,
9837 int>::type = 0>
9839 {
9840 return m_enabled;
9841 }
9842
9843 template<
9844 typename T,
9845 typename std::enable_if<
9846 std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian::Sigma>::value,
9847 int>::type = 0>
9849 {
9850 return m_sigma;
9851 }
9852
9853 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
9855 {
9856 return m_enabled;
9857 }
9858
9859 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
9861 {
9862 return m_sigma;
9863 }
9864
9866 template<typename F>
9867 void forEach(const F &f) const
9868 {
9869 f(m_enabled);
9870 f(m_sigma);
9871 }
9872
9874 template<typename F>
9875 void forEach(const F &f)
9876 {
9877 f(m_enabled);
9878 f(m_sigma);
9879 }
9880
9882 bool operator==(const Gaussian &other) const;
9883
9885 bool operator!=(const Gaussian &other) const;
9886
9888 std::string toString() const;
9889
9891 friend std::ostream &operator<<(std::ostream &stream, const Gaussian &value)
9892 {
9893 return stream << value.toString();
9894 }
9895
9896 private:
9897 void setFromString(const std::string &value);
9898
9899 void setFromString(const std::string &fullPath, const std::string &value);
9900
9901 std::string getString(const std::string &fullPath) const;
9902
9903 Enabled m_enabled;
9904 Sigma m_sigma;
9905
9906 friend struct DataModel::Detail::Befriend<Gaussian>;
9907 };
9908
9909 using Descendants = std::tuple<
9913
9916
9930#ifndef NO_DOC
9931 template<
9932 typename... Args,
9933 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
9934 typename std::enable_if<
9935 Zivid::Detail::TypeTraits::
9936 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
9937 int>::type = 0>
9938#else
9939 template<typename... Args>
9940#endif
9941 explicit Smoothing(Args &&...args)
9942 {
9943 using namespace Zivid::Detail::TypeTraits;
9944
9945 static_assert(
9946 AllArgsDecayedAreUnique<Args...>::value,
9947 "Found duplicate types among the arguments passed to Smoothing(...). "
9948 "Types should be listed at most once.");
9949
9950 set(std::forward<Args>(args)...);
9951 }
9952
9965#ifndef NO_DOC
9966 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
9967#else
9968 template<typename... Args>
9969#endif
9970 void set(Args &&...args)
9971 {
9972 using namespace Zivid::Detail::TypeTraits;
9973
9974 using AllArgsAreDescendantNodes =
9975 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
9976 static_assert(
9977 AllArgsAreDescendantNodes::value,
9978 "All arguments passed to set(...) must be descendant nodes.");
9979
9980 static_assert(
9981 AllArgsDecayedAreUnique<Args...>::value,
9982 "Found duplicate types among the arguments passed to set(...). "
9983 "Types should be listed at most once.");
9984
9985 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
9986 }
9987
10001#ifndef NO_DOC
10002 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
10003#else
10004 template<typename... Args>
10005#endif
10006 Smoothing copyWith(Args &&...args) const
10007 {
10008 using namespace Zivid::Detail::TypeTraits;
10009
10010 using AllArgsAreDescendantNodes =
10011 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
10012 static_assert(
10013 AllArgsAreDescendantNodes::value,
10014 "All arguments passed to copyWith(...) must be descendant nodes.");
10015
10016 static_assert(
10017 AllArgsDecayedAreUnique<Args...>::value,
10018 "Found duplicate types among the arguments passed to copyWith(...). "
10019 "Types should be listed at most once.");
10020
10021 auto copy{ *this };
10022 copy.set(std::forward<Args>(args)...);
10023 return copy;
10024 }
10025
10027 const Gaussian &gaussian() const
10028 {
10029 return m_gaussian;
10030 }
10031
10034 {
10035 return m_gaussian;
10036 }
10037
10039 Smoothing &set(const Gaussian &value)
10040 {
10041 m_gaussian = value;
10042 return *this;
10043 }
10044
10047 {
10048 m_gaussian.set(value);
10049 return *this;
10050 }
10051
10054 {
10055 m_gaussian.set(value);
10056 return *this;
10057 }
10058
10059 template<
10060 typename T,
10061 typename std::enable_if<
10062 std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian>::value,
10063 int>::type = 0>
10065 {
10066 return m_gaussian;
10067 }
10068
10069 template<
10070 typename T,
10071 typename std::enable_if<
10072 std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian::Enabled>::value,
10073 int>::type = 0>
10075 {
10077 }
10078
10079 template<
10080 typename T,
10081 typename std::enable_if<
10082 std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian::Sigma>::value,
10083 int>::type = 0>
10085 {
10087 }
10088
10089 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
10091 {
10092 return m_gaussian;
10093 }
10094
10096 template<typename F>
10097 void forEach(const F &f) const
10098 {
10099 f(m_gaussian);
10100 }
10101
10103 template<typename F>
10104 void forEach(const F &f)
10105 {
10106 f(m_gaussian);
10107 }
10108
10110 bool operator==(const Smoothing &other) const;
10111
10113 bool operator!=(const Smoothing &other) const;
10114
10116 std::string toString() const;
10117
10119 friend std::ostream &operator<<(std::ostream &stream, const Smoothing &value)
10120 {
10121 return stream << value.toString();
10122 }
10123
10124 private:
10125 void setFromString(const std::string &value);
10126
10127 void setFromString(const std::string &fullPath, const std::string &value);
10128
10129 std::string getString(const std::string &fullPath) const;
10130
10131 Gaussian m_gaussian;
10132
10133 friend struct DataModel::Detail::Befriend<Smoothing>;
10134 };
10135
10136 using Descendants = std::tuple<
10175
10178
10227#ifndef NO_DOC
10228 template<
10229 typename... Args,
10230 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
10231 typename std::enable_if<
10232 Zivid::Detail::TypeTraits::AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::
10233 value,
10234 int>::type = 0>
10235#else
10236 template<typename... Args>
10237#endif
10238 explicit Filters(Args &&...args)
10239 {
10240 using namespace Zivid::Detail::TypeTraits;
10241
10242 static_assert(
10243 AllArgsDecayedAreUnique<Args...>::value,
10244 "Found duplicate types among the arguments passed to Filters(...). "
10245 "Types should be listed at most once.");
10246
10247 set(std::forward<Args>(args)...);
10248 }
10249
10297#ifndef NO_DOC
10298 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
10299#else
10300 template<typename... Args>
10301#endif
10302 void set(Args &&...args)
10303 {
10304 using namespace Zivid::Detail::TypeTraits;
10305
10306 using AllArgsAreDescendantNodes =
10307 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
10308 static_assert(
10309 AllArgsAreDescendantNodes::value, "All arguments passed to set(...) must be descendant nodes.");
10310
10311 static_assert(
10312 AllArgsDecayedAreUnique<Args...>::value,
10313 "Found duplicate types among the arguments passed to set(...). "
10314 "Types should be listed at most once.");
10315
10316 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
10317 }
10318
10367#ifndef NO_DOC
10368 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
10369#else
10370 template<typename... Args>
10371#endif
10372 Filters copyWith(Args &&...args) const
10373 {
10374 using namespace Zivid::Detail::TypeTraits;
10375
10376 using AllArgsAreDescendantNodes =
10377 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
10378 static_assert(
10379 AllArgsAreDescendantNodes::value,
10380 "All arguments passed to copyWith(...) must be descendant nodes.");
10381
10382 static_assert(
10383 AllArgsDecayedAreUnique<Args...>::value,
10384 "Found duplicate types among the arguments passed to copyWith(...). "
10385 "Types should be listed at most once.");
10386
10387 auto copy{ *this };
10388 copy.set(std::forward<Args>(args)...);
10389 return copy;
10390 }
10391
10393 const Cluster &cluster() const
10394 {
10395 return m_cluster;
10396 }
10397
10400 {
10401 return m_cluster;
10402 }
10403
10405 Filters &set(const Cluster &value)
10406 {
10407 m_cluster = value;
10408 return *this;
10409 }
10410
10413 {
10414 m_cluster.set(value);
10415 return *this;
10416 }
10417
10420 {
10421 m_cluster.set(value);
10422 return *this;
10423 }
10424
10427 {
10428 m_cluster.set(value);
10429 return *this;
10430 }
10431
10434 {
10435 m_cluster.set(value);
10436 return *this;
10437 }
10438
10441 {
10442 return m_experimental;
10443 }
10444
10447 {
10448 return m_experimental;
10449 }
10450
10452 Filters &set(const Experimental &value)
10453 {
10454 m_experimental = value;
10455 return *this;
10456 }
10457
10460 {
10461 m_experimental.set(value);
10462 return *this;
10463 }
10464
10467 {
10468 m_experimental.set(value);
10469 return *this;
10470 }
10471
10474 {
10475 m_experimental.set(value);
10476 return *this;
10477 }
10478
10481 {
10482 m_experimental.set(value);
10483 return *this;
10484 }
10485
10488 {
10489 m_experimental.set(value);
10490 return *this;
10491 }
10492
10495 {
10496 m_experimental.set(value);
10497 return *this;
10498 }
10499
10502 {
10503 m_experimental.set(value);
10504 return *this;
10505 }
10506
10509 {
10510 m_experimental.set(value);
10511 return *this;
10512 }
10513
10516 {
10517 m_experimental.set(value);
10518 return *this;
10519 }
10520
10523 {
10524 m_experimental.set(value);
10525 return *this;
10526 }
10527
10530 {
10531 m_experimental.set(value);
10532 return *this;
10533 }
10534
10536 const Noise &noise() const
10537 {
10538 return m_noise;
10539 }
10540
10543 {
10544 return m_noise;
10545 }
10546
10548 Filters &set(const Noise &value)
10549 {
10550 m_noise = value;
10551 return *this;
10552 }
10553
10556 {
10557 m_noise.set(value);
10558 return *this;
10559 }
10560
10563 {
10564 m_noise.set(value);
10565 return *this;
10566 }
10567
10570 {
10571 m_noise.set(value);
10572 return *this;
10573 }
10574
10577 {
10578 m_noise.set(value);
10579 return *this;
10580 }
10581
10584 {
10585 m_noise.set(value);
10586 return *this;
10587 }
10588
10591 {
10592 m_noise.set(value);
10593 return *this;
10594 }
10595
10598 {
10599 m_noise.set(value);
10600 return *this;
10601 }
10602
10604 const Outlier &outlier() const
10605 {
10606 return m_outlier;
10607 }
10608
10611 {
10612 return m_outlier;
10613 }
10614
10616 Filters &set(const Outlier &value)
10617 {
10618 m_outlier = value;
10619 return *this;
10620 }
10621
10624 {
10625 m_outlier.set(value);
10626 return *this;
10627 }
10628
10631 {
10632 m_outlier.set(value);
10633 return *this;
10634 }
10635
10638 {
10639 m_outlier.set(value);
10640 return *this;
10641 }
10642
10644 const Reflection &reflection() const
10645 {
10646 return m_reflection;
10647 }
10648
10651 {
10652 return m_reflection;
10653 }
10654
10656 Filters &set(const Reflection &value)
10657 {
10658 m_reflection = value;
10659 return *this;
10660 }
10661
10664 {
10665 m_reflection.set(value);
10666 return *this;
10667 }
10668
10671 {
10672 m_reflection.set(value);
10673 return *this;
10674 }
10675
10678 {
10679 m_reflection.set(value);
10680 return *this;
10681 }
10682
10685 {
10686 m_reflection.set(value);
10687 return *this;
10688 }
10689
10691 const Smoothing &smoothing() const
10692 {
10693 return m_smoothing;
10694 }
10695
10698 {
10699 return m_smoothing;
10700 }
10701
10703 Filters &set(const Smoothing &value)
10704 {
10705 m_smoothing = value;
10706 return *this;
10707 }
10708
10711 {
10712 m_smoothing.set(value);
10713 return *this;
10714 }
10715
10718 {
10719 m_smoothing.set(value);
10720 return *this;
10721 }
10722
10725 {
10726 m_smoothing.set(value);
10727 return *this;
10728 }
10729
10730 template<
10731 typename T,
10732 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Cluster>::value, int>::type =
10733 0>
10735 {
10736 return m_cluster;
10737 }
10738
10739 template<
10740 typename T,
10741 typename std::enable_if<
10742 std::is_same<T, Settings::Processing::Filters::Cluster::Removal>::value,
10743 int>::type = 0>
10745 {
10747 }
10748
10749 template<
10750 typename T,
10751 typename std::enable_if<
10752 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::Enabled>::value,
10753 int>::type = 0>
10755 {
10757 }
10758
10759 template<
10760 typename T,
10761 typename std::enable_if<
10762 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance>::value,
10763 int>::type = 0>
10765 {
10767 }
10768
10769 template<
10770 typename T,
10771 typename std::enable_if<
10772 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::MinArea>::value,
10773 int>::type = 0>
10775 {
10777 }
10778
10779 template<
10780 typename T,
10781 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Experimental>::value, int>::
10782 type = 0>
10784 {
10785 return m_experimental;
10786 }
10787
10788 template<
10789 typename T,
10790 typename std::enable_if<
10791 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion>::value,
10792 int>::type = 0>
10794 {
10796 }
10797
10798 template<
10799 typename T,
10800 typename std::enable_if<
10801 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction>::
10802 value,
10803 int>::type = 0>
10805 {
10806 return m_experimental
10808 }
10809
10810 template<
10811 typename T,
10812 typename std::enable_if<
10813 std::is_same<
10814 T,
10816 value,
10817 int>::type = 0>
10819 {
10820 return m_experimental
10822 }
10823
10824 template<
10825 typename T,
10826 typename std::enable_if<
10827 std::is_same<
10828 T,
10830 value,
10831 int>::type = 0>
10833 {
10834 return m_experimental
10836 }
10837
10838 template<
10839 typename T,
10840 typename std::enable_if<
10841 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal>::
10842 value,
10843 int>::type = 0>
10845 {
10846 return m_experimental
10848 }
10849
10850 template<
10851 typename T,
10852 typename std::enable_if<
10853 std::is_same<
10854 T,
10856 int>::type = 0>
10858 {
10859 return m_experimental
10861 }
10862
10863 template<
10864 typename T,
10865 typename std::enable_if<
10866 std::is_same<
10867 T,
10869 int>::type = 0>
10871 {
10872 return m_experimental
10874 }
10875
10876 template<
10877 typename T,
10878 typename std::enable_if<
10879 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling>::value,
10880 int>::type = 0>
10882 {
10884 }
10885
10886 template<
10887 typename T,
10888 typename std::enable_if<
10889 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::Enabled>::value,
10890 int>::type = 0>
10892 {
10894 }
10895
10896 template<
10897 typename T,
10898 typename std::enable_if<
10899 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::HoleSize>::value,
10900 int>::type = 0>
10902 {
10904 }
10905
10906 template<
10907 typename T,
10908 typename std::enable_if<
10909 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::Strictness>::value,
10910 int>::type = 0>
10912 {
10914 }
10915
10916 template<
10917 typename T,
10918 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Noise>::value, int>::type =
10919 0>
10921 {
10922 return m_noise;
10923 }
10924
10925 template<
10926 typename T,
10927 typename std::
10928 enable_if<std::is_same<T, Settings::Processing::Filters::Noise::Removal>::value, int>::type = 0>
10930 {
10932 }
10933
10934 template<
10935 typename T,
10936 typename std::enable_if<
10937 std::is_same<T, Settings::Processing::Filters::Noise::Removal::Enabled>::value,
10938 int>::type = 0>
10940 {
10942 }
10943
10944 template<
10945 typename T,
10946 typename std::enable_if<
10947 std::is_same<T, Settings::Processing::Filters::Noise::Removal::Threshold>::value,
10948 int>::type = 0>
10950 {
10952 }
10953
10954 template<
10955 typename T,
10956 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Noise::Repair>::value, int>::
10957 type = 0>
10959 {
10961 }
10962
10963 template<
10964 typename T,
10965 typename std::enable_if<
10966 std::is_same<T, Settings::Processing::Filters::Noise::Repair::Enabled>::value,
10967 int>::type = 0>
10969 {
10971 }
10972
10973 template<
10974 typename T,
10975 typename std::enable_if<
10976 std::is_same<T, Settings::Processing::Filters::Noise::Suppression>::value,
10977 int>::type = 0>
10979 {
10981 }
10982
10983 template<
10984 typename T,
10985 typename std::enable_if<
10986 std::is_same<T, Settings::Processing::Filters::Noise::Suppression::Enabled>::value,
10987 int>::type = 0>
10989 {
10991 }
10992
10993 template<
10994 typename T,
10995 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Outlier>::value, int>::type =
10996 0>
10998 {
10999 return m_outlier;
11000 }
11001
11002 template<
11003 typename T,
11004 typename std::enable_if<
11005 std::is_same<T, Settings::Processing::Filters::Outlier::Removal>::value,
11006 int>::type = 0>
11008 {
11010 }
11011
11012 template<
11013 typename T,
11014 typename std::enable_if<
11015 std::is_same<T, Settings::Processing::Filters::Outlier::Removal::Enabled>::value,
11016 int>::type = 0>
11018 {
11020 }
11021
11022 template<
11023 typename T,
11024 typename std::enable_if<
11025 std::is_same<T, Settings::Processing::Filters::Outlier::Removal::Threshold>::value,
11026 int>::type = 0>
11028 {
11030 }
11031
11032 template<
11033 typename T,
11034 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Reflection>::value, int>::
11035 type = 0>
11037 {
11038 return m_reflection;
11039 }
11040
11041 template<
11042 typename T,
11043 typename std::enable_if<
11044 std::is_same<T, Settings::Processing::Filters::Reflection::Removal>::value,
11045 int>::type = 0>
11047 {
11049 }
11050
11051 template<
11052 typename T,
11053 typename std::enable_if<
11054 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Enabled>::value,
11055 int>::type = 0>
11057 {
11059 }
11060
11061 template<
11062 typename T,
11063 typename std::enable_if<
11064 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Experimental>::value,
11065 int>::type = 0>
11067 {
11069 }
11070
11071 template<
11072 typename T,
11073 typename std::enable_if<
11074 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Experimental::Mode>::value,
11075 int>::type = 0>
11077 {
11079 }
11080
11081 template<
11082 typename T,
11083 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Smoothing>::value, int>::
11084 type = 0>
11086 {
11087 return m_smoothing;
11088 }
11089
11090 template<
11091 typename T,
11092 typename std::enable_if<
11093 std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian>::value,
11094 int>::type = 0>
11096 {
11098 }
11099
11100 template<
11101 typename T,
11102 typename std::enable_if<
11103 std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian::Enabled>::value,
11104 int>::type = 0>
11106 {
11108 }
11109
11110 template<
11111 typename T,
11112 typename std::enable_if<
11113 std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian::Sigma>::value,
11114 int>::type = 0>
11116 {
11118 }
11119
11120 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
11122 {
11123 return m_cluster;
11124 }
11125
11126 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
11128 {
11129 return m_experimental;
11130 }
11131
11132 template<size_t i, typename std::enable_if<i == 2, int>::type = 0>
11134 {
11135 return m_noise;
11136 }
11137
11138 template<size_t i, typename std::enable_if<i == 3, int>::type = 0>
11140 {
11141 return m_outlier;
11142 }
11143
11144 template<size_t i, typename std::enable_if<i == 4, int>::type = 0>
11146 {
11147 return m_reflection;
11148 }
11149
11150 template<size_t i, typename std::enable_if<i == 5, int>::type = 0>
11152 {
11153 return m_smoothing;
11154 }
11155
11157 template<typename F>
11158 void forEach(const F &f) const
11159 {
11160 f(m_cluster);
11161 f(m_experimental);
11162 f(m_noise);
11163 f(m_outlier);
11164 f(m_reflection);
11165 f(m_smoothing);
11166 }
11167
11169 template<typename F>
11170 void forEach(const F &f)
11171 {
11172 f(m_cluster);
11173 f(m_experimental);
11174 f(m_noise);
11175 f(m_outlier);
11176 f(m_reflection);
11177 f(m_smoothing);
11178 }
11179
11181 bool operator==(const Filters &other) const;
11182
11184 bool operator!=(const Filters &other) const;
11185
11187 std::string toString() const;
11188
11190 friend std::ostream &operator<<(std::ostream &stream, const Filters &value)
11191 {
11192 return stream << value.toString();
11193 }
11194
11195 private:
11196 void setFromString(const std::string &value);
11197
11198 void setFromString(const std::string &fullPath, const std::string &value);
11199
11200 std::string getString(const std::string &fullPath) const;
11201
11202 Cluster m_cluster;
11203 Experimental m_experimental;
11204 Noise m_noise;
11205 Outlier m_outlier;
11206 Reflection m_reflection;
11207 Smoothing m_smoothing;
11208
11209 friend struct DataModel::Detail::Befriend<Filters>;
11210 };
11211
11212 using Descendants = std::tuple<
11260
11263
11321#ifndef NO_DOC
11322 template<
11323 typename... Args,
11324 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
11325 typename std::enable_if<
11326 Zivid::Detail::TypeTraits::AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::
11327 value,
11328 int>::type = 0>
11329#else
11330 template<typename... Args>
11331#endif
11332 explicit Processing(Args &&...args)
11333 {
11334 using namespace Zivid::Detail::TypeTraits;
11335
11336 static_assert(
11337 AllArgsDecayedAreUnique<Args...>::value,
11338 "Found duplicate types among the arguments passed to Processing(...). "
11339 "Types should be listed at most once.");
11340
11341 set(std::forward<Args>(args)...);
11342 }
11343
11400#ifndef NO_DOC
11401 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
11402#else
11403 template<typename... Args>
11404#endif
11405 void set(Args &&...args)
11406 {
11407 using namespace Zivid::Detail::TypeTraits;
11408
11409 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
11410 static_assert(
11411 AllArgsAreDescendantNodes::value, "All arguments passed to set(...) must be descendant nodes.");
11412
11413 static_assert(
11414 AllArgsDecayedAreUnique<Args...>::value,
11415 "Found duplicate types among the arguments passed to set(...). "
11416 "Types should be listed at most once.");
11417
11418 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
11419 }
11420
11478#ifndef NO_DOC
11479 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
11480#else
11481 template<typename... Args>
11482#endif
11483 Processing copyWith(Args &&...args) const
11484 {
11485 using namespace Zivid::Detail::TypeTraits;
11486
11487 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
11488 static_assert(
11489 AllArgsAreDescendantNodes::value,
11490 "All arguments passed to copyWith(...) must be descendant nodes.");
11491
11492 static_assert(
11493 AllArgsDecayedAreUnique<Args...>::value,
11494 "Found duplicate types among the arguments passed to copyWith(...). "
11495 "Types should be listed at most once.");
11496
11497 auto copy{ *this };
11498 copy.set(std::forward<Args>(args)...);
11499 return copy;
11500 }
11501
11503 const Color &color() const
11504 {
11505 return m_color;
11506 }
11507
11510 {
11511 return m_color;
11512 }
11513
11515 Processing &set(const Color &value)
11516 {
11517 m_color = value;
11518 return *this;
11519 }
11520
11523 {
11524 m_color.set(value);
11525 return *this;
11526 }
11527
11530 {
11531 m_color.set(value);
11532 return *this;
11533 }
11534
11537 {
11538 m_color.set(value);
11539 return *this;
11540 }
11541
11544 {
11545 m_color.set(value);
11546 return *this;
11547 }
11548
11551 {
11552 m_color.set(value);
11553 return *this;
11554 }
11555
11558 {
11559 m_color.set(value);
11560 return *this;
11561 }
11562
11565 {
11566 m_color.set(value);
11567 return *this;
11568 }
11569
11571 const Filters &filters() const
11572 {
11573 return m_filters;
11574 }
11575
11578 {
11579 return m_filters;
11580 }
11581
11583 Processing &set(const Filters &value)
11584 {
11585 m_filters = value;
11586 return *this;
11587 }
11588
11591 {
11592 m_filters.set(value);
11593 return *this;
11594 }
11595
11598 {
11599 m_filters.set(value);
11600 return *this;
11601 }
11602
11605 {
11606 m_filters.set(value);
11607 return *this;
11608 }
11609
11612 {
11613 m_filters.set(value);
11614 return *this;
11615 }
11616
11619 {
11620 m_filters.set(value);
11621 return *this;
11622 }
11623
11626 {
11627 m_filters.set(value);
11628 return *this;
11629 }
11630
11633 {
11634 m_filters.set(value);
11635 return *this;
11636 }
11637
11640 {
11641 m_filters.set(value);
11642 return *this;
11643 }
11644
11647 {
11648 m_filters.set(value);
11649 return *this;
11650 }
11651
11654 {
11655 m_filters.set(value);
11656 return *this;
11657 }
11658
11661 {
11662 m_filters.set(value);
11663 return *this;
11664 }
11665
11668 {
11669 m_filters.set(value);
11670 return *this;
11671 }
11672
11675 {
11676 m_filters.set(value);
11677 return *this;
11678 }
11679
11682 {
11683 m_filters.set(value);
11684 return *this;
11685 }
11686
11689 {
11690 m_filters.set(value);
11691 return *this;
11692 }
11693
11696 {
11697 m_filters.set(value);
11698 return *this;
11699 }
11700
11703 {
11704 m_filters.set(value);
11705 return *this;
11706 }
11707
11710 {
11711 m_filters.set(value);
11712 return *this;
11713 }
11714
11717 {
11718 m_filters.set(value);
11719 return *this;
11720 }
11721
11724 {
11725 m_filters.set(value);
11726 return *this;
11727 }
11728
11731 {
11732 m_filters.set(value);
11733 return *this;
11734 }
11735
11738 {
11739 m_filters.set(value);
11740 return *this;
11741 }
11742
11745 {
11746 m_filters.set(value);
11747 return *this;
11748 }
11749
11752 {
11753 m_filters.set(value);
11754 return *this;
11755 }
11756
11759 {
11760 m_filters.set(value);
11761 return *this;
11762 }
11763
11766 {
11767 m_filters.set(value);
11768 return *this;
11769 }
11770
11773 {
11774 m_filters.set(value);
11775 return *this;
11776 }
11777
11780 {
11781 m_filters.set(value);
11782 return *this;
11783 }
11784
11787 {
11788 m_filters.set(value);
11789 return *this;
11790 }
11791
11794 {
11795 m_filters.set(value);
11796 return *this;
11797 }
11798
11801 {
11802 m_filters.set(value);
11803 return *this;
11804 }
11805
11808 {
11809 m_filters.set(value);
11810 return *this;
11811 }
11812
11815 {
11816 m_filters.set(value);
11817 return *this;
11818 }
11819
11822 {
11823 m_filters.set(value);
11824 return *this;
11825 }
11826
11829 {
11830 m_filters.set(value);
11831 return *this;
11832 }
11833
11836 {
11837 m_filters.set(value);
11838 return *this;
11839 }
11840
11843 {
11844 m_filters.set(value);
11845 return *this;
11846 }
11847
11850 {
11851 m_filters.set(value);
11852 return *this;
11853 }
11854
11855 template<
11856 typename T,
11857 typename std::enable_if<std::is_same<T, Settings::Processing::Color>::value, int>::type = 0>
11859 {
11860 return m_color;
11861 }
11862
11863 template<
11864 typename T,
11865 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Balance>::value, int>::type = 0>
11867 {
11868 return m_color.get<Settings::Processing::Color::Balance>();
11869 }
11870
11871 template<
11872 typename T,
11873 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Balance::Blue>::value, int>::type =
11874 0>
11876 {
11877 return m_color.get<Settings::Processing::Color::Balance::Blue>();
11878 }
11879
11880 template<
11881 typename T,
11882 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Balance::Green>::value, int>::
11883 type = 0>
11885 {
11886 return m_color.get<Settings::Processing::Color::Balance::Green>();
11887 }
11888
11889 template<
11890 typename T,
11891 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Balance::Red>::value, int>::type =
11892 0>
11894 {
11895 return m_color.get<Settings::Processing::Color::Balance::Red>();
11896 }
11897
11898 template<
11899 typename T,
11900 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Experimental>::value, int>::type =
11901 0>
11903 {
11905 }
11906
11907 template<
11908 typename T,
11909 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Experimental::Mode>::value, int>::
11910 type = 0>
11912 {
11914 }
11915
11916 template<
11917 typename T,
11918 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Gamma>::value, int>::type = 0>
11920 {
11921 return m_color.get<Settings::Processing::Color::Gamma>();
11922 }
11923
11924 template<
11925 typename T,
11926 typename std::enable_if<std::is_same<T, Settings::Processing::Filters>::value, int>::type = 0>
11928 {
11929 return m_filters;
11930 }
11931
11932 template<
11933 typename T,
11934 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Cluster>::value, int>::type = 0>
11936 {
11937 return m_filters.get<Settings::Processing::Filters::Cluster>();
11938 }
11939
11940 template<
11941 typename T,
11942 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Cluster::Removal>::value, int>::
11943 type = 0>
11945 {
11947 }
11948
11949 template<
11950 typename T,
11951 typename std::enable_if<
11952 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::Enabled>::value,
11953 int>::type = 0>
11955 {
11957 }
11958
11959 template<
11960 typename T,
11961 typename std::enable_if<
11962 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance>::value,
11963 int>::type = 0>
11965 {
11967 }
11968
11969 template<
11970 typename T,
11971 typename std::enable_if<
11972 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::MinArea>::value,
11973 int>::type = 0>
11975 {
11977 }
11978
11979 template<
11980 typename T,
11981 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Experimental>::value, int>::
11982 type = 0>
11984 {
11986 }
11987
11988 template<
11989 typename T,
11990 typename std::enable_if<
11991 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion>::value,
11992 int>::type = 0>
11994 {
11996 }
11997
11998 template<
11999 typename T,
12000 typename std::enable_if<
12001 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction>::value,
12002 int>::type = 0>
12004 {
12006 }
12007
12008 template<
12009 typename T,
12010 typename std::enable_if<
12011 std::is_same<
12012 T,
12014 int>::type = 0>
12016 {
12017 return m_filters
12019 }
12020
12021 template<
12022 typename T,
12023 typename std::enable_if<
12024 std::is_same<
12025 T,
12027 int>::type = 0>
12029 {
12030 return m_filters
12032 }
12033
12034 template<
12035 typename T,
12036 typename std::enable_if<
12037 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal>::value,
12038 int>::type = 0>
12040 {
12042 }
12043
12044 template<
12045 typename T,
12046 typename std::enable_if<
12047 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled>::
12048 value,
12049 int>::type = 0>
12051 {
12052 return m_filters
12054 }
12055
12056 template<
12057 typename T,
12058 typename std::enable_if<
12059 std::is_same<
12060 T,
12062 int>::type = 0>
12064 {
12065 return m_filters
12067 }
12068
12069 template<
12070 typename T,
12071 typename std::enable_if<
12072 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling>::value,
12073 int>::type = 0>
12075 {
12077 }
12078
12079 template<
12080 typename T,
12081 typename std::enable_if<
12082 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::Enabled>::value,
12083 int>::type = 0>
12085 {
12087 }
12088
12089 template<
12090 typename T,
12091 typename std::enable_if<
12092 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::HoleSize>::value,
12093 int>::type = 0>
12095 {
12097 }
12098
12099 template<
12100 typename T,
12101 typename std::enable_if<
12102 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::Strictness>::value,
12103 int>::type = 0>
12105 {
12107 }
12108
12109 template<
12110 typename T,
12111 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Noise>::value, int>::type = 0>
12113 {
12114 return m_filters.get<Settings::Processing::Filters::Noise>();
12115 }
12116
12117 template<
12118 typename T,
12119 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Noise::Removal>::value, int>::
12120 type = 0>
12122 {
12124 }
12125
12126 template<
12127 typename T,
12128 typename std::enable_if<
12129 std::is_same<T, Settings::Processing::Filters::Noise::Removal::Enabled>::value,
12130 int>::type = 0>
12132 {
12134 }
12135
12136 template<
12137 typename T,
12138 typename std::enable_if<
12139 std::is_same<T, Settings::Processing::Filters::Noise::Removal::Threshold>::value,
12140 int>::type = 0>
12142 {
12144 }
12145
12146 template<
12147 typename T,
12148 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Noise::Repair>::value, int>::
12149 type = 0>
12151 {
12153 }
12154
12155 template<
12156 typename T,
12157 typename std::enable_if<
12158 std::is_same<T, Settings::Processing::Filters::Noise::Repair::Enabled>::value,
12159 int>::type = 0>
12161 {
12163 }
12164
12165 template<
12166 typename T,
12167 typename std::
12168 enable_if<std::is_same<T, Settings::Processing::Filters::Noise::Suppression>::value, int>::type = 0>
12170 {
12172 }
12173
12174 template<
12175 typename T,
12176 typename std::enable_if<
12177 std::is_same<T, Settings::Processing::Filters::Noise::Suppression::Enabled>::value,
12178 int>::type = 0>
12180 {
12182 }
12183
12184 template<
12185 typename T,
12186 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Outlier>::value, int>::type = 0>
12188 {
12189 return m_filters.get<Settings::Processing::Filters::Outlier>();
12190 }
12191
12192 template<
12193 typename T,
12194 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Outlier::Removal>::value, int>::
12195 type = 0>
12197 {
12199 }
12200
12201 template<
12202 typename T,
12203 typename std::enable_if<
12204 std::is_same<T, Settings::Processing::Filters::Outlier::Removal::Enabled>::value,
12205 int>::type = 0>
12207 {
12209 }
12210
12211 template<
12212 typename T,
12213 typename std::enable_if<
12214 std::is_same<T, Settings::Processing::Filters::Outlier::Removal::Threshold>::value,
12215 int>::type = 0>
12217 {
12219 }
12220
12221 template<
12222 typename T,
12223 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Reflection>::value, int>::type =
12224 0>
12226 {
12228 }
12229
12230 template<
12231 typename T,
12232 typename std::enable_if<
12233 std::is_same<T, Settings::Processing::Filters::Reflection::Removal>::value,
12234 int>::type = 0>
12236 {
12238 }
12239
12240 template<
12241 typename T,
12242 typename std::enable_if<
12243 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Enabled>::value,
12244 int>::type = 0>
12246 {
12248 }
12249
12250 template<
12251 typename T,
12252 typename std::enable_if<
12253 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Experimental>::value,
12254 int>::type = 0>
12256 {
12258 }
12259
12260 template<
12261 typename T,
12262 typename std::enable_if<
12263 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Experimental::Mode>::value,
12264 int>::type = 0>
12266 {
12268 }
12269
12270 template<
12271 typename T,
12272 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Smoothing>::value, int>::type =
12273 0>
12275 {
12277 }
12278
12279 template<
12280 typename T,
12281 typename std::enable_if<
12282 std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian>::value,
12283 int>::type = 0>
12285 {
12287 }
12288
12289 template<
12290 typename T,
12291 typename std::enable_if<
12292 std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian::Enabled>::value,
12293 int>::type = 0>
12295 {
12297 }
12298
12299 template<
12300 typename T,
12301 typename std::enable_if<
12302 std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian::Sigma>::value,
12303 int>::type = 0>
12305 {
12307 }
12308
12309 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
12311 {
12312 return m_color;
12313 }
12314
12315 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
12317 {
12318 return m_filters;
12319 }
12320
12322 template<typename F>
12323 void forEach(const F &f) const
12324 {
12325 f(m_color);
12326 f(m_filters);
12327 }
12328
12330 template<typename F>
12331 void forEach(const F &f)
12332 {
12333 f(m_color);
12334 f(m_filters);
12335 }
12336
12338 bool operator==(const Processing &other) const;
12339
12341 bool operator!=(const Processing &other) const;
12342
12344 std::string toString() const;
12345
12347 friend std::ostream &operator<<(std::ostream &stream, const Processing &value)
12348 {
12349 return stream << value.toString();
12350 }
12351
12352 private:
12353 void setFromString(const std::string &value);
12354
12355 void setFromString(const std::string &fullPath, const std::string &value);
12356
12357 std::string getString(const std::string &fullPath) const;
12358
12359 Color m_color;
12360 Filters m_filters;
12361
12362 friend struct DataModel::Detail::Befriend<Processing>;
12363 };
12364
12367
12368 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
12370 {
12371 public:
12374
12376 static constexpr const char *path{ "RegionOfInterest" };
12377
12379 static constexpr const char *name{ "RegionOfInterest" };
12380
12382 static constexpr const char *description{ R"description(Removes points outside the region of interest.
12383)description" };
12384
12396
12397 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
12399 {
12400 public:
12403
12405 static constexpr const char *path{ "RegionOfInterest/Box" };
12406
12408 static constexpr const char *name{ "Box" };
12409
12411 static constexpr const char *description{ R"description(Removes the points outside the box.
12412
12413The box is defined by three points: O, A and B. These points define two vectors,
12414OA that goes from PointO to PointA, and OB that goes from PointO to PointB.
12415This gives 4 points O, A, B and (O + OA + OB), that together form a
12416parallelogram in 3D.
12417
12418Two extents can be provided, to extrude the parallelogram along the surface
12419normal vector of the parallelogram plane. This creates a 3D volume (parallelepiped).
12420The surface normal vector is defined by the cross product OA x OB.
12421)description" };
12422
12424
12425 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
12427 {
12428 public:
12431
12433 static constexpr const char *path{ "RegionOfInterest/Box/Enabled" };
12434
12436 static constexpr const char *name{ "Enabled" };
12437
12439 static constexpr const char *description{ R"description(Enabled)description" };
12440
12442 using ValueType = bool;
12443 static const Enabled yes;
12444 static const Enabled no;
12445
12447 static std::set<bool> validValues()
12448 {
12449 return { false, true };
12450 }
12451
12453 Enabled() = default;
12454
12456 explicit constexpr Enabled(bool value)
12457 : m_opt{ value }
12458 {}
12459
12464 bool value() const;
12465
12467 bool hasValue() const;
12468
12470 void reset();
12471
12473 std::string toString() const;
12474
12476 bool operator==(const Enabled &other) const
12477 {
12478 return m_opt == other.m_opt;
12479 }
12480
12482 bool operator!=(const Enabled &other) const
12483 {
12484 return m_opt != other.m_opt;
12485 }
12486
12488 friend std::ostream &operator<<(std::ostream &stream, const Enabled &value)
12489 {
12490 return stream << value.toString();
12491 }
12492
12493 private:
12494 void setFromString(const std::string &value);
12495
12496 Zivid::DataModel::Detail::Optional<bool> m_opt;
12497
12498 friend struct DataModel::Detail::Befriend<Enabled>;
12499 };
12500
12502
12503 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
12505 {
12506 public:
12509
12511 static constexpr const char *path{ "RegionOfInterest/Box/Extents" };
12512
12514 static constexpr const char *name{ "Extents" };
12515
12517 static constexpr const char *description{
12518 R"description(Two points on the normal describing the direction and distance from the plane from which the normal is derived.)description"
12519 };
12520
12523
12525 Extents() = default;
12526
12528 explicit constexpr Extents(Zivid::Range<double> value)
12529 : m_opt{ value }
12530 {}
12531
12537
12539 bool hasValue() const;
12540
12542 void reset();
12543
12545 std::string toString() const;
12546
12548 explicit constexpr Extents(double minValue, double maxValue)
12549 : Extents{ Zivid::Range<double>{ minValue, maxValue } }
12550 {}
12551
12553 bool operator==(const Extents &other) const
12554 {
12555 return m_opt == other.m_opt;
12556 }
12557
12559 bool operator!=(const Extents &other) const
12560 {
12561 return m_opt != other.m_opt;
12562 }
12563
12565 friend std::ostream &operator<<(std::ostream &stream, const Extents &value)
12566 {
12567 return stream << value.toString();
12568 }
12569
12570 private:
12571 void setFromString(const std::string &value);
12572
12573 Zivid::DataModel::Detail::Optional<Zivid::Range<double>> m_opt;
12574
12575 friend struct DataModel::Detail::Befriend<Extents>;
12576 };
12577
12579
12580 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
12582 {
12583 public:
12586
12588 static constexpr const char *path{ "RegionOfInterest/Box/PointA" };
12589
12591 static constexpr const char *name{ "PointA" };
12592
12594 static constexpr const char *description{
12595 R"description(A point such that the vector from PointO to PointA describes the first edge of the parallelogram)description"
12596 };
12597
12600
12602 PointA() = default;
12603
12605 explicit constexpr PointA(Zivid::PointXYZ value)
12606 : m_opt{ value }
12607 {}
12608
12614
12616 bool hasValue() const;
12617
12619 void reset();
12620
12622 std::string toString() const;
12623
12625 explicit constexpr PointA(float x, float y, float z)
12626 : PointA{ Zivid::PointXYZ{ x, y, z } }
12627 {}
12628
12630 bool operator==(const PointA &other) const
12631 {
12632 return m_opt == other.m_opt;
12633 }
12634
12636 bool operator!=(const PointA &other) const
12637 {
12638 return m_opt != other.m_opt;
12639 }
12640
12642 friend std::ostream &operator<<(std::ostream &stream, const PointA &value)
12643 {
12644 return stream << value.toString();
12645 }
12646
12647 private:
12648 void setFromString(const std::string &value);
12649
12650 Zivid::DataModel::Detail::Optional<Zivid::PointXYZ> m_opt;
12651
12652 friend struct DataModel::Detail::Befriend<PointA>;
12653 };
12654
12656
12657 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
12659 {
12660 public:
12663
12665 static constexpr const char *path{ "RegionOfInterest/Box/PointB" };
12666
12668 static constexpr const char *name{ "PointB" };
12669
12671 static constexpr const char *description{
12672 R"description(A point such that the vector from PointO to PointB describes the second edge of the parallelogram)description"
12673 };
12674
12677
12679 PointB() = default;
12680
12682 explicit constexpr PointB(Zivid::PointXYZ value)
12683 : m_opt{ value }
12684 {}
12685
12691
12693 bool hasValue() const;
12694
12696 void reset();
12697
12699 std::string toString() const;
12700
12702 explicit constexpr PointB(float x, float y, float z)
12703 : PointB{ Zivid::PointXYZ{ x, y, z } }
12704 {}
12705
12707 bool operator==(const PointB &other) const
12708 {
12709 return m_opt == other.m_opt;
12710 }
12711
12713 bool operator!=(const PointB &other) const
12714 {
12715 return m_opt != other.m_opt;
12716 }
12717
12719 friend std::ostream &operator<<(std::ostream &stream, const PointB &value)
12720 {
12721 return stream << value.toString();
12722 }
12723
12724 private:
12725 void setFromString(const std::string &value);
12726
12727 Zivid::DataModel::Detail::Optional<Zivid::PointXYZ> m_opt;
12728
12729 friend struct DataModel::Detail::Befriend<PointB>;
12730 };
12731
12733
12734 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
12736 {
12737 public:
12740
12742 static constexpr const char *path{ "RegionOfInterest/Box/PointO" };
12743
12745 static constexpr const char *name{ "PointO" };
12746
12748 static constexpr const char *description{
12749 R"description(The point at the intersection of two adjacent edges defining a parallelogram)description"
12750 };
12751
12754
12756 PointO() = default;
12757
12759 explicit constexpr PointO(Zivid::PointXYZ value)
12760 : m_opt{ value }
12761 {}
12762
12768
12770 bool hasValue() const;
12771
12773 void reset();
12774
12776 std::string toString() const;
12777
12779 explicit constexpr PointO(float x, float y, float z)
12780 : PointO{ Zivid::PointXYZ{ x, y, z } }
12781 {}
12782
12784 bool operator==(const PointO &other) const
12785 {
12786 return m_opt == other.m_opt;
12787 }
12788
12790 bool operator!=(const PointO &other) const
12791 {
12792 return m_opt != other.m_opt;
12793 }
12794
12796 friend std::ostream &operator<<(std::ostream &stream, const PointO &value)
12797 {
12798 return stream << value.toString();
12799 }
12800
12801 private:
12802 void setFromString(const std::string &value);
12803
12804 Zivid::DataModel::Detail::Optional<Zivid::PointXYZ> m_opt;
12805
12806 friend struct DataModel::Detail::Befriend<PointO>;
12807 };
12808
12809 using Descendants = std::tuple<
12815
12818
12834#ifndef NO_DOC
12835 template<
12836 typename... Args,
12837 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
12838 typename std::enable_if<
12839 Zivid::Detail::TypeTraits::AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::
12840 value,
12841 int>::type = 0>
12842#else
12843 template<typename... Args>
12844#endif
12845 explicit Box(Args &&...args)
12846 {
12847 using namespace Zivid::Detail::TypeTraits;
12848
12849 static_assert(
12850 AllArgsDecayedAreUnique<Args...>::value,
12851 "Found duplicate types among the arguments passed to Box(...). "
12852 "Types should be listed at most once.");
12853
12854 set(std::forward<Args>(args)...);
12855 }
12856
12871#ifndef NO_DOC
12872 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
12873#else
12874 template<typename... Args>
12875#endif
12876 void set(Args &&...args)
12877 {
12878 using namespace Zivid::Detail::TypeTraits;
12879
12880 using AllArgsAreDescendantNodes =
12881 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
12882 static_assert(
12883 AllArgsAreDescendantNodes::value, "All arguments passed to set(...) must be descendant nodes.");
12884
12885 static_assert(
12886 AllArgsDecayedAreUnique<Args...>::value,
12887 "Found duplicate types among the arguments passed to set(...). "
12888 "Types should be listed at most once.");
12889
12890 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
12891 }
12892
12908#ifndef NO_DOC
12909 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
12910#else
12911 template<typename... Args>
12912#endif
12913 Box copyWith(Args &&...args) const
12914 {
12915 using namespace Zivid::Detail::TypeTraits;
12916
12917 using AllArgsAreDescendantNodes =
12918 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
12919 static_assert(
12920 AllArgsAreDescendantNodes::value,
12921 "All arguments passed to copyWith(...) must be descendant nodes.");
12922
12923 static_assert(
12924 AllArgsDecayedAreUnique<Args...>::value,
12925 "Found duplicate types among the arguments passed to copyWith(...). "
12926 "Types should be listed at most once.");
12927
12928 auto copy{ *this };
12929 copy.set(std::forward<Args>(args)...);
12930 return copy;
12931 }
12932
12934 const Enabled &isEnabled() const
12935 {
12936 return m_enabled;
12937 }
12938
12941 {
12942 return m_enabled;
12943 }
12944
12946 Box &set(const Enabled &value)
12947 {
12948 m_enabled = value;
12949 return *this;
12950 }
12951
12953 const Extents &extents() const
12954 {
12955 return m_extents;
12956 }
12957
12960 {
12961 return m_extents;
12962 }
12963
12965 Box &set(const Extents &value)
12966 {
12967 m_extents = value;
12968 return *this;
12969 }
12970
12972 const PointA &pointA() const
12973 {
12974 return m_pointA;
12975 }
12976
12979 {
12980 return m_pointA;
12981 }
12982
12984 Box &set(const PointA &value)
12985 {
12986 m_pointA = value;
12987 return *this;
12988 }
12989
12991 const PointB &pointB() const
12992 {
12993 return m_pointB;
12994 }
12995
12998 {
12999 return m_pointB;
13000 }
13001
13003 Box &set(const PointB &value)
13004 {
13005 m_pointB = value;
13006 return *this;
13007 }
13008
13010 const PointO &pointO() const
13011 {
13012 return m_pointO;
13013 }
13014
13017 {
13018 return m_pointO;
13019 }
13020
13022 Box &set(const PointO &value)
13023 {
13024 m_pointO = value;
13025 return *this;
13026 }
13027
13028 template<
13029 typename T,
13030 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::Enabled>::value, int>::
13031 type = 0>
13033 {
13034 return m_enabled;
13035 }
13036
13037 template<
13038 typename T,
13039 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::Extents>::value, int>::
13040 type = 0>
13042 {
13043 return m_extents;
13044 }
13045
13046 template<
13047 typename T,
13048 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::PointA>::value, int>::
13049 type = 0>
13051 {
13052 return m_pointA;
13053 }
13054
13055 template<
13056 typename T,
13057 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::PointB>::value, int>::
13058 type = 0>
13060 {
13061 return m_pointB;
13062 }
13063
13064 template<
13065 typename T,
13066 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::PointO>::value, int>::
13067 type = 0>
13069 {
13070 return m_pointO;
13071 }
13072
13073 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
13075 {
13076 return m_enabled;
13077 }
13078
13079 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
13081 {
13082 return m_extents;
13083 }
13084
13085 template<size_t i, typename std::enable_if<i == 2, int>::type = 0>
13087 {
13088 return m_pointA;
13089 }
13090
13091 template<size_t i, typename std::enable_if<i == 3, int>::type = 0>
13093 {
13094 return m_pointB;
13095 }
13096
13097 template<size_t i, typename std::enable_if<i == 4, int>::type = 0>
13099 {
13100 return m_pointO;
13101 }
13102
13104 template<typename F>
13105 void forEach(const F &f) const
13106 {
13107 f(m_enabled);
13108 f(m_extents);
13109 f(m_pointA);
13110 f(m_pointB);
13111 f(m_pointO);
13112 }
13113
13115 template<typename F>
13116 void forEach(const F &f)
13117 {
13118 f(m_enabled);
13119 f(m_extents);
13120 f(m_pointA);
13121 f(m_pointB);
13122 f(m_pointO);
13123 }
13124
13126 bool operator==(const Box &other) const;
13127
13129 bool operator!=(const Box &other) const;
13130
13132 std::string toString() const;
13133
13135 friend std::ostream &operator<<(std::ostream &stream, const Box &value)
13136 {
13137 return stream << value.toString();
13138 }
13139
13140 private:
13141 void setFromString(const std::string &value);
13142
13143 void setFromString(const std::string &fullPath, const std::string &value);
13144
13145 std::string getString(const std::string &fullPath) const;
13146
13147 Enabled m_enabled;
13148 Extents m_extents;
13149 PointA m_pointA;
13150 PointB m_pointB;
13151 PointO m_pointO;
13152
13153 friend struct DataModel::Detail::Befriend<Box>;
13154 };
13155
13159
13160 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
13162 {
13163 public:
13166
13168 static constexpr const char *path{ "RegionOfInterest/Depth" };
13169
13171 static constexpr const char *name{ "Depth" };
13172
13174 static constexpr const char *description{
13175 R"description(Removes points that reside outside of a depth range, meaning that their Z coordinate
13176falls above a given maximum or below a given minimum.
13177)description"
13178 };
13179
13181
13182 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
13184 {
13185 public:
13188
13190 static constexpr const char *path{ "RegionOfInterest/Depth/Enabled" };
13191
13193 static constexpr const char *name{ "Enabled" };
13194
13196 static constexpr const char *description{ R"description(Enabled)description" };
13197
13199 using ValueType = bool;
13200 static const Enabled yes;
13201 static const Enabled no;
13202
13204 static std::set<bool> validValues()
13205 {
13206 return { false, true };
13207 }
13208
13210 Enabled() = default;
13211
13213 explicit constexpr Enabled(bool value)
13214 : m_opt{ value }
13215 {}
13216
13221 bool value() const;
13222
13224 bool hasValue() const;
13225
13227 void reset();
13228
13230 std::string toString() const;
13231
13233 bool operator==(const Enabled &other) const
13234 {
13235 return m_opt == other.m_opt;
13236 }
13237
13239 bool operator!=(const Enabled &other) const
13240 {
13241 return m_opt != other.m_opt;
13242 }
13243
13245 friend std::ostream &operator<<(std::ostream &stream, const Enabled &value)
13246 {
13247 return stream << value.toString();
13248 }
13249
13250 private:
13251 void setFromString(const std::string &value);
13252
13253 Zivid::DataModel::Detail::Optional<bool> m_opt;
13254
13255 friend struct DataModel::Detail::Befriend<Enabled>;
13256 };
13257
13259
13260 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
13262 {
13263 public:
13266
13268 static constexpr const char *path{ "RegionOfInterest/Depth/Range" };
13269
13271 static constexpr const char *name{ "Range" };
13272
13274 static constexpr const char *description{
13275 R"description(Specify the minimum and maximum Z value that will be included.)description"
13276 };
13277
13280
13282 Range() = default;
13283
13285 explicit constexpr Range(Zivid::Range<double> value)
13286 : m_opt{ value }
13287 {}
13288
13294
13296 bool hasValue() const;
13297
13299 void reset();
13300
13302 std::string toString() const;
13303
13305 explicit constexpr Range(double minValue, double maxValue)
13306 : Range{ Zivid::Range<double>{ minValue, maxValue } }
13307 {}
13308
13310 bool operator==(const Range &other) const
13311 {
13312 return m_opt == other.m_opt;
13313 }
13314
13316 bool operator!=(const Range &other) const
13317 {
13318 return m_opt != other.m_opt;
13319 }
13320
13322 friend std::ostream &operator<<(std::ostream &stream, const Range &value)
13323 {
13324 return stream << value.toString();
13325 }
13326
13327 private:
13328 void setFromString(const std::string &value);
13329
13330 Zivid::DataModel::Detail::Optional<Zivid::Range<double>> m_opt;
13331
13332 friend struct DataModel::Detail::Befriend<Range>;
13333 };
13334
13336 std::tuple<Settings::RegionOfInterest::Depth::Enabled, Settings::RegionOfInterest::Depth::Range>;
13337
13340
13353#ifndef NO_DOC
13354 template<
13355 typename... Args,
13356 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
13357 typename std::enable_if<
13358 Zivid::Detail::TypeTraits::AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::
13359 value,
13360 int>::type = 0>
13361#else
13362 template<typename... Args>
13363#endif
13364 explicit Depth(Args &&...args)
13365 {
13366 using namespace Zivid::Detail::TypeTraits;
13367
13368 static_assert(
13369 AllArgsDecayedAreUnique<Args...>::value,
13370 "Found duplicate types among the arguments passed to Depth(...). "
13371 "Types should be listed at most once.");
13372
13373 set(std::forward<Args>(args)...);
13374 }
13375
13387#ifndef NO_DOC
13388 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
13389#else
13390 template<typename... Args>
13391#endif
13392 void set(Args &&...args)
13393 {
13394 using namespace Zivid::Detail::TypeTraits;
13395
13396 using AllArgsAreDescendantNodes =
13397 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
13398 static_assert(
13399 AllArgsAreDescendantNodes::value, "All arguments passed to set(...) must be descendant nodes.");
13400
13401 static_assert(
13402 AllArgsDecayedAreUnique<Args...>::value,
13403 "Found duplicate types among the arguments passed to set(...). "
13404 "Types should be listed at most once.");
13405
13406 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
13407 }
13408
13421#ifndef NO_DOC
13422 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
13423#else
13424 template<typename... Args>
13425#endif
13426 Depth copyWith(Args &&...args) const
13427 {
13428 using namespace Zivid::Detail::TypeTraits;
13429
13430 using AllArgsAreDescendantNodes =
13431 AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
13432 static_assert(
13433 AllArgsAreDescendantNodes::value,
13434 "All arguments passed to copyWith(...) must be descendant nodes.");
13435
13436 static_assert(
13437 AllArgsDecayedAreUnique<Args...>::value,
13438 "Found duplicate types among the arguments passed to copyWith(...). "
13439 "Types should be listed at most once.");
13440
13441 auto copy{ *this };
13442 copy.set(std::forward<Args>(args)...);
13443 return copy;
13444 }
13445
13447 const Enabled &isEnabled() const
13448 {
13449 return m_enabled;
13450 }
13451
13454 {
13455 return m_enabled;
13456 }
13457
13459 Depth &set(const Enabled &value)
13460 {
13461 m_enabled = value;
13462 return *this;
13463 }
13464
13466 const Range &range() const
13467 {
13468 return m_range;
13469 }
13470
13473 {
13474 return m_range;
13475 }
13476
13478 Depth &set(const Range &value)
13479 {
13480 m_range = value;
13481 return *this;
13482 }
13483
13484 template<
13485 typename T,
13486 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Depth::Enabled>::value, int>::
13487 type = 0>
13489 {
13490 return m_enabled;
13491 }
13492
13493 template<
13494 typename T,
13495 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Depth::Range>::value, int>::
13496 type = 0>
13498 {
13499 return m_range;
13500 }
13501
13502 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
13504 {
13505 return m_enabled;
13506 }
13507
13508 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
13510 {
13511 return m_range;
13512 }
13513
13515 template<typename F>
13516 void forEach(const F &f) const
13517 {
13518 f(m_enabled);
13519 f(m_range);
13520 }
13521
13523 template<typename F>
13524 void forEach(const F &f)
13525 {
13526 f(m_enabled);
13527 f(m_range);
13528 }
13529
13531 bool operator==(const Depth &other) const;
13532
13534 bool operator!=(const Depth &other) const;
13535
13537 std::string toString() const;
13538
13540 friend std::ostream &operator<<(std::ostream &stream, const Depth &value)
13541 {
13542 return stream << value.toString();
13543 }
13544
13545 private:
13546 void setFromString(const std::string &value);
13547
13548 void setFromString(const std::string &fullPath, const std::string &value);
13549
13550 std::string getString(const std::string &fullPath) const;
13551
13552 Enabled m_enabled;
13553 Range m_range;
13554
13555 friend struct DataModel::Detail::Befriend<Depth>;
13556 };
13557
13558 using Descendants = std::tuple<
13568
13571
13591#ifndef NO_DOC
13592 template<
13593 typename... Args,
13594 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
13595 typename std::enable_if<
13596 Zivid::Detail::TypeTraits::AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::
13597 value,
13598 int>::type = 0>
13599#else
13600 template<typename... Args>
13601#endif
13602 explicit RegionOfInterest(Args &&...args)
13603 {
13604 using namespace Zivid::Detail::TypeTraits;
13605
13606 static_assert(
13607 AllArgsDecayedAreUnique<Args...>::value,
13608 "Found duplicate types among the arguments passed to RegionOfInterest(...). "
13609 "Types should be listed at most once.");
13610
13611 set(std::forward<Args>(args)...);
13612 }
13613
13632#ifndef NO_DOC
13633 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
13634#else
13635 template<typename... Args>
13636#endif
13637 void set(Args &&...args)
13638 {
13639 using namespace Zivid::Detail::TypeTraits;
13640
13641 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
13642 static_assert(
13643 AllArgsAreDescendantNodes::value, "All arguments passed to set(...) must be descendant nodes.");
13644
13645 static_assert(
13646 AllArgsDecayedAreUnique<Args...>::value,
13647 "Found duplicate types among the arguments passed to set(...). "
13648 "Types should be listed at most once.");
13649
13650 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
13651 }
13652
13672#ifndef NO_DOC
13673 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
13674#else
13675 template<typename... Args>
13676#endif
13677 RegionOfInterest copyWith(Args &&...args) const
13678 {
13679 using namespace Zivid::Detail::TypeTraits;
13680
13681 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
13682 static_assert(
13683 AllArgsAreDescendantNodes::value,
13684 "All arguments passed to copyWith(...) must be descendant nodes.");
13685
13686 static_assert(
13687 AllArgsDecayedAreUnique<Args...>::value,
13688 "Found duplicate types among the arguments passed to copyWith(...). "
13689 "Types should be listed at most once.");
13690
13691 auto copy{ *this };
13692 copy.set(std::forward<Args>(args)...);
13693 return copy;
13694 }
13695
13697 const Box &box() const
13698 {
13699 return m_box;
13700 }
13701
13704 {
13705 return m_box;
13706 }
13707
13709 RegionOfInterest &set(const Box &value)
13710 {
13711 m_box = value;
13712 return *this;
13713 }
13714
13717 {
13718 m_box.set(value);
13719 return *this;
13720 }
13721
13724 {
13725 m_box.set(value);
13726 return *this;
13727 }
13728
13731 {
13732 m_box.set(value);
13733 return *this;
13734 }
13735
13738 {
13739 m_box.set(value);
13740 return *this;
13741 }
13742
13745 {
13746 m_box.set(value);
13747 return *this;
13748 }
13749
13751 const Depth &depth() const
13752 {
13753 return m_depth;
13754 }
13755
13758 {
13759 return m_depth;
13760 }
13761
13764 {
13765 m_depth = value;
13766 return *this;
13767 }
13768
13771 {
13772 m_depth.set(value);
13773 return *this;
13774 }
13775
13778 {
13779 m_depth.set(value);
13780 return *this;
13781 }
13782
13783 template<
13784 typename T,
13785 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box>::value, int>::type = 0>
13787 {
13788 return m_box;
13789 }
13790
13791 template<
13792 typename T,
13793 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::Enabled>::value, int>::type =
13794 0>
13796 {
13797 return m_box.get<Settings::RegionOfInterest::Box::Enabled>();
13798 }
13799
13800 template<
13801 typename T,
13802 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::Extents>::value, int>::type =
13803 0>
13805 {
13806 return m_box.get<Settings::RegionOfInterest::Box::Extents>();
13807 }
13808
13809 template<
13810 typename T,
13811 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::PointA>::value, int>::type = 0>
13813 {
13814 return m_box.get<Settings::RegionOfInterest::Box::PointA>();
13815 }
13816
13817 template<
13818 typename T,
13819 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::PointB>::value, int>::type = 0>
13821 {
13822 return m_box.get<Settings::RegionOfInterest::Box::PointB>();
13823 }
13824
13825 template<
13826 typename T,
13827 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::PointO>::value, int>::type = 0>
13829 {
13830 return m_box.get<Settings::RegionOfInterest::Box::PointO>();
13831 }
13832
13833 template<
13834 typename T,
13835 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Depth>::value, int>::type = 0>
13837 {
13838 return m_depth;
13839 }
13840
13841 template<
13842 typename T,
13843 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Depth::Enabled>::value, int>::type =
13844 0>
13846 {
13847 return m_depth.get<Settings::RegionOfInterest::Depth::Enabled>();
13848 }
13849
13850 template<
13851 typename T,
13852 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Depth::Range>::value, int>::type =
13853 0>
13855 {
13856 return m_depth.get<Settings::RegionOfInterest::Depth::Range>();
13857 }
13858
13859 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
13861 {
13862 return m_box;
13863 }
13864
13865 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
13867 {
13868 return m_depth;
13869 }
13870
13872 template<typename F>
13873 void forEach(const F &f) const
13874 {
13875 f(m_box);
13876 f(m_depth);
13877 }
13878
13880 template<typename F>
13881 void forEach(const F &f)
13882 {
13883 f(m_box);
13884 f(m_depth);
13885 }
13886
13888 bool operator==(const RegionOfInterest &other) const;
13889
13891 bool operator!=(const RegionOfInterest &other) const;
13892
13894 std::string toString() const;
13895
13897 friend std::ostream &operator<<(std::ostream &stream, const RegionOfInterest &value)
13898 {
13899 return stream << value.toString();
13900 }
13901
13902 private:
13903 void setFromString(const std::string &value);
13904
13905 void setFromString(const std::string &fullPath, const std::string &value);
13906
13907 std::string getString(const std::string &fullPath) const;
13908
13909 Box m_box;
13910 Depth m_depth;
13911
13912 friend struct DataModel::Detail::Befriend<RegionOfInterest>;
13913 };
13914
13917
13918 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
13920 {
13921 public:
13923 static constexpr DataModel::NodeType nodeType = DataModel::NodeType::group;
13924
13926 static constexpr const char *path{ "Sampling" };
13927
13929 static constexpr const char *name{ "Sampling" };
13930
13932 static constexpr const char *description{ R"description(Sampling group
13933)description" };
13934
13940
13941 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
13943 {
13944 public:
13946 static constexpr DataModel::NodeType nodeType = DataModel::NodeType::leafValue;
13947
13949 static constexpr const char *path{ "Sampling/Color" };
13950
13952 static constexpr const char *name{ "Color" };
13953
13955 static constexpr const char *description{
13956 R"description(Choose how to sample colors for the pointcloud. The `rgb` option gives all
13957colors for a regular Zivid camera. The `disabled` option gives no colors and
13958can allow for faster captures. It is also useful if you want to avoid projecting
13959white light in the subsampling modes under `Sampling::Pixel`.
13960)description"
13961 };
13962
13964 enum class ValueType
13965 {
13966 rgb,
13967 disabled
13968 };
13969 static const Color rgb;
13970 static const Color disabled;
13971
13973 static std::set<ValueType> validValues()
13974 {
13975 return { ValueType::rgb, ValueType::disabled };
13976 }
13977
13979 Color() = default;
13980
13982 explicit constexpr Color(ValueType value)
13983 : m_opt{ verifyValue(value) }
13984 {}
13985
13991
13993 bool hasValue() const;
13994
13996 void reset();
13997
13999 std::string toString() const;
14000
14002 friend std::ostream &operator<<(std::ostream &stream, const Color::ValueType &value)
14003 {
14004 return stream << Color{ value }.toString();
14005 }
14006
14008 bool operator==(const Color &other) const
14009 {
14010 return m_opt == other.m_opt;
14011 }
14012
14014 bool operator!=(const Color &other) const
14015 {
14016 return m_opt != other.m_opt;
14017 }
14018
14020 friend std::ostream &operator<<(std::ostream &stream, const Color &value)
14021 {
14022 return stream << value.toString();
14023 }
14024
14025 private:
14026 void setFromString(const std::string &value);
14027
14028 constexpr ValueType static verifyValue(const ValueType &value)
14029 {
14030 return value == ValueType::rgb || value == ValueType::disabled
14031 ? value
14032 : throw std::invalid_argument{
14033 "Invalid value: Color{ "
14034 + std::to_string(static_cast<std::underlying_type<ValueType>::type>(value)) + " }"
14035 };
14036 }
14037
14038 Zivid::DataModel::Detail::Optional<ValueType> m_opt;
14039
14040 friend struct DataModel::Detail::Befriend<Color>;
14041 };
14042
14052
14053 // NOLINTNEXTLINE(clang-analyzer-optin.performance.Padding)
14055 {
14056 public:
14058 static constexpr DataModel::NodeType nodeType = DataModel::NodeType::leafValue;
14059
14061 static constexpr const char *path{ "Sampling/Pixel" };
14062
14064 static constexpr const char *name{ "Pixel" };
14065
14067 static constexpr const char *description{
14068 R"description(Set whether the full image sensor should be used with white projector light or
14069only specific color channels with corresponding projector light.
14070Using only a specific color channel will subsample pixels and give a
14071smaller resolution.
14072
14073Subsampling decreases the capture time, as less data will be captured and processed.
14074Picking a specific color channel can also help reduce noise and effects of ambient light.
14075Projecting blue light will in most cases give better data than red light.
14076)description"
14077 };
14078
14080 enum class ValueType
14081 {
14082 all,
14083 blueSubsample2x2,
14084 redSubsample2x2
14085 };
14086 static const Pixel all;
14088 static const Pixel redSubsample2x2;
14089
14091 static std::set<ValueType> validValues()
14092 {
14093 return { ValueType::all, ValueType::blueSubsample2x2, ValueType::redSubsample2x2 };
14094 }
14095
14097 Pixel() = default;
14098
14100 explicit constexpr Pixel(ValueType value)
14101 : m_opt{ verifyValue(value) }
14102 {}
14103
14109
14111 bool hasValue() const;
14112
14114 void reset();
14115
14117 std::string toString() const;
14118
14120 friend std::ostream &operator<<(std::ostream &stream, const Pixel::ValueType &value)
14121 {
14122 return stream << Pixel{ value }.toString();
14123 }
14124
14126 bool operator==(const Pixel &other) const
14127 {
14128 return m_opt == other.m_opt;
14129 }
14130
14132 bool operator!=(const Pixel &other) const
14133 {
14134 return m_opt != other.m_opt;
14135 }
14136
14138 friend std::ostream &operator<<(std::ostream &stream, const Pixel &value)
14139 {
14140 return stream << value.toString();
14141 }
14142
14143 private:
14144 void setFromString(const std::string &value);
14145
14146 constexpr ValueType static verifyValue(const ValueType &value)
14147 {
14148 return value == ValueType::all || value == ValueType::blueSubsample2x2
14149 || value == ValueType::redSubsample2x2
14150 ? value
14151 : throw std::invalid_argument{
14152 "Invalid value: Pixel{ "
14153 + std::to_string(static_cast<std::underlying_type<ValueType>::type>(value)) + " }"
14154 };
14155 }
14156
14157 Zivid::DataModel::Detail::Optional<ValueType> m_opt;
14158
14159 friend struct DataModel::Detail::Befriend<Pixel>;
14160 };
14161
14162 using Descendants = std::tuple<Settings::Sampling::Color, Settings::Sampling::Pixel>;
14163
14166
14179#ifndef NO_DOC
14180 template<
14181 typename... Args,
14182 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
14183 typename std::enable_if<
14184 Zivid::Detail::TypeTraits::AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::
14185 value,
14186 int>::type = 0>
14187#else
14188 template<typename... Args>
14189#endif
14190 explicit Sampling(Args &&...args)
14191 {
14192 using namespace Zivid::Detail::TypeTraits;
14193
14194 static_assert(
14195 AllArgsDecayedAreUnique<Args...>::value,
14196 "Found duplicate types among the arguments passed to Sampling(...). "
14197 "Types should be listed at most once.");
14198
14199 set(std::forward<Args>(args)...);
14200 }
14201
14213#ifndef NO_DOC
14214 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
14215#else
14216 template<typename... Args>
14217#endif
14218 void set(Args &&...args)
14219 {
14220 using namespace Zivid::Detail::TypeTraits;
14221
14222 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
14223 static_assert(
14224 AllArgsAreDescendantNodes::value, "All arguments passed to set(...) must be descendant nodes.");
14225
14226 static_assert(
14227 AllArgsDecayedAreUnique<Args...>::value,
14228 "Found duplicate types among the arguments passed to set(...). "
14229 "Types should be listed at most once.");
14230
14231 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
14232 }
14233
14246#ifndef NO_DOC
14247 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
14248#else
14249 template<typename... Args>
14250#endif
14251 Sampling copyWith(Args &&...args) const
14252 {
14253 using namespace Zivid::Detail::TypeTraits;
14254
14255 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
14256 static_assert(
14257 AllArgsAreDescendantNodes::value,
14258 "All arguments passed to copyWith(...) must be descendant nodes.");
14259
14260 static_assert(
14261 AllArgsDecayedAreUnique<Args...>::value,
14262 "Found duplicate types among the arguments passed to copyWith(...). "
14263 "Types should be listed at most once.");
14264
14265 auto copy{ *this };
14266 copy.set(std::forward<Args>(args)...);
14267 return copy;
14268 }
14269
14271 const Color &color() const
14272 {
14273 return m_color;
14274 }
14275
14278 {
14279 return m_color;
14280 }
14281
14283 Sampling &set(const Color &value)
14284 {
14285 m_color = value;
14286 return *this;
14287 }
14288
14290 const Pixel &pixel() const
14291 {
14292 return m_pixel;
14293 }
14294
14297 {
14298 return m_pixel;
14299 }
14300
14302 Sampling &set(const Pixel &value)
14303 {
14304 m_pixel = value;
14305 return *this;
14306 }
14307
14308 template<
14309 typename T,
14310 typename std::enable_if<std::is_same<T, Settings::Sampling::Color>::value, int>::type = 0>
14312 {
14313 return m_color;
14314 }
14315
14316 template<
14317 typename T,
14318 typename std::enable_if<std::is_same<T, Settings::Sampling::Pixel>::value, int>::type = 0>
14320 {
14321 return m_pixel;
14322 }
14323
14324 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
14326 {
14327 return m_color;
14328 }
14329
14330 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
14332 {
14333 return m_pixel;
14334 }
14335
14337 template<typename F>
14338 void forEach(const F &f) const
14339 {
14340 f(m_color);
14341 f(m_pixel);
14342 }
14343
14345 template<typename F>
14346 void forEach(const F &f)
14347 {
14348 f(m_color);
14349 f(m_pixel);
14350 }
14351
14353 bool operator==(const Sampling &other) const;
14354
14356 bool operator!=(const Sampling &other) const;
14357
14359 std::string toString() const;
14360
14362 friend std::ostream &operator<<(std::ostream &stream, const Sampling &value)
14363 {
14364 return stream << value.toString();
14365 }
14366
14367 private:
14368 void setFromString(const std::string &value);
14369
14370 void setFromString(const std::string &fullPath, const std::string &value);
14371
14372 std::string getString(const std::string &fullPath) const;
14373
14374 Color m_color;
14375 Pixel m_pixel;
14376
14377 friend struct DataModel::Detail::Befriend<Sampling>;
14378 };
14379
14380 using Descendants = std::tuple<
14447
14450
14452 explicit Settings(const std::string &fileName);
14453
14530#ifndef NO_DOC
14531 template<
14532 typename... Args,
14533 typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0,
14534 typename std::enable_if<
14535 Zivid::Detail::TypeTraits::AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>::value,
14536 int>::type = 0>
14537#else
14538 template<typename... Args>
14539#endif
14540 explicit Settings(Args &&...args)
14541 {
14542 using namespace Zivid::Detail::TypeTraits;
14543
14544 static_assert(
14545 AllArgsDecayedAreUnique<Args...>::value,
14546 "Found duplicate types among the arguments passed to Settings(...). "
14547 "Types should be listed at most once.");
14548
14549 set(std::forward<Args>(args)...);
14550 }
14551
14627#ifndef NO_DOC
14628 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 2, int>::type = 0>
14629#else
14630 template<typename... Args>
14631#endif
14632 void set(Args &&...args)
14633 {
14634 using namespace Zivid::Detail::TypeTraits;
14635
14636 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
14637 static_assert(
14638 AllArgsAreDescendantNodes::value, "All arguments passed to set(...) must be descendant nodes.");
14639
14640 static_assert(
14641 AllArgsDecayedAreUnique<Args...>::value,
14642 "Found duplicate types among the arguments passed to set(...). "
14643 "Types should be listed at most once.");
14644
14645 Zivid::DataModel::Detail::invokeSetWithEachArgument(*this, std::forward<Args>(args)...);
14646 }
14647
14724#ifndef NO_DOC
14725 template<typename... Args, typename std::enable_if<sizeof...(Args) >= 1, int>::type = 0>
14726#else
14727 template<typename... Args>
14728#endif
14729 Settings copyWith(Args &&...args) const
14730 {
14731 using namespace Zivid::Detail::TypeTraits;
14732
14733 using AllArgsAreDescendantNodes = AllArgsAreInTuple<Descendants, typename std::decay<Args>::type...>;
14734 static_assert(
14735 AllArgsAreDescendantNodes::value, "All arguments passed to copyWith(...) must be descendant nodes.");
14736
14737 static_assert(
14738 AllArgsDecayedAreUnique<Args...>::value,
14739 "Found duplicate types among the arguments passed to copyWith(...). "
14740 "Types should be listed at most once.");
14741
14742 auto copy{ *this };
14743 copy.set(std::forward<Args>(args)...);
14744 return copy;
14745 }
14746
14749 {
14750 return m_acquisitions;
14751 }
14752
14755 {
14756 return m_acquisitions;
14757 }
14758
14761 {
14762 m_acquisitions = value;
14763 return *this;
14764 }
14765
14768 {
14769 return m_diagnostics;
14770 }
14771
14774 {
14775 return m_diagnostics;
14776 }
14777
14779 Settings &set(const Diagnostics &value)
14780 {
14781 m_diagnostics = value;
14782 return *this;
14783 }
14784
14787 {
14788 m_diagnostics.set(value);
14789 return *this;
14790 }
14791
14794 {
14795 return m_experimental;
14796 }
14797
14800 {
14801 return m_experimental;
14802 }
14803
14806 {
14807 m_experimental = value;
14808 return *this;
14809 }
14810
14813 {
14814 m_experimental.set(value);
14815 return *this;
14816 }
14817
14819 const Processing &processing() const
14820 {
14821 return m_processing;
14822 }
14823
14826 {
14827 return m_processing;
14828 }
14829
14831 Settings &set(const Processing &value)
14832 {
14833 m_processing = value;
14834 return *this;
14835 }
14836
14839 {
14840 m_processing.set(value);
14841 return *this;
14842 }
14843
14846 {
14847 m_processing.set(value);
14848 return *this;
14849 }
14850
14853 {
14854 m_processing.set(value);
14855 return *this;
14856 }
14857
14860 {
14861 m_processing.set(value);
14862 return *this;
14863 }
14864
14867 {
14868 m_processing.set(value);
14869 return *this;
14870 }
14871
14874 {
14875 m_processing.set(value);
14876 return *this;
14877 }
14878
14881 {
14882 m_processing.set(value);
14883 return *this;
14884 }
14885
14888 {
14889 m_processing.set(value);
14890 return *this;
14891 }
14892
14895 {
14896 m_processing.set(value);
14897 return *this;
14898 }
14899
14902 {
14903 m_processing.set(value);
14904 return *this;
14905 }
14906
14909 {
14910 m_processing.set(value);
14911 return *this;
14912 }
14913
14916 {
14917 m_processing.set(value);
14918 return *this;
14919 }
14920
14923 {
14924 m_processing.set(value);
14925 return *this;
14926 }
14927
14930 {
14931 m_processing.set(value);
14932 return *this;
14933 }
14934
14937 {
14938 m_processing.set(value);
14939 return *this;
14940 }
14941
14944 {
14945 m_processing.set(value);
14946 return *this;
14947 }
14948
14951 {
14952 m_processing.set(value);
14953 return *this;
14954 }
14955
14958 {
14959 m_processing.set(value);
14960 return *this;
14961 }
14962
14965 {
14966 m_processing.set(value);
14967 return *this;
14968 }
14969
14972 {
14973 m_processing.set(value);
14974 return *this;
14975 }
14976
14979 {
14980 m_processing.set(value);
14981 return *this;
14982 }
14983
14986 {
14987 m_processing.set(value);
14988 return *this;
14989 }
14990
14993 {
14994 m_processing.set(value);
14995 return *this;
14996 }
14997
15000 {
15001 m_processing.set(value);
15002 return *this;
15003 }
15004
15007 {
15008 m_processing.set(value);
15009 return *this;
15010 }
15011
15014 {
15015 m_processing.set(value);
15016 return *this;
15017 }
15018
15021 {
15022 m_processing.set(value);
15023 return *this;
15024 }
15025
15028 {
15029 m_processing.set(value);
15030 return *this;
15031 }
15032
15035 {
15036 m_processing.set(value);
15037 return *this;
15038 }
15039
15042 {
15043 m_processing.set(value);
15044 return *this;
15045 }
15046
15049 {
15050 m_processing.set(value);
15051 return *this;
15052 }
15053
15056 {
15057 m_processing.set(value);
15058 return *this;
15059 }
15060
15063 {
15064 m_processing.set(value);
15065 return *this;
15066 }
15067
15070 {
15071 m_processing.set(value);
15072 return *this;
15073 }
15074
15077 {
15078 m_processing.set(value);
15079 return *this;
15080 }
15081
15084 {
15085 m_processing.set(value);
15086 return *this;
15087 }
15088
15091 {
15092 m_processing.set(value);
15093 return *this;
15094 }
15095
15098 {
15099 m_processing.set(value);
15100 return *this;
15101 }
15102
15105 {
15106 m_processing.set(value);
15107 return *this;
15108 }
15109
15112 {
15113 m_processing.set(value);
15114 return *this;
15115 }
15116
15119 {
15120 m_processing.set(value);
15121 return *this;
15122 }
15123
15126 {
15127 m_processing.set(value);
15128 return *this;
15129 }
15130
15133 {
15134 m_processing.set(value);
15135 return *this;
15136 }
15137
15140 {
15141 m_processing.set(value);
15142 return *this;
15143 }
15144
15147 {
15148 m_processing.set(value);
15149 return *this;
15150 }
15151
15154 {
15155 m_processing.set(value);
15156 return *this;
15157 }
15158
15161 {
15162 m_processing.set(value);
15163 return *this;
15164 }
15165
15168 {
15169 return m_regionOfInterest;
15170 }
15171
15174 {
15175 return m_regionOfInterest;
15176 }
15177
15180 {
15181 m_regionOfInterest = value;
15182 return *this;
15183 }
15184
15187 {
15188 m_regionOfInterest.set(value);
15189 return *this;
15190 }
15191
15194 {
15195 m_regionOfInterest.set(value);
15196 return *this;
15197 }
15198
15201 {
15202 m_regionOfInterest.set(value);
15203 return *this;
15204 }
15205
15208 {
15209 m_regionOfInterest.set(value);
15210 return *this;
15211 }
15212
15215 {
15216 m_regionOfInterest.set(value);
15217 return *this;
15218 }
15219
15222 {
15223 m_regionOfInterest.set(value);
15224 return *this;
15225 }
15226
15229 {
15230 m_regionOfInterest.set(value);
15231 return *this;
15232 }
15233
15236 {
15237 m_regionOfInterest.set(value);
15238 return *this;
15239 }
15240
15243 {
15244 m_regionOfInterest.set(value);
15245 return *this;
15246 }
15247
15249 const Sampling &sampling() const
15250 {
15251 return m_sampling;
15252 }
15253
15256 {
15257 return m_sampling;
15258 }
15259
15261 Settings &set(const Sampling &value)
15262 {
15263 m_sampling = value;
15264 return *this;
15265 }
15266
15269 {
15270 m_sampling.set(value);
15271 return *this;
15272 }
15273
15276 {
15277 m_sampling.set(value);
15278 return *this;
15279 }
15280
15281 template<typename T, typename std::enable_if<std::is_same<T, Settings::Acquisitions>::value, int>::type = 0>
15283 {
15284 return m_acquisitions;
15285 }
15286
15287 template<typename T, typename std::enable_if<std::is_same<T, Settings::Diagnostics>::value, int>::type = 0>
15289 {
15290 return m_diagnostics;
15291 }
15292
15293 template<
15294 typename T,
15295 typename std::enable_if<std::is_same<T, Settings::Diagnostics::Enabled>::value, int>::type = 0>
15297 {
15298 return m_diagnostics.get<Settings::Diagnostics::Enabled>();
15299 }
15300
15301 template<typename T, typename std::enable_if<std::is_same<T, Settings::Experimental>::value, int>::type = 0>
15303 {
15304 return m_experimental;
15305 }
15306
15307 template<
15308 typename T,
15309 typename std::enable_if<std::is_same<T, Settings::Experimental::Engine>::value, int>::type = 0>
15311 {
15312 return m_experimental.get<Settings::Experimental::Engine>();
15313 }
15314
15315 template<typename T, typename std::enable_if<std::is_same<T, Settings::Processing>::value, int>::type = 0>
15317 {
15318 return m_processing;
15319 }
15320
15321 template<
15322 typename T,
15323 typename std::enable_if<std::is_same<T, Settings::Processing::Color>::value, int>::type = 0>
15325 {
15326 return m_processing.get<Settings::Processing::Color>();
15327 }
15328
15329 template<
15330 typename T,
15331 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Balance>::value, int>::type = 0>
15333 {
15334 return m_processing.get<Settings::Processing::Color::Balance>();
15335 }
15336
15337 template<
15338 typename T,
15339 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Balance::Blue>::value, int>::type = 0>
15341 {
15342 return m_processing.get<Settings::Processing::Color::Balance::Blue>();
15343 }
15344
15345 template<
15346 typename T,
15347 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Balance::Green>::value, int>::type = 0>
15349 {
15350 return m_processing.get<Settings::Processing::Color::Balance::Green>();
15351 }
15352
15353 template<
15354 typename T,
15355 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Balance::Red>::value, int>::type = 0>
15357 {
15358 return m_processing.get<Settings::Processing::Color::Balance::Red>();
15359 }
15360
15361 template<
15362 typename T,
15363 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Experimental>::value, int>::type = 0>
15365 {
15366 return m_processing.get<Settings::Processing::Color::Experimental>();
15367 }
15368
15369 template<
15370 typename T,
15371 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Experimental::Mode>::value, int>::
15372 type = 0>
15374 {
15375 return m_processing.get<Settings::Processing::Color::Experimental::Mode>();
15376 }
15377
15378 template<
15379 typename T,
15380 typename std::enable_if<std::is_same<T, Settings::Processing::Color::Gamma>::value, int>::type = 0>
15382 {
15383 return m_processing.get<Settings::Processing::Color::Gamma>();
15384 }
15385
15386 template<
15387 typename T,
15388 typename std::enable_if<std::is_same<T, Settings::Processing::Filters>::value, int>::type = 0>
15390 {
15391 return m_processing.get<Settings::Processing::Filters>();
15392 }
15393
15394 template<
15395 typename T,
15396 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Cluster>::value, int>::type = 0>
15398 {
15399 return m_processing.get<Settings::Processing::Filters::Cluster>();
15400 }
15401
15402 template<
15403 typename T,
15404 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Cluster::Removal>::value, int>::
15405 type = 0>
15407 {
15409 }
15410
15411 template<
15412 typename T,
15413 typename std::enable_if<
15414 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::Enabled>::value,
15415 int>::type = 0>
15417 {
15419 }
15420
15421 template<
15422 typename T,
15423 typename std::enable_if<
15424 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance>::value,
15425 int>::type = 0>
15427 {
15429 }
15430
15431 template<
15432 typename T,
15433 typename std::enable_if<
15434 std::is_same<T, Settings::Processing::Filters::Cluster::Removal::MinArea>::value,
15435 int>::type = 0>
15437 {
15439 }
15440
15441 template<
15442 typename T,
15443 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Experimental>::value, int>::type = 0>
15445 {
15446 return m_processing.get<Settings::Processing::Filters::Experimental>();
15447 }
15448
15449 template<
15450 typename T,
15451 typename std::enable_if<
15452 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion>::value,
15453 int>::type = 0>
15455 {
15457 }
15458
15459 template<
15460 typename T,
15461 typename std::enable_if<
15462 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction>::value,
15463 int>::type = 0>
15465 {
15467 }
15468
15469 template<
15470 typename T,
15471 typename std::enable_if<
15472 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled>::
15473 value,
15474 int>::type = 0>
15476 {
15477 return m_processing
15479 }
15480
15481 template<
15482 typename T,
15483 typename std::enable_if<
15484 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Strength>::
15485 value,
15486 int>::type = 0>
15488 {
15489 return m_processing
15491 }
15492
15493 template<
15494 typename T,
15495 typename std::enable_if<
15496 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal>::value,
15497 int>::type = 0>
15499 {
15501 }
15502
15503 template<
15504 typename T,
15505 typename std::enable_if<
15506 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled>::
15507 value,
15508 int>::type = 0>
15510 {
15511 return m_processing
15513 }
15514
15515 template<
15516 typename T,
15517 typename std::enable_if<
15518 std::is_same<T, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold>::
15519 value,
15520 int>::type = 0>
15522 {
15523 return m_processing
15525 }
15526
15527 template<
15528 typename T,
15529 typename std::enable_if<
15530 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling>::value,
15531 int>::type = 0>
15533 {
15535 }
15536
15537 template<
15538 typename T,
15539 typename std::enable_if<
15540 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::Enabled>::value,
15541 int>::type = 0>
15543 {
15545 }
15546
15547 template<
15548 typename T,
15549 typename std::enable_if<
15550 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::HoleSize>::value,
15551 int>::type = 0>
15553 {
15555 }
15556
15557 template<
15558 typename T,
15559 typename std::enable_if<
15560 std::is_same<T, Settings::Processing::Filters::Experimental::HoleFilling::Strictness>::value,
15561 int>::type = 0>
15563 {
15565 }
15566
15567 template<
15568 typename T,
15569 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Noise>::value, int>::type = 0>
15571 {
15572 return m_processing.get<Settings::Processing::Filters::Noise>();
15573 }
15574
15575 template<
15576 typename T,
15577 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Noise::Removal>::value, int>::type =
15578 0>
15580 {
15582 }
15583
15584 template<
15585 typename T,
15586 typename std::enable_if<
15587 std::is_same<T, Settings::Processing::Filters::Noise::Removal::Enabled>::value,
15588 int>::type = 0>
15590 {
15592 }
15593
15594 template<
15595 typename T,
15596 typename std::enable_if<
15597 std::is_same<T, Settings::Processing::Filters::Noise::Removal::Threshold>::value,
15598 int>::type = 0>
15600 {
15602 }
15603
15604 template<
15605 typename T,
15606 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Noise::Repair>::value, int>::type =
15607 0>
15609 {
15611 }
15612
15613 template<
15614 typename T,
15615 typename std::
15616 enable_if<std::is_same<T, Settings::Processing::Filters::Noise::Repair::Enabled>::value, int>::type = 0>
15618 {
15620 }
15621
15622 template<
15623 typename T,
15624 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Noise::Suppression>::value, int>::
15625 type = 0>
15627 {
15629 }
15630
15631 template<
15632 typename T,
15633 typename std::enable_if<
15634 std::is_same<T, Settings::Processing::Filters::Noise::Suppression::Enabled>::value,
15635 int>::type = 0>
15637 {
15639 }
15640
15641 template<
15642 typename T,
15643 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Outlier>::value, int>::type = 0>
15645 {
15646 return m_processing.get<Settings::Processing::Filters::Outlier>();
15647 }
15648
15649 template<
15650 typename T,
15651 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Outlier::Removal>::value, int>::
15652 type = 0>
15654 {
15656 }
15657
15658 template<
15659 typename T,
15660 typename std::enable_if<
15661 std::is_same<T, Settings::Processing::Filters::Outlier::Removal::Enabled>::value,
15662 int>::type = 0>
15664 {
15666 }
15667
15668 template<
15669 typename T,
15670 typename std::enable_if<
15671 std::is_same<T, Settings::Processing::Filters::Outlier::Removal::Threshold>::value,
15672 int>::type = 0>
15674 {
15676 }
15677
15678 template<
15679 typename T,
15680 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Reflection>::value, int>::type = 0>
15682 {
15683 return m_processing.get<Settings::Processing::Filters::Reflection>();
15684 }
15685
15686 template<
15687 typename T,
15688 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Reflection::Removal>::value, int>::
15689 type = 0>
15691 {
15693 }
15694
15695 template<
15696 typename T,
15697 typename std::enable_if<
15698 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Enabled>::value,
15699 int>::type = 0>
15701 {
15703 }
15704
15705 template<
15706 typename T,
15707 typename std::enable_if<
15708 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Experimental>::value,
15709 int>::type = 0>
15711 {
15713 }
15714
15715 template<
15716 typename T,
15717 typename std::enable_if<
15718 std::is_same<T, Settings::Processing::Filters::Reflection::Removal::Experimental::Mode>::value,
15719 int>::type = 0>
15721 {
15723 }
15724
15725 template<
15726 typename T,
15727 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Smoothing>::value, int>::type = 0>
15729 {
15730 return m_processing.get<Settings::Processing::Filters::Smoothing>();
15731 }
15732
15733 template<
15734 typename T,
15735 typename std::enable_if<std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian>::value, int>::
15736 type = 0>
15738 {
15740 }
15741
15742 template<
15743 typename T,
15744 typename std::enable_if<
15745 std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian::Enabled>::value,
15746 int>::type = 0>
15748 {
15750 }
15751
15752 template<
15753 typename T,
15754 typename std::enable_if<
15755 std::is_same<T, Settings::Processing::Filters::Smoothing::Gaussian::Sigma>::value,
15756 int>::type = 0>
15758 {
15760 }
15761
15762 template<typename T, typename std::enable_if<std::is_same<T, Settings::RegionOfInterest>::value, int>::type = 0>
15764 {
15765 return m_regionOfInterest;
15766 }
15767
15768 template<
15769 typename T,
15770 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box>::value, int>::type = 0>
15772 {
15773 return m_regionOfInterest.get<Settings::RegionOfInterest::Box>();
15774 }
15775
15776 template<
15777 typename T,
15778 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::Enabled>::value, int>::type = 0>
15780 {
15781 return m_regionOfInterest.get<Settings::RegionOfInterest::Box::Enabled>();
15782 }
15783
15784 template<
15785 typename T,
15786 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::Extents>::value, int>::type = 0>
15788 {
15789 return m_regionOfInterest.get<Settings::RegionOfInterest::Box::Extents>();
15790 }
15791
15792 template<
15793 typename T,
15794 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::PointA>::value, int>::type = 0>
15796 {
15797 return m_regionOfInterest.get<Settings::RegionOfInterest::Box::PointA>();
15798 }
15799
15800 template<
15801 typename T,
15802 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::PointB>::value, int>::type = 0>
15804 {
15805 return m_regionOfInterest.get<Settings::RegionOfInterest::Box::PointB>();
15806 }
15807
15808 template<
15809 typename T,
15810 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Box::PointO>::value, int>::type = 0>
15812 {
15813 return m_regionOfInterest.get<Settings::RegionOfInterest::Box::PointO>();
15814 }
15815
15816 template<
15817 typename T,
15818 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Depth>::value, int>::type = 0>
15820 {
15821 return m_regionOfInterest.get<Settings::RegionOfInterest::Depth>();
15822 }
15823
15824 template<
15825 typename T,
15826 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Depth::Enabled>::value, int>::type = 0>
15828 {
15829 return m_regionOfInterest.get<Settings::RegionOfInterest::Depth::Enabled>();
15830 }
15831
15832 template<
15833 typename T,
15834 typename std::enable_if<std::is_same<T, Settings::RegionOfInterest::Depth::Range>::value, int>::type = 0>
15836 {
15837 return m_regionOfInterest.get<Settings::RegionOfInterest::Depth::Range>();
15838 }
15839
15840 template<typename T, typename std::enable_if<std::is_same<T, Settings::Sampling>::value, int>::type = 0>
15842 {
15843 return m_sampling;
15844 }
15845
15846 template<typename T, typename std::enable_if<std::is_same<T, Settings::Sampling::Color>::value, int>::type = 0>
15848 {
15849 return m_sampling.get<Settings::Sampling::Color>();
15850 }
15851
15852 template<typename T, typename std::enable_if<std::is_same<T, Settings::Sampling::Pixel>::value, int>::type = 0>
15854 {
15855 return m_sampling.get<Settings::Sampling::Pixel>();
15856 }
15857
15858 template<size_t i, typename std::enable_if<i == 0, int>::type = 0>
15860 {
15861 return m_acquisitions;
15862 }
15863
15864 template<size_t i, typename std::enable_if<i == 1, int>::type = 0>
15866 {
15867 return m_diagnostics;
15868 }
15869
15870 template<size_t i, typename std::enable_if<i == 2, int>::type = 0>
15872 {
15873 return m_experimental;
15874 }
15875
15876 template<size_t i, typename std::enable_if<i == 3, int>::type = 0>
15878 {
15879 return m_processing;
15880 }
15881
15882 template<size_t i, typename std::enable_if<i == 4, int>::type = 0>
15884 {
15885 return m_regionOfInterest;
15886 }
15887
15888 template<size_t i, typename std::enable_if<i == 5, int>::type = 0>
15890 {
15891 return m_sampling;
15892 }
15893
15895 template<typename F>
15896 void forEach(const F &f) const
15897 {
15898 f(m_acquisitions);
15899 f(m_diagnostics);
15900 f(m_experimental);
15901 f(m_processing);
15902 f(m_regionOfInterest);
15903 f(m_sampling);
15904 }
15905
15907 template<typename F>
15908 void forEach(const F &f)
15909 {
15910 f(m_acquisitions);
15911 f(m_diagnostics);
15912 f(m_experimental);
15913 f(m_processing);
15914 f(m_regionOfInterest);
15915 f(m_sampling);
15916 }
15917
15919 bool operator==(const Settings &other) const;
15920
15922 bool operator!=(const Settings &other) const;
15923
15925 std::string toString() const;
15926
15928 friend std::ostream &operator<<(std::ostream &stream, const Settings &value)
15929 {
15930 return stream << value.toString();
15931 }
15932
15934 void save(const std::string &fileName) const;
15935
15937 void load(const std::string &fileName);
15938
15939 private:
15940 void setFromString(const std::string &value);
15941
15942 void setFromString(const std::string &fullPath, const std::string &value);
15943
15944 std::string getString(const std::string &fullPath) const;
15945
15946 Acquisitions m_acquisitions;
15947 Diagnostics m_diagnostics;
15948 Experimental m_experimental;
15949 Processing m_processing;
15950 RegionOfInterest m_regionOfInterest;
15951 Sampling m_sampling;
15952
15953 friend struct DataModel::Detail::Befriend<Settings>;
15954 };
15955
15956#ifndef NO_DOC
15958 namespace Detail
15959 {
15960 ZIVID_CORE_EXPORT void save(const Settings &dataModel, std::ostream &ostream);
15961 ZIVID_CORE_EXPORT void load(Settings &dataModel, std::istream &istream);
15962 } // namespace Detail
15963#endif
15964
15965#ifndef NO_DOC
15966 template<>
15967 struct Settings::Version<21>
15968 {
15969 using Type = Settings;
15970 };
15971#endif
15972
15973} // namespace Zivid
15974
15975#ifdef _MSC_VER
15976# pragma warning(pop)
15977#endif
15978
15979#ifndef NO_DOC
15980# if !(defined(_MSC_VER) && (_MSC_VER <= 1900))
15981namespace std // NOLINT
15982{
15983
15984 template<>
15985 struct tuple_size<Zivid::Settings::Diagnostics> : integral_constant<size_t, 1>
15986 {};
15987
15988 template<size_t i>
15989 struct tuple_element<i, Zivid::Settings::Diagnostics>
15990 {
15991 static_assert(i < tuple_size<Zivid::Settings::Diagnostics>::value, "Index must be less than 1");
15992
15993 using type // NOLINT
15994 = decltype(declval<Zivid::Settings::Diagnostics>().get<i>());
15995 };
15996
15997 template<>
15998 struct tuple_size<Zivid::Settings::Experimental> : integral_constant<size_t, 1>
15999 {};
16000
16001 template<size_t i>
16002 struct tuple_element<i, Zivid::Settings::Experimental>
16003 {
16004 static_assert(i < tuple_size<Zivid::Settings::Experimental>::value, "Index must be less than 1");
16005
16006 using type // NOLINT
16007 = decltype(declval<Zivid::Settings::Experimental>().get<i>());
16008 };
16009
16010 template<>
16011 struct tuple_size<Zivid::Settings::Processing> : integral_constant<size_t, 2>
16012 {};
16013
16014 template<size_t i>
16015 struct tuple_element<i, Zivid::Settings::Processing>
16016 {
16017 static_assert(i < tuple_size<Zivid::Settings::Processing>::value, "Index must be less than 2");
16018
16019 using type // NOLINT
16020 = decltype(declval<Zivid::Settings::Processing>().get<i>());
16021 };
16022
16023 template<>
16024 struct tuple_size<Zivid::Settings::Processing::Color> : integral_constant<size_t, 3>
16025 {};
16026
16027 template<size_t i>
16028 struct tuple_element<i, Zivid::Settings::Processing::Color>
16029 {
16030 static_assert(i < tuple_size<Zivid::Settings::Processing::Color>::value, "Index must be less than 3");
16031
16032 using type // NOLINT
16033 = decltype(declval<Zivid::Settings::Processing::Color>().get<i>());
16034 };
16035
16036 template<>
16037 struct tuple_size<Zivid::Settings::Processing::Color::Balance> : integral_constant<size_t, 3>
16038 {};
16039
16040 template<size_t i>
16041 struct tuple_element<i, Zivid::Settings::Processing::Color::Balance>
16042 {
16043 static_assert(i < tuple_size<Zivid::Settings::Processing::Color::Balance>::value, "Index must be less than 3");
16044
16045 using type // NOLINT
16046 = decltype(declval<Zivid::Settings::Processing::Color::Balance>().get<i>());
16047 };
16048
16049 template<>
16050 struct tuple_size<Zivid::Settings::Processing::Color::Experimental> : integral_constant<size_t, 1>
16051 {};
16052
16053 template<size_t i>
16054 struct tuple_element<i, Zivid::Settings::Processing::Color::Experimental>
16055 {
16056 static_assert(
16057 i < tuple_size<Zivid::Settings::Processing::Color::Experimental>::value,
16058 "Index must be less than 1");
16059
16060 using type // NOLINT
16061 = decltype(declval<Zivid::Settings::Processing::Color::Experimental>().get<i>());
16062 };
16063
16064 template<>
16065 struct tuple_size<Zivid::Settings::Processing::Filters> : integral_constant<size_t, 6>
16066 {};
16067
16068 template<size_t i>
16069 struct tuple_element<i, Zivid::Settings::Processing::Filters>
16070 {
16071 static_assert(i < tuple_size<Zivid::Settings::Processing::Filters>::value, "Index must be less than 6");
16072
16073 using type // NOLINT
16074 = decltype(declval<Zivid::Settings::Processing::Filters>().get<i>());
16075 };
16076
16077 template<>
16078 struct tuple_size<Zivid::Settings::Processing::Filters::Cluster> : integral_constant<size_t, 1>
16079 {};
16080
16081 template<size_t i>
16082 struct tuple_element<i, Zivid::Settings::Processing::Filters::Cluster>
16083 {
16084 static_assert(
16085 i < tuple_size<Zivid::Settings::Processing::Filters::Cluster>::value,
16086 "Index must be less than 1");
16087
16088 using type // NOLINT
16089 = decltype(declval<Zivid::Settings::Processing::Filters::Cluster>().get<i>());
16090 };
16091
16092 template<>
16093 struct tuple_size<Zivid::Settings::Processing::Filters::Cluster::Removal> : integral_constant<size_t, 3>
16094 {};
16095
16096 template<size_t i>
16097 struct tuple_element<i, Zivid::Settings::Processing::Filters::Cluster::Removal>
16098 {
16099 static_assert(
16100 i < tuple_size<Zivid::Settings::Processing::Filters::Cluster::Removal>::value,
16101 "Index must be less than 3");
16102
16103 using type // NOLINT
16104 = decltype(declval<Zivid::Settings::Processing::Filters::Cluster::Removal>().get<i>());
16105 };
16106
16107 template<>
16108 struct tuple_size<Zivid::Settings::Processing::Filters::Experimental> : integral_constant<size_t, 2>
16109 {};
16110
16111 template<size_t i>
16112 struct tuple_element<i, Zivid::Settings::Processing::Filters::Experimental>
16113 {
16114 static_assert(
16115 i < tuple_size<Zivid::Settings::Processing::Filters::Experimental>::value,
16116 "Index must be less than 2");
16117
16118 using type // NOLINT
16119 = decltype(declval<Zivid::Settings::Processing::Filters::Experimental>().get<i>());
16120 };
16121
16122 template<>
16123 struct tuple_size<Zivid::Settings::Processing::Filters::Experimental::ContrastDistortion>
16124 : integral_constant<size_t, 2>
16125 {};
16126
16127 template<size_t i>
16128 struct tuple_element<i, Zivid::Settings::Processing::Filters::Experimental::ContrastDistortion>
16129 {
16130 static_assert(
16131 i < tuple_size<Zivid::Settings::Processing::Filters::Experimental::ContrastDistortion>::value,
16132 "Index must be less than 2");
16133
16134 using type // NOLINT
16135 = decltype(declval<Zivid::Settings::Processing::Filters::Experimental::ContrastDistortion>().get<i>());
16136 };
16137
16138 template<>
16139 struct tuple_size<Zivid::Settings::Processing::Filters::Experimental::ContrastDistortion::Correction>
16140 : integral_constant<size_t, 2>
16141 {};
16142
16143 template<size_t i>
16144 struct tuple_element<i, Zivid::Settings::Processing::Filters::Experimental::ContrastDistortion::Correction>
16145 {
16146 static_assert(
16147 i < tuple_size<Zivid::Settings::Processing::Filters::Experimental::ContrastDistortion::Correction>::value,
16148 "Index must be less than 2");
16149
16150 using type // NOLINT
16151 = decltype(declval<Zivid::Settings::Processing::Filters::Experimental::ContrastDistortion::Correction>()
16152 .get<i>());
16153 };
16154
16155 template<>
16156 struct tuple_size<Zivid::Settings::Processing::Filters::Experimental::ContrastDistortion::Removal>
16157 : integral_constant<size_t, 2>
16158 {};
16159
16160 template<size_t i>
16161 struct tuple_element<i, Zivid::Settings::Processing::Filters::Experimental::ContrastDistortion::Removal>
16162 {
16163 static_assert(
16164 i < tuple_size<Zivid::Settings::Processing::Filters::Experimental::ContrastDistortion::Removal>::value,
16165 "Index must be less than 2");
16166
16167 using type // NOLINT
16168 = decltype(declval<Zivid::Settings::Processing::Filters::Experimental::ContrastDistortion::Removal>()
16169 .get<i>());
16170 };
16171
16172 template<>
16173 struct tuple_size<Zivid::Settings::Processing::Filters::Experimental::HoleFilling> : integral_constant<size_t, 3>
16174 {};
16175
16176 template<size_t i>
16177 struct tuple_element<i, Zivid::Settings::Processing::Filters::Experimental::HoleFilling>
16178 {
16179 static_assert(
16180 i < tuple_size<Zivid::Settings::Processing::Filters::Experimental::HoleFilling>::value,
16181 "Index must be less than 3");
16182
16183 using type // NOLINT
16184 = decltype(declval<Zivid::Settings::Processing::Filters::Experimental::HoleFilling>().get<i>());
16185 };
16186
16187 template<>
16188 struct tuple_size<Zivid::Settings::Processing::Filters::Noise> : integral_constant<size_t, 3>
16189 {};
16190
16191 template<size_t i>
16192 struct tuple_element<i, Zivid::Settings::Processing::Filters::Noise>
16193 {
16194 static_assert(i < tuple_size<Zivid::Settings::Processing::Filters::Noise>::value, "Index must be less than 3");
16195
16196 using type // NOLINT
16197 = decltype(declval<Zivid::Settings::Processing::Filters::Noise>().get<i>());
16198 };
16199
16200 template<>
16201 struct tuple_size<Zivid::Settings::Processing::Filters::Noise::Removal> : integral_constant<size_t, 2>
16202 {};
16203
16204 template<size_t i>
16205 struct tuple_element<i, Zivid::Settings::Processing::Filters::Noise::Removal>
16206 {
16207 static_assert(
16208 i < tuple_size<Zivid::Settings::Processing::Filters::Noise::Removal>::value,
16209 "Index must be less than 2");
16210
16211 using type // NOLINT
16212 = decltype(declval<Zivid::Settings::Processing::Filters::Noise::Removal>().get<i>());
16213 };
16214
16215 template<>
16216 struct tuple_size<Zivid::Settings::Processing::Filters::Noise::Repair> : integral_constant<size_t, 1>
16217 {};
16218
16219 template<size_t i>
16220 struct tuple_element<i, Zivid::Settings::Processing::Filters::Noise::Repair>
16221 {
16222 static_assert(
16223 i < tuple_size<Zivid::Settings::Processing::Filters::Noise::Repair>::value,
16224 "Index must be less than 1");
16225
16226 using type // NOLINT
16227 = decltype(declval<Zivid::Settings::Processing::Filters::Noise::Repair>().get<i>());
16228 };
16229
16230 template<>
16231 struct tuple_size<Zivid::Settings::Processing::Filters::Noise::Suppression> : integral_constant<size_t, 1>
16232 {};
16233
16234 template<size_t i>
16235 struct tuple_element<i, Zivid::Settings::Processing::Filters::Noise::Suppression>
16236 {
16237 static_assert(
16238 i < tuple_size<Zivid::Settings::Processing::Filters::Noise::Suppression>::value,
16239 "Index must be less than 1");
16240
16241 using type // NOLINT
16242 = decltype(declval<Zivid::Settings::Processing::Filters::Noise::Suppression>().get<i>());
16243 };
16244
16245 template<>
16246 struct tuple_size<Zivid::Settings::Processing::Filters::Outlier> : integral_constant<size_t, 1>
16247 {};
16248
16249 template<size_t i>
16250 struct tuple_element<i, Zivid::Settings::Processing::Filters::Outlier>
16251 {
16252 static_assert(
16253 i < tuple_size<Zivid::Settings::Processing::Filters::Outlier>::value,
16254 "Index must be less than 1");
16255
16256 using type // NOLINT
16257 = decltype(declval<Zivid::Settings::Processing::Filters::Outlier>().get<i>());
16258 };
16259
16260 template<>
16261 struct tuple_size<Zivid::Settings::Processing::Filters::Outlier::Removal> : integral_constant<size_t, 2>
16262 {};
16263
16264 template<size_t i>
16265 struct tuple_element<i, Zivid::Settings::Processing::Filters::Outlier::Removal>
16266 {
16267 static_assert(
16268 i < tuple_size<Zivid::Settings::Processing::Filters::Outlier::Removal>::value,
16269 "Index must be less than 2");
16270
16271 using type // NOLINT
16272 = decltype(declval<Zivid::Settings::Processing::Filters::Outlier::Removal>().get<i>());
16273 };
16274
16275 template<>
16276 struct tuple_size<Zivid::Settings::Processing::Filters::Reflection> : integral_constant<size_t, 1>
16277 {};
16278
16279 template<size_t i>
16280 struct tuple_element<i, Zivid::Settings::Processing::Filters::Reflection>
16281 {
16282 static_assert(
16283 i < tuple_size<Zivid::Settings::Processing::Filters::Reflection>::value,
16284 "Index must be less than 1");
16285
16286 using type // NOLINT
16287 = decltype(declval<Zivid::Settings::Processing::Filters::Reflection>().get<i>());
16288 };
16289
16290 template<>
16291 struct tuple_size<Zivid::Settings::Processing::Filters::Reflection::Removal> : integral_constant<size_t, 2>
16292 {};
16293
16294 template<size_t i>
16295 struct tuple_element<i, Zivid::Settings::Processing::Filters::Reflection::Removal>
16296 {
16297 static_assert(
16298 i < tuple_size<Zivid::Settings::Processing::Filters::Reflection::Removal>::value,
16299 "Index must be less than 2");
16300
16301 using type // NOLINT
16302 = decltype(declval<Zivid::Settings::Processing::Filters::Reflection::Removal>().get<i>());
16303 };
16304
16305 template<>
16306 struct tuple_size<Zivid::Settings::Processing::Filters::Reflection::Removal::Experimental>
16307 : integral_constant<size_t, 1>
16308 {};
16309
16310 template<size_t i>
16311 struct tuple_element<i, Zivid::Settings::Processing::Filters::Reflection::Removal::Experimental>
16312 {
16313 static_assert(
16314 i < tuple_size<Zivid::Settings::Processing::Filters::Reflection::Removal::Experimental>::value,
16315 "Index must be less than 1");
16316
16317 using type // NOLINT
16318 = decltype(declval<Zivid::Settings::Processing::Filters::Reflection::Removal::Experimental>().get<i>());
16319 };
16320
16321 template<>
16322 struct tuple_size<Zivid::Settings::Processing::Filters::Smoothing> : integral_constant<size_t, 1>
16323 {};
16324
16325 template<size_t i>
16326 struct tuple_element<i, Zivid::Settings::Processing::Filters::Smoothing>
16327 {
16328 static_assert(
16329 i < tuple_size<Zivid::Settings::Processing::Filters::Smoothing>::value,
16330 "Index must be less than 1");
16331
16332 using type // NOLINT
16333 = decltype(declval<Zivid::Settings::Processing::Filters::Smoothing>().get<i>());
16334 };
16335
16336 template<>
16337 struct tuple_size<Zivid::Settings::Processing::Filters::Smoothing::Gaussian> : integral_constant<size_t, 2>
16338 {};
16339
16340 template<size_t i>
16341 struct tuple_element<i, Zivid::Settings::Processing::Filters::Smoothing::Gaussian>
16342 {
16343 static_assert(
16344 i < tuple_size<Zivid::Settings::Processing::Filters::Smoothing::Gaussian>::value,
16345 "Index must be less than 2");
16346
16347 using type // NOLINT
16348 = decltype(declval<Zivid::Settings::Processing::Filters::Smoothing::Gaussian>().get<i>());
16349 };
16350
16351 template<>
16352 struct tuple_size<Zivid::Settings::RegionOfInterest> : integral_constant<size_t, 2>
16353 {};
16354
16355 template<size_t i>
16356 struct tuple_element<i, Zivid::Settings::RegionOfInterest>
16357 {
16358 static_assert(i < tuple_size<Zivid::Settings::RegionOfInterest>::value, "Index must be less than 2");
16359
16360 using type // NOLINT
16361 = decltype(declval<Zivid::Settings::RegionOfInterest>().get<i>());
16362 };
16363
16364 template<>
16365 struct tuple_size<Zivid::Settings::RegionOfInterest::Box> : integral_constant<size_t, 5>
16366 {};
16367
16368 template<size_t i>
16369 struct tuple_element<i, Zivid::Settings::RegionOfInterest::Box>
16370 {
16371 static_assert(i < tuple_size<Zivid::Settings::RegionOfInterest::Box>::value, "Index must be less than 5");
16372
16373 using type // NOLINT
16374 = decltype(declval<Zivid::Settings::RegionOfInterest::Box>().get<i>());
16375 };
16376
16377 template<>
16378 struct tuple_size<Zivid::Settings::RegionOfInterest::Depth> : integral_constant<size_t, 2>
16379 {};
16380
16381 template<size_t i>
16382 struct tuple_element<i, Zivid::Settings::RegionOfInterest::Depth>
16383 {
16384 static_assert(i < tuple_size<Zivid::Settings::RegionOfInterest::Depth>::value, "Index must be less than 2");
16385
16386 using type // NOLINT
16387 = decltype(declval<Zivid::Settings::RegionOfInterest::Depth>().get<i>());
16388 };
16389
16390 template<>
16391 struct tuple_size<Zivid::Settings::Sampling> : integral_constant<size_t, 2>
16392 {};
16393
16394 template<size_t i>
16395 struct tuple_element<i, Zivid::Settings::Sampling>
16396 {
16397 static_assert(i < tuple_size<Zivid::Settings::Sampling>::value, "Index must be less than 2");
16398
16399 using type // NOLINT
16400 = decltype(declval<Zivid::Settings::Sampling>().get<i>());
16401 };
16402
16403 template<>
16404 struct tuple_size<Zivid::Settings> : integral_constant<size_t, 6>
16405 {};
16406
16407 template<size_t i>
16408 struct tuple_element<i, Zivid::Settings>
16409 {
16410 static_assert(i < tuple_size<Zivid::Settings>::value, "Index must be less than 6");
16411
16412 using type // NOLINT
16413 = decltype(declval<Zivid::Settings>().get<i>());
16414 };
16415
16416} // namespace std
16417# endif
16418#endif
16419
16420// If we have access to the DataModel library, automatically include internal DataModel
16421// header. This header is necessary for serialization and deserialization.
16422#if defined(__has_include) && !defined(NO_DOC)
16423# if __has_include("Zivid/SettingsInternal.h") && __has_include("Zivid/DataModelNodeMetaData.h")
16424# include "Zivid/SettingsInternal.h"
16425# endif
16426#endif
#define ZIVID_CORE_EXPORT
Definition: CoreExport.h:101
Class describing a range of values for a given type T
Definition: Range.h:118
Aperture setting for the camera. Specified as an f-number (the ratio of lens focal length to the effe...
Definition: Settings.h:178
bool operator<(const Aperture &other) const
Comparison operator
Definition: Settings.h:241
friend std::ostream & operator<<(std::ostream &stream, const Aperture &value)
Operator to serialize the value to a stream
Definition: Settings.h:265
double value() const
Get the value
std::string toString() const
Get the value as string
bool operator<=(const Aperture &other) const
Comparison operator
Definition: Settings.h:253
bool operator>(const Aperture &other) const
Comparison operator
Definition: Settings.h:247
bool operator==(const Aperture &other) const
Comparison operator
Definition: Settings.h:229
bool operator>=(const Aperture &other) const
Comparison operator
Definition: Settings.h:259
bool operator!=(const Aperture &other) const
Comparison operator
Definition: Settings.h:235
Aperture()=default
Default constructor
constexpr Aperture(double value)
Constructor
Definition: Settings.h:209
double ValueType
The type of the underlying value
Definition: Settings.h:197
void reset()
Reset the node to unset state
static constexpr Range< double > validRange()
The range of valid values for Aperture
Definition: Settings.h:200
bool hasValue() const
Check if the value is set
Brightness controls the light output from the projector.
Definition: Settings.h:301
bool operator<=(const Brightness &other) const
Comparison operator
Definition: Settings.h:384
bool operator!=(const Brightness &other) const
Comparison operator
Definition: Settings.h:366
bool operator>=(const Brightness &other) const
Comparison operator
Definition: Settings.h:390
bool operator<(const Brightness &other) const
Comparison operator
Definition: Settings.h:372
bool operator>(const Brightness &other) const
Comparison operator
Definition: Settings.h:378
void reset()
Reset the node to unset state
static constexpr Range< double > validRange()
The range of valid values for Brightness
Definition: Settings.h:331
std::string toString() const
Get the value as string
double value() const
Get the value
friend std::ostream & operator<<(std::ostream &stream, const Brightness &value)
Operator to serialize the value to a stream
Definition: Settings.h:396
constexpr Brightness(double value)
Constructor
Definition: Settings.h:340
bool hasValue() const
Check if the value is set
Brightness()=default
Default constructor
double ValueType
The type of the underlying value
Definition: Settings.h:328
bool operator==(const Brightness &other) const
Comparison operator
Definition: Settings.h:360
Exposure time for each single image in the measurement. Affects frame rate.
Definition: Settings.h:422
bool operator>=(const ExposureTime &other) const
Comparison operator
Definition: Settings.h:501
bool operator<(const ExposureTime &other) const
Comparison operator
Definition: Settings.h:483
ExposureTime()=default
Default constructor
bool hasValue() const
Check if the value is set
void reset()
Reset the node to unset state
std::string toString() const
Get the value as string
bool operator>(const ExposureTime &other) const
Comparison operator
Definition: Settings.h:489
std::chrono::microseconds ValueType
The type of the underlying value
Definition: Settings.h:439
bool operator==(const ExposureTime &other) const
Comparison operator
Definition: Settings.h:471
bool operator!=(const ExposureTime &other) const
Comparison operator
Definition: Settings.h:477
std::chrono::microseconds value() const
Get the value
static constexpr Range< std::chrono::microseconds > validRange()
The range of valid values for ExposureTime
Definition: Settings.h:442
constexpr ExposureTime(std::chrono::microseconds value)
Constructor
Definition: Settings.h:451
friend std::ostream & operator<<(std::ostream &stream, const ExposureTime &value)
Operator to serialize the value to a stream
Definition: Settings.h:507
bool operator<=(const ExposureTime &other) const
Comparison operator
Definition: Settings.h:495
Analog gain in the camera
Definition: Settings.h:534
bool operator==(const Gain &other) const
Comparison operator
Definition: Settings.h:581
friend std::ostream & operator<<(std::ostream &stream, const Gain &value)
Operator to serialize the value to a stream
Definition: Settings.h:617
constexpr Gain(double value)
Constructor
Definition: Settings.h:561
bool operator>=(const Gain &other) const
Comparison operator
Definition: Settings.h:611
void reset()
Reset the node to unset state
bool operator<=(const Gain &other) const
Comparison operator
Definition: Settings.h:605
static constexpr Range< double > validRange()
The range of valid values for Gain
Definition: Settings.h:552
double value() const
Get the value
Gain()=default
Default constructor
bool hasValue() const
Check if the value is set
double ValueType
The type of the underlying value
Definition: Settings.h:549
std::string toString() const
Get the value as string
bool operator!=(const Gain &other) const
Comparison operator
Definition: Settings.h:587
bool operator>(const Gain &other) const
Comparison operator
Definition: Settings.h:599
bool operator<(const Gain &other) const
Comparison operator
Definition: Settings.h:593
Settings for a single acquisition
Definition: Settings.h:158
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:891
Acquisition & set(const Aperture &value)
Set Aperture
Definition: Settings.h:770
const Aperture & aperture() const
Get Aperture
Definition: Settings.h:758
Gain & gain()
Get Gain
Definition: Settings.h:821
const Settings::Acquisition::Aperture & get() const
Definition: Settings.h:836
Brightness & brightness()
Get Brightness
Definition: Settings.h:783
friend std::ostream & operator<<(std::ostream &stream, const Acquisition &value)
Operator to send the value as string to a stream
Definition: Settings.h:919
std::tuple< Settings::Acquisition::Aperture, Settings::Acquisition::Brightness, Settings::Acquisition::ExposureTime, Settings::Acquisition::Gain > Descendants
Definition: Settings.h:643
bool operator==(const Acquisition &other) const
Equality operator
const Settings::Acquisition::ExposureTime & get() const
Definition: Settings.h:852
bool operator!=(const Acquisition &other) const
Inequality operator
const ExposureTime & exposureTime() const
Get ExposureTime
Definition: Settings.h:796
Acquisition & set(const Brightness &value)
Set Brightness
Definition: Settings.h:789
Acquisition & set(const ExposureTime &value)
Set ExposureTime
Definition: Settings.h:808
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:703
const Brightness & brightness() const
Get Brightness
Definition: Settings.h:777
const Settings::Acquisition::Gain & get() const
Definition: Settings.h:860
Acquisition & set(const Gain &value)
Set Gain
Definition: Settings.h:827
Acquisition copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:738
Aperture & aperture()
Get Aperture
Definition: Settings.h:764
const Settings::Acquisition::Brightness & get() const
Definition: Settings.h:844
Acquisition(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:673
ExposureTime & exposureTime()
Get ExposureTime
Definition: Settings.h:802
const Gain & gain() const
Get Gain
Definition: Settings.h:815
Acquisition()
Default constructor
std::string toString() const
Get the value as string
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:901
List of Acquisition objects
Definition: Settings.h:943
bool operator!=(const Acquisitions &other) const
Comparison operator
Definition: Settings.h:1081
std::vector< Settings::Acquisition >::const_iterator ConstIterator
Constant iterator type for Acquisitions
Definition: Settings.h:1060
Iterator begin() noexcept
Returns an iterator to the first element of the list
const std::vector< Settings::Acquisition > & value() const
Get the value
std::string toString() const
Get the value as string
void forEach(const F &f) const
Run the given function on each element in the list
Definition: Settings.h:1042
std::vector< Settings::Acquisition >::iterator Iterator
Iterator type for Acquisitions
Definition: Settings.h:1051
const Settings::Acquisition & at(std::size_t pos) const
Returns a const reference to the element at position pos in the list
Acquisitions()=default
Default constructor
Acquisitions(std::initializer_list< Settings::Acquisition > value)
Constructor
Definition: Settings.h:975
friend std::ostream & operator<<(std::ostream &stream, const Acquisitions &value)
Operator to serialize the value to a stream
Definition: Settings.h:1087
void forEach(const F &f)
Run the given function on each element in the list
Definition: Settings.h:1032
Acquisitions(std::vector< Settings::Acquisition > value)
Constructor
Definition: Settings.h:970
std::vector< Settings::Acquisition > ValueType
The type of the underlying value
Definition: Settings.h:958
static constexpr Range< ValueType::size_type > validSize()
The valid sizes for Acquisitions
Definition: Settings.h:961
const Settings::Acquisition & operator[](std::size_t pos) const
Returns a const reference to the element at position pos in the list
Settings::Acquisition & at(std::size_t pos)
Returns a reference to the element at position pos in the list
std::size_t size() const noexcept
Get the size of the list
Settings::Acquisition & operator[](std::size_t pos)
Returns a reference to the element at position pos in the list
Enable diagnostics
Definition: Settings.h:1136
static const Enabled no
Off/disabled.
Definition: Settings.h:1153
bool hasValue() const
Check if the value is set
static std::set< bool > validValues()
All valid values of Enabled
Definition: Settings.h:1156
void reset()
Reset the node to unset state
Enabled()=default
Default constructor
bool ValueType
The type of the underlying value
Definition: Settings.h:1151
static const Enabled yes
On/enabled.
Definition: Settings.h:1152
bool operator==(const Enabled &other) const
Comparison operator
Definition: Settings.h:1185
bool value() const
Get the value
friend std::ostream & operator<<(std::ostream &stream, const Enabled &value)
Operator to serialize the value to a stream
Definition: Settings.h:1197
constexpr Enabled(bool value)
Constructor
Definition: Settings.h:1165
bool operator!=(const Enabled &other) const
Comparison operator
Definition: Settings.h:1191
std::string toString() const
Get the value as string
When Diagnostics is enabled, extra diagnostic information is recorded during capture....
Definition: Settings.h:1110
friend std::ostream & operator<<(std::ostream &stream, const Diagnostics &value)
Operator to send the value as string to a stream
Definition: Settings.h:1372
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:1350
std::tuple< Settings::Diagnostics::Enabled > Descendants
Definition: Settings.h:1210
std::string toString() const
Get the value as string
Diagnostics copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:1296
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:1357
Diagnostics()
Default constructor
Enabled & isEnabled()
Get Enabled
Definition: Settings.h:1322
bool operator==(const Diagnostics &other) const
Equality operator
Diagnostics(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:1237
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:1264
const Settings::Diagnostics::Enabled & get() const
Definition: Settings.h:1337
bool operator!=(const Diagnostics &other) const
Inequality operator
Diagnostics & set(const Enabled &value)
Set Enabled
Definition: Settings.h:1328
const Enabled & isEnabled() const
Get Enabled
Definition: Settings.h:1316
Set the Zivid Vision Engine to use.
Definition: Settings.h:1432
ValueType value() const
Get the value
static const Engine phase
phase
Definition: Settings.h:1472
bool hasValue() const
Check if the value is set
static const Engine omni
omni
Definition: Settings.h:1474
ValueType
The type of the underlying value
Definition: Settings.h:1467
friend std::ostream & operator<<(std::ostream &stream, const Engine &value)
Operator to serialize the value to a stream
Definition: Settings.h:1524
static std::set< ValueType > validValues()
All valid values of Engine
Definition: Settings.h:1477
std::string toString() const
Get the value as string
bool operator==(const Engine &other) const
Comparison operator
Definition: Settings.h:1512
Engine()=default
Default constructor
bool operator!=(const Engine &other) const
Comparison operator
Definition: Settings.h:1518
constexpr Engine(ValueType value)
Constructor
Definition: Settings.h:1486
friend std::ostream & operator<<(std::ostream &stream, const Engine::ValueType &value)
Operator to serialize ValueType to a stream
Definition: Settings.h:1506
static const Engine stripe
stripe
Definition: Settings.h:1473
void reset()
Reset the node to unset state
Experimental features. These settings may be changed, renamed, moved or deleted in the future.
Definition: Settings.h:1393
Engine & engine()
Get Engine
Definition: Settings.h:1659
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:1601
Experimental copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:1633
std::string toString() const
Get the value as string
bool operator!=(const Experimental &other) const
Inequality operator
friend std::ostream & operator<<(std::ostream &stream, const Experimental &value)
Operator to send the value as string to a stream
Definition: Settings.h:1709
const Settings::Experimental::Engine & get() const
Definition: Settings.h:1674
std::tuple< Settings::Experimental::Engine > Descendants
Definition: Settings.h:1547
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:1687
bool operator==(const Experimental &other) const
Equality operator
Experimental(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:1574
Experimental()
Default constructor
Experimental & set(const Engine &value)
Set Engine
Definition: Settings.h:1665
const Engine & engine() const
Get Engine
Definition: Settings.h:1653
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:1694
Digital gain applied to blue channel
Definition: Settings.h:1786
friend std::ostream & operator<<(std::ostream &stream, const Blue &value)
Operator to serialize the value to a stream
Definition: Settings.h:1871
void reset()
Reset the node to unset state
bool operator==(const Blue &other) const
Comparison operator
Definition: Settings.h:1835
bool operator>=(const Blue &other) const
Comparison operator
Definition: Settings.h:1865
std::string toString() const
Get the value as string
bool operator<(const Blue &other) const
Comparison operator
Definition: Settings.h:1847
constexpr Blue(double value)
Constructor
Definition: Settings.h:1815
bool operator<=(const Blue &other) const
Comparison operator
Definition: Settings.h:1859
bool operator!=(const Blue &other) const
Comparison operator
Definition: Settings.h:1841
bool hasValue() const
Check if the value is set
double ValueType
The type of the underlying value
Definition: Settings.h:1803
bool operator>(const Blue &other) const
Comparison operator
Definition: Settings.h:1853
static constexpr Range< double > validRange()
The range of valid values for Blue
Definition: Settings.h:1806
Digital gain applied to green channel
Definition: Settings.h:1898
void reset()
Reset the node to unset state
bool operator>(const Green &other) const
Comparison operator
Definition: Settings.h:1965
bool hasValue() const
Check if the value is set
friend std::ostream & operator<<(std::ostream &stream, const Green &value)
Operator to serialize the value to a stream
Definition: Settings.h:1983
double ValueType
The type of the underlying value
Definition: Settings.h:1915
bool operator>=(const Green &other) const
Comparison operator
Definition: Settings.h:1977
constexpr Green(double value)
Constructor
Definition: Settings.h:1927
bool operator==(const Green &other) const
Comparison operator
Definition: Settings.h:1947
bool operator!=(const Green &other) const
Comparison operator
Definition: Settings.h:1953
std::string toString() const
Get the value as string
bool operator<(const Green &other) const
Comparison operator
Definition: Settings.h:1959
static constexpr Range< double > validRange()
The range of valid values for Green
Definition: Settings.h:1918
bool operator<=(const Green &other) const
Comparison operator
Definition: Settings.h:1971
Digital gain applied to red channel
Definition: Settings.h:2010
bool operator!=(const Red &other) const
Comparison operator
Definition: Settings.h:2065
constexpr Red(double value)
Constructor
Definition: Settings.h:2039
friend std::ostream & operator<<(std::ostream &stream, const Red &value)
Operator to serialize the value to a stream
Definition: Settings.h:2095
bool operator>=(const Red &other) const
Comparison operator
Definition: Settings.h:2089
double ValueType
The type of the underlying value
Definition: Settings.h:2027
static constexpr Range< double > validRange()
The range of valid values for Red
Definition: Settings.h:2030
bool operator==(const Red &other) const
Comparison operator
Definition: Settings.h:2059
bool operator<(const Red &other) const
Comparison operator
Definition: Settings.h:2071
void reset()
Reset the node to unset state
bool operator>(const Red &other) const
Comparison operator
Definition: Settings.h:2077
bool hasValue() const
Check if the value is set
bool operator<=(const Red &other) const
Comparison operator
Definition: Settings.h:2083
std::string toString() const
Get the value as string
Color balance settings
Definition: Settings.h:1768
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:2179
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:2341
bool operator!=(const Balance &other) const
Inequality operator
Balance & set(const Red &value)
Set Red
Definition: Settings.h:2286
Green & green()
Get Green
Definition: Settings.h:2261
std::string toString() const
Get the value as string
Balance(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:2150
Red & red()
Get Red
Definition: Settings.h:2280
bool operator==(const Balance &other) const
Equality operator
Balance copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:2215
Balance & set(const Blue &value)
Set Blue
Definition: Settings.h:2248
Blue & blue()
Get Blue
Definition: Settings.h:2242
const Red & red() const
Get Red
Definition: Settings.h:2274
std::tuple< Settings::Processing::Color::Balance::Blue, Settings::Processing::Color::Balance::Green, Settings::Processing::Color::Balance::Red > Descendants
Definition: Settings.h:2121
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:2350
const Settings::Processing::Color::Balance::Green & get() const
Definition: Settings.h:2307
const Settings::Processing::Color::Balance::Red & get() const
Definition: Settings.h:2316
Balance & set(const Green &value)
Set Green
Definition: Settings.h:2267
const Green & green() const
Get Green
Definition: Settings.h:2255
friend std::ostream & operator<<(std::ostream &stream, const Balance &value)
Operator to send the value as string to a stream
Definition: Settings.h:2367
const Settings::Processing::Color::Balance::Blue & get() const
Definition: Settings.h:2297
const Blue & blue() const
Get Blue
Definition: Settings.h:2236
This setting controls how the color image is computed.
Definition: Settings.h:2431
static const Mode toneMapping
toneMapping
Definition: Settings.h:2477
std::string toString() const
Get the value as string
static const Mode automatic
automatic
Definition: Settings.h:2475
friend std::ostream & operator<<(std::ostream &stream, const Mode &value)
Operator to serialize the value to a stream
Definition: Settings.h:2527
void reset()
Reset the node to unset state
static const Mode useFirstAcquisition
useFirstAcquisition
Definition: Settings.h:2476
bool operator!=(const Mode &other) const
Comparison operator
Definition: Settings.h:2521
bool operator==(const Mode &other) const
Comparison operator
Definition: Settings.h:2515
ValueType
The type of the underlying value
Definition: Settings.h:2470
bool hasValue() const
Check if the value is set
constexpr Mode(ValueType value)
Constructor
Definition: Settings.h:2489
static std::set< ValueType > validValues()
All valid values of Mode
Definition: Settings.h:2480
friend std::ostream & operator<<(std::ostream &stream, const Mode::ValueType &value)
Operator to serialize ValueType to a stream
Definition: Settings.h:2509
Experimental color settings. These may be renamed, moved or deleted in the future.
Definition: Settings.h:2390
std::tuple< Settings::Processing::Color::Experimental::Mode > Descendants
Definition: Settings.h:2552
bool operator!=(const Experimental &other) const
Inequality operator
friend std::ostream & operator<<(std::ostream &stream, const Experimental &value)
Operator to send the value as string to a stream
Definition: Settings.h:2719
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:2704
Experimental(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:2579
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:2606
std::string toString() const
Get the value as string
Experimental & set(const Mode &value)
Set Mode
Definition: Settings.h:2673
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:2697
bool operator==(const Experimental &other) const
Equality operator
Mode & mode()
Get Mode
Definition: Settings.h:2667
const Mode & mode() const
Get Mode
Definition: Settings.h:2661
const Settings::Processing::Color::Experimental::Mode & get() const
Definition: Settings.h:2684
Experimental copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:2640
Gamma applied to the color values. Gamma less than 1 makes the colors brighter, while gamma greater t...
Definition: Settings.h:2742
friend std::ostream & operator<<(std::ostream &stream, const Gamma &value)
Operator to serialize the value to a stream
Definition: Settings.h:2829
double value() const
Get the value
bool operator>(const Gamma &other) const
Comparison operator
Definition: Settings.h:2811
void reset()
Reset the node to unset state
static constexpr Range< double > validRange()
The range of valid values for Gamma
Definition: Settings.h:2764
Gamma()=default
Default constructor
double ValueType
The type of the underlying value
Definition: Settings.h:2761
bool hasValue() const
Check if the value is set
bool operator>=(const Gamma &other) const
Comparison operator
Definition: Settings.h:2823
constexpr Gamma(double value)
Constructor
Definition: Settings.h:2773
bool operator!=(const Gamma &other) const
Comparison operator
Definition: Settings.h:2799
bool operator<(const Gamma &other) const
Comparison operator
Definition: Settings.h:2805
std::string toString() const
Get the value as string
bool operator==(const Gamma &other) const
Comparison operator
Definition: Settings.h:2793
bool operator<=(const Gamma &other) const
Comparison operator
Definition: Settings.h:2817
Color settings
Definition: Settings.h:1750
Color & set(const Gamma &value)
Set Gamma
Definition: Settings.h:3062
const Settings::Processing::Color::Gamma & get() const
Definition: Settings.h:3126
const Settings::Processing::Color::Balance::Red & get() const
Definition: Settings.h:3099
bool operator==(const Color &other) const
Equality operator
Color & set(const Experimental::Mode &value)
Set Experimental::Mode
Definition: Settings.h:3043
const Settings::Processing::Color::Balance::Green & get() const
Definition: Settings.h:3090
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:2924
Color & set(const Experimental &value)
Set Experimental
Definition: Settings.h:3036
Color & set(const Balance &value)
Set Balance
Definition: Settings.h:2996
friend std::ostream & operator<<(std::ostream &stream, const Color &value)
Operator to send the value as string to a stream
Definition: Settings.h:3177
const Balance & balance() const
Get Balance
Definition: Settings.h:2984
const Experimental & experimental() const
Get Experimental
Definition: Settings.h:3024
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:3160
const Settings::Processing::Color::Experimental & get() const
Definition: Settings.h:3108
Color & set(const Balance::Green &value)
Set Balance::Green
Definition: Settings.h:3010
Experimental & experimental()
Get Experimental
Definition: Settings.h:3030
std::string toString() const
Get the value as string
bool operator!=(const Color &other) const
Inequality operator
std::tuple< Settings::Processing::Color::Balance, Settings::Processing::Color::Balance::Blue, Settings::Processing::Color::Balance::Green, Settings::Processing::Color::Balance::Red, Settings::Processing::Color::Experimental, Settings::Processing::Color::Experimental::Mode, Settings::Processing::Color::Gamma > Descendants
Definition: Settings.h:2858
Color & set(const Balance::Blue &value)
Set Balance::Blue
Definition: Settings.h:3003
Gamma & gamma()
Get Gamma
Definition: Settings.h:3056
Color copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:2963
const Settings::Processing::Color::Experimental::Mode & get() const
Definition: Settings.h:3118
Color & set(const Balance::Red &value)
Set Balance::Red
Definition: Settings.h:3017
const Gamma & gamma() const
Get Gamma
Definition: Settings.h:3050
Color(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:2891
const Settings::Processing::Color::Balance & get() const
Definition: Settings.h:3072
Balance & balance()
Get Balance
Definition: Settings.h:2990
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:3151
const Settings::Processing::Color::Balance::Blue & get() const
Definition: Settings.h:3081
bool ValueType
The type of the underlying value
Definition: Settings.h:3273
static const Enabled no
Off/disabled.
Definition: Settings.h:3275
constexpr Enabled(bool value)
Constructor
Definition: Settings.h:3287
static std::set< bool > validValues()
All valid values of Enabled
Definition: Settings.h:3278
bool operator!=(const Enabled &other) const
Comparison operator
Definition: Settings.h:3313
friend std::ostream & operator<<(std::ostream &stream, const Enabled &value)
Operator to serialize the value to a stream
Definition: Settings.h:3319
bool operator==(const Enabled &other) const
Comparison operator
Definition: Settings.h:3307
std::string toString() const
Get the value as string
static const Enabled yes
On/enabled.
Definition: Settings.h:3274
Maximum normalized distance between neighboring points that are still classified as belonging to the ...
Definition: Settings.h:3339
constexpr MaxNeighborDistance(double value)
Constructor
Definition: Settings.h:3373
bool operator!=(const MaxNeighborDistance &other) const
Comparison operator
Definition: Settings.h:3399
double ValueType
The type of the underlying value
Definition: Settings.h:3361
bool operator>=(const MaxNeighborDistance &other) const
Comparison operator
Definition: Settings.h:3423
bool operator<(const MaxNeighborDistance &other) const
Comparison operator
Definition: Settings.h:3405
static constexpr Range< double > validRange()
The range of valid values for MaxNeighborDistance
Definition: Settings.h:3364
bool operator<=(const MaxNeighborDistance &other) const
Comparison operator
Definition: Settings.h:3417
friend std::ostream & operator<<(std::ostream &stream, const MaxNeighborDistance &value)
Operator to serialize the value to a stream
Definition: Settings.h:3429
bool operator==(const MaxNeighborDistance &other) const
Comparison operator
Definition: Settings.h:3393
bool operator>(const MaxNeighborDistance &other) const
Comparison operator
Definition: Settings.h:3411
Clusters with area below this threshold are removed by the filter. The area is given in mm^2.
Definition: Settings.h:3458
bool operator>=(const MinArea &other) const
Comparison operator
Definition: Settings.h:3539
double ValueType
The type of the underlying value
Definition: Settings.h:3477
friend std::ostream & operator<<(std::ostream &stream, const MinArea &value)
Operator to serialize the value to a stream
Definition: Settings.h:3545
bool operator<(const MinArea &other) const
Comparison operator
Definition: Settings.h:3521
bool operator!=(const MinArea &other) const
Comparison operator
Definition: Settings.h:3515
bool operator<=(const MinArea &other) const
Comparison operator
Definition: Settings.h:3533
constexpr MinArea(double value)
Constructor
Definition: Settings.h:3489
std::string toString() const
Get the value as string
bool operator>(const MinArea &other) const
Comparison operator
Definition: Settings.h:3527
static constexpr Range< double > validRange()
The range of valid values for MinArea
Definition: Settings.h:3480
bool operator==(const MinArea &other) const
Comparison operator
Definition: Settings.h:3509
Removal(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:3600
friend std::ostream & operator<<(std::ostream &stream, const Removal &value)
Operator to send the value as string to a stream
Definition: Settings.h:3819
const MaxNeighborDistance & maxNeighborDistance() const
Get MaxNeighborDistance
Definition: Settings.h:3705
const Enabled & isEnabled() const
Get Enabled
Definition: Settings.h:3686
const Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance & get() const
Definition: Settings.h:3758
std::string toString() const
Get the value as string
MinArea & minArea()
Get MinArea
Definition: Settings.h:3730
const MinArea & minArea() const
Get MinArea
Definition: Settings.h:3724
bool operator!=(const Removal &other) const
Inequality operator
Removal copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:3665
Removal & set(const MaxNeighborDistance &value)
Set MaxNeighborDistance
Definition: Settings.h:3717
const Settings::Processing::Filters::Cluster::Removal::MinArea & get() const
Definition: Settings.h:3768
Removal & set(const MinArea &value)
Set MinArea
Definition: Settings.h:3736
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:3793
const Settings::Processing::Filters::Cluster::Removal::Enabled & get() const
Definition: Settings.h:3747
Enabled & isEnabled()
Get Enabled
Definition: Settings.h:3692
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:3629
bool operator==(const Removal &other) const
Equality operator
MaxNeighborDistance & maxNeighborDistance()
Get MaxNeighborDistance
Definition: Settings.h:3711
std::tuple< Settings::Processing::Filters::Cluster::Removal::Enabled, Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance, Settings::Processing::Filters::Cluster::Removal::MinArea > Descendants
Definition: Settings.h:3571
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:3802
Removal & set(const Enabled &value)
Set Enabled
Definition: Settings.h:3698
Removes floating points and isolated clusters from the point cloud.
Definition: Settings.h:3219
const Removal & removal() const
Get Removal
Definition: Settings.h:3960
Cluster(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:3872
const Settings::Processing::Filters::Cluster::Removal::MinArea & get() const
Definition: Settings.h:4035
const Settings::Processing::Filters::Cluster::Removal & get() const
Definition: Settings.h:4004
Cluster & set(const Removal::MaxNeighborDistance &value)
Set Removal::MaxNeighborDistance
Definition: Settings.h:3986
bool operator!=(const Cluster &other) const
Inequality operator
const Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance & get() const
Definition: Settings.h:4025
bool operator==(const Cluster &other) const
Equality operator
Cluster copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:3939
Removal & removal()
Get Removal
Definition: Settings.h:3966
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:4055
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:4048
Cluster & set(const Removal::Enabled &value)
Set Removal::Enabled
Definition: Settings.h:3979
Cluster & set(const Removal &value)
Set Removal
Definition: Settings.h:3972
Cluster & set(const Removal::MinArea &value)
Set Removal::MinArea
Definition: Settings.h:3993
const Settings::Processing::Filters::Cluster::Removal::Enabled & get() const
Definition: Settings.h:4014
std::tuple< Settings::Processing::Filters::Cluster::Removal, Settings::Processing::Filters::Cluster::Removal::Enabled, Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance, Settings::Processing::Filters::Cluster::Removal::MinArea > Descendants
Definition: Settings.h:3842
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:3902
std::string toString() const
Get the value as string
friend std::ostream & operator<<(std::ostream &stream, const Cluster &value)
Operator to send the value as string to a stream
Definition: Settings.h:4070
bool ValueType
The type of the underlying value
Definition: Settings.h:4176
static std::set< bool > validValues()
All valid values of Enabled
Definition: Settings.h:4181
constexpr Enabled(bool value)
Constructor
Definition: Settings.h:4190
friend std::ostream & operator<<(std::ostream &stream, const Enabled &value)
Operator to serialize the value to a stream
Definition: Settings.h:4222
bool operator==(const Enabled &other) const
Comparison operator
Definition: Settings.h:4210
bool operator!=(const Enabled &other) const
Comparison operator
Definition: Settings.h:4216
Higher values gives more correction.
Definition: Settings.h:4239
double ValueType
The type of the underlying value
Definition: Settings.h:4258
bool operator>(const Strength &other) const
Comparison operator
Definition: Settings.h:4308
bool operator!=(const Strength &other) const
Comparison operator
Definition: Settings.h:4296
constexpr Strength(double value)
Constructor
Definition: Settings.h:4270
static constexpr Range< double > validRange()
The range of valid values for Strength
Definition: Settings.h:4261
bool operator<=(const Strength &other) const
Comparison operator
Definition: Settings.h:4314
bool operator>=(const Strength &other) const
Comparison operator
Definition: Settings.h:4320
friend std::ostream & operator<<(std::ostream &stream, const Strength &value)
Operator to serialize the value to a stream
Definition: Settings.h:4326
bool operator<(const Strength &other) const
Comparison operator
Definition: Settings.h:4302
bool operator==(const Strength &other) const
Comparison operator
Definition: Settings.h:4290
bool operator==(const Correction &other) const
Equality operator
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:4546
const Enabled & isEnabled() const
Get Enabled
Definition: Settings.h:4463
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Strength & get() const
Definition: Settings.h:4524
std::tuple< Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Strength > Descendants
Definition: Settings.h:4351
Correction copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:4442
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled & get() const
Definition: Settings.h:4509
bool operator!=(const Correction &other) const
Inequality operator
friend std::ostream & operator<<(std::ostream &stream, const Correction &value)
Operator to send the value as string to a stream
Definition: Settings.h:4570
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:4407
Correction & set(const Enabled &value)
Set Enabled
Definition: Settings.h:4475
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:4554
Correction & set(const Strength &value)
Set Strength
Definition: Settings.h:4494
const Strength & strength() const
Get Strength
Definition: Settings.h:4482
Correction(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:4379
static const Enabled yes
On/enabled.
Definition: Settings.h:4630
constexpr Enabled(bool value)
Constructor
Definition: Settings.h:4643
bool operator!=(const Enabled &other) const
Comparison operator
Definition: Settings.h:4669
bool ValueType
The type of the underlying value
Definition: Settings.h:4629
static std::set< bool > validValues()
All valid values of Enabled
Definition: Settings.h:4634
friend std::ostream & operator<<(std::ostream &stream, const Enabled &value)
Operator to serialize the value to a stream
Definition: Settings.h:4675
bool operator==(const Enabled &other) const
Comparison operator
Definition: Settings.h:4663
static const Enabled no
Off/disabled.
Definition: Settings.h:4631
Higher values remove more points.
Definition: Settings.h:4692
bool operator<=(const Threshold &other) const
Comparison operator
Definition: Settings.h:4767
constexpr Threshold(double value)
Constructor
Definition: Settings.h:4723
bool operator!=(const Threshold &other) const
Comparison operator
Definition: Settings.h:4749
bool operator<(const Threshold &other) const
Comparison operator
Definition: Settings.h:4755
static constexpr Range< double > validRange()
The range of valid values for Threshold
Definition: Settings.h:4714
bool operator==(const Threshold &other) const
Comparison operator
Definition: Settings.h:4743
bool operator>=(const Threshold &other) const
Comparison operator
Definition: Settings.h:4773
bool operator>(const Threshold &other) const
Comparison operator
Definition: Settings.h:4761
friend std::ostream & operator<<(std::ostream &stream, const Threshold &value)
Operator to serialize the value to a stream
Definition: Settings.h:4779
double ValueType
The type of the underlying value
Definition: Settings.h:4711
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:4997
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:4860
friend std::ostream & operator<<(std::ostream &stream, const Removal &value)
Operator to send the value as string to a stream
Definition: Settings.h:5021
const Threshold & threshold() const
Get Threshold
Definition: Settings.h:4935
Removal & set(const Threshold &value)
Set Threshold
Definition: Settings.h:4947
Removal(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:4832
bool operator!=(const Removal &other) const
Inequality operator
Removal copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:4895
Threshold & threshold()
Get Threshold
Definition: Settings.h:4941
Removal & set(const Enabled &value)
Set Enabled
Definition: Settings.h:4928
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled & get() const
Definition: Settings.h:4962
std::tuple< Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold > Descendants
Definition: Settings.h:4804
const Enabled & isEnabled() const
Get Enabled
Definition: Settings.h:4916
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold & get() const
Definition: Settings.h:4976
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:5005
Corrects artifacts that appear when imaging scenes with large texture gradients or high contrast....
Definition: Settings.h:4115
ContrastDistortion & set(const Removal::Enabled &value)
Set Removal::Enabled
Definition: Settings.h:5221
ContrastDistortion & set(const Correction::Enabled &value)
Set Correction::Enabled
Definition: Settings.h:5188
ContrastDistortion & set(const Correction &value)
Set Correction
Definition: Settings.h:5181
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:5332
bool operator!=(const ContrastDistortion &other) const
Inequality operator
friend std::ostream & operator<<(std::ostream &stream, const ContrastDistortion &value)
Operator to send the value as string to a stream
Definition: Settings.h:5356
ContrastDistortion copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:5148
std::tuple< Settings::Processing::Filters::Experimental::ContrastDistortion::Correction, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Strength, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold > Descendants
Definition: Settings.h:5045
ContrastDistortion & set(const Correction::Strength &value)
Set Correction::Strength
Definition: Settings.h:5195
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:5109
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:5340
ContrastDistortion & set(const Removal &value)
Set Removal
Definition: Settings.h:5214
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold & get() const
Definition: Settings.h:5311
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal & get() const
Definition: Settings.h:5283
const Removal & removal() const
Get Removal
Definition: Settings.h:5202
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled & get() const
Definition: Settings.h:5255
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction & get() const
Definition: Settings.h:5241
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Strength & get() const
Definition: Settings.h:5270
Removal & removal()
Get Removal
Definition: Settings.h:5208
bool operator==(const ContrastDistortion &other) const
Equality operator
ContrastDistortion & set(const Removal::Threshold &value)
Set Removal::Threshold
Definition: Settings.h:5228
const Correction & correction() const
Get Correction
Definition: Settings.h:5169
ContrastDistortion(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:5077
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled & get() const
Definition: Settings.h:5296
Correction & correction()
Get Correction
Definition: Settings.h:5175
static const Enabled no
Off/disabled.
Definition: Settings.h:5417
bool operator==(const Enabled &other) const
Comparison operator
Definition: Settings.h:5449
static const Enabled yes
On/enabled.
Definition: Settings.h:5416
bool ValueType
The type of the underlying value
Definition: Settings.h:5415
static std::set< bool > validValues()
All valid values of Enabled
Definition: Settings.h:5420
bool operator!=(const Enabled &other) const
Comparison operator
Definition: Settings.h:5455
friend std::ostream & operator<<(std::ostream &stream, const Enabled &value)
Operator to serialize the value to a stream
Definition: Settings.h:5461
constexpr Enabled(bool value)
Constructor
Definition: Settings.h:5429
Relative diameter of holes to fill. Increasing this will fill more points, but require more computati...
Definition: Settings.h:5481
bool operator>=(const HoleSize &other) const
Comparison operator
Definition: Settings.h:5563
bool operator<=(const HoleSize &other) const
Comparison operator
Definition: Settings.h:5557
double ValueType
The type of the underlying value
Definition: Settings.h:5501
friend std::ostream & operator<<(std::ostream &stream, const HoleSize &value)
Operator to serialize the value to a stream
Definition: Settings.h:5569
bool operator!=(const HoleSize &other) const
Comparison operator
Definition: Settings.h:5539
bool operator>(const HoleSize &other) const
Comparison operator
Definition: Settings.h:5551
constexpr HoleSize(double value)
Constructor
Definition: Settings.h:5513
static constexpr Range< double > validRange()
The range of valid values for HoleSize
Definition: Settings.h:5504
bool operator==(const HoleSize &other) const
Comparison operator
Definition: Settings.h:5533
bool operator<(const HoleSize &other) const
Comparison operator
Definition: Settings.h:5545
Level of strictness when considering if a point should be filled. A higher level of strictness requir...
Definition: Settings.h:5600
bool operator==(const Strictness &other) const
Comparison operator
Definition: Settings.h:5655
bool operator<(const Strictness &other) const
Comparison operator
Definition: Settings.h:5667
bool operator>(const Strictness &other) const
Comparison operator
Definition: Settings.h:5673
bool operator<=(const Strictness &other) const
Comparison operator
Definition: Settings.h:5679
constexpr Strictness(int32_t value)
Constructor
Definition: Settings.h:5635
bool operator!=(const Strictness &other) const
Comparison operator
Definition: Settings.h:5661
static constexpr Range< int32_t > validRange()
The range of valid values for Strictness
Definition: Settings.h:5626
int32_t ValueType
The type of the underlying value
Definition: Settings.h:5623
friend std::ostream & operator<<(std::ostream &stream, const Strictness &value)
Operator to serialize the value to a stream
Definition: Settings.h:5691
bool operator>=(const Strictness &other) const
Comparison operator
Definition: Settings.h:5685
Fills in removed points by interpolating remaining surrounding points.
Definition: Settings.h:5379
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:5941
const Strictness & strictness() const
Get Strictness
Definition: Settings.h:5870
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:5950
Strictness & strictness()
Get Strictness
Definition: Settings.h:5876
HoleFilling copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:5811
HoleSize & holeSize()
Get HoleSize
Definition: Settings.h:5857
bool operator==(const HoleFilling &other) const
Equality operator
std::tuple< Settings::Processing::Filters::Experimental::HoleFilling::Enabled, Settings::Processing::Filters::Experimental::HoleFilling::HoleSize, Settings::Processing::Filters::Experimental::HoleFilling::Strictness > Descendants
Definition: Settings.h:5717
const Enabled & isEnabled() const
Get Enabled
Definition: Settings.h:5832
HoleFilling & set(const Strictness &value)
Set Strictness
Definition: Settings.h:5882
const Settings::Processing::Filters::Experimental::HoleFilling::Strictness & get() const
Definition: Settings.h:5916
const Settings::Processing::Filters::Experimental::HoleFilling::Enabled & get() const
Definition: Settings.h:5894
const HoleSize & holeSize() const
Get HoleSize
Definition: Settings.h:5851
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:5775
const Settings::Processing::Filters::Experimental::HoleFilling::HoleSize & get() const
Definition: Settings.h:5905
HoleFilling & set(const Enabled &value)
Set Enabled
Definition: Settings.h:5844
bool operator!=(const HoleFilling &other) const
Inequality operator
Enabled & isEnabled()
Get Enabled
Definition: Settings.h:5838
HoleFilling(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:5746
std::string toString() const
Get the value as string
friend std::ostream & operator<<(std::ostream &stream, const HoleFilling &value)
Operator to send the value as string to a stream
Definition: Settings.h:5967
HoleFilling & set(const HoleSize &value)
Set HoleSize
Definition: Settings.h:5863
Experimental filters. These may be renamed, moved or deleted in the future.
Definition: Settings.h:4091
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:6394
ContrastDistortion & contrastDistortion()
Get ContrastDistortion
Definition: Settings.h:6142
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal & get() const
Definition: Settings.h:6295
const HoleFilling & holeFilling() const
Get HoleFilling
Definition: Settings.h:6197
Experimental copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:6115
Experimental(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:6034
Experimental & set(const ContrastDistortion &value)
Set ContrastDistortion
Definition: Settings.h:6148
Experimental & set(const ContrastDistortion::Removal::Threshold &value)
Set ContrastDistortion::Removal::Threshold
Definition: Settings.h:6190
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:6071
const Settings::Processing::Filters::Experimental::HoleFilling::Enabled & get() const
Definition: Settings.h:6345
Experimental & set(const ContrastDistortion::Correction::Strength &value)
Set ContrastDistortion::Correction::Strength
Definition: Settings.h:6169
Experimental & set(const HoleFilling::HoleSize &value)
Set HoleFilling::HoleSize
Definition: Settings.h:6223
Experimental & set(const HoleFilling::Strictness &value)
Set HoleFilling::Strictness
Definition: Settings.h:6230
friend std::ostream & operator<<(std::ostream &stream, const Experimental &value)
Operator to send the value as string to a stream
Definition: Settings.h:6410
std::tuple< Settings::Processing::Filters::Experimental::ContrastDistortion, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Strength, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold, Settings::Processing::Filters::Experimental::HoleFilling, Settings::Processing::Filters::Experimental::HoleFilling::Enabled, Settings::Processing::Filters::Experimental::HoleFilling::HoleSize, Settings::Processing::Filters::Experimental::HoleFilling::Strictness > Descendants
Definition: Settings.h:5997
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Strength & get() const
Definition: Settings.h:6282
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:6386
const Settings::Processing::Filters::Experimental::HoleFilling::Strictness & get() const
Definition: Settings.h:6366
const Settings::Processing::Filters::Experimental::HoleFilling::HoleSize & get() const
Definition: Settings.h:6355
Experimental & set(const ContrastDistortion::Removal &value)
Set ContrastDistortion::Removal
Definition: Settings.h:6176
const Settings::Processing::Filters::Experimental::ContrastDistortion & get() const
Definition: Settings.h:6241
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction & get() const
Definition: Settings.h:6253
bool operator!=(const Experimental &other) const
Inequality operator
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold & get() const
Definition: Settings.h:6323
Experimental & set(const ContrastDistortion::Correction::Enabled &value)
Set ContrastDistortion::Correction::Enabled
Definition: Settings.h:6162
Experimental & set(const HoleFilling::Enabled &value)
Set HoleFilling::Enabled
Definition: Settings.h:6216
const ContrastDistortion & contrastDistortion() const
Get ContrastDistortion
Definition: Settings.h:6136
std::string toString() const
Get the value as string
bool operator==(const Experimental &other) const
Equality operator
Experimental & set(const HoleFilling &value)
Set HoleFilling
Definition: Settings.h:6209
const Settings::Processing::Filters::Experimental::HoleFilling & get() const
Definition: Settings.h:6335
Experimental & set(const ContrastDistortion::Correction &value)
Set ContrastDistortion::Correction
Definition: Settings.h:6155
Experimental & set(const ContrastDistortion::Removal::Enabled &value)
Set ContrastDistortion::Removal::Enabled
Definition: Settings.h:6183
HoleFilling & holeFilling()
Get HoleFilling
Definition: Settings.h:6203
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled & get() const
Definition: Settings.h:6267
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled & get() const
Definition: Settings.h:6309
Enable or disable the SNR filter
Definition: Settings.h:6472
static const Enabled yes
On/enabled.
Definition: Settings.h:6490
bool operator!=(const Enabled &other) const
Comparison operator
Definition: Settings.h:6529
bool operator==(const Enabled &other) const
Comparison operator
Definition: Settings.h:6523
static std::set< bool > validValues()
All valid values of Enabled
Definition: Settings.h:6494
constexpr Enabled(bool value)
Constructor
Definition: Settings.h:6503
friend std::ostream & operator<<(std::ostream &stream, const Enabled &value)
Operator to serialize the value to a stream
Definition: Settings.h:6535
static const Enabled no
Off/disabled.
Definition: Settings.h:6491
bool ValueType
The type of the underlying value
Definition: Settings.h:6489
std::string toString() const
Get the value as string
Discard points with signal-to-noise ratio (SNR) below the given value
Definition: Settings.h:6552
bool operator>=(const Threshold &other) const
Comparison operator
Definition: Settings.h:6631
constexpr Threshold(double value)
Constructor
Definition: Settings.h:6581
bool operator==(const Threshold &other) const
Comparison operator
Definition: Settings.h:6601
bool operator<=(const Threshold &other) const
Comparison operator
Definition: Settings.h:6625
static constexpr Range< double > validRange()
The range of valid values for Threshold
Definition: Settings.h:6572
friend std::ostream & operator<<(std::ostream &stream, const Threshold &value)
Operator to serialize the value to a stream
Definition: Settings.h:6637
bool operator>(const Threshold &other) const
Comparison operator
Definition: Settings.h:6619
bool operator<(const Threshold &other) const
Comparison operator
Definition: Settings.h:6613
std::string toString() const
Get the value as string
double ValueType
The type of the underlying value
Definition: Settings.h:6569
bool operator!=(const Threshold &other) const
Comparison operator
Definition: Settings.h:6607
Discard points with signal-to-noise ratio (SNR) values below a threshold
Definition: Settings.h:6452
Removal(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:6690
friend std::ostream & operator<<(std::ostream &stream, const Removal &value)
Operator to send the value as string to a stream
Definition: Settings.h:6869
const Enabled & isEnabled() const
Get Enabled
Definition: Settings.h:6774
const Threshold & threshold() const
Get Threshold
Definition: Settings.h:6793
std::tuple< Settings::Processing::Filters::Noise::Removal::Enabled, Settings::Processing::Filters::Noise::Removal::Threshold > Descendants
Definition: Settings.h:6662
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:6853
Removal & set(const Enabled &value)
Set Enabled
Definition: Settings.h:6786
Removal & set(const Threshold &value)
Set Threshold
Definition: Settings.h:6805
bool operator==(const Removal &other) const
Equality operator
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:6718
bool operator!=(const Removal &other) const
Inequality operator
const Settings::Processing::Filters::Noise::Removal::Threshold & get() const
Definition: Settings.h:6826
Threshold & threshold()
Get Threshold
Definition: Settings.h:6799
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:6845
Removal copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:6753
Enabled & isEnabled()
Get Enabled
Definition: Settings.h:6780
std::string toString() const
Get the value as string
const Settings::Processing::Filters::Noise::Removal::Enabled & get() const
Definition: Settings.h:6816
Enable or disable noise repair
Definition: Settings.h:6917
static std::set< bool > validValues()
All valid values of Enabled
Definition: Settings.h:6939
bool ValueType
The type of the underlying value
Definition: Settings.h:6934
static const Enabled no
Off/disabled.
Definition: Settings.h:6936
bool operator!=(const Enabled &other) const
Comparison operator
Definition: Settings.h:6974
constexpr Enabled(bool value)
Constructor
Definition: Settings.h:6948
std::string toString() const
Get the value as string
static const Enabled yes
On/enabled.
Definition: Settings.h:6935
friend std::ostream & operator<<(std::ostream &stream, const Enabled &value)
Operator to serialize the value to a stream
Definition: Settings.h:6980
bool operator==(const Enabled &other) const
Comparison operator
Definition: Settings.h:6968
Get better surface coverage by repairing regions of missing data due to noisy points....
Definition: Settings.h:6894
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:7138
Repair(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:7020
bool operator!=(const Repair &other) const
Inequality operator
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:7145
bool operator==(const Repair &other) const
Equality operator
Repair & set(const Enabled &value)
Set Enabled
Definition: Settings.h:7114
std::tuple< Settings::Processing::Filters::Noise::Repair::Enabled > Descendants
Definition: Settings.h:6993
Enabled & isEnabled()
Get Enabled
Definition: Settings.h:7108
const Enabled & isEnabled() const
Get Enabled
Definition: Settings.h:7102
Repair copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:7081
const Settings::Processing::Filters::Noise::Repair::Enabled & get() const
Definition: Settings.h:7125
friend std::ostream & operator<<(std::ostream &stream, const Repair &value)
Operator to send the value as string to a stream
Definition: Settings.h:7160
std::string toString() const
Get the value as string
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:7047
Enable or disable noise suppression
Definition: Settings.h:7207
static const Enabled no
Off/disabled.
Definition: Settings.h:7226
constexpr Enabled(bool value)
Constructor
Definition: Settings.h:7238
bool operator!=(const Enabled &other) const
Comparison operator
Definition: Settings.h:7264
bool ValueType
The type of the underlying value
Definition: Settings.h:7224
std::string toString() const
Get the value as string
static const Enabled yes
On/enabled.
Definition: Settings.h:7225
static std::set< bool > validValues()
All valid values of Enabled
Definition: Settings.h:7229
friend std::ostream & operator<<(std::ostream &stream, const Enabled &value)
Operator to serialize the value to a stream
Definition: Settings.h:7270
bool operator==(const Enabled &other) const
Comparison operator
Definition: Settings.h:7258
Reduce noise and outliers in the point cloud. This filter can also be used to reduce ripple effects c...
Definition: Settings.h:7184
const Settings::Processing::Filters::Noise::Suppression::Enabled & get() const
Definition: Settings.h:7415
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:7428
Enabled & isEnabled()
Get Enabled
Definition: Settings.h:7398
const Enabled & isEnabled() const
Get Enabled
Definition: Settings.h:7392
std::string toString() const
Get the value as string
std::tuple< Settings::Processing::Filters::Noise::Suppression::Enabled > Descendants
Definition: Settings.h:7283
Suppression copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:7371
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:7337
friend std::ostream & operator<<(std::ostream &stream, const Suppression &value)
Operator to send the value as string to a stream
Definition: Settings.h:7450
bool operator!=(const Suppression &other) const
Inequality operator
Suppression & set(const Enabled &value)
Set Enabled
Definition: Settings.h:7404
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:7435
Suppression(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:7310
bool operator==(const Suppression &other) const
Equality operator
Contains filters that can be used to clean up a noisy point cloud
Definition: Settings.h:6432
std::tuple< Settings::Processing::Filters::Noise::Removal, Settings::Processing::Filters::Noise::Removal::Enabled, Settings::Processing::Filters::Noise::Removal::Threshold, Settings::Processing::Filters::Noise::Repair, Settings::Processing::Filters::Noise::Repair::Enabled, Settings::Processing::Filters::Noise::Suppression, Settings::Processing::Filters::Noise::Suppression::Enabled > Descendants
Definition: Settings.h:7474
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:7775
Noise & set(const Suppression &value)
Set Suppression
Definition: Settings.h:7672
std::string toString() const
Get the value as string
const Settings::Processing::Filters::Noise::Suppression & get() const
Definition: Settings.h:7740
Suppression & suppression()
Get Suppression
Definition: Settings.h:7666
Removal & removal()
Get Removal
Definition: Settings.h:7607
const Settings::Processing::Filters::Noise::Suppression::Enabled & get() const
Definition: Settings.h:7750
Noise(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:7507
Noise & set(const Removal::Threshold &value)
Set Removal::Threshold
Definition: Settings.h:7627
Noise copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:7580
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:7784
const Suppression & suppression() const
Get Suppression
Definition: Settings.h:7660
const Settings::Processing::Filters::Noise::Removal::Threshold & get() const
Definition: Settings.h:7710
Noise & set(const Removal::Enabled &value)
Set Removal::Enabled
Definition: Settings.h:7620
const Repair & repair() const
Get Repair
Definition: Settings.h:7634
Noise & set(const Repair::Enabled &value)
Set Repair::Enabled
Definition: Settings.h:7653
Noise & set(const Repair &value)
Set Repair
Definition: Settings.h:7646
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:7540
bool operator!=(const Noise &other) const
Inequality operator
friend std::ostream & operator<<(std::ostream &stream, const Noise &value)
Operator to send the value as string to a stream
Definition: Settings.h:7801
Repair & repair()
Get Repair
Definition: Settings.h:7640
const Settings::Processing::Filters::Noise::Repair & get() const
Definition: Settings.h:7720
const Removal & removal() const
Get Removal
Definition: Settings.h:7601
const Settings::Processing::Filters::Noise::Removal::Enabled & get() const
Definition: Settings.h:7700
const Settings::Processing::Filters::Noise::Repair::Enabled & get() const
Definition: Settings.h:7730
bool operator==(const Noise &other) const
Equality operator
Noise & set(const Suppression::Enabled &value)
Set Suppression::Enabled
Definition: Settings.h:7679
const Settings::Processing::Filters::Noise::Removal & get() const
Definition: Settings.h:7690
Noise & set(const Removal &value)
Set Removal
Definition: Settings.h:7613
Enable or disable the outlier filter
Definition: Settings.h:7864
bool ValueType
The type of the underlying value
Definition: Settings.h:7881
bool operator!=(const Enabled &other) const
Comparison operator
Definition: Settings.h:7921
constexpr Enabled(bool value)
Constructor
Definition: Settings.h:7895
static const Enabled no
Off/disabled.
Definition: Settings.h:7883
std::string toString() const
Get the value as string
static const Enabled yes
On/enabled.
Definition: Settings.h:7882
friend std::ostream & operator<<(std::ostream &stream, const Enabled &value)
Operator to serialize the value to a stream
Definition: Settings.h:7927
static std::set< bool > validValues()
All valid values of Enabled
Definition: Settings.h:7886
bool operator==(const Enabled &other) const
Comparison operator
Definition: Settings.h:7915
Discard point if Euclidean distance to neighboring points is above the given value
Definition: Settings.h:7944
static constexpr Range< double > validRange()
The range of valid values for Threshold
Definition: Settings.h:7964
constexpr Threshold(double value)
Constructor
Definition: Settings.h:7973
bool operator<(const Threshold &other) const
Comparison operator
Definition: Settings.h:8005
bool operator==(const Threshold &other) const
Comparison operator
Definition: Settings.h:7993
bool operator>=(const Threshold &other) const
Comparison operator
Definition: Settings.h:8023
bool operator!=(const Threshold &other) const
Comparison operator
Definition: Settings.h:7999
friend std::ostream & operator<<(std::ostream &stream, const Threshold &value)
Operator to serialize the value to a stream
Definition: Settings.h:8029
bool operator<=(const Threshold &other) const
Comparison operator
Definition: Settings.h:8017
bool operator>(const Threshold &other) const
Comparison operator
Definition: Settings.h:8011
std::string toString() const
Get the value as string
double ValueType
The type of the underlying value
Definition: Settings.h:7961
Discard point if Euclidean distance to neighboring points is above a threshold
Definition: Settings.h:7844
bool operator!=(const Removal &other) const
Inequality operator
friend std::ostream & operator<<(std::ostream &stream, const Removal &value)
Operator to send the value as string to a stream
Definition: Settings.h:8261
const Enabled & isEnabled() const
Get Enabled
Definition: Settings.h:8166
Removal copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:8145
Removal & set(const Enabled &value)
Set Enabled
Definition: Settings.h:8178
Enabled & isEnabled()
Get Enabled
Definition: Settings.h:8172
Removal & set(const Threshold &value)
Set Threshold
Definition: Settings.h:8197
const Settings::Processing::Filters::Outlier::Removal::Enabled & get() const
Definition: Settings.h:8208
Removal(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:8082
const Settings::Processing::Filters::Outlier::Removal::Threshold & get() const
Definition: Settings.h:8218
std::tuple< Settings::Processing::Filters::Outlier::Removal::Enabled, Settings::Processing::Filters::Outlier::Removal::Threshold > Descendants
Definition: Settings.h:8054
const Threshold & threshold() const
Get Threshold
Definition: Settings.h:8185
Threshold & threshold()
Get Threshold
Definition: Settings.h:8191
std::string toString() const
Get the value as string
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:8237
bool operator==(const Removal &other) const
Equality operator
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:8110
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:8245
Contains a filter that removes points with large Euclidean distance to neighboring points
Definition: Settings.h:7824
const Removal & removal() const
Get Removal
Definition: Settings.h:8397
Outlier(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:8311
Outlier & set(const Removal &value)
Set Removal
Definition: Settings.h:8409
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:8474
std::string toString() const
Get the value as string
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:8467
bool operator!=(const Outlier &other) const
Inequality operator
Outlier & set(const Removal::Threshold &value)
Set Removal::Threshold
Definition: Settings.h:8423
Outlier & set(const Removal::Enabled &value)
Set Removal::Enabled
Definition: Settings.h:8416
Removal & removal()
Get Removal
Definition: Settings.h:8403
Outlier copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:8376
friend std::ostream & operator<<(std::ostream &stream, const Outlier &value)
Operator to send the value as string to a stream
Definition: Settings.h:8489
bool operator==(const Outlier &other) const
Equality operator
const Settings::Processing::Filters::Outlier::Removal::Threshold & get() const
Definition: Settings.h:8454
const Settings::Processing::Filters::Outlier::Removal & get() const
Definition: Settings.h:8434
const Settings::Processing::Filters::Outlier::Removal::Enabled & get() const
Definition: Settings.h:8444
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:8340
std::tuple< Settings::Processing::Filters::Outlier::Removal, Settings::Processing::Filters::Outlier::Removal::Enabled, Settings::Processing::Filters::Outlier::Removal::Threshold > Descendants
Definition: Settings.h:8282
Enable or disable the reflection filter. Note that this filter is computationally intensive and may a...
Definition: Settings.h:8550
bool ValueType
The type of the underlying value
Definition: Settings.h:8567
static const Enabled yes
On/enabled.
Definition: Settings.h:8568
bool operator!=(const Enabled &other) const
Comparison operator
Definition: Settings.h:8607
constexpr Enabled(bool value)
Constructor
Definition: Settings.h:8581
std::string toString() const
Get the value as string
friend std::ostream & operator<<(std::ostream &stream, const Enabled &value)
Operator to serialize the value to a stream
Definition: Settings.h:8613
static const Enabled no
Off/disabled.
Definition: Settings.h:8569
bool operator==(const Enabled &other) const
Comparison operator
Definition: Settings.h:8601
static std::set< bool > validValues()
All valid values of Enabled
Definition: Settings.h:8572
The reflection filter has two modes: Local and Global. Local mode preserves more 3D data on thinner o...
Definition: Settings.h:8657
friend std::ostream & operator<<(std::ostream &stream, const Mode &value)
Operator to serialize the value to a stream
Definition: Settings.h:8739
static const Mode global
global
Definition: Settings.h:8688
constexpr Mode(ValueType value)
Constructor
Definition: Settings.h:8701
bool operator==(const Mode &other) const
Comparison operator
Definition: Settings.h:8727
bool operator!=(const Mode &other) const
Comparison operator
Definition: Settings.h:8733
ValueType
The type of the underlying value
Definition: Settings.h:8684
static std::set< ValueType > validValues()
All valid values of Mode
Definition: Settings.h:8692
friend std::ostream & operator<<(std::ostream &stream, const Mode::ValueType &value)
Operator to serialize ValueType to a stream
Definition: Settings.h:8721
Experimental reflection filter related settings
Definition: Settings.h:8630
Experimental(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:8792
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:8919
bool operator!=(const Experimental &other) const
Inequality operator
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:8912
Experimental copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:8853
std::tuple< Settings::Processing::Filters::Reflection::Removal::Experimental::Mode > Descendants
Definition: Settings.h:8765
friend std::ostream & operator<<(std::ostream &stream, const Experimental &value)
Operator to send the value as string to a stream
Definition: Settings.h:8934
const Settings::Processing::Filters::Reflection::Removal::Experimental::Mode & get() const
Definition: Settings.h:8899
bool operator==(const Experimental &other) const
Equality operator
const Mode & mode() const
Get Mode
Definition: Settings.h:8874
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:8819
Experimental & set(const Mode &value)
Set Mode
Definition: Settings.h:8886
Discard points likely introduced by reflections (useful for shiny materials)
Definition: Settings.h:8530
const Experimental & experimental() const
Get Experimental
Definition: Settings.h:9088
Enabled & isEnabled()
Get Enabled
Definition: Settings.h:9075
friend std::ostream & operator<<(std::ostream &stream, const Removal &value)
Operator to send the value as string to a stream
Definition: Settings.h:9185
std::string toString() const
Get the value as string
bool operator==(const Removal &other) const
Equality operator
const Settings::Processing::Filters::Reflection::Removal::Enabled & get() const
Definition: Settings.h:9118
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:9012
std::tuple< Settings::Processing::Filters::Reflection::Removal::Enabled, Settings::Processing::Filters::Reflection::Removal::Experimental, Settings::Processing::Filters::Reflection::Removal::Experimental::Mode > Descendants
Definition: Settings.h:8954
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:9161
const Settings::Processing::Filters::Reflection::Removal::Experimental::Mode & get() const
Definition: Settings.h:9141
Removal copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:9048
Removal(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:8983
Removal & set(const Enabled &value)
Set Enabled
Definition: Settings.h:9081
Removal & set(const Experimental &value)
Set Experimental
Definition: Settings.h:9100
Experimental & experimental()
Get Experimental
Definition: Settings.h:9094
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:9169
const Enabled & isEnabled() const
Get Enabled
Definition: Settings.h:9069
const Settings::Processing::Filters::Reflection::Removal::Experimental & get() const
Definition: Settings.h:9129
bool operator!=(const Removal &other) const
Inequality operator
Removal & set(const Experimental::Mode &value)
Set Experimental::Mode
Definition: Settings.h:9107
Contains a filter that removes points likely introduced by reflections (useful for shiny materials)
Definition: Settings.h:8510
const Settings::Processing::Filters::Reflection::Removal::Experimental::Mode & get() const
Definition: Settings.h:9400
Reflection & set(const Removal::Experimental &value)
Set Removal::Experimental
Definition: Settings.h:9351
bool operator!=(const Reflection &other) const
Inequality operator
bool operator==(const Reflection &other) const
Equality operator
std::tuple< Settings::Processing::Filters::Reflection::Removal, Settings::Processing::Filters::Reflection::Removal::Enabled, Settings::Processing::Filters::Reflection::Removal::Experimental, Settings::Processing::Filters::Reflection::Removal::Experimental::Mode > Descendants
Definition: Settings.h:9207
const Settings::Processing::Filters::Reflection::Removal::Experimental & get() const
Definition: Settings.h:9389
Removal & removal()
Get Removal
Definition: Settings.h:9331
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:9267
friend std::ostream & operator<<(std::ostream &stream, const Reflection &value)
Operator to send the value as string to a stream
Definition: Settings.h:9435
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:9420
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:9413
Reflection & set(const Removal::Enabled &value)
Set Removal::Enabled
Definition: Settings.h:9344
const Settings::Processing::Filters::Reflection::Removal::Enabled & get() const
Definition: Settings.h:9379
Reflection(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:9237
std::string toString() const
Get the value as string
Reflection & set(const Removal::Experimental::Mode &value)
Set Removal::Experimental::Mode
Definition: Settings.h:9358
const Removal & removal() const
Get Removal
Definition: Settings.h:9325
const Settings::Processing::Filters::Reflection::Removal & get() const
Definition: Settings.h:9369
Reflection & set(const Removal &value)
Set Removal
Definition: Settings.h:9337
Reflection copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:9304
Enable or disable the smoothing filter
Definition: Settings.h:9494
bool ValueType
The type of the underlying value
Definition: Settings.h:9511
static std::set< bool > validValues()
All valid values of Enabled
Definition: Settings.h:9516
bool operator!=(const Enabled &other) const
Comparison operator
Definition: Settings.h:9551
static const Enabled yes
On/enabled.
Definition: Settings.h:9512
bool operator==(const Enabled &other) const
Comparison operator
Definition: Settings.h:9545
friend std::ostream & operator<<(std::ostream &stream, const Enabled &value)
Operator to serialize the value to a stream
Definition: Settings.h:9557
static const Enabled no
Off/disabled.
Definition: Settings.h:9513
constexpr Enabled(bool value)
Constructor
Definition: Settings.h:9525
std::string toString() const
Get the value as string
Higher values result in smoother point clouds (Standard deviation of the filter coefficients)
Definition: Settings.h:9574
double ValueType
The type of the underlying value
Definition: Settings.h:9591
bool operator!=(const Sigma &other) const
Comparison operator
Definition: Settings.h:9629
bool operator>(const Sigma &other) const
Comparison operator
Definition: Settings.h:9641
constexpr Sigma(double value)
Constructor
Definition: Settings.h:9603
static constexpr Range< double > validRange()
The range of valid values for Sigma
Definition: Settings.h:9594
friend std::ostream & operator<<(std::ostream &stream, const Sigma &value)
Operator to serialize the value to a stream
Definition: Settings.h:9659
bool operator>=(const Sigma &other) const
Comparison operator
Definition: Settings.h:9653
bool operator==(const Sigma &other) const
Comparison operator
Definition: Settings.h:9623
bool operator<=(const Sigma &other) const
Comparison operator
Definition: Settings.h:9647
std::string toString() const
Get the value as string
bool operator<(const Sigma &other) const
Comparison operator
Definition: Settings.h:9635
Gaussian smoothing of the point cloud
Definition: Settings.h:9474
Gaussian(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:9712
Enabled & isEnabled()
Get Enabled
Definition: Settings.h:9802
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:9867
const Settings::Processing::Filters::Smoothing::Gaussian::Sigma & get() const
Definition: Settings.h:9848
Gaussian & set(const Enabled &value)
Set Enabled
Definition: Settings.h:9808
friend std::ostream & operator<<(std::ostream &stream, const Gaussian &value)
Operator to send the value as string to a stream
Definition: Settings.h:9891
const Sigma & sigma() const
Get Sigma
Definition: Settings.h:9815
std::tuple< Settings::Processing::Filters::Smoothing::Gaussian::Enabled, Settings::Processing::Filters::Smoothing::Gaussian::Sigma > Descendants
Definition: Settings.h:9684
bool operator==(const Gaussian &other) const
Equality operator
const Enabled & isEnabled() const
Get Enabled
Definition: Settings.h:9796
bool operator!=(const Gaussian &other) const
Inequality operator
std::string toString() const
Get the value as string
const Settings::Processing::Filters::Smoothing::Gaussian::Enabled & get() const
Definition: Settings.h:9838
Gaussian copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:9775
Gaussian & set(const Sigma &value)
Set Sigma
Definition: Settings.h:9827
Sigma & sigma()
Get Sigma
Definition: Settings.h:9821
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:9740
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:9875
Smoothing filters
Definition: Settings.h:9456
Smoothing copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:10006
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:9970
Smoothing & set(const Gaussian &value)
Set Gaussian
Definition: Settings.h:10039
std::tuple< Settings::Processing::Filters::Smoothing::Gaussian, Settings::Processing::Filters::Smoothing::Gaussian::Enabled, Settings::Processing::Filters::Smoothing::Gaussian::Sigma > Descendants
Definition: Settings.h:9912
const Settings::Processing::Filters::Smoothing::Gaussian::Enabled & get() const
Definition: Settings.h:10074
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:10104
Smoothing & set(const Gaussian::Sigma &value)
Set Gaussian::Sigma
Definition: Settings.h:10053
Smoothing & set(const Gaussian::Enabled &value)
Set Gaussian::Enabled
Definition: Settings.h:10046
bool operator!=(const Smoothing &other) const
Inequality operator
const Gaussian & gaussian() const
Get Gaussian
Definition: Settings.h:10027
Smoothing(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:9941
std::string toString() const
Get the value as string
bool operator==(const Smoothing &other) const
Equality operator
const Settings::Processing::Filters::Smoothing::Gaussian & get() const
Definition: Settings.h:10064
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:10097
const Settings::Processing::Filters::Smoothing::Gaussian::Sigma & get() const
Definition: Settings.h:10084
friend std::ostream & operator<<(std::ostream &stream, const Smoothing &value)
Operator to send the value as string to a stream
Definition: Settings.h:10119
Gaussian & gaussian()
Get Gaussian
Definition: Settings.h:10033
Filters
Definition: Settings.h:3200
bool operator!=(const Filters &other) const
Inequality operator
const Settings::Processing::Filters::Outlier::Removal & get() const
Definition: Settings.h:11007
Filters & set(const Reflection::Removal::Enabled &value)
Set Reflection::Removal::Enabled
Definition: Settings.h:10670
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:11170
Filters & set(const Cluster &value)
Set Cluster
Definition: Settings.h:10405
const Settings::Processing::Filters::Outlier::Removal::Enabled & get() const
Definition: Settings.h:11017
Filters copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:10372
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold & get() const
Definition: Settings.h:10870
Filters & set(const Noise::Repair &value)
Set Noise::Repair
Definition: Settings.h:10576
std::string toString() const
Get the value as string
Filters & set(const Reflection::Removal::Experimental &value)
Set Reflection::Removal::Experimental
Definition: Settings.h:10677
const Settings::Processing::Filters::Noise::Suppression & get() const
Definition: Settings.h:10978
Filters & set(const Cluster::Removal::MaxNeighborDistance &value)
Set Cluster::Removal::MaxNeighborDistance
Definition: Settings.h:10426
const Settings::Processing::Filters::Noise::Removal::Enabled & get() const
Definition: Settings.h:10939
const Settings::Processing::Filters::Reflection::Removal::Experimental & get() const
Definition: Settings.h:11066
const Settings::Processing::Filters::Noise::Suppression::Enabled & get() const
Definition: Settings.h:10988
const Settings::Processing::Filters::Smoothing & get() const
Definition: Settings.h:11085
Filters & set(const Noise::Repair::Enabled &value)
Set Noise::Repair::Enabled
Definition: Settings.h:10583
const Settings::Processing::Filters::Cluster::Removal & get() const
Definition: Settings.h:10744
Cluster & cluster()
Get Cluster
Definition: Settings.h:10399
Filters & set(const Reflection::Removal::Experimental::Mode &value)
Set Reflection::Removal::Experimental::Mode
Definition: Settings.h:10684
const Settings::Processing::Filters::Reflection::Removal & get() const
Definition: Settings.h:11046
const Settings::Processing::Filters::Reflection & get() const
Definition: Settings.h:11036
Filters & set(const Outlier::Removal::Threshold &value)
Set Outlier::Removal::Threshold
Definition: Settings.h:10637
Filters & set(const Experimental::ContrastDistortion::Correction::Strength &value)
Set Experimental::ContrastDistortion::Correction::Strength
Definition: Settings.h:10480
Filters & set(const Experimental &value)
Set Experimental
Definition: Settings.h:10452
Outlier & outlier()
Get Outlier
Definition: Settings.h:10610
Filters & set(const Noise::Suppression &value)
Set Noise::Suppression
Definition: Settings.h:10590
Filters & set(const Outlier::Removal &value)
Set Outlier::Removal
Definition: Settings.h:10623
const Cluster & cluster() const
Get Cluster
Definition: Settings.h:10393
const Experimental & experimental() const
Get Experimental
Definition: Settings.h:10440
Filters & set(const Experimental::ContrastDistortion &value)
Set Experimental::ContrastDistortion
Definition: Settings.h:10459
friend std::ostream & operator<<(std::ostream &stream, const Filters &value)
Operator to send the value as string to a stream
Definition: Settings.h:11190
Filters & set(const Cluster::Removal::Enabled &value)
Set Cluster::Removal::Enabled
Definition: Settings.h:10419
const Settings::Processing::Filters::Reflection::Removal::Enabled & get() const
Definition: Settings.h:11056
const Settings::Processing::Filters::Experimental::HoleFilling & get() const
Definition: Settings.h:10881
const Settings::Processing::Filters::Outlier & get() const
Definition: Settings.h:10997
const Settings::Processing::Filters::Experimental::ContrastDistortion & get() const
Definition: Settings.h:10793
const Settings::Processing::Filters::Smoothing::Gaussian::Sigma & get() const
Definition: Settings.h:11115
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:10302
const Reflection & reflection() const
Get Reflection
Definition: Settings.h:10644
const Settings::Processing::Filters::Experimental & get() const
Definition: Settings.h:10783
Filters & set(const Experimental::HoleFilling::Enabled &value)
Set Experimental::HoleFilling::Enabled
Definition: Settings.h:10515
Filters & set(const Noise::Removal::Threshold &value)
Set Noise::Removal::Threshold
Definition: Settings.h:10569
Filters & set(const Experimental::HoleFilling &value)
Set Experimental::HoleFilling
Definition: Settings.h:10508
const Settings::Processing::Filters::Smoothing::Gaussian::Enabled & get() const
Definition: Settings.h:11105
Filters & set(const Reflection &value)
Set Reflection
Definition: Settings.h:10656
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Strength & get() const
Definition: Settings.h:10832
Filters & set(const Experimental::ContrastDistortion::Removal &value)
Set Experimental::ContrastDistortion::Removal
Definition: Settings.h:10487
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:11158
const Settings::Processing::Filters::Cluster::Removal::Enabled & get() const
Definition: Settings.h:10754
Filters & set(const Outlier &value)
Set Outlier
Definition: Settings.h:10616
const Noise & noise() const
Get Noise
Definition: Settings.h:10536
Filters & set(const Experimental::ContrastDistortion::Correction &value)
Set Experimental::ContrastDistortion::Correction
Definition: Settings.h:10466
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled & get() const
Definition: Settings.h:10818
Filters & set(const Reflection::Removal &value)
Set Reflection::Removal
Definition: Settings.h:10663
const Settings::Processing::Filters::Noise::Removal & get() const
Definition: Settings.h:10929
Filters & set(const Noise::Removal::Enabled &value)
Set Noise::Removal::Enabled
Definition: Settings.h:10562
const Settings::Processing::Filters::Experimental::HoleFilling::Strictness & get() const
Definition: Settings.h:10911
Filters & set(const Smoothing::Gaussian::Enabled &value)
Set Smoothing::Gaussian::Enabled
Definition: Settings.h:10717
const Settings::Processing::Filters::Noise & get() const
Definition: Settings.h:10920
const Settings::Processing::Filters::Noise::Repair::Enabled & get() const
Definition: Settings.h:10968
Filters & set(const Experimental::ContrastDistortion::Removal::Threshold &value)
Set Experimental::ContrastDistortion::Removal::Threshold
Definition: Settings.h:10501
Filters & set(const Smoothing::Gaussian &value)
Set Smoothing::Gaussian
Definition: Settings.h:10710
bool operator==(const Filters &other) const
Equality operator
Filters & set(const Outlier::Removal::Enabled &value)
Set Outlier::Removal::Enabled
Definition: Settings.h:10630
Filters & set(const Experimental::HoleFilling::HoleSize &value)
Set Experimental::HoleFilling::HoleSize
Definition: Settings.h:10522
Filters & set(const Cluster::Removal &value)
Set Cluster::Removal
Definition: Settings.h:10412
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled & get() const
Definition: Settings.h:10857
const Settings::Processing::Filters::Reflection::Removal::Experimental::Mode & get() const
Definition: Settings.h:11076
const Settings::Processing::Filters::Experimental::HoleFilling::HoleSize & get() const
Definition: Settings.h:10901
std::tuple< Settings::Processing::Filters::Cluster, Settings::Processing::Filters::Cluster::Removal, Settings::Processing::Filters::Cluster::Removal::Enabled, Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance, Settings::Processing::Filters::Cluster::Removal::MinArea, Settings::Processing::Filters::Experimental, Settings::Processing::Filters::Experimental::ContrastDistortion, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Strength, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold, Settings::Processing::Filters::Experimental::HoleFilling, Settings::Processing::Filters::Experimental::HoleFilling::Enabled, Settings::Processing::Filters::Experimental::HoleFilling::HoleSize, Settings::Processing::Filters::Experimental::HoleFilling::Strictness, Settings::Processing::Filters::Noise, Settings::Processing::Filters::Noise::Removal, Settings::Processing::Filters::Noise::Removal::Enabled, Settings::Processing::Filters::Noise::Removal::Threshold, Settings::Processing::Filters::Noise::Repair, Settings::Processing::Filters::Noise::Repair::Enabled, Settings::Processing::Filters::Noise::Suppression, Settings::Processing::Filters::Noise::Suppression::Enabled, Settings::Processing::Filters::Outlier, Settings::Processing::Filters::Outlier::Removal, Settings::Processing::Filters::Outlier::Removal::Enabled, Settings::Processing::Filters::Outlier::Removal::Threshold, Settings::Processing::Filters::Reflection, Settings::Processing::Filters::Reflection::Removal, Settings::Processing::Filters::Reflection::Removal::Enabled, Settings::Processing::Filters::Reflection::Removal::Experimental, Settings::Processing::Filters::Reflection::Removal::Experimental::Mode, Settings::Processing::Filters::Smoothing, Settings::Processing::Filters::Smoothing::Gaussian, Settings::Processing::Filters::Smoothing::Gaussian::Enabled, Settings::Processing::Filters::Smoothing::Gaussian::Sigma > Descendants
Definition: Settings.h:10174
Filters & set(const Cluster::Removal::MinArea &value)
Set Cluster::Removal::MinArea
Definition: Settings.h:10433
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal & get() const
Definition: Settings.h:10844
Filters(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:10238
Noise & noise()
Get Noise
Definition: Settings.h:10542
Filters & set(const Smoothing &value)
Set Smoothing
Definition: Settings.h:10703
Filters & set(const Experimental::ContrastDistortion::Correction::Enabled &value)
Set Experimental::ContrastDistortion::Correction::Enabled
Definition: Settings.h:10473
const Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance & get() const
Definition: Settings.h:10764
Filters & set(const Noise::Removal &value)
Set Noise::Removal
Definition: Settings.h:10555
const Settings::Processing::Filters::Cluster & get() const
Definition: Settings.h:10734
const Settings::Processing::Filters::Outlier::Removal::Threshold & get() const
Definition: Settings.h:11027
const Settings::Processing::Filters::Noise::Removal::Threshold & get() const
Definition: Settings.h:10949
Smoothing & smoothing()
Get Smoothing
Definition: Settings.h:10697
const Settings::Processing::Filters::Cluster::Removal::MinArea & get() const
Definition: Settings.h:10774
Filters & set(const Noise::Suppression::Enabled &value)
Set Noise::Suppression::Enabled
Definition: Settings.h:10597
const Settings::Processing::Filters::Smoothing::Gaussian & get() const
Definition: Settings.h:11095
Filters & set(const Experimental::ContrastDistortion::Removal::Enabled &value)
Set Experimental::ContrastDistortion::Removal::Enabled
Definition: Settings.h:10494
Filters & set(const Experimental::HoleFilling::Strictness &value)
Set Experimental::HoleFilling::Strictness
Definition: Settings.h:10529
const Outlier & outlier() const
Get Outlier
Definition: Settings.h:10604
const Settings::Processing::Filters::Noise::Repair & get() const
Definition: Settings.h:10958
const Settings::Processing::Filters::Experimental::HoleFilling::Enabled & get() const
Definition: Settings.h:10891
Reflection & reflection()
Get Reflection
Definition: Settings.h:10650
Filters & set(const Noise &value)
Set Noise
Definition: Settings.h:10548
Filters & set(const Smoothing::Gaussian::Sigma &value)
Set Smoothing::Gaussian::Sigma
Definition: Settings.h:10724
const Smoothing & smoothing() const
Get Smoothing
Definition: Settings.h:10691
Experimental & experimental()
Get Experimental
Definition: Settings.h:10446
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction & get() const
Definition: Settings.h:10804
Settings related to processing of a capture, including filters and color balance
Definition: Settings.h:1730
const Settings::Processing::Filters::Experimental::HoleFilling::Strictness & get() const
Definition: Settings.h:12104
const Settings::Processing::Color::Experimental::Mode & get() const
Definition: Settings.h:11911
std::tuple< Settings::Processing::Color, Settings::Processing::Color::Balance, Settings::Processing::Color::Balance::Blue, Settings::Processing::Color::Balance::Green, Settings::Processing::Color::Balance::Red, Settings::Processing::Color::Experimental, Settings::Processing::Color::Experimental::Mode, Settings::Processing::Color::Gamma, Settings::Processing::Filters, Settings::Processing::Filters::Cluster, Settings::Processing::Filters::Cluster::Removal, Settings::Processing::Filters::Cluster::Removal::Enabled, Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance, Settings::Processing::Filters::Cluster::Removal::MinArea, Settings::Processing::Filters::Experimental, Settings::Processing::Filters::Experimental::ContrastDistortion, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Strength, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold, Settings::Processing::Filters::Experimental::HoleFilling, Settings::Processing::Filters::Experimental::HoleFilling::Enabled, Settings::Processing::Filters::Experimental::HoleFilling::HoleSize, Settings::Processing::Filters::Experimental::HoleFilling::Strictness, Settings::Processing::Filters::Noise, Settings::Processing::Filters::Noise::Removal, Settings::Processing::Filters::Noise::Removal::Enabled, Settings::Processing::Filters::Noise::Removal::Threshold, Settings::Processing::Filters::Noise::Repair, Settings::Processing::Filters::Noise::Repair::Enabled, Settings::Processing::Filters::Noise::Suppression, Settings::Processing::Filters::Noise::Suppression::Enabled, Settings::Processing::Filters::Outlier, Settings::Processing::Filters::Outlier::Removal, Settings::Processing::Filters::Outlier::Removal::Enabled, Settings::Processing::Filters::Outlier::Removal::Threshold, Settings::Processing::Filters::Reflection, Settings::Processing::Filters::Reflection::Removal, Settings::Processing::Filters::Reflection::Removal::Enabled, Settings::Processing::Filters::Reflection::Removal::Experimental, Settings::Processing::Filters::Reflection::Removal::Experimental::Mode, Settings::Processing::Filters::Smoothing, Settings::Processing::Filters::Smoothing::Gaussian, Settings::Processing::Filters::Smoothing::Gaussian::Enabled, Settings::Processing::Filters::Smoothing::Gaussian::Sigma > Descendants
Definition: Settings.h:11259
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal & get() const
Definition: Settings.h:12039
const Settings::Processing::Filters::Smoothing::Gaussian & get() const
Definition: Settings.h:12284
const Settings::Processing::Filters::Reflection::Removal::Enabled & get() const
Definition: Settings.h:12245
Processing & set(const Color::Experimental &value)
Set Color::Experimental
Definition: Settings.h:11550
Processing & set(const Color &value)
Set Color
Definition: Settings.h:11515
Processing & set(const Filters::Cluster::Removal::MaxNeighborDistance &value)
Set Filters::Cluster::Removal::MaxNeighborDistance
Definition: Settings.h:11611
const Settings::Processing::Filters::Noise::Repair::Enabled & get() const
Definition: Settings.h:12160
const Settings::Processing::Color::Balance::Red & get() const
Definition: Settings.h:11893
Processing & set(const Color::Balance &value)
Set Color::Balance
Definition: Settings.h:11522
Processing & set(const Filters::Smoothing::Gaussian &value)
Set Filters::Smoothing::Gaussian
Definition: Settings.h:11835
Processing copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:11483
Filters & filters()
Get Filters
Definition: Settings.h:11577
Processing & set(const Filters::Smoothing::Gaussian::Enabled &value)
Set Filters::Smoothing::Gaussian::Enabled
Definition: Settings.h:11842
const Settings::Processing::Filters::Noise::Suppression::Enabled & get() const
Definition: Settings.h:12179
const Settings::Processing::Color::Gamma & get() const
Definition: Settings.h:11919
Processing & set(const Filters::Experimental::ContrastDistortion::Removal &value)
Set Filters::Experimental::ContrastDistortion::Removal
Definition: Settings.h:11660
Processing & set(const Filters::Experimental::HoleFilling::HoleSize &value)
Set Filters::Experimental::HoleFilling::HoleSize
Definition: Settings.h:11695
Processing()
Default constructor
const Settings::Processing::Filters::Smoothing & get() const
Definition: Settings.h:12274
Processing & set(const Filters::Experimental::ContrastDistortion::Removal::Threshold &value)
Set Filters::Experimental::ContrastDistortion::Removal::Threshold
Definition: Settings.h:11674
const Settings::Processing::Color::Balance::Green & get() const
Definition: Settings.h:11884
Processing & set(const Filters::Outlier::Removal &value)
Set Filters::Outlier::Removal
Definition: Settings.h:11772
Processing & set(const Filters::Experimental::ContrastDistortion::Removal::Enabled &value)
Set Filters::Experimental::ContrastDistortion::Removal::Enabled
Definition: Settings.h:11667
Processing & set(const Filters::Cluster::Removal::Enabled &value)
Set Filters::Cluster::Removal::Enabled
Definition: Settings.h:11604
friend std::ostream & operator<<(std::ostream &stream, const Processing &value)
Operator to send the value as string to a stream
Definition: Settings.h:12347
const Settings::Processing::Filters::Noise::Suppression & get() const
Definition: Settings.h:12169
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled & get() const
Definition: Settings.h:12050
const Settings::Processing::Filters::Reflection::Removal & get() const
Definition: Settings.h:12235
std::string toString() const
Get the value as string
const Settings::Processing::Filters::Noise::Removal::Threshold & get() const
Definition: Settings.h:12141
const Settings::Processing::Filters::Smoothing::Gaussian::Sigma & get() const
Definition: Settings.h:12304
const Settings::Processing::Filters::Noise::Removal::Enabled & get() const
Definition: Settings.h:12131
Processing & set(const Color::Balance::Blue &value)
Set Color::Balance::Blue
Definition: Settings.h:11529
Color & color()
Get Color
Definition: Settings.h:11509
Processing & set(const Filters::Experimental::HoleFilling::Strictness &value)
Set Filters::Experimental::HoleFilling::Strictness
Definition: Settings.h:11702
const Settings::Processing::Filters::Reflection::Removal::Experimental & get() const
Definition: Settings.h:12255
const Settings::Processing::Filters::Smoothing::Gaussian::Enabled & get() const
Definition: Settings.h:12294
Processing & set(const Filters::Reflection &value)
Set Filters::Reflection
Definition: Settings.h:11793
Processing & set(const Filters::Noise &value)
Set Filters::Noise
Definition: Settings.h:11709
Processing & set(const Filters::Cluster &value)
Set Filters::Cluster
Definition: Settings.h:11590
const Settings::Processing::Filters::Outlier & get() const
Definition: Settings.h:12187
const Settings::Processing::Filters & get() const
Definition: Settings.h:11927
Processing & set(const Filters::Experimental::ContrastDistortion::Correction::Strength &value)
Set Filters::Experimental::ContrastDistortion::Correction::Strength
Definition: Settings.h:11653
Processing & set(const Filters::Noise::Removal::Enabled &value)
Set Filters::Noise::Removal::Enabled
Definition: Settings.h:11723
Processing & set(const Filters::Smoothing &value)
Set Filters::Smoothing
Definition: Settings.h:11828
const Settings::Processing::Color::Balance & get() const
Definition: Settings.h:11866
const Filters & filters() const
Get Filters
Definition: Settings.h:11571
Processing & set(const Filters::Cluster::Removal &value)
Set Filters::Cluster::Removal
Definition: Settings.h:11597
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:12331
const Settings::Processing::Filters::Cluster::Removal::MinArea & get() const
Definition: Settings.h:11974
Processing & set(const Filters::Smoothing::Gaussian::Sigma &value)
Set Filters::Smoothing::Gaussian::Sigma
Definition: Settings.h:11849
Processing & set(const Filters::Noise::Suppression &value)
Set Filters::Noise::Suppression
Definition: Settings.h:11751
Processing & set(const Filters::Noise::Removal &value)
Set Filters::Noise::Removal
Definition: Settings.h:11716
const Settings::Processing::Filters::Experimental::HoleFilling::Enabled & get() const
Definition: Settings.h:12084
Processing & set(const Filters::Reflection::Removal::Experimental &value)
Set Filters::Reflection::Removal::Experimental
Definition: Settings.h:11814
Processing & set(const Filters::Outlier::Removal::Enabled &value)
Set Filters::Outlier::Removal::Enabled
Definition: Settings.h:11779
Processing & set(const Filters::Noise::Removal::Threshold &value)
Set Filters::Noise::Removal::Threshold
Definition: Settings.h:11730
const Settings::Processing::Color::Balance::Blue & get() const
Definition: Settings.h:11875
Processing & set(const Filters::Cluster::Removal::MinArea &value)
Set Filters::Cluster::Removal::MinArea
Definition: Settings.h:11618
Processing & set(const Filters::Experimental &value)
Set Filters::Experimental
Definition: Settings.h:11625
const Settings::Processing::Filters::Noise::Removal & get() const
Definition: Settings.h:12121
Processing & set(const Filters::Outlier::Removal::Threshold &value)
Set Filters::Outlier::Removal::Threshold
Definition: Settings.h:11786
Processing & set(const Filters::Experimental::HoleFilling &value)
Set Filters::Experimental::HoleFilling
Definition: Settings.h:11681
Processing & set(const Color::Balance::Green &value)
Set Color::Balance::Green
Definition: Settings.h:11536
Processing & set(const Filters::Experimental::HoleFilling::Enabled &value)
Set Filters::Experimental::HoleFilling::Enabled
Definition: Settings.h:11688
const Settings::Processing::Color::Experimental & get() const
Definition: Settings.h:11902
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Strength & get() const
Definition: Settings.h:12028
Processing & set(const Filters::Outlier &value)
Set Filters::Outlier
Definition: Settings.h:11765
Processing & set(const Filters::Noise::Repair::Enabled &value)
Set Filters::Noise::Repair::Enabled
Definition: Settings.h:11744
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled & get() const
Definition: Settings.h:12015
Processing & set(const Color::Experimental::Mode &value)
Set Color::Experimental::Mode
Definition: Settings.h:11557
Processing & set(const Filters::Reflection::Removal::Enabled &value)
Set Filters::Reflection::Removal::Enabled
Definition: Settings.h:11807
Processing & set(const Filters::Experimental::ContrastDistortion::Correction::Enabled &value)
Set Filters::Experimental::ContrastDistortion::Correction::Enabled
Definition: Settings.h:11646
const Settings::Processing::Filters::Cluster::Removal::Enabled & get() const
Definition: Settings.h:11954
const Settings::Processing::Filters::Outlier::Removal::Threshold & get() const
Definition: Settings.h:12216
Processing & set(const Filters::Reflection::Removal::Experimental::Mode &value)
Set Filters::Reflection::Removal::Experimental::Mode
Definition: Settings.h:11821
Processing & set(const Filters::Reflection::Removal &value)
Set Filters::Reflection::Removal
Definition: Settings.h:11800
const Settings::Processing::Filters::Reflection::Removal::Experimental::Mode & get() const
Definition: Settings.h:12265
const Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance & get() const
Definition: Settings.h:11964
Processing(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:11332
Processing & set(const Filters::Experimental::ContrastDistortion::Correction &value)
Set Filters::Experimental::ContrastDistortion::Correction
Definition: Settings.h:11639
const Settings::Processing::Color & get() const
Definition: Settings.h:11858
bool operator==(const Processing &other) const
Equality operator
const Color & color() const
Get Color
Definition: Settings.h:11503
Processing & set(const Filters::Experimental::ContrastDistortion &value)
Set Filters::Experimental::ContrastDistortion
Definition: Settings.h:11632
Processing & set(const Filters::Noise::Suppression::Enabled &value)
Set Filters::Noise::Suppression::Enabled
Definition: Settings.h:11758
const Settings::Processing::Filters::Cluster::Removal & get() const
Definition: Settings.h:11944
const Settings::Processing::Filters::Reflection & get() const
Definition: Settings.h:12225
const Settings::Processing::Filters::Outlier::Removal::Enabled & get() const
Definition: Settings.h:12206
Processing & set(const Filters &value)
Set Filters
Definition: Settings.h:11583
const Settings::Processing::Filters::Experimental::HoleFilling::HoleSize & get() const
Definition: Settings.h:12094
Processing & set(const Color::Balance::Red &value)
Set Color::Balance::Red
Definition: Settings.h:11543
const Settings::Processing::Filters::Noise & get() const
Definition: Settings.h:12112
bool operator!=(const Processing &other) const
Inequality operator
const Settings::Processing::Filters::Experimental & get() const
Definition: Settings.h:11983
const Settings::Processing::Filters::Noise::Repair & get() const
Definition: Settings.h:12150
Processing & set(const Color::Gamma &value)
Set Color::Gamma
Definition: Settings.h:11564
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:11405
const Settings::Processing::Filters::Experimental::HoleFilling & get() const
Definition: Settings.h:12074
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold & get() const
Definition: Settings.h:12063
const Settings::Processing::Filters::Cluster & get() const
Definition: Settings.h:11935
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction & get() const
Definition: Settings.h:12003
Processing & set(const Filters::Noise::Repair &value)
Set Filters::Noise::Repair
Definition: Settings.h:11737
const Settings::Processing::Filters::Experimental::ContrastDistortion & get() const
Definition: Settings.h:11993
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:12323
const Settings::Processing::Filters::Outlier::Removal & get() const
Definition: Settings.h:12196
Enabled
Definition: Settings.h:12427
constexpr Enabled(bool value)
Constructor
Definition: Settings.h:12456
bool ValueType
The type of the underlying value
Definition: Settings.h:12442
bool operator==(const Enabled &other) const
Comparison operator
Definition: Settings.h:12476
static std::set< bool > validValues()
All valid values of Enabled
Definition: Settings.h:12447
static const Enabled yes
On/enabled.
Definition: Settings.h:12443
static const Enabled no
Off/disabled.
Definition: Settings.h:12444
bool hasValue() const
Check if the value is set
void reset()
Reset the node to unset state
friend std::ostream & operator<<(std::ostream &stream, const Enabled &value)
Operator to serialize the value to a stream
Definition: Settings.h:12488
std::string toString() const
Get the value as string
bool operator!=(const Enabled &other) const
Comparison operator
Definition: Settings.h:12482
Two points on the normal describing the direction and distance from the plane from which the normal i...
Definition: Settings.h:12505
std::string toString() const
Get the value as string
bool operator==(const Extents &other) const
Comparison operator
Definition: Settings.h:12553
void reset()
Reset the node to unset state
constexpr Extents(Zivid::Range< double > value)
Constructor
Definition: Settings.h:12528
constexpr Extents(double minValue, double maxValue)
Constructor
Definition: Settings.h:12548
bool hasValue() const
Check if the value is set
friend std::ostream & operator<<(std::ostream &stream, const Extents &value)
Operator to serialize the value to a stream
Definition: Settings.h:12565
const Zivid::Range< double > & value() const
Get the value
bool operator!=(const Extents &other) const
Comparison operator
Definition: Settings.h:12559
A point such that the vector from PointO to PointA describes the first edge of the parallelogram
Definition: Settings.h:12582
void reset()
Reset the node to unset state
constexpr PointA(float x, float y, float z)
Constructor
Definition: Settings.h:12625
bool operator!=(const PointA &other) const
Comparison operator
Definition: Settings.h:12636
bool operator==(const PointA &other) const
Comparison operator
Definition: Settings.h:12630
bool hasValue() const
Check if the value is set
friend std::ostream & operator<<(std::ostream &stream, const PointA &value)
Operator to serialize the value to a stream
Definition: Settings.h:12642
constexpr PointA(Zivid::PointXYZ value)
Constructor
Definition: Settings.h:12605
Zivid::PointXYZ value() const
Get the value
std::string toString() const
Get the value as string
A point such that the vector from PointO to PointB describes the second edge of the parallelogram
Definition: Settings.h:12659
bool operator==(const PointB &other) const
Comparison operator
Definition: Settings.h:12707
bool hasValue() const
Check if the value is set
friend std::ostream & operator<<(std::ostream &stream, const PointB &value)
Operator to serialize the value to a stream
Definition: Settings.h:12719
void reset()
Reset the node to unset state
std::string toString() const
Get the value as string
constexpr PointB(float x, float y, float z)
Constructor
Definition: Settings.h:12702
constexpr PointB(Zivid::PointXYZ value)
Constructor
Definition: Settings.h:12682
Zivid::PointXYZ value() const
Get the value
bool operator!=(const PointB &other) const
Comparison operator
Definition: Settings.h:12713
The point at the intersection of two adjacent edges defining a parallelogram
Definition: Settings.h:12736
constexpr PointO(float x, float y, float z)
Constructor
Definition: Settings.h:12779
void reset()
Reset the node to unset state
bool operator!=(const PointO &other) const
Comparison operator
Definition: Settings.h:12790
constexpr PointO(Zivid::PointXYZ value)
Constructor
Definition: Settings.h:12759
bool operator==(const PointO &other) const
Comparison operator
Definition: Settings.h:12784
bool hasValue() const
Check if the value is set
Zivid::PointXYZ value() const
Get the value
std::string toString() const
Get the value as string
friend std::ostream & operator<<(std::ostream &stream, const PointO &value)
Operator to serialize the value to a stream
Definition: Settings.h:12796
Removes the points outside the box.
Definition: Settings.h:12399
std::tuple< Settings::RegionOfInterest::Box::Enabled, Settings::RegionOfInterest::Box::Extents, Settings::RegionOfInterest::Box::PointA, Settings::RegionOfInterest::Box::PointB, Settings::RegionOfInterest::Box::PointO > Descendants
Definition: Settings.h:12814
std::string toString() const
Get the value as string
Box & set(const PointA &value)
Set PointA
Definition: Settings.h:12984
Box copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:12913
const PointO & pointO() const
Get PointO
Definition: Settings.h:13010
Box & set(const PointO &value)
Set PointO
Definition: Settings.h:13022
Enabled & isEnabled()
Get Enabled
Definition: Settings.h:12940
const Enabled & isEnabled() const
Get Enabled
Definition: Settings.h:12934
Box & set(const Extents &value)
Set Extents
Definition: Settings.h:12965
const Settings::RegionOfInterest::Box::Enabled & get() const
Definition: Settings.h:13032
PointA & pointA()
Get PointA
Definition: Settings.h:12978
PointB & pointB()
Get PointB
Definition: Settings.h:12997
Box & set(const PointB &value)
Set PointB
Definition: Settings.h:13003
const Settings::RegionOfInterest::Box::PointO & get() const
Definition: Settings.h:13068
const Settings::RegionOfInterest::Box::PointA & get() const
Definition: Settings.h:13050
const Extents & extents() const
Get Extents
Definition: Settings.h:12953
Box(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:12845
const PointA & pointA() const
Get PointA
Definition: Settings.h:12972
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:12876
PointO & pointO()
Get PointO
Definition: Settings.h:13016
Extents & extents()
Get Extents
Definition: Settings.h:12959
const PointB & pointB() const
Get PointB
Definition: Settings.h:12991
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:13105
friend std::ostream & operator<<(std::ostream &stream, const Box &value)
Operator to send the value as string to a stream
Definition: Settings.h:13135
bool operator!=(const Box &other) const
Inequality operator
bool operator==(const Box &other) const
Equality operator
const Settings::RegionOfInterest::Box::PointB & get() const
Definition: Settings.h:13059
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:13116
const Settings::RegionOfInterest::Box::Extents & get() const
Definition: Settings.h:13041
Box & set(const Enabled &value)
Set Enabled
Definition: Settings.h:12946
Enabled
Definition: Settings.h:13184
static const Enabled yes
On/enabled.
Definition: Settings.h:13200
bool hasValue() const
Check if the value is set
void reset()
Reset the node to unset state
bool operator==(const Enabled &other) const
Comparison operator
Definition: Settings.h:13233
bool operator!=(const Enabled &other) const
Comparison operator
Definition: Settings.h:13239
bool ValueType
The type of the underlying value
Definition: Settings.h:13199
friend std::ostream & operator<<(std::ostream &stream, const Enabled &value)
Operator to serialize the value to a stream
Definition: Settings.h:13245
static std::set< bool > validValues()
All valid values of Enabled
Definition: Settings.h:13204
std::string toString() const
Get the value as string
static const Enabled no
Off/disabled.
Definition: Settings.h:13201
constexpr Enabled(bool value)
Constructor
Definition: Settings.h:13213
Specify the minimum and maximum Z value that will be included.
Definition: Settings.h:13262
constexpr Range(double minValue, double maxValue)
Constructor
Definition: Settings.h:13305
constexpr Range(Zivid::Range< double > value)
Constructor
Definition: Settings.h:13285
const Zivid::Range< double > & value() const
Get the value
std::string toString() const
Get the value as string
friend std::ostream & operator<<(std::ostream &stream, const Range &value)
Operator to serialize the value to a stream
Definition: Settings.h:13322
bool operator==(const Range &other) const
Comparison operator
Definition: Settings.h:13310
bool operator!=(const Range &other) const
Comparison operator
Definition: Settings.h:13316
void reset()
Reset the node to unset state
bool hasValue() const
Check if the value is set
Removes points that reside outside of a depth range, meaning that their Z coordinate falls above a gi...
Definition: Settings.h:13162
Depth & set(const Enabled &value)
Set Enabled
Definition: Settings.h:13459
std::string toString() const
Get the value as string
const Range & range() const
Get Range
Definition: Settings.h:13466
Depth & set(const Range &value)
Set Range
Definition: Settings.h:13478
std::tuple< Settings::RegionOfInterest::Depth::Enabled, Settings::RegionOfInterest::Depth::Range > Descendants
Definition: Settings.h:13336
const Enabled & isEnabled() const
Get Enabled
Definition: Settings.h:13447
bool operator==(const Depth &other) const
Equality operator
Depth(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:13364
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:13524
bool operator!=(const Depth &other) const
Inequality operator
const Settings::RegionOfInterest::Depth::Enabled & get() const
Definition: Settings.h:13488
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:13516
Range & range()
Get Range
Definition: Settings.h:13472
friend std::ostream & operator<<(std::ostream &stream, const Depth &value)
Operator to send the value as string to a stream
Definition: Settings.h:13540
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:13392
Enabled & isEnabled()
Get Enabled
Definition: Settings.h:13453
const Settings::RegionOfInterest::Depth::Range & get() const
Definition: Settings.h:13497
Depth copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:13426
Removes points outside the region of interest.
Definition: Settings.h:12370
const Settings::RegionOfInterest::Depth::Enabled & get() const
Definition: Settings.h:13845
std::tuple< Settings::RegionOfInterest::Box, Settings::RegionOfInterest::Box::Enabled, Settings::RegionOfInterest::Box::Extents, Settings::RegionOfInterest::Box::PointA, Settings::RegionOfInterest::Box::PointB, Settings::RegionOfInterest::Box::PointO, Settings::RegionOfInterest::Depth, Settings::RegionOfInterest::Depth::Enabled, Settings::RegionOfInterest::Depth::Range > Descendants
Definition: Settings.h:13567
Depth & depth()
Get Depth
Definition: Settings.h:13757
RegionOfInterest & set(const Depth::Enabled &value)
Set Depth::Enabled
Definition: Settings.h:13770
const Box & box() const
Get Box
Definition: Settings.h:13697
RegionOfInterest & set(const Box &value)
Set Box
Definition: Settings.h:13709
friend std::ostream & operator<<(std::ostream &stream, const RegionOfInterest &value)
Operator to send the value as string to a stream
Definition: Settings.h:13897
RegionOfInterest & set(const Box::PointO &value)
Set Box::PointO
Definition: Settings.h:13744
const Settings::RegionOfInterest::Box::PointO & get() const
Definition: Settings.h:13828
std::string toString() const
Get the value as string
const Settings::RegionOfInterest::Box::PointA & get() const
Definition: Settings.h:13812
const Settings::RegionOfInterest::Depth & get() const
Definition: Settings.h:13836
const Settings::RegionOfInterest::Box::Extents & get() const
Definition: Settings.h:13804
const Settings::RegionOfInterest::Depth::Range & get() const
Definition: Settings.h:13854
const Settings::RegionOfInterest::Box::PointB & get() const
Definition: Settings.h:13820
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:13637
RegionOfInterest copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:13677
Box & box()
Get Box
Definition: Settings.h:13703
const Settings::RegionOfInterest::Box & get() const
Definition: Settings.h:13786
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:13873
RegionOfInterest & set(const Box::PointA &value)
Set Box::PointA
Definition: Settings.h:13730
const Depth & depth() const
Get Depth
Definition: Settings.h:13751
RegionOfInterest & set(const Box::Extents &value)
Set Box::Extents
Definition: Settings.h:13723
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:13881
RegionOfInterest & set(const Box::Enabled &value)
Set Box::Enabled
Definition: Settings.h:13716
RegionOfInterest & set(const Depth::Range &value)
Set Depth::Range
Definition: Settings.h:13777
bool operator!=(const RegionOfInterest &other) const
Inequality operator
RegionOfInterest & set(const Depth &value)
Set Depth
Definition: Settings.h:13763
RegionOfInterest & set(const Box::PointB &value)
Set Box::PointB
Definition: Settings.h:13737
bool operator==(const RegionOfInterest &other) const
Equality operator
RegionOfInterest(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:13602
const Settings::RegionOfInterest::Box::Enabled & get() const
Definition: Settings.h:13795
RegionOfInterest()
Default constructor
Choose how to sample colors for the pointcloud. The rgb option gives all colors for a regular Zivid c...
Definition: Settings.h:13943
ValueType
The type of the underlying value
Definition: Settings.h:13965
std::string toString() const
Get the value as string
static std::set< ValueType > validValues()
All valid values of Color
Definition: Settings.h:13973
friend std::ostream & operator<<(std::ostream &stream, const Color &value)
Operator to serialize the value to a stream
Definition: Settings.h:14020
constexpr Color(ValueType value)
Constructor
Definition: Settings.h:13982
bool operator!=(const Color &other) const
Comparison operator
Definition: Settings.h:14014
Color()=default
Default constructor
static const Color disabled
disabled
Definition: Settings.h:13970
bool hasValue() const
Check if the value is set
void reset()
Reset the node to unset state
bool operator==(const Color &other) const
Comparison operator
Definition: Settings.h:14008
friend std::ostream & operator<<(std::ostream &stream, const Color::ValueType &value)
Operator to serialize ValueType to a stream
Definition: Settings.h:14002
static const Color rgb
rgb
Definition: Settings.h:13969
ValueType value() const
Get the value
Set whether the full image sensor should be used with white projector light or only specific color ch...
Definition: Settings.h:14055
ValueType value() const
Get the value
void reset()
Reset the node to unset state
static std::set< ValueType > validValues()
All valid values of Pixel
Definition: Settings.h:14091
constexpr Pixel(ValueType value)
Constructor
Definition: Settings.h:14100
static const Pixel all
all
Definition: Settings.h:14086
static const Pixel blueSubsample2x2
blueSubsample2x2
Definition: Settings.h:14087
bool operator!=(const Pixel &other) const
Comparison operator
Definition: Settings.h:14132
ValueType
The type of the underlying value
Definition: Settings.h:14081
static const Pixel redSubsample2x2
redSubsample2x2
Definition: Settings.h:14088
Pixel()=default
Default constructor
bool operator==(const Pixel &other) const
Comparison operator
Definition: Settings.h:14126
bool hasValue() const
Check if the value is set
friend std::ostream & operator<<(std::ostream &stream, const Pixel::ValueType &value)
Operator to serialize ValueType to a stream
Definition: Settings.h:14120
friend std::ostream & operator<<(std::ostream &stream, const Pixel &value)
Operator to serialize the value to a stream
Definition: Settings.h:14138
std::string toString() const
Get the value as string
Sampling group
Definition: Settings.h:13920
std::tuple< Settings::Sampling::Color, Settings::Sampling::Pixel > Descendants
Definition: Settings.h:14162
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:14218
bool operator==(const Sampling &other) const
Equality operator
Color & color()
Get Color
Definition: Settings.h:14277
Sampling copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:14251
const Pixel & pixel() const
Get Pixel
Definition: Settings.h:14290
friend std::ostream & operator<<(std::ostream &stream, const Sampling &value)
Operator to send the value as string to a stream
Definition: Settings.h:14362
Pixel & pixel()
Get Pixel
Definition: Settings.h:14296
const Settings::Sampling::Color & get() const
Definition: Settings.h:14311
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:14338
Sampling()
Default constructor
const Settings::Sampling::Pixel & get() const
Definition: Settings.h:14319
bool operator!=(const Sampling &other) const
Inequality operator
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:14346
Sampling(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:14190
const Color & color() const
Get Color
Definition: Settings.h:14271
std::string toString() const
Get the value as string
Sampling & set(const Color &value)
Set Color
Definition: Settings.h:14283
Sampling & set(const Pixel &value)
Set Pixel
Definition: Settings.h:14302
Settings used when capturing with a Zivid camera
Definition: Settings.h:124
const Settings::RegionOfInterest::Depth & get() const
Definition: Settings.h:15819
const Settings::Processing::Filters::Outlier::Removal::Enabled & get() const
Definition: Settings.h:15663
Settings(Args &&...args)
Constructor taking variadic number of arguments
Definition: Settings.h:14540
Settings & set(const Processing::Filters::Cluster::Removal::MinArea &value)
Set Processing::Filters::Cluster::Removal::MinArea
Definition: Settings.h:14929
const Settings::Processing::Filters::Outlier & get() const
Definition: Settings.h:15644
Settings & set(const RegionOfInterest::Box::PointB &value)
Set RegionOfInterest::Box::PointB
Definition: Settings.h:15214
const Settings::Processing::Color::Balance & get() const
Definition: Settings.h:15332
Settings & set(const Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled &value)
Set Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled
Definition: Settings.h:14978
const Experimental & experimental() const
Get Experimental
Definition: Settings.h:14793
const Settings::Processing::Color::Balance::Red & get() const
Definition: Settings.h:15356
Settings & set(const Processing::Color::Experimental::Mode &value)
Set Processing::Color::Experimental::Mode
Definition: Settings.h:14880
Settings & set(const Processing::Filters::Smoothing &value)
Set Processing::Filters::Smoothing
Definition: Settings.h:15139
const Settings::Processing::Filters::Experimental::HoleFilling::Enabled & get() const
Definition: Settings.h:15542
const Settings::RegionOfInterest & get() const
Definition: Settings.h:15763
const Settings::Processing::Filters::Noise::Removal & get() const
Definition: Settings.h:15579
Settings copyWith(Args &&...args) const
Returns a copy of this object with the given argument(s) set to the new value(s)
Definition: Settings.h:14729
const Processing & processing() const
Get Processing
Definition: Settings.h:14819
const Settings::Processing::Filters::Experimental::HoleFilling::HoleSize & get() const
Definition: Settings.h:15552
const Settings::Experimental & get() const
Definition: Settings.h:15302
const Settings::Processing::Color::Gamma & get() const
Definition: Settings.h:15381
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal & get() const
Definition: Settings.h:15498
Settings & set(const Processing &value)
Set Processing
Definition: Settings.h:14831
const Settings::Sampling::Pixel & get() const
Definition: Settings.h:15853
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold & get() const
Definition: Settings.h:15521
Settings & set(const Sampling &value)
Set Sampling
Definition: Settings.h:15261
Settings & set(const Processing::Filters::Outlier::Removal::Enabled &value)
Set Processing::Filters::Outlier::Removal::Enabled
Definition: Settings.h:15090
const Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance & get() const
Definition: Settings.h:15426
Settings & set(const Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold &value)
Set Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold
Definition: Settings.h:14985
Settings & set(const Experimental::Engine &value)
Set Experimental::Engine
Definition: Settings.h:14812
Settings & set(const Processing::Filters::Smoothing::Gaussian &value)
Set Processing::Filters::Smoothing::Gaussian
Definition: Settings.h:15146
Settings & set(const Sampling::Color &value)
Set Sampling::Color
Definition: Settings.h:15268
Settings & set(const Diagnostics &value)
Set Diagnostics
Definition: Settings.h:14779
const Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled & get() const
Definition: Settings.h:15509
Settings & set(const RegionOfInterest::Depth::Enabled &value)
Set RegionOfInterest::Depth::Enabled
Definition: Settings.h:15235
Settings & set(const Processing::Filters::Noise &value)
Set Processing::Filters::Noise
Definition: Settings.h:15020
const Sampling & sampling() const
Get Sampling
Definition: Settings.h:15249
void load(const std::string &fileName)
Load from the given file
const Settings::Processing::Filters::Cluster::Removal::MinArea & get() const
Definition: Settings.h:15436
const Settings::Acquisitions & get() const
Definition: Settings.h:15282
const Settings::Processing::Filters::Experimental::HoleFilling & get() const
Definition: Settings.h:15532
const Settings::Processing::Filters::Experimental & get() const
Definition: Settings.h:15444
const Settings::Processing::Filters::Noise::Suppression & get() const
Definition: Settings.h:15626
const Settings::Processing::Filters::Outlier::Removal & get() const
Definition: Settings.h:15653
Settings & set(const Processing::Filters::Cluster &value)
Set Processing::Filters::Cluster
Definition: Settings.h:14901
const Settings::Processing::Filters::Smoothing::Gaussian::Sigma & get() const
Definition: Settings.h:15757
Settings & set(const Processing::Filters::Reflection::Removal::Experimental &value)
Set Processing::Filters::Reflection::Removal::Experimental
Definition: Settings.h:15125
const Settings::Diagnostics & get() const
Definition: Settings.h:15288
RegionOfInterest & regionOfInterest()
Get RegionOfInterest
Definition: Settings.h:15173
const Settings::Processing::Filters::Smoothing::Gaussian::Enabled & get() const
Definition: Settings.h:15747
const Settings::RegionOfInterest::Box & get() const
Definition: Settings.h:15771
Settings & set(const Processing::Color::Balance &value)
Set Processing::Color::Balance
Definition: Settings.h:14845
const Settings::RegionOfInterest::Box::PointO & get() const
Definition: Settings.h:15811
Settings & set(const RegionOfInterest::Depth &value)
Set RegionOfInterest::Depth
Definition: Settings.h:15228
const Settings::Processing::Filters::Noise::Removal::Enabled & get() const
Definition: Settings.h:15589
const Settings::RegionOfInterest::Depth::Enabled & get() const
Definition: Settings.h:15827
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction & get() const
Definition: Settings.h:15464
void forEach(const F &f) const
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:15896
const Settings::Processing::Color::Balance::Green & get() const
Definition: Settings.h:15348
const Settings::RegionOfInterest::Box::Extents & get() const
Definition: Settings.h:15787
Settings & set(const Processing::Filters::Smoothing::Gaussian::Enabled &value)
Set Processing::Filters::Smoothing::Gaussian::Enabled
Definition: Settings.h:15153
const Settings::Processing & get() const
Definition: Settings.h:15316
Settings & set(const Processing::Filters::Reflection &value)
Set Processing::Filters::Reflection
Definition: Settings.h:15104
const Settings::Experimental::Engine & get() const
Definition: Settings.h:15310
void forEach(const F &f)
Run the given function on each direct member with the value of the member as parameter
Definition: Settings.h:15908
Settings()
Default constructor
const Settings::Processing::Filters::Experimental::ContrastDistortion & get() const
Definition: Settings.h:15454
Settings & set(const Processing::Filters::Outlier::Removal::Threshold &value)
Set Processing::Filters::Outlier::Removal::Threshold
Definition: Settings.h:15097
const Settings::RegionOfInterest::Box::Enabled & get() const
Definition: Settings.h:15779
const Settings::Processing::Color::Experimental::Mode & get() const
Definition: Settings.h:15373
Settings & set(const Processing::Filters::Experimental::ContrastDistortion::Correction::Strength &value)
Set Processing::Filters::Experimental::ContrastDistortion::Correction::Strength
Definition: Settings.h:14964
Settings & set(const RegionOfInterest::Box::Enabled &value)
Set RegionOfInterest::Box::Enabled
Definition: Settings.h:15193
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Strength & get() const
Definition: Settings.h:15487
Settings & set(const RegionOfInterest::Box::Extents &value)
Set RegionOfInterest::Box::Extents
Definition: Settings.h:15200
const Settings::Processing::Color::Balance::Blue & get() const
Definition: Settings.h:15340
std::tuple< Settings::Acquisitions, Settings::Diagnostics, Settings::Diagnostics::Enabled, Settings::Experimental, Settings::Experimental::Engine, Settings::Processing, Settings::Processing::Color, Settings::Processing::Color::Balance, Settings::Processing::Color::Balance::Blue, Settings::Processing::Color::Balance::Green, Settings::Processing::Color::Balance::Red, Settings::Processing::Color::Experimental, Settings::Processing::Color::Experimental::Mode, Settings::Processing::Color::Gamma, Settings::Processing::Filters, Settings::Processing::Filters::Cluster, Settings::Processing::Filters::Cluster::Removal, Settings::Processing::Filters::Cluster::Removal::Enabled, Settings::Processing::Filters::Cluster::Removal::MaxNeighborDistance, Settings::Processing::Filters::Cluster::Removal::MinArea, Settings::Processing::Filters::Experimental, Settings::Processing::Filters::Experimental::ContrastDistortion, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled, Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Strength, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Enabled, Settings::Processing::Filters::Experimental::ContrastDistortion::Removal::Threshold, Settings::Processing::Filters::Experimental::HoleFilling, Settings::Processing::Filters::Experimental::HoleFilling::Enabled, Settings::Processing::Filters::Experimental::HoleFilling::HoleSize, Settings::Processing::Filters::Experimental::HoleFilling::Strictness, Settings::Processing::Filters::Noise, Settings::Processing::Filters::Noise::Removal, Settings::Processing::Filters::Noise::Removal::Enabled, Settings::Processing::Filters::Noise::Removal::Threshold, Settings::Processing::Filters::Noise::Repair, Settings::Processing::Filters::Noise::Repair::Enabled, Settings::Processing::Filters::Noise::Suppression, Settings::Processing::Filters::Noise::Suppression::Enabled, Settings::Processing::Filters::Outlier, Settings::Processing::Filters::Outlier::Removal, Settings::Processing::Filters::Outlier::Removal::Enabled, Settings::Processing::Filters::Outlier::Removal::Threshold, Settings::Processing::Filters::Reflection, Settings::Processing::Filters::Reflection::Removal, Settings::Processing::Filters::Reflection::Removal::Enabled, Settings::Processing::Filters::Reflection::Removal::Experimental, Settings::Processing::Filters::Reflection::Removal::Experimental::Mode, Settings::Processing::Filters::Smoothing, Settings::Processing::Filters::Smoothing::Gaussian, Settings::Processing::Filters::Smoothing::Gaussian::Enabled, Settings::Processing::Filters::Smoothing::Gaussian::Sigma, Settings::RegionOfInterest, Settings::RegionOfInterest::Box, Settings::RegionOfInterest::Box::Enabled, Settings::RegionOfInterest::Box::Extents, Settings::RegionOfInterest::Box::PointA, Settings::RegionOfInterest::Box::PointB, Settings::RegionOfInterest::Box::PointO, Settings::RegionOfInterest::Depth, Settings::RegionOfInterest::Depth::Enabled, Settings::RegionOfInterest::Depth::Range, Settings::Sampling, Settings::Sampling::Color, Settings::Sampling::Pixel > Descendants
Definition: Settings.h:14446
const Acquisitions & acquisitions() const
Get Acquisitions
Definition: Settings.h:14748
void set(Args &&...args)
Set multiple arguments
Definition: Settings.h:14632
const Settings::Processing::Filters::Reflection & get() const
Definition: Settings.h:15681
Settings & set(const Processing::Filters::Experimental &value)
Set Processing::Filters::Experimental
Definition: Settings.h:14936
const Settings::Processing::Filters::Smoothing & get() const
Definition: Settings.h:15728
const Settings::Processing::Filters & get() const
Definition: Settings.h:15389
Settings & set(const Processing::Color::Experimental &value)
Set Processing::Color::Experimental
Definition: Settings.h:14873
void save(const std::string &fileName) const
Save to the given file
Settings & set(const RegionOfInterest::Depth::Range &value)
Set RegionOfInterest::Depth::Range
Definition: Settings.h:15242
const Settings::Processing::Filters::Experimental::HoleFilling::Strictness & get() const
Definition: Settings.h:15562
const Settings::Processing::Color::Experimental & get() const
Definition: Settings.h:15364
const Settings::Processing::Filters::Noise::Repair & get() const
Definition: Settings.h:15608
Settings & set(const Processing::Filters::Experimental::ContrastDistortion::Removal &value)
Set Processing::Filters::Experimental::ContrastDistortion::Removal
Definition: Settings.h:14971
const Settings::RegionOfInterest::Box::PointA & get() const
Definition: Settings.h:15795
Settings & set(const Processing::Color &value)
Set Processing::Color
Definition: Settings.h:14838
Experimental & experimental()
Get Experimental
Definition: Settings.h:14799
Settings & set(const Processing::Filters::Outlier &value)
Set Processing::Filters::Outlier
Definition: Settings.h:15076
bool operator==(const Settings &other) const
Equality operator
Acquisitions & acquisitions()
Get Acquisitions
Definition: Settings.h:14754
Settings & set(const Processing::Filters::Reflection::Removal &value)
Set Processing::Filters::Reflection::Removal
Definition: Settings.h:15111
const Settings::Processing::Filters::Noise::Suppression::Enabled & get() const
Definition: Settings.h:15636
const Settings::Processing::Filters::Cluster & get() const
Definition: Settings.h:15397
const Settings::Processing::Filters::Noise::Repair::Enabled & get() const
Definition: Settings.h:15617
Settings(const std::string &fileName)
Construct Settings by loading from file
Settings & set(const Processing::Color::Balance::Red &value)
Set Processing::Color::Balance::Red
Definition: Settings.h:14866
Settings & set(const RegionOfInterest::Box::PointO &value)
Set RegionOfInterest::Box::PointO
Definition: Settings.h:15221
const Settings::Sampling::Color & get() const
Definition: Settings.h:15847
Settings & set(const Processing::Filters::Cluster::Removal &value)
Set Processing::Filters::Cluster::Removal
Definition: Settings.h:14908
Settings & set(const RegionOfInterest::Box &value)
Set RegionOfInterest::Box
Definition: Settings.h:15186
Settings & set(const Processing::Filters::Noise::Suppression &value)
Set Processing::Filters::Noise::Suppression
Definition: Settings.h:15062
Diagnostics & diagnostics()
Get Diagnostics
Definition: Settings.h:14773
const Settings::Processing::Filters::Noise::Removal::Threshold & get() const
Definition: Settings.h:15599
const Settings::Processing::Filters::Cluster::Removal::Enabled & get() const
Definition: Settings.h:15416
const Settings::Processing::Filters::Reflection::Removal::Experimental & get() const
Definition: Settings.h:15710
Sampling & sampling()
Get Sampling
Definition: Settings.h:15255
Settings & set(const Processing::Filters::Reflection::Removal::Enabled &value)
Set Processing::Filters::Reflection::Removal::Enabled
Definition: Settings.h:15118
Processing & processing()
Get Processing
Definition: Settings.h:14825
Settings & set(const RegionOfInterest::Box::PointA &value)
Set RegionOfInterest::Box::PointA
Definition: Settings.h:15207
Settings & set(const Processing::Filters::Experimental::HoleFilling::Enabled &value)
Set Processing::Filters::Experimental::HoleFilling::Enabled
Definition: Settings.h:14999
Settings & set(const Processing::Filters::Experimental::HoleFilling &value)
Set Processing::Filters::Experimental::HoleFilling
Definition: Settings.h:14992
Settings & set(const Diagnostics::Enabled &value)
Set Diagnostics::Enabled
Definition: Settings.h:14786
const Settings::Processing::Filters::Noise & get() const
Definition: Settings.h:15570
const Settings::Diagnostics::Enabled & get() const
Definition: Settings.h:15296
const Settings::Processing::Filters::Cluster::Removal & get() const
Definition: Settings.h:15406
Settings & set(const Processing::Filters::Experimental::HoleFilling::Strictness &value)
Set Processing::Filters::Experimental::HoleFilling::Strictness
Definition: Settings.h:15013
std::string toString() const
Get the value as string
const Settings::Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled & get() const
Definition: Settings.h:15475
const Settings::RegionOfInterest::Box::PointB & get() const
Definition: Settings.h:15803
Settings & set(const Processing::Filters::Experimental::ContrastDistortion &value)
Set Processing::Filters::Experimental::ContrastDistortion
Definition: Settings.h:14943
Settings & set(const Sampling::Pixel &value)
Set Sampling::Pixel
Definition: Settings.h:15275
Settings & set(const Processing::Color::Gamma &value)
Set Processing::Color::Gamma
Definition: Settings.h:14887
Settings & set(const Processing::Filters::Cluster::Removal::Enabled &value)
Set Processing::Filters::Cluster::Removal::Enabled
Definition: Settings.h:14915
const Settings::RegionOfInterest::Depth::Range & get() const
Definition: Settings.h:15835
const Settings::Sampling & get() const
Definition: Settings.h:15841
Settings & set(const Processing::Filters::Noise::Removal::Threshold &value)
Set Processing::Filters::Noise::Removal::Threshold
Definition: Settings.h:15041
Settings & set(const Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled &value)
Set Processing::Filters::Experimental::ContrastDistortion::Correction::Enabled
Definition: Settings.h:14957
Settings & set(const Processing::Filters::Reflection::Removal::Experimental::Mode &value)
Set Processing::Filters::Reflection::Removal::Experimental::Mode
Definition: Settings.h:15132
Settings & set(const Processing::Filters::Experimental::HoleFilling::HoleSize &value)
Set Processing::Filters::Experimental::HoleFilling::HoleSize
Definition: Settings.h:15006
Settings & set(const Acquisitions &value)
Set Acquisitions
Definition: Settings.h:14760
Settings & set(const Processing::Filters::Smoothing::Gaussian::Sigma &value)
Set Processing::Filters::Smoothing::Gaussian::Sigma
Definition: Settings.h:15160
const Diagnostics & diagnostics() const
Get Diagnostics
Definition: Settings.h:14767
bool operator!=(const Settings &other) const
Inequality operator
Settings & set(const Processing::Filters::Noise::Removal &value)
Set Processing::Filters::Noise::Removal
Definition: Settings.h:15027
Settings & set(const Processing::Filters::Noise::Repair &value)
Set Processing::Filters::Noise::Repair
Definition: Settings.h:15048
Settings & set(const Processing::Filters::Cluster::Removal::MaxNeighborDistance &value)
Set Processing::Filters::Cluster::Removal::MaxNeighborDistance
Definition: Settings.h:14922
Settings & set(const Processing::Filters::Outlier::Removal &value)
Set Processing::Filters::Outlier::Removal
Definition: Settings.h:15083
Settings & set(const RegionOfInterest &value)
Set RegionOfInterest
Definition: Settings.h:15179
Settings & set(const Processing::Filters::Noise::Removal::Enabled &value)
Set Processing::Filters::Noise::Removal::Enabled
Definition: Settings.h:15034
Settings & set(const Processing::Filters::Experimental::ContrastDistortion::Correction &value)
Set Processing::Filters::Experimental::ContrastDistortion::Correction
Definition: Settings.h:14950
const Settings::Processing::Color & get() const
Definition: Settings.h:15324
Settings & set(const Processing::Filters::Noise::Repair::Enabled &value)
Set Processing::Filters::Noise::Repair::Enabled
Definition: Settings.h:15055
const Settings::Processing::Filters::Reflection::Removal::Enabled & get() const
Definition: Settings.h:15700
Settings & set(const Processing::Filters::Noise::Suppression::Enabled &value)
Set Processing::Filters::Noise::Suppression::Enabled
Definition: Settings.h:15069
const Settings::Processing::Filters::Reflection::Removal & get() const
Definition: Settings.h:15690
Settings & set(const Processing::Color::Balance::Green &value)
Set Processing::Color::Balance::Green
Definition: Settings.h:14859
Settings & set(const Processing::Filters &value)
Set Processing::Filters
Definition: Settings.h:14894
const RegionOfInterest & regionOfInterest() const
Get RegionOfInterest
Definition: Settings.h:15167
Settings & set(const Experimental &value)
Set Experimental
Definition: Settings.h:14805
const Settings::Processing::Filters::Outlier::Removal::Threshold & get() const
Definition: Settings.h:15673
Settings & set(const Processing::Color::Balance::Blue &value)
Set Processing::Color::Balance::Blue
Definition: Settings.h:14852
const Settings::Processing::Filters::Smoothing::Gaussian & get() const
Definition: Settings.h:15737
friend std::ostream & operator<<(std::ostream &stream, const Settings &value)
Operator to send the value as string to a stream
Definition: Settings.h:15928
const Settings::Processing::Filters::Reflection::Removal::Experimental::Mode & get() const
Definition: Settings.h:15720
NodeType
Definition: NodeType.h:100
Ret validRange(const CameraInfo &cameraInfo)
Definition: SettingsInfo.h:227
The main Zivid namespace. All Zivid code is found here
Definition: Application.h:99
Array2D< T >::ConstIterator end(const Array2D< T > &array)
Iterator to the end of the array
Definition: Array2D.h:336
Array2D< T >::ConstIterator cbegin(const Array2D< T > &array)
Iterator to the beginning of the array
Definition: Array2D.h:315
Array2D< T >::ConstIterator cend(const Array2D< T > &array)
Iterator to the end of the array
Definition: Array2D.h:329
Array2D< T >::ConstIterator begin(const Array2D< T > &array)
Iterator to the beginning of the array
Definition: Array2D.h:322
Point with three coordinates as float
Definition: Point.h:105