private bool CheckDpadDs4AxisAsButton(ScpHidReport Data, DSAxis parAxis) { if (parAxis.DS4 != null & parAxis.DS4 != Ds4Axis.None) { return(CheckDpadAxisAsButton(Data[parAxis.DS4].Value, parAxis.triggerHigh)); } else { return(false); } }
private void AssignAxisButton(ref uint parSourceButton, DSAxis parSourceID, string parTargetButton) { if (parTargetButton.StartsWith("B")) { //used for button uint buttonid = uint.Parse(parTargetButton.Remove(0, 1)); if (buttonid > m_nButtons) { m_nButtons = (byte)buttonid; } parSourceButton = buttonid; } else if (parTargetButton.StartsWith("P")) { //used for POV m_dpad = true; switch (parTargetButton) { case "PU": { m_aPUp = parSourceID; } break; case "PD": { m_aPDown = parSourceID; } break; case "PL": { m_aPLeft = parSourceID; } break; case "PR": { m_aPRight = parSourceID; } break; } } }
private bool CheckDpadDs4AxisAsButton(ScpHidReport Data, DSAxis parAxis) { if (parAxis.DS4 != null & parAxis.DS4 != Ds4Axis.None) { return CheckDpadAxisAsButton(Data[parAxis.DS4].Value, parAxis.triggerHigh); } else { return false; } }
private bool CheckDpadDs4AxisAsButton(DsPacket Data, DSAxis parAxis) { if (parAxis.DS4 != Ds4Axis.None) { return CheckDpadAxisAsButton(Data.Axis(parAxis.DS4), parAxis.triggerHigh); } else { return false; } }