DGtal
0.6.devel
|
#include <StandardDSLQ0.h>
Data Structures | |
struct | ConstIterator |
Public Types | |
typedef TFraction | Fraction |
typedef StandardDSLQ0< TFraction > | Self |
typedef Fraction::Integer | Integer |
typedef Fraction::UnsignedInteger | UnsignedInteger |
typedef Fraction::Quotient | Quotient |
typedef IntegerComputer< Integer > | IC |
typedef IC::IntegerParamType | IntegerParamType |
typedef IC::Vector2I | Vector2I |
typedef IC::Point2I | Point2I |
typedef IC::Point2I | Point |
Protected Attributes | |
Pattern< Fraction > | myPattern |
Integer | myMu |
Static Private Member Functions | |
static Fraction | deepest (Fraction f1, Fraction f2, Fraction f3) |
static Fraction | deepest (Fraction f1, Fraction f2) |
Private Attributes | |
IC | ic |
Definition at line 78 of file StandardDSLQ0.h.
typedef TFraction DGtal::StandardDSLQ0< TFraction >::Fraction |
Definition at line 82 of file StandardDSLQ0.h.
typedef IntegerComputer<Integer> DGtal::StandardDSLQ0< TFraction >::IC |
Definition at line 90 of file StandardDSLQ0.h.
typedef Fraction::Integer DGtal::StandardDSLQ0< TFraction >::Integer |
Definition at line 84 of file StandardDSLQ0.h.
typedef IC::IntegerParamType DGtal::StandardDSLQ0< TFraction >::IntegerParamType |
Definition at line 91 of file StandardDSLQ0.h.
typedef IC::Point2I DGtal::StandardDSLQ0< TFraction >::Point |
Definition at line 96 of file StandardDSLQ0.h.
typedef IC::Point2I DGtal::StandardDSLQ0< TFraction >::Point2I |
Definition at line 93 of file StandardDSLQ0.h.
typedef Fraction::Quotient DGtal::StandardDSLQ0< TFraction >::Quotient |
Definition at line 86 of file StandardDSLQ0.h.
typedef StandardDSLQ0<TFraction> DGtal::StandardDSLQ0< TFraction >::Self |
Definition at line 83 of file StandardDSLQ0.h.
typedef Fraction::UnsignedInteger DGtal::StandardDSLQ0< TFraction >::UnsignedInteger |
Definition at line 85 of file StandardDSLQ0.h.
typedef IC::Vector2I DGtal::StandardDSLQ0< TFraction >::Vector2I |
Definition at line 92 of file StandardDSLQ0.h.
|
inline |
|
inline |
DGtal::StandardDSLQ0< TFraction >::StandardDSLQ0 | ( | const StandardDSLQ0< TFraction > & | other | ) |
Copy constructor.
other | the object to clone. |
|
inline |
Creates the DSL(a,b,mu).
aSlope | the slope a/b, where gcd(a,b)=1 |
aMu | the shift to origin. |
Definition at line 79 of file StandardDSLQ0.ih.
|
inline |
Creates the DSL(a/g,b/g,mu), where g = gcd( a, b).
a1 | any integer |
b1 | any integer |
mu1 | the shift to origin. |
Definition at line 87 of file StandardDSLQ0.ih.
|
inline |
Definition at line 153 of file StandardDSLQ0.ih.
|
inline |
Definition at line 162 of file StandardDSLQ0.ih.
|
inline |
Definition at line 242 of file StandardDSLQ0.ih.
|
inline |
Definition at line 252 of file StandardDSLQ0.ih.
DGtal::StandardDSLQ0< TFraction >::ConstIterator DGtal::StandardDSLQ0< TFraction >::begin | ( | Point | p | ) | const |
p | a point in the DSL. |
Definition at line 261 of file StandardDSLQ0.ih.
|
inlinestaticprivate |
Definition at line 592 of file StandardDSLQ0.ih.
|
inlinestaticprivate |
Definition at line 601 of file StandardDSLQ0.ih.
DGtal::StandardDSLQ0< TFraction >::Self DGtal::StandardDSLQ0< TFraction >::DSSWithinTwoPatterns | ( | Point | U1, |
Point | U2, | ||
const Point & | A, | ||
const Point & | B | ||
) | const |
Used by reversedSmartDSS. Computes the exact characteristics of the subsegment [A,B] of this DSL. Note that |U2-U1| = 2 * length().
A | any point belonging to this DSL, A < B. |
B | any point belonging to this DSL, A < B. |
U1 | the first upper leaning point such that U1 <= A. |
U2 | the second upper leaning point such that B <= U2. |
Definition at line 383 of file StandardDSLQ0.ih.
References DGtal::Pattern< TFraction >::getGreatestIncludedSubpattern(), DGtal::Pattern< TFraction >::getSmallestCoveringSubpattern(), DGtal::Pattern< TFraction >::L(), DGtal::Pattern< TFraction >::length(), DGtal::Pattern< TFraction >::rE(), DGtal::Pattern< TFraction >::slope(), DGtal::Pattern< TFraction >::v(), and DGtal::StandardDSLQ0< TFraction >::v().
DGtal::StandardDSLQ0< TFraction >::ConstIterator DGtal::StandardDSLQ0< TFraction >::end | ( | Point | p | ) | const |
p | a point in the DSL. |
Definition at line 269 of file StandardDSLQ0.ih.
|
inline |
Checks the validity/consistency of the object.
Definition at line 631 of file StandardDSLQ0.ih.
|
inline |
|
inline |
|
inline |
|
inline |
Definition at line 135 of file StandardDSLQ0.ih.
|
inline |
Definition at line 144 of file StandardDSLQ0.ih.
|
inline |
|
inline |
Assignment.
other | the object to copy. |
Definition at line 69 of file StandardDSLQ0.ih.
References DGtal::StandardDSLQ0< TFraction >::myMu, and DGtal::StandardDSLQ0< TFraction >::myPattern.
|
inline |
Definition at line 126 of file StandardDSLQ0.ih.
|
inline |
Remainder a p.x - b p.y of point p in this DSL.
p | any point in Z2 |
Definition at line 107 of file StandardDSLQ0.ih.
DGtal::StandardDSLQ0< TFraction >::Self DGtal::StandardDSLQ0< TFraction >::reversedSmartDSS | ( | const Point & | A, |
const Point & | B | ||
) | const |
Algorithm ReversedSmartDSS. See M. Said and J.-O. Lachaud, DGCI2010.
Computes the exact characteristics of the subsegment [A,B] of this DSL in time O(log(|B-A|)). An even better bound in the output is achieved.
A | any point belonging to this DSL, A < B. |
B | any point belonging to this DSL, A < B. |
Definition at line 279 of file StandardDSLQ0.ih.
Referenced by DGtal::StandardDSLQ0< TFraction >::reversedSmartDSS().
DGtal::StandardDSLQ0< TFraction >::Self DGtal::StandardDSLQ0< TFraction >::reversedSmartDSS | ( | Point | U1, |
Point | U2, | ||
const Point & | A, | ||
const Point & | B | ||
) | const |
Algorithm ReversedSmartDSS. See M. Said and J.-O. Lachaud, DGCI2010.
Computes the exact characteristics of the subsegment [A,B] of this DSL in time O(log(|B-A|)). An even better bound in the output is achieved.
A | any point belonging to this DSL, A < B. |
B | any point belonging to this DSL, A < B. |
U1 | the first upper leaning point such that U1 <= A. |
U2 | the second upper leaning point such that B <= U2. |
Definition at line 295 of file StandardDSLQ0.ih.
References DGtal::Pattern< TFraction >::getSmallestCoveringSubpattern(), DGtal::Pattern< TFraction >::rE(), DGtal::StandardDSLQ0< TFraction >::reversedSmartDSS(), DGtal::Pattern< TFraction >::slope(), DGtal::Pattern< TFraction >::v(), and DGtal::StandardDSLQ0< TFraction >::v().
|
inline |
Writes/Displays the object on an output stream.
out | the output stream where the object is written. |
Definition at line 618 of file StandardDSLQ0.ih.
|
inline |
Definition at line 117 of file StandardDSLQ0.ih.
References DGtal::StandardDSLQ0< TFraction >::slope().
Referenced by DGtal::StandardDSLQ0< TFraction >::slope().
DGtal::StandardDSLQ0< TFraction >::Self DGtal::StandardDSLQ0< TFraction >::smartDSS | ( | const Point & | A, |
const Point & | B | ||
) | const |
Algorithm SmartDSS. See M. Said and J.-O. Lachaud, DGCI2009.
Computes the exact characteristics of the subsegment [A,B] of this DSL in time O(sum_k u_k), where the continued fraction of this DSL slope a/b is [u_0; u_1, u_2, ... ]
A | any point belonging to this DSL, A < B. |
B | any point belonging to this DSL, A < B. |
Definition at line 500 of file StandardDSLQ0.ih.
References DGtal::Pattern< TFraction >::bezout(), DGtal::Pattern< TFraction >::slope(), and DGtal::Pattern< TFraction >::v().
|
inline |
Definition at line 180 of file StandardDSLQ0.ih.
|
inline |
|
inline |
|
inline |
Definition at line 171 of file StandardDSLQ0.ih.
References DGtal::StandardDSLQ0< TFraction >::v().
Referenced by DGtal::StandardDSLQ0< TFraction >::DSSWithinTwoPatterns(), DGtal::StandardDSLQ0< TFraction >::reversedSmartDSS(), and DGtal::StandardDSLQ0< TFraction >::v().
|
private |
Used in some computations.
Definition at line 385 of file StandardDSLQ0.h.
|
protected |
the shift to origin.
Definition at line 380 of file StandardDSLQ0.h.
Referenced by DGtal::StandardDSLQ0< TFraction >::operator=().
|
protected |
the characteristic pattern of this DSL.
Definition at line 378 of file StandardDSLQ0.h.
Referenced by DGtal::StandardDSLQ0< TFraction >::operator=().