Easy_rider
 
Loading...
Searching...
No Matches
GraphVisualizer.h
1#ifndef GRAPH_VISUALIZER_H
2#define GRAPH_VISUALIZER_H
3
4#include "Graph.h"
5#include "Intersection.h"
6#include "Road.h"
7#include <SFML/Graphics.hpp>
8
14public:
15 GraphVisualizer(unsigned int width = 800, unsigned int height = 600,
16 const std::string &title = "Graph Visualizer");
17
18 void run(const Graph<Intersection, Road> &graph);
19
20private:
21 void processEvents();
22 void draw(const Graph<Intersection, Road> &graph);
23
24 sf::RenderWindow window_;
25 sf::Font font_;
26};
27
28#endif // GRAPH_VISUALIZER_H
A generic Graph template parameterized on Node and Edge types.
Declaration of the Intersection class representing a point in 2D space.
Declaration of the Road class representing a connection between two Intersections.
Temporary test-only class to visualize a Graph<Intersection,Road> using SFML.
Definition GraphVisualizer.h:13
A templated graph storing nodes of type T and edges of type U.
Definition Graph.h:58