ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
octree.h
Go to the documentation of this file.
1 // ----------------------------------------------------------------------------
2 // - CloudViewer: www.cloudViewer.org -
3 // ----------------------------------------------------------------------------
4 // Copyright (c) 2018-2024 www.cloudViewer.org
5 // SPDX-License-Identifier: MIT
6 // ----------------------------------------------------------------------------
7 
8 #pragma once
9 
10 #include <Octree.h>
11 
12 namespace cloudViewer {
13 namespace geometry {
14 
15 // Trampoline classes for octree datastructures
16 template <class OctreeNodeBase = OctreeNode>
17 class PyOctreeNode : public OctreeNodeBase {
18 public:
19  using OctreeNodeBase::OctreeNodeBase;
20 };
21 
22 // Trampoline classes for octree datastructures
23 template <class OctreeLeafNodeBase = OctreeLeafNode>
24 class PyOctreeLeafNode : public PyOctreeNode<OctreeLeafNodeBase> {
25 public:
27 
28  bool operator==(const OctreeLeafNode& other) const override {
29  PYBIND11_OVERLOAD_PURE(bool, OctreeLeafNodeBase, other);
30  };
31 
32  std::shared_ptr<OctreeLeafNode> Clone() const override {
33  PYBIND11_OVERLOAD_PURE(std::shared_ptr<OctreeLeafNode>,
34  OctreeLeafNodeBase, );
35  };
36 };
37 
38 } // namespace geometry
39 } // namespace cloudViewer
OctreeLeafNode base class.
Definition: Octree.h:173
std::shared_ptr< OctreeLeafNode > Clone() const override
Clone this OctreeLeafNode.
Definition: octree.h:32
bool operator==(const OctreeLeafNode &other) const override
Definition: octree.h:28
Generic file read and write utility for python interface.