Priority queue for integer coordinates with squared distances as priority. More...
#include <bucketedqueue.h>
Public Member Functions | |
BucketPrioQueue () | |
Standard constructor. More... | |
void | clear () |
bool | empty () |
Checks whether the Queue is empty. More... | |
int | getNumBuckets () |
T | pop () |
return and pop the element with the lowest squared distance */ More... | |
void | push (int prio, T t) |
push an element More... | |
int | size () |
Private Types | |
typedef std::map< int, std::queue< T > > | BucketType |
Private Attributes | |
BucketType | buckets |
int | count |
BucketType::iterator | nextPop |
Priority queue for integer coordinates with squared distances as priority.
dynamicEDT3D: A library for incrementally updatable Euclidean distance transforms in 3D.
Definition at line 57 of file bucketedqueue.h.
|
private |
Definition at line 82 of file bucketedqueue.h.
BucketPrioQueue< T >::BucketPrioQueue | ( | ) |
Standard constructor.
Standard constructor. When called for the first time it creates a look up table that maps square distanes to bucket numbers, which might take some time...
|
inline |
Definition at line 66 of file bucketedqueue.h.
bool BucketPrioQueue< T >::empty | ( | ) |
Checks whether the Queue is empty.
|
inline |
Definition at line 76 of file bucketedqueue.h.
T BucketPrioQueue< T >::pop | ( | ) |
return and pop the element with the lowest squared distance */
void BucketPrioQueue< T >::push | ( | int | prio, |
T | t | ||
) |
push an element
|
inline |
Definition at line 75 of file bucketedqueue.h.
|
private |
Definition at line 83 of file bucketedqueue.h.
|
private |
Definition at line 80 of file bucketedqueue.h.
|
private |
Definition at line 84 of file bucketedqueue.h.