fixed compile error with vs2012

fmod function in vs2012 has 3 different definitions,
current code has different type arguments. cause compile error in vs2012.