Lines Matching refs:acc
437 sp->acc.x = sp->acc.z = 0.0f ; in reset_kpad()
438 sp->acc.y = -1.0f ; in reset_kpad()
441 kp->hard_acc = sp->acc ; in reset_kpad()
729 static void calc_acc( KPADInsideStatus *kp, f32 *acc, f32 acc2 ) in calc_acc() argument
735 f2 = acc2 - *acc ; in calc_acc()
757 *acc += f1 * f2 ; in calc_acc()
760 *acc += ( f2 + kp->acc_play_radius ) * kp->acc_sensitivity ; in calc_acc()
762 *acc += ( f2 - kp->acc_play_radius ) * kp->acc_sensitivity ; in calc_acc()
851 static f32 clamp_acc( f32 acc, f32 clamp ) in clamp_acc() argument
853 if ( acc < 0.0f ) { in clamp_acc()
854 if ( acc < -clamp ) return ( -clamp ) ; in clamp_acc()
856 if ( acc > clamp ) return ( clamp ) ; in clamp_acc()
858 return ( acc ) ; in clamp_acc()
888 vec = sp->acc ; in read_kpad_acc()
891 calc_acc( kp, &sp->acc.x, kp->hard_acc.x ) ; in read_kpad_acc()
892 calc_acc( kp, &sp->acc.y, kp->hard_acc.y ) ; in read_kpad_acc()
893 calc_acc( kp, &sp->acc.z, kp->hard_acc.z ) ; in read_kpad_acc()
894 sp->acc_value = sqrtf( sp->acc.x * sp->acc.x + sp->acc.y * sp->acc.y + sp->acc.z * sp->acc.z ) ; in read_kpad_acc()
897 vec.x -= sp->acc.x ; in read_kpad_acc()
898 vec.y -= sp->acc.y ; in read_kpad_acc()
899 vec.z -= sp->acc.z ; in read_kpad_acc()
926 vec = sp->ex_status.fs.acc ; in read_kpad_acc()
929 calc_acc( kp, &sp->ex_status.fs.acc.x, fsrc.x ) ; in read_kpad_acc()
930 calc_acc( kp, &sp->ex_status.fs.acc.y, fsrc.y ) ; in read_kpad_acc()
931 calc_acc( kp, &sp->ex_status.fs.acc.z, fsrc.z ) ; in read_kpad_acc()
932 …x_status.fs.acc.x * sp->ex_status.fs.acc.x + sp->ex_status.fs.acc.y * sp->ex_status.fs.acc.y + sp-… in read_kpad_acc()
935 vec.x -= sp->ex_status.fs.acc.x ; in read_kpad_acc()
936 vec.y -= sp->ex_status.fs.acc.y ; in read_kpad_acc()
937 vec.z -= sp->ex_status.fs.acc.z ; in read_kpad_acc()
1751 ep->fs.acc.x = ep->fs.acc.z = 0.0f ; in read_kpad_ext()
1752 ep->fs.acc.y = -1.0f ; in read_kpad_ext()
2828 f32 KPADReviseAcc( Vec *acc ) in KPADReviseAcc() argument
2830 MTXMultVec( kp_fs_rot, acc, acc ) ; in KPADReviseAcc()