HOG2
Public Member Functions | Public Attributes | Private Member Functions | Private Attributes | List of all members
AStarDelay Class Reference

#include <AStarDelay.h>

Inheritance diagram for AStarDelay:
Inheritance graph
[legend]
Collaboration diagram for AStarDelay:
Collaboration graph
[legend]

Public Member Functions

 AStarDelay ()
 
 AStarDelay (int lev)
 
virtual ~AStarDelay ()
 
void GetPath (GraphEnvironment *env, Graph *_g, graphState from, graphState to, std::vector< graphState > &thePath)
 
uint64_t GetNodesExpanded ()
 
uint64_t GetNodesTouched ()
 
uint64_t GetNodesFirstExpanded ()
 
uint64_t GetNodesMetaExpanded ()
 
uint64_t GetNodesReopened ()
 
bool InitializeSearch (GraphEnvironment *env, Graph *g, graphState from, graphState to, std::vector< graphState > &thePath)
 
bool DoSingleSearchStep (std::vector< graphState > &thePath)
 
void ExtractPathToStart (graphState goalNode, std::vector< graphState > &thePath)
 
void OpenGLDraw () const
 
void DrawText (double x, double y, double z, float r, float g, float b, char *str)
 
void DrawEdge (unsigned int from, unsigned int to, double weight)
 
double GetSolutionCost ()
 
const char * GetName ()
 
int GetSolutionEdges ()
 
void ReversePropX1 (AStarDelayUtil::SearchNode &topNode)
 
void Broadcast (int level, int levelcount)
 
- Public Member Functions inherited from GraphAlgorithm
virtual ~GraphAlgorithm ()
 

Public Attributes

double solutionCost
 
int verID
 
int fD
 
long metaexpanded
 
AStarDelayUtil::PQueue openQueue
 
AStarDelayUtil::NodeLookupTable closedList
 
uint64_t closedSize
 

Private Member Functions

bool DoSingleStep (AStarDelayUtil::SearchNode &topNode, std::vector< graphState > &thePath)
 
double HandleNeighbor (graphState neighbor, AStarDelayUtil::SearchNode &topNode)
 
double HandleNeighborX (graphState neighbor, AStarDelayUtil::SearchNode &topNode)
 
double UpdateDelayedNode (graphState neighbor, AStarDelayUtil::SearchNode &topNode)
 
double UpdateClosedNode (graphState neighbor, AStarDelayUtil::SearchNode &topNode)
 
double UpdateOpenNode (graphState neighbor, AStarDelayUtil::SearchNode &topNode)
 
double AddNewNode (graphState neighbor, AStarDelayUtil::SearchNode &topNode)
 
double fDelay (double N)
 

Private Attributes

double F
 
double nodesExpanded
 
uint64_t nodesTouched
 
uint64_t nodesReopened
 
std::vector< graphStateneighbors
 
graphState goal
 
graphState start
 
GraphEnvironmentenv
 
AStarDelayUtil::GQueue delayQueue
 
AStarDelayUtil::GQueue fQueue
 
Graphg
 
int pathSize
 
int bpmxLevel
 
std::deque< graphStatefifo
 
std::vector< graphStatemyneighbors
 

Detailed Description

Definition at line 121 of file AStarDelay.h.

Constructor & Destructor Documentation

◆ AStarDelay() [1/2]

AStarDelay::AStarDelay ( )
inline

Definition at line 123 of file AStarDelay.h.

References bpmxLevel, fD, and verID.

◆ AStarDelay() [2/2]

AStarDelay::AStarDelay ( int  lev)
inline

Definition at line 124 of file AStarDelay.h.

References bpmxLevel, fD, and verID.

◆ ~AStarDelay()

virtual AStarDelay::~AStarDelay ( )
inlinevirtual

Definition at line 125 of file AStarDelay.h.

Member Function Documentation

◆ AddNewNode()

double AStarDelay::AddNewNode ( graphState  neighbor,
AStarDelayUtil::SearchNode topNode 
)
private

◆ Broadcast()

void AStarDelay::Broadcast ( int  level,
int  levelcount 
)

◆ DoSingleSearchStep()

bool AStarDelay::DoSingleSearchStep ( std::vector< graphState > &  thePath)
virtual

fgreater(delayQueue.top().fCost, openQueue.top().fCost)

fless(topNode.fCost, openQueue.top().fCost)

cmpkey(delayQueue.top() , openQueue.top())

Implements GraphAlgorithm.

Definition at line 83 of file AStarDelay.cpp.

References AStarDelayUtil::SearchNode::fCost, fgreater(), and fless().

◆ DoSingleStep()

bool AStarDelay::DoSingleStep ( AStarDelayUtil::SearchNode topNode,
std::vector< graphState > &  thePath 
)
private

◆ DrawEdge()

void AStarDelay::DrawEdge ( unsigned int  from,
unsigned int  to,
double  weight 
)

◆ DrawText()

void AStarDelay::DrawText ( double  x,
double  y,
double  z,
float  r,
float  g,
float  b,
char *  str 
)

Definition at line 755 of file AStarDelay.cpp.

◆ ExtractPathToStart()

void AStarDelay::ExtractPathToStart ( graphState  goalNode,
std::vector< graphState > &  thePath 
)

◆ fDelay()

double AStarDelay::fDelay ( double  N)
inlineprivate

Definition at line 191 of file AStarDelay.h.

References D_FOUR, D_LOG2, D_ONE, D_SQRT, D_THREE, D_TWO, and fD.

◆ GetName()

const char* AStarDelay::GetName ( )
inlinevirtual

Implements GraphAlgorithm.

Definition at line 145 of file AStarDelay.h.

◆ GetNodesExpanded()

uint64_t AStarDelay::GetNodesExpanded ( )
inlinevirtual

Implements GraphAlgorithm.

Definition at line 128 of file AStarDelay.h.

References nodesExpanded.

◆ GetNodesFirstExpanded()

uint64_t AStarDelay::GetNodesFirstExpanded ( )
inline

Definition at line 131 of file AStarDelay.h.

References closedSize.

◆ GetNodesMetaExpanded()

uint64_t AStarDelay::GetNodesMetaExpanded ( )
inline

Definition at line 132 of file AStarDelay.h.

References metaexpanded.

◆ GetNodesReopened()

uint64_t AStarDelay::GetNodesReopened ( )
inlinevirtual

Implements GraphAlgorithm.

Definition at line 133 of file AStarDelay.h.

References nodesReopened.

◆ GetNodesTouched()

uint64_t AStarDelay::GetNodesTouched ( )
inlinevirtual

Implements GraphAlgorithm.

Definition at line 129 of file AStarDelay.h.

References nodesTouched.

◆ GetPath()

void AStarDelay::GetPath ( GraphEnvironment env,
Graph _g,
graphState  from,
graphState  to,
std::vector< graphState > &  thePath 
)
virtual

Implements GraphAlgorithm.

Definition at line 24 of file AStarDelay.cpp.

◆ GetSolutionCost()

double AStarDelay::GetSolutionCost ( )
inlinevirtual

Implements GraphAlgorithm.

Definition at line 144 of file AStarDelay.h.

References solutionCost.

◆ GetSolutionEdges()

int AStarDelay::GetSolutionEdges ( )
inlinevirtual

Implements GraphAlgorithm.

Definition at line 146 of file AStarDelay.h.

References pathSize.

◆ HandleNeighbor()

double AStarDelay::HandleNeighbor ( graphState  neighbor,
AStarDelayUtil::SearchNode topNode 
)
private

Definition at line 452 of file AStarDelay.cpp.

◆ HandleNeighborX()

double AStarDelay::HandleNeighborX ( graphState  neighbor,
AStarDelayUtil::SearchNode topNode 
)
private

◆ InitializeSearch()

bool AStarDelay::InitializeSearch ( GraphEnvironment env,
Graph g,
graphState  from,
graphState  to,
std::vector< graphState > &  thePath 
)
virtual

Implements GraphAlgorithm.

Definition at line 46 of file AStarDelay.cpp.

References UINT32_MAX.

◆ OpenGLDraw()

void AStarDelay::OpenGLDraw ( ) const
virtual

Implements GraphAlgorithm.

Definition at line 677 of file AStarDelay.cpp.

◆ ReversePropX1()

void AStarDelay::ReversePropX1 ( AStarDelayUtil::SearchNode topNode)

◆ UpdateClosedNode()

double AStarDelay::UpdateClosedNode ( graphState  neighbor,
AStarDelayUtil::SearchNode topNode 
)
private

◆ UpdateDelayedNode()

double AStarDelay::UpdateDelayedNode ( graphState  neighbor,
AStarDelayUtil::SearchNode topNode 
)
private

◆ UpdateOpenNode()

double AStarDelay::UpdateOpenNode ( graphState  neighbor,
AStarDelayUtil::SearchNode topNode 
)
private

Member Data Documentation

◆ bpmxLevel

int AStarDelay::bpmxLevel
private

Definition at line 218 of file AStarDelay.h.

Referenced by AStarDelay().

◆ closedList

AStarDelayUtil::NodeLookupTable AStarDelay::closedList

Definition at line 167 of file AStarDelay.h.

◆ closedSize

uint64_t AStarDelay::closedSize

Definition at line 169 of file AStarDelay.h.

Referenced by GetNodesFirstExpanded().

◆ delayQueue

AStarDelayUtil::GQueue AStarDelay::delayQueue
private

Definition at line 211 of file AStarDelay.h.

◆ env

GraphEnvironment* AStarDelay::env
private

Definition at line 209 of file AStarDelay.h.

◆ F

double AStarDelay::F
private

Definition at line 189 of file AStarDelay.h.

◆ fD

int AStarDelay::fD

Definition at line 153 of file AStarDelay.h.

Referenced by AStarDelay(), and fDelay().

◆ fifo

std::deque<graphState> AStarDelay::fifo
private

Definition at line 220 of file AStarDelay.h.

◆ fQueue

AStarDelayUtil::GQueue AStarDelay::fQueue
private

Definition at line 211 of file AStarDelay.h.

◆ g

Graph* AStarDelay::g
private

Definition at line 213 of file AStarDelay.h.

◆ goal

graphState AStarDelay::goal
private

Definition at line 208 of file AStarDelay.h.

◆ metaexpanded

long AStarDelay::metaexpanded

Definition at line 164 of file AStarDelay.h.

Referenced by GetNodesMetaExpanded().

◆ myneighbors

std::vector<graphState> AStarDelay::myneighbors
private

Definition at line 221 of file AStarDelay.h.

◆ neighbors

std::vector<graphState> AStarDelay::neighbors
private

Definition at line 207 of file AStarDelay.h.

◆ nodesExpanded

double AStarDelay::nodesExpanded
private

Definition at line 205 of file AStarDelay.h.

Referenced by GetNodesExpanded().

◆ nodesReopened

uint64_t AStarDelay::nodesReopened
private

Definition at line 206 of file AStarDelay.h.

Referenced by GetNodesReopened().

◆ nodesTouched

uint64_t AStarDelay::nodesTouched
private

Definition at line 206 of file AStarDelay.h.

Referenced by GetNodesTouched().

◆ openQueue

AStarDelayUtil::PQueue AStarDelay::openQueue

Definition at line 166 of file AStarDelay.h.

◆ pathSize

int AStarDelay::pathSize
private

Definition at line 216 of file AStarDelay.h.

Referenced by GetSolutionEdges().

◆ solutionCost

double AStarDelay::solutionCost

Definition at line 151 of file AStarDelay.h.

Referenced by GetSolutionCost().

◆ start

graphState AStarDelay::start
private

Definition at line 208 of file AStarDelay.h.

◆ verID

int AStarDelay::verID

Definition at line 152 of file AStarDelay.h.

Referenced by AStarDelay().


The documentation for this class was generated from the following files: