Skip to content

Commit 3140148

Browse files
author
frozar
committed
[OCTREE] Review from 'taketwo'.
1 parent 947bab6 commit 3140148

File tree

2 files changed

+74
-74
lines changed

2 files changed

+74
-74
lines changed

octree/include/pcl/octree/impl/octree_iterator.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -317,7 +317,7 @@ namespace pcl
317317
OctreeBreadthFirstIterator<OctreeT>::reset ();
318318

319319
// Set the current_state_ to the right depth
320-
while ( this->current_state_ && ( this->getCurrentOctreeDepth () != depth_ ) )
320+
while (this->current_state_ && (this->getCurrentOctreeDepth () != depth_))
321321
{
322322
++*this;
323323
}

octree/include/pcl/octree/octree_iterator.h

Lines changed: 73 additions & 73 deletions
Original file line numberDiff line numberDiff line change
@@ -530,81 +530,81 @@ namespace pcl
530530
* \ingroup octree
531531
* \author Fabien Rozar ([email protected])
532532
*/
533-
template<typename OctreeT>
534-
class OctreeBreadthFirstAtDepthIterator : public OctreeBreadthFirstIterator<OctreeT>
535-
{
536-
public:
537-
538-
// public typedefs
539-
using typename OctreeBreadthFirstIterator<OctreeT>::BranchNode;
540-
using typename OctreeBreadthFirstIterator<OctreeT>::LeafNode;
541-
542-
/** \brief Empty constructor.
543-
* \param[in] depth_arg Depth level during traversal
544-
*/
545-
explicit
546-
OctreeBreadthFirstAtDepthIterator (unsigned int depth_arg = 0);
547-
548-
/** \brief Constructor.
549-
* \param[in] octree_arg Octree to be iterated. Initially the iterator is set to its root node.
550-
* \param[in] depth_arg Depth level during traversal
551-
*/
552-
explicit
553-
OctreeBreadthFirstAtDepthIterator (OctreeT* octree_arg, unsigned int depth_arg = 0);
554-
555-
/** \brief Copy constructor.
556-
* \param[in] octree_arg Octree to be iterated. Initially the iterator is set to its root node.
557-
* \param[in] depth_arg Depth level during traversal
558-
*/
559-
OctreeBreadthFirstAtDepthIterator (const OctreeBreadthFirstAtDepthIterator& iterator);
560-
561-
virtual
562-
~OctreeBreadthFirstAtDepthIterator ();
563-
564-
/** \brief Copy operator.
565-
* \param[in] src the iterator to copy into this
566-
*/
567-
inline OctreeBreadthFirstAtDepthIterator&
568-
operator = (const OctreeBreadthFirstAtDepthIterator& src)
569-
{
570-
OctreeBreadthFirstIterator<OctreeT>::operator= (src);
571-
this->depth_ = src.depth_;
572-
return *this;
573-
}
574-
575-
/** \brief Reset the iterator to the first node at the depth given initially of the octree
576-
*/
577-
void
578-
reset ();
579-
580-
/** \brief Reset the iterator to the first node at the depth given initially of the octree
581-
*/
582-
void
583-
reset (int depth);
584-
585-
/** \brief Preincrement operator.
586-
* \note step to next octree node
587-
*/
588-
OctreeBreadthFirstAtDepthIterator&
589-
operator++ ();
590-
591-
/** \brief postincrement operator.
592-
* \note step to next octree node
593-
*/
594-
inline OctreeBreadthFirstAtDepthIterator
595-
operator++ (int)
596-
{
597-
OctreeBreadthFirstAtDepthIterator tmp = *this;
598-
++*this;
599-
return (tmp);
600-
}
533+
template<typename OctreeT>
534+
class OctreeBreadthFirstAtDepthIterator : public OctreeBreadthFirstIterator<OctreeT>
535+
{
536+
public:
537+
538+
// public typedefs
539+
using typename OctreeBreadthFirstIterator<OctreeT>::BranchNode;
540+
using typename OctreeBreadthFirstIterator<OctreeT>::LeafNode;
541+
542+
/** \brief Empty constructor.
543+
* \param[in] depth_arg Depth level during traversal
544+
*/
545+
explicit
546+
OctreeBreadthFirstAtDepthIterator (unsigned int depth_arg = 0);
547+
548+
/** \brief Constructor.
549+
* \param[in] octree_arg Octree to be iterated. Initially the iterator is set to its root node.
550+
* \param[in] depth_arg Depth level during traversal
551+
*/
552+
explicit
553+
OctreeBreadthFirstAtDepthIterator (OctreeT* octree_arg, unsigned int depth_arg = 0);
554+
555+
/** \brief Copy constructor.
556+
* \param[in] octree_arg Octree to be iterated. Initially the iterator is set to its root node.
557+
* \param[in] depth_arg Depth level during traversal
558+
*/
559+
OctreeBreadthFirstAtDepthIterator (const OctreeBreadthFirstAtDepthIterator& iterator);
560+
561+
virtual
562+
~OctreeBreadthFirstAtDepthIterator ();
563+
564+
/** \brief Copy operator.
565+
* \param[in] src the iterator to copy into this
566+
*/
567+
inline OctreeBreadthFirstAtDepthIterator&
568+
operator = (const OctreeBreadthFirstAtDepthIterator& src)
569+
{
570+
OctreeBreadthFirstIterator<OctreeT>::operator= (src);
571+
this->depth_ = src.depth_;
572+
return *this;
573+
}
574+
575+
/** \brief Reset the iterator to the first node at the depth given initially of the octree
576+
*/
577+
void
578+
reset ();
579+
580+
/** \brief Reset the iterator to the first node at the depth given as parameter
581+
*/
582+
void
583+
reset (int depth);
584+
585+
/** \brief Preincrement operator.
586+
* \note step to next octree node
587+
*/
588+
OctreeBreadthFirstAtDepthIterator&
589+
operator++ ();
590+
591+
/** \brief postincrement operator.
592+
* \note step to next octree node
593+
*/
594+
inline OctreeBreadthFirstAtDepthIterator
595+
operator++ (int)
596+
{
597+
OctreeBreadthFirstAtDepthIterator tmp = *this;
598+
++*this;
599+
return (tmp);
600+
}
601601

602-
protected:
603-
using OctreeBreadthFirstIterator<OctreeT>::FIFO_;
602+
protected:
603+
using OctreeBreadthFirstIterator<OctreeT>::FIFO_;
604604

605-
/** \brief Given level of the node to be iterated */
606-
unsigned int depth_;
607-
} ;
605+
/** \brief Given level of the node to be iterated */
606+
unsigned int depth_;
607+
};
608608

609609
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
610610
/** \brief Octree leaf node iterator class

0 commit comments

Comments
 (0)