Interpolation.h
Go to the documentation of this file.
00001 #ifndef __Interpolation_H__
00002 #define __Interpolation_H__
00003 
00004 namespace EdgeDetection
00005 {
00006         class Interpolation
00007         {
00008                 public: static double InterpolateForward(double start, double end, double fraction)
00009                 {
00010                         if (fraction < 0) return start;
00011                         if (fraction > 1) return end;
00012 
00013                         return start + fraction * (end - start);
00014                 }
00015                 public: static double InterpolateReverse(double start, double end, double value)
00016                 {
00017                         if (value < start) return 0;
00018                         if (value > end) return 1;
00019 
00020                         return (value - start) / (end - start);
00021                 }
00022         };
00023 };
00024 
00025 #endif


aruco_pose
Author(s): Julian Brunner
autogenerated on Mon Oct 6 2014 08:32:33