n-Dimensional Fast Methods  0.7
 All Classes Functions Variables Typedefs Pages
GridPlotter Class Reference

Auxiliar class which helps to visualise Fast Marching steps and results. More...

#include <gridplotter.hpp>

Static Public Member Functions

template<class T , size_t ndims>
static void plotMap (nDGridMap< T, ndims > &grid, std::string name="")
 Plots the binary map of a given grid. It is based on the nDGridMap::getOccupancy(). This function has to be overloaded in another occupancy type is being used. More...
 
template<class T , size_t ndims>
static void plotOccupancyMap (nDGridMap< T, ndims > &grid, std::string name="")
 Plots the occupancy map of a given grid. It is based on the nDGridMap::getOccupancy(), This function has to be overloaded if another occupancy type is being used. More...
 
template<class T , size_t ndims = 2>
static void plotArrivalTimes (nDGridMap< T, ndims > &grid, std::string name="")
 Plots the values map of a given grid. It is based on the nDGridMap::getValue(). This function has to be overloaded in another value type is being used. More...
 
template<class T , size_t ndims = 2>
static void plotMapPath (nDGridMap< T, ndims > &grid, const Path2D &path, std::string name="")
 Plots the values map of a given grid. It is based on the nDGridMap::getValue(). This function has to be overloaded in another value type is being used. Also plots a given path. More...
 
template<class T , size_t ndims = 2>
static void plotOccupancyPath (nDGridMap< T, ndims > &grid, const Path2D &path, std::string name="")
 Plots the values map of a given grid. It is based on the nDGridMap::getValue(). This function has to be overloaded in another value type is being used. More...
 
template<class T , size_t ndims = 2>
static void plotMapPaths (nDGridMap< T, ndims > &grid, const Paths2D &paths, std::string name="")
 Plots the values map of a given grid. It is based on the nDGridMap::getValue(). This function has to be overloaded in another value type is being used. Also plots 2 given paths. More...
 
template<class T , size_t ndims = 2>
static void plotArrivalTimesPath (nDGridMap< T, ndims > &grid, const Path2D &path, std::string name="")
 Plots the values map of a given grid. It is based on the nDGridMap::getValue(). This function has to be overloaded in another value type is being used. It also plots a given path. More...
 
template<class T , size_t ndims = 2>
static void plotFMStates (nDGridMap< T, ndims > &grid, std::string name="")
 Plots the FMState of a cell. Should be used only in 2D grids. More...
 

Private Types

typedef std::array< unsigned
int, 2 > 
Coord2D
 Shorthand for 2D coordinates.
 
typedef std::array< double, 2 > Point2D
 Shorthand for 2D real points.
 
typedef std::vector< Point2DPath2D
 Shorthand for 2D paths of real points.
 
typedef std::vector< Path2DPaths2D
 Shorthand for vector of 2D paths of real points.
 

Detailed Description

Todo:

include checks which ensure that the grids are adecuate for the functions used.

generalize plotMapPaths to work with multiple (n>2) paths.

It is based on the CImg library, therefore it has to be accessible. Copyright (C) 2014 Javier V. Gomez and Jose Pardeiro www.javiervgomez.com

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

Definition at line 36 of file gridplotter.hpp.

Member Function Documentation

template<class T , size_t ndims = 2>
static void GridPlotter::plotArrivalTimes ( nDGridMap< T, ndims > &  grid,
std::string  name = "" 
)
inlinestatic

Should be used only in 2D grids.

The Y dimension flipping is because nDGridMap works in X-Y coordinates, not in image indices as CImg.

IMPORTANT NOTE: no type-checkings are done. T type has to be Cell or any class with bool getValue() method.

Definition at line 104 of file gridplotter.hpp.

template<class T , size_t ndims = 2>
static void GridPlotter::plotArrivalTimesPath ( nDGridMap< T, ndims > &  grid,
const Path2D path,
std::string  name = "" 
)
inlinestatic

Should be used only in 2D grids.

The Y dimension flipping is because nDGridMap works in X-Y coordinates, not in image indices as CImg.

IMPORTANT NOTE: no type-checkings are done. T type has to be Cell or any class with bool getOccupancy() method.

Definition at line 212 of file gridplotter.hpp.

template<class T , size_t ndims = 2>
static void GridPlotter::plotFMStates ( nDGridMap< T, ndims > &  grid,
std::string  name = "" 
)
inlinestatic

The Y dimension flipping is because nDGridMap works in X-Y coordinates, not in image indices as CImg.

IMPORTANT NOTE: no type-checkings are done. T type has to be Cell or any class with bool getValue() method.

Definition at line 236 of file gridplotter.hpp.

template<class T , size_t ndims>
static void GridPlotter::plotMap ( nDGridMap< T, ndims > &  grid,
std::string  name = "" 
)
inlinestatic

Should be used only in 2D grids.

The Y dimension flipping is because nDGridMap works in X-Y coordinates, not in image indices as CImg.

IMPORTANT NOTE: no type-checkings are done. T type has to be Cell or any class with bool getOccupancy() method.

Definition at line 61 of file gridplotter.hpp.

template<class T , size_t ndims = 2>
static void GridPlotter::plotMapPath ( nDGridMap< T, ndims > &  grid,
const Path2D path,
std::string  name = "" 
)
inlinestatic

Should be used only in 2D grids.

The Y dimension flipping is because nDGridMap works in X-Y coordinates, not in image indices as CImg.

IMPORTANT NOTE: no type-checkings are done. T type has to be Cell or any class with bool getOccupancy() method.

Definition at line 126 of file gridplotter.hpp.

template<class T , size_t ndims = 2>
static void GridPlotter::plotMapPaths ( nDGridMap< T, ndims > &  grid,
const Paths2D paths,
std::string  name = "" 
)
inlinestatic

Should be used only in 2D grids.

The Y dimension flipping is because nDGridMap works in X-Y coordinates, not in image indices as CImg.

IMPORTANT NOTE: no type-checkings are done. T type has to be Cell or any class with bool getOccupancy() method.

Definition at line 180 of file gridplotter.hpp.

template<class T , size_t ndims>
static void GridPlotter::plotOccupancyMap ( nDGridMap< T, ndims > &  grid,
std::string  name = "" 
)
inlinestatic

Should be used only in 2D grids.

The Y dimension flipping is because nDGridMap works in X-Y coordinates, not in image indices as CImg.

IMPORTANT NOTE: no type-checkings are done. T type has to be Cell or any class with bool getOccupancy() method.

Definition at line 84 of file gridplotter.hpp.

template<class T , size_t ndims = 2>
static void GridPlotter::plotOccupancyPath ( nDGridMap< T, ndims > &  grid,
const Path2D path,
std::string  name = "" 
)
inlinestatic

Should be used only in 2D grids.

The Y dimension flipping is because nDGridMap works in X-Y coordinates, not in image indices as CImg.

IMPORTANT NOTE: no type-checkings are done. T type has to be Cell or any class with bool getOccupancy() method.

Definition at line 154 of file gridplotter.hpp.


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