Lines Matching refs:Rational
202 class Rational { class
204 Rational(void) : _n(0), _d(1) {} in Rational() function in Rational
205 Rational(uint32_t n, uint32_t d) : _n(n), _d(d) {} in Rational() function in Rational
210 bool operator==(const Rational& other) const;
211 bool operator!=(const Rational& other) const { return !(*this == other); } in operator !=()
212 bool operator<(const Rational& other) const;
213 bool operator>(const Rational& other) const { in operator >()
217 Rational& lower, Rational& upper);
263 Rational hScale;
266 Rational vScale;
293 Rational scHScale(uint32_t format,
297 Rational scVScale(uint32_t format,
535 >= Rational(searchLimits.sourceCrop.width(), in main()
550 >= Rational(searchLimits.sourceCrop.height(), in main()
1098 Rational scHScale(uint32_t format, in scHScale()
1104 Rational best(0, 1), minBad; // Current bounds for a binary search in scHScale()
1121 Rational lower, upper, selected; in scHScale()
1129 Rational::double2Rational(mid, in scHScale()
1154 num, (float) Rational(scDim.width(), dfDim.width()), in scHScale()
1166 if (firstPass) { return Rational(scDim.width(), dfDim.width()); } in scHScale()
1169 best = Rational(scDim.width(), dfDim.width()); in scHScale()
1173 minBad = Rational(scDim.width(), dfDim.width()); in scHScale()
1197 Rational scVScale(uint32_t format, in scVScale()
1203 Rational best(0, 1), minBad; // Current bounds for a binary search in scVScale()
1220 Rational lower, upper, selected; in scVScale()
1228 Rational::double2Rational(mid, in scVScale()
1253 num, (float) Rational(scDim.height(), dfDim.height()), in scVScale()
1265 if (firstPass) { return Rational(scDim.height(), dfDim.height()); } in scVScale()
1268 best = Rational(scDim.height(), dfDim.height()); in scVScale()
1272 minBad = Rational(scDim.height(), dfDim.height()); in scVScale()
1339 bool Rational::operator==(const Rational& other) const in operator ==()
1347 bool Rational::operator<(const Rational& other) const in operator <()
1355 Rational::operator string() const in operator string()
1364 void Rational::double2Rational(double f, Range nRange, Range dRange, in double2Rational()
1365 Rational& lower, Rational& upper) in double2Rational()
1367 Rational bestLower(nRange.lower(), dRange.upper()); in double2Rational()
1368 Rational bestUpper(nRange.upper(), dRange.lower()); in double2Rational()
1372 Rational val(d * f, d); // Lower, because double to int cast truncates in double2Rational()