Package svs_simulation :: Package terrain :: Module navgraphs
[show private | hide private]
[frames | no frames]

Module svs_simulation.terrain.navgraphs

Navigation graphs.

The nodes of the graph are represented by custom classes contained in this module. The main graph istelf is handled by the undirected graph from pygraphlib:

http://pygraphlib.sourceforge.net/

Author: Simon Yuill

Contact: simon@lipparosa.org

Copyright: 2005 Simon Yuill

License: GNU GPL version 2 or any later version

Classes
NavGraph Navigation graph.
NavGraphNode Node in a navigation graph.

Function Summary
  createNavGraphForStructure(structure, seedX, seedY, spaceX, spaceY, agentRadius)
Builds a navigation graph for inside a structure.
  linkNodesWithinTransition(self, graph, transition)
Links nodes in graph that are within transition area to transition.
  _fillVertical(structure, graph, startX, startY, spaceX, spaceY, agentRadius)
  _linkNeighboursFromNode(node, structure, graph, spaceX, spaceY)
Creates links to neighbour points around a node.

Function Details

createNavGraphForStructure(structure, seedX, seedY, spaceX, spaceY, agentRadius)

Builds a navigation graph for inside a structure.

This uses a flood fill algorithm based on: http://www.student.kuleuven.ac.be/~m0216922/CG/floodfill.html.
Parameters:
structure
           (type=svs_simulation.terrain.structures.Structure)
spaceX
           (type=float)
spaceY
           (type=float)
agentRadius
           (type=float)

linkNodesWithinTransition(self, graph, transition)

Links nodes in graph that are within transition area to transition.

_linkNeighboursFromNode(node, structure, graph, spaceX, spaceY)

Creates links to neighbour points around a node.

Generated by Epydoc 2.1 on Thu Oct 20 15:30:24 2005 http://epydoc.sf.net