Removed harmless warnings on rarely used objects...

This commit is contained in:
Paolo Cignoni 2017-03-28 17:43:16 +02:00
parent 2c3034d483
commit 32c26911c4
5 changed files with 5 additions and 9 deletions

View File

@ -59,7 +59,6 @@ public:
template <class OBJPOINTDISTANCEFUNCT> template <class OBJPOINTDISTANCEFUNCT>
static inline ObjPtr Closest(TreeType & tree, OBJPOINTDISTANCEFUNCT & getPointDistance, const CoordType & p, const ScalarType & maxDist, ScalarType & minDist, CoordType & q) { static inline ObjPtr Closest(TreeType & tree, OBJPOINTDISTANCEFUNCT & getPointDistance, const CoordType & p, const ScalarType & maxDist, ScalarType & minDist, CoordType & q) {
typedef OBJPOINTDISTANCEFUNCT ObjPointDistanceFunct;
typedef std::vector<NodeType *> NodePtrVector; typedef std::vector<NodeType *> NodePtrVector;
typedef typename NodePtrVector::const_iterator NodePtrVector_ci; typedef typename NodePtrVector::const_iterator NodePtrVector_ci;

View File

@ -76,8 +76,6 @@ protected:
public: public:
template <class OBJPOINTDISTANCEFUNCT, class OBJPTRCONTAINERTYPE, class DISTCONTAINERTYPE, class POINTCONTAINERTYPE> template <class OBJPOINTDISTANCEFUNCT, class OBJPTRCONTAINERTYPE, class DISTCONTAINERTYPE, class POINTCONTAINERTYPE>
static inline unsigned int KClosest(TreeType & tree, OBJPOINTDISTANCEFUNCT & getPointDistance, const unsigned int k, const CoordType & p, const ScalarType & maxDist, OBJPTRCONTAINERTYPE & objects, DISTCONTAINERTYPE & distances, POINTCONTAINERTYPE & points) { static inline unsigned int KClosest(TreeType & tree, OBJPOINTDISTANCEFUNCT & getPointDistance, const unsigned int k, const CoordType & p, const ScalarType & maxDist, OBJPTRCONTAINERTYPE & objects, DISTCONTAINERTYPE & distances, POINTCONTAINERTYPE & points) {
typedef std::vector<NodeType *> NodePtrVector;
typedef typename NodePtrVector::const_iterator NodePtrVector_ci;
if (k == 0) { if (k == 0) {
return (0); return (0);

View File

@ -60,8 +60,6 @@ public:
template <class OBJRAYISECTFUNCT> template <class OBJRAYISECTFUNCT>
static inline ObjPtr Ray(TreeType & tree, OBJRAYISECTFUNCT & rayIntersection, const Ray3<ScalarType> & ray, const ScalarType & maxDist, ScalarType & t) { static inline ObjPtr Ray(TreeType & tree, OBJRAYISECTFUNCT & rayIntersection, const Ray3<ScalarType> & ray, const ScalarType & maxDist, ScalarType & t) {
typedef std::vector<NodeType *> NodePtrVector;
typedef typename NodePtrVector::const_iterator NodePtrVector_ci;
NodeType * pRoot = tree.pRoot; NodeType * pRoot = tree.pRoot;

View File

@ -500,7 +500,6 @@ OBJECT_RETRIEVER:
//otherwise, retrieve the leaves and fill the container with the objects contained //otherwise, retrieve the leaves and fill the container with the objects contained
std::vector< NodePointer > leaves; std::vector< NodePointer > leaves;
unsigned int object_count;
int leaves_count; int leaves_count;
TemplatedOctree::ContainedLeaves(query_bounding_box, leaves, TemplatedOctree::Root(), TemplatedOctree::boundingBox); TemplatedOctree::ContainedLeaves(query_bounding_box, leaves, TemplatedOctree::Root(), TemplatedOctree::boundingBox);

View File

@ -81,7 +81,9 @@ protected:
parent = NULL; parent = NULL;
level = -1; level = -1;
} }
virtual ~Node() {}
// Constructor: create a new Node // Constructor: create a new Node
Node(NodePointer parent, int level) Node(NodePointer parent, int level)
{ {
@ -106,7 +108,7 @@ protected:
*/ */
struct InnerNode : public Node struct InnerNode : public Node
{ {
InnerNode() : Node() {}; InnerNode() : Node() {}
InnerNode(NodePointer parent, int level) : Node(parent, level) InnerNode(NodePointer parent, int level) : Node(parent, level)
{ {
memset(&sons[0], 0, 8*sizeof(Node*)); memset(&sons[0], 0, 8*sizeof(Node*));
@ -131,7 +133,7 @@ protected:
*/ */
struct Leaf : public Node struct Leaf : public Node
{ {
Leaf() : Node() {}; Leaf() : Node() {}
Leaf(NodePointer parent, int level) : Node(parent, level) {} Leaf(NodePointer parent, int level) : Node(parent, level) {}
inline NodePointer &Son(int /*sonIndex*/) inline NodePointer &Son(int /*sonIndex*/)