| 764 | } |
| 765 | |
| 766 | bool |
| 767 | Curve::getKeyFrameWithTime(double time, |
| 768 | KeyFrame* k) const |
| 769 | { |
| 770 | assert(k); |
| 771 | QMutexLocker l(&_imp->_lock); |
| 772 | KeyFrameSet::const_iterator it = find(time); |
| 773 | |
| 774 | if ( it == _imp->keyFrames.end() ) { |
| 775 | return false; |
| 776 | } |
| 777 | |
| 778 | *k = *it; |
| 779 | |
| 780 | return true; |
| 781 | } |
| 782 | |
| 783 | /// compute interpolation parameters from keyframes and an iterator |
| 784 | /// to the next keyframe (the first with time > t) |
no test coverage detected