Aim: Set of static methods that create digital straight segments (DSS) from some input parameters, eg. patterns (or reversed patterns) from two upper leaning points (or lower leaning points).
More...
#include <DGtal/geometry/curves/ArithmeticalDSSFactory.h>
|
static DSS | createSubsegment (const DSL &aDSL, const Point &aF, const Point &aL) |
|
static DSS | createSubsegment (const DSS &aDSS, const Point &aF, const Point &aL) |
|
static DSS | createPattern (const Point &aF, const Point &aL) |
| Method that creates a DSS that is a pattern or a repetition of a pattern from two input digital points, viewed as upper leaning points. More...
|
|
static DSS | createReversedPattern (const Point &aF, const Point &aL) |
| Method that creates a DSS that is a reversed pattern or a repetition of a reversed pattern from two input digital points, viewed as lower leaning points. Creates the pattern from aL to aF and negates the result. More...
|
|
static DSS | createDSS (const Coordinate &aA, const Coordinate &aB, const Point &aF, const Point &aL, const Point &aU) |
| Method that creates a DSS from a direction vector, a first and last point and one upper leaning point. More...
|
|
template<typename TCoordinate, typename TInteger = TCoordinate, unsigned short adjacency = 8>
class DGtal::ArithmeticalDSSFactory< TCoordinate, TInteger, adjacency >
Aim: Set of static methods that create digital straight segments (DSS) from some input parameters, eg. patterns (or reversed patterns) from two upper leaning points (or lower leaning points).
Description of template class 'ArithmeticalDSSFactory'
- Template Parameters
-
TCoordinate | a model of integer for the DGtal point coordinate |
TInteger | a model of integer for the DSS parameters (a, b, mu, omega) |
adjacency | a integer equal to 8 (default) for naive and 8-connected DSS, and 4 for standard and 4-connected DSS. |
Definition at line 73 of file ArithmeticalDSSFactory.h.
◆ Coordinate
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
◆ DSL
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
◆ DSS
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
◆ Integer
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
◆ Point
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
◆ Position
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
◆ Steps
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
◆ Vector
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
◆ bezoutVector()
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
Returns the bezout vector (u,v) of a given direction vector of slope aA / aB such that u and aB (resp. v and aA) have the same sign.
- Returns
- bezout vector
- Parameters
-
aA | y-component of the direction vector |
aB | x-component of the dirention vector |
aR | a remainder equal to either 1 or -1 |
- See also
- createPattern
NB: this method uses the extended Euclid's algorithm and runs in logarithmic time.
◆ createDSS()
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
Method that creates a DSS from a direction vector, a first and last point and one upper leaning point.
- Parameters
-
aA | y-component of the direction vector |
aB | x-component of the direction vector |
aF | first input digital point |
aL | second input digital point |
aU | upper leaning point |
- Returns
- a DSS
NB: logarithmic-time in the max of the greatest component of the vector starting from aU and pointing to aL and the greatest component of the vector starting from aF and pointing to aU.
◆ createLeftSubsegment()
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
Construction of the left subsegment of minimal parameters of a greater DSS. It is bound by the first point of aDSS on the left and by aL on the right.
- Parameters
-
aDSS | bounding DSS |
aL | last point of the subsegment |
NB: logarithmic-time in the greatest component of the direction vector of the subsegment. Uses reversedSmartCH algorithm [Roussillon 2014 : [108]].
◆ createPattern()
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
Method that creates a DSS that is a pattern or a repetition of a pattern from two input digital points, viewed as upper leaning points.
- Parameters
-
aF | first input digital point |
aL | second input digital point |
NB: logarithmic-time in the greatest component of the vector starting from aF and pointing to aL
◆ createReversedPattern()
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
Method that creates a DSS that is a reversed pattern or a repetition of a reversed pattern from two input digital points, viewed as lower leaning points. Creates the pattern from aL to aF and negates the result.
- See also
- createPattern
- Parameters
-
aF | first input digital point |
aL | second input digital point |
NB: logarithmic-time in the greatest component of the vector starting from aF and pointing to aL
◆ createSubsegment() [1/2]
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
Construction of the subsegment of minimal parameters of a given DSL.
- Parameters
-
aDSL | bounding DSL |
aF | first point of the subsegment |
aL | last point of the subsegment |
NB: logarithmic-time in the greatest component of the direction vector of the subsegment. Uses smartCH algorithm [Roussillon 2014 : [108]].
◆ createSubsegment() [2/2]
template<typename TCoordinate , typename TInteger = TCoordinate, unsigned short adjacency = 8>
Construction of the subsegment of minimal parameters of a greater DSS.
- Parameters
-
aDSS | bounding DSS |
aF | first point of the subsegment |
aL | last point of the subsegment |
NB: logarithmic-time in the greatest component of the direction vector of the subsegment. Uses reversedSmartCH algorithm [Roussillon 2014 : [108]].
- See also
- createLeftSubsegment
The documentation for this class was generated from the following file: