Adobe Source Libraries 1.49.0
A collection of C++ libraries.
|
Functions | |
template<class T, class R> | |
const T & | select_0_2 (const T &a, const T &b, R r) |
select_0 implementation | |
template<class T, class R> | |
T & | select_0_2 (T &a, T &b, R r) |
select_0 implementation | |
template<class T, class R> | |
const T & | select_1_2 (const T &a, const T &b, R r) |
select_0 implementation | |
template<class T, class R> | |
T & | select_1_2 (T &a, T &b, R r) |
select_0 implementation | |
template<typename T, typename R> | |
const T & | select_1_3_ac (const T &a, const T &b, const T &c, R r) |
select_1_ab implementation | |
template<typename T, typename R> | |
T & | select_1_3_ac (T &a, T &b, T &c, R r) |
select_1_ab implementation | |
template<typename T, typename R> | |
const T & | select_1_3_ab (const T &a, const T &b, const T &c, R r) |
select_1_ab implementation | |
template<typename T, typename R> | |
T & | select_1_3_ab (T &a, T &b, T &c, R r) |
select_1_ab implementation | |
template<typename T, typename R> | |
const T & | select_1_3 (const T &a, const T &b, const T &c, R r) |
select_1 implementation | |
template<typename T, typename R> | |
T & | select_1_3 (T &a, T &b, T &c, R r) |
select_1 implementation |
The select() algorithms are building blocks for other algorithms such as median() and clamp(). The general form of a select algorithm is:
select_<argument_index>_<argument_ordering>()
For example: select_1_3_ab(a, b, c)
means "select the second of three element
(index starts at zero) assuming that arguments \c a and \c b are supplied in non-decreasing order."
Because these routines are low level, they do not atomatically bind their comparison argument nor provide convience functions defaulting the comparison to less(). That is handled at a higher level.
All of the select function are stable. An algorithm is stable if it respects the original order of equivalent objects. So if we think of minimum and maximum as selecting, respectively, the smallest and second-smallest from a list of two arguments, stability requires that when called with equivalent elements, minimum should return the first and maximum the second.
const T & select_0_2 | ( | const T & | a, |
const T & | b, | ||
R | r ) |
Definition at line 50 of file algorithm/select.hpp.
T & select_0_2 | ( | T & | a, |
T & | b, | ||
R | r ) |
Definition at line 59 of file algorithm/select.hpp.
const T & select_1_2 | ( | const T & | a, |
const T & | b, | ||
R | r ) |
Definition at line 68 of file algorithm/select.hpp.
T & select_1_2 | ( | T & | a, |
T & | b, | ||
R | r ) |
Definition at line 77 of file algorithm/select.hpp.
const T & select_1_3_ac | ( | const T & | a, |
const T & | b, | ||
const T & | c, | ||
R | r ) |
Definition at line 86 of file algorithm/select.hpp.
T & select_1_3_ac | ( | T & | a, |
T & | b, | ||
T & | c, | ||
R | r ) |
Definition at line 96 of file algorithm/select.hpp.
const T & select_1_3_ab | ( | const T & | a, |
const T & | b, | ||
const T & | c, | ||
R | r ) |
Definition at line 106 of file algorithm/select.hpp.
T & select_1_3_ab | ( | T & | a, |
T & | b, | ||
T & | c, | ||
R | r ) |
Definition at line 116 of file algorithm/select.hpp.
const T & select_1_3 | ( | const T & | a, |
const T & | b, | ||
const T & | c, | ||
R | r ) |
Definition at line 126 of file algorithm/select.hpp.
T & select_1_3 | ( | T & | a, |
T & | b, | ||
T & | c, | ||
R | r ) |
Definition at line 135 of file algorithm/select.hpp.