2014-01-27 22:28:03 -0600 | asked a question | W_BITS and FLT_SCALE in LKTrackerInvoker I am studying cv::detail::LKTrackerInvoker::operator() code called by calcOpticalFlowPyrLK in lkpyramid.cpp. I noticed the following constants. const int W_BITS = 14, W_BITS1 = 14; const float FLT_SCALE = 1.f/(1 << 20); I wonder why W_BITS and W_BITS1 are defined to be 14 instead of 16. I think we can use the full resolution of 32 bit integer by using 16. And FLT_SCALE seems to be a normalization factor. Is there a particular reason why the constant is defined to be 1.f/(1 << 20)? Thanks. |