GCAdapter.h 690 B

1234567891011121314151617181920212223242526272829303132
  1. // Copyright 2014 Dolphin Emulator Project
  2. // SPDX-License-Identifier: GPL-2.0-or-later
  3. #pragma once
  4. #include <functional>
  5. #include "Common/CommonTypes.h"
  6. struct GCPadStatus;
  7. namespace GCAdapter
  8. {
  9. void Init();
  10. void ResetRumble();
  11. void Shutdown();
  12. void SetAdapterCallback(std::function<void(void)> func);
  13. void StartScanThread();
  14. void StopScanThread();
  15. // Buttons have PAD_GET_ORIGIN set on new connection
  16. // Netplay and CSIDevice_GCAdapter make use of this.
  17. GCPadStatus Input(int chan);
  18. void Output(int chan, u8 rumble_command);
  19. bool IsDetected(const char** error_message);
  20. bool DeviceConnected(int chan);
  21. void ResetDeviceType(int chan);
  22. bool UseAdapter();
  23. } // namespace GCAdapter