49#include "DGtal/base/Common.h"
50#include "DGtal/topology/KhalimskySpaceND.h"
51#include "DGtal/helpers/StdDefs.h"
52#include "DGtal/io/Color.h"
53#include "DGtal/io/boards/Board2D.h"
62int main(
int argc,
char** argv )
66 for (
int i = 0; i < argc; ++i )
123 for ( KPS::uSetKCoord( qq,
K.
uFirst( qq, 1 ), 1 );
K.
uIsInside(qq, 1); qq = KPS::uGetIncr(qq, 1) )
140 boardScan1.
saveSVG(
"khalimskySpaceScanner1.svg");
141 boardScan1.
saveFIG(
"khalimskySpaceScanner1.fig");
143 boardScan2.
saveSVG(
"khalimskySpaceScanner2.svg");
144 boardScan2.
saveFIG(
"khalimskySpaceScanner2.fig");
Aim: This class specializes a 'Board' class so as to display DGtal objects more naturally (with <<)....
const Point & lowerBound() const
const Point & upperBound() const
std::string className() const
Cell uSpel(Point p) const
From the digital coordinates of a point in Zn, builds the corresponding spel (cell of maximal dimensi...
bool uIsInside(const PreCell &p, Dimension k) const
Useful to check if you are going out of the space.
bool init(const Point &lower, const Point &upper, bool isClosed)
Specifies the upper and lower bounds for the maximal cells in this space.
Cell uGetMax(Cell p, Dimension k) const
Useful to check if you are going out of the space.
Integer uLast(const PreCell &p, Dimension k) const
Return the k-th Khalimsky coordinate of the last cell of the space with the same type as [p].
bool uNext(Cell &p, const Cell &lower, const Cell &upper) const
Increment the cell [p] to its next position (as classically done in a scanning).
Cell uCell(const PreCell &c) const
From an unsigned cell, returns an unsigned cell lying into this Khalismky space.
Integer uFirst(const PreCell &p, Dimension k) const
Return the k-th Khalimsky coordinate of the first cell of the space with the same type as [p].
Point uCoords(const Cell &c) const
Return its digital coordinates.
KhalimskyCell< dim, Integer > Cell
void beginBlock(const std::string &keyword="")
Board & setPenColor(const DGtal::Color &color)
void saveFIG(const char *filename, PageSize size=Board::BoundingBox, double margin=10.0, bool includeFIGHeader=true) const
void saveSVG(const char *filename, PageSize size=Board::BoundingBox, double margin=10.0) const
KhalimskyPreSpaceND< 2, Integer > KPreSpace
KhalimskySpaceND< 2, Integer > KSpace
HyperRectDomain< Space > Domain
DGtal is the top-level namespace which contains all DGtal functions and types.
static void draw(DGtal::Board2D &board, const DGtal::DiscreteExteriorCalculus< dimEmbedded, dimAmbient, TLinearAlgebraBackend, TInteger > &calculus)
SetMode(std::string classname, std::string mode)