Made thresh_ a member variables of FID in order to use in inline functions.