Ponca  7abd0fd82719106ad460aa0f2070dffbe375d727
Point Cloud Analysis library
Loading...
Searching...
No Matches
concepts.h
1#pragma once
2
3#include "../concepts.h"
4
5namespace Ponca
6{
7 template <typename T>
8 concept ProvidesScaleDerivative = T::isScaleDer();
9
10 template <typename T>
11 concept ProvidesSpaceDerivative = T::isSpaceDer();
12
13 template <typename K>
15
16 template <typename K>
28 template <typename T>
29 concept ProvidesComputeState = ProvidesCommonTypes<T> && requires(T t, const T ct) {
30 { ct.isStable() } -> std::same_as<bool>;
31 { ct.isReady() } -> std::same_as<bool>;
32 { ct.getCurrentState() } -> std::same_as<FIT_RESULT>;
33 };
37 template <typename T>
38 concept ProvidesBasketUnitBase = ProvidesCommonTypes<T> && ProvidesComputeState<T> && requires(T t, const T ct) {
39 typename T::NeighborFilter;
40 t.setNeighborFilter(typename T::NeighborFilter{});
41 { ct.getNeighborFilter() } -> std::convertible_to<typename T::NeighborFilter>;
42
43 { ct.getWeightSum() } -> std::same_as<typename T::Scalar>;
44 { ct.getNumNeighbors() } -> std::integral;
45 };
46
50 template <typename T>
51 concept ProvidesBasketDiffUnitBase = ProvidesBasketUnitBase<T> && requires(T t, const T ct) {
52 { ct.isScaleDer() } -> std::same_as<bool>;
53 { ct.isSpaceDer() } -> std::same_as<bool>;
54 { ct.derDimension() } -> std::integral;
55 };
56
57} // namespace Ponca
This concept ensures that the default types and accessors in a BasketDiff are well-formed.
Definition concepts.h:51
This concept ensures that the default types and accessors in a Basket are well-formed.
Definition concepts.h:38
This concept if currently only used a base concept for ProvidesBasketUnitBase.
Definition concepts.h:29
This Source Code Form is subject to the terms of the Mozilla Public License, v.
Definition concepts.h:11