Lines Matching refs:S
39 template <typename S, typename T>
40 class Interpolator : public std::map<S, T> {
54 std::pair<S, T> first() const { in first()
58 std::pair<S, T> last() const { in last()
63 T findY(S x) { // logically const, but modifies cache in findY()
89 const S interval = high->first - low->first; in findY()
93 const S t = (x - low->first) / interval; in findY()
94 const S t2 = t * t; in findY()
125 S sec, sec0, sec1; in findY()
137 S m0, m1; in findY()
159 const S maxSlope = 3 * sec; in findY()
167 const S t = (x - low->first) / interval; in findY()
168 const S t2 = t * t; in findY()
174 const S c0 = low->second; in findY()
175 const S c1 = m0; in findY()
176 const S c2 = 3 * dy - 2 * m0 - m1; in findY()
177 const S c3 = m0 + m1 - 2 * dy; in findY()
182 const S t3 = t2 * t; in findY()
183 const S h00 = 2 * t3 - 3 * t2 + 1; in findY()
184 const S h10 = t3 - 2 * t2 + t ; in findY()
185 const S h01 = -2 * t3 + 3 * t2 ; in findY()
186 const S h11 = t3 - t2 ; in findY()
311 static S constrainSlope(S slope, S maxSlope) { in constrainSlope()
314 slope = std::max(slope, S(0)); // not globally monotonic in constrainSlope()
317 slope = std::min(slope, S(0)); // not globally monotonic in constrainSlope()
326 S mFirstSlope;
327 S mLastSlope;
330 std::unordered_map<S, std::tuple<S /* c1 */, S /* c2 */, S /* c3 */>> mMemo;