Convert Figma logo to code with AI

Jays2Kings logoDS4Windows

Like those other ds4tools, but sexier

2,995
1,436
2,995
614

Top Related Projects

[NOT maintained anymore] Graphical program used to map keyboard buttons and mouse controls to a gamepad. Useful for playing games with no gamepad support

2,584

Primary repository for the x360ce library, front-end and tools.

Windows kernel-mode driver emulating well-known USB game controllers.

Like those other ds4tools, but sexier

Quick Overview

DS4Windows is an open-source tool that allows users to use a DualShock 4 (PS4) controller on Windows PC games and applications. It emulates an Xbox 360 controller, providing compatibility with a wide range of games and customizable controls.

Pros

  • Enables use of DualShock 4 controllers on Windows PCs
  • Offers extensive customization options for button mapping and sensitivity
  • Supports multiple controller profiles for different games or users
  • Includes features like touchpad mouse emulation and motion controls

Cons

  • Requires initial setup and configuration
  • May need occasional updates to maintain compatibility with Windows updates
  • Some games may still have issues recognizing the emulated controller
  • Can be complex for novice users to fully utilize all features

Getting Started

  1. Download the latest release from the DS4Windows GitHub repository.
  2. Extract the zip file to a folder on your PC.
  3. Run DS4Windows.exe.
  4. Connect your DualShock 4 controller via USB or Bluetooth.
  5. DS4Windows will automatically detect the controller and apply default settings.
  6. Customize your controller settings in the "Profiles" tab if desired.
  7. Start playing your games with your DualShock 4 controller!

Note: For some games, you may need to enable "Hide DS4 Controller" in the Settings tab to prevent conflicts.

Competitor Comparisons

[NOT maintained anymore] Graphical program used to map keyboard buttons and mouse controls to a gamepad. Useful for playing games with no gamepad support

Pros of AntiMicro

  • Supports a wider range of input devices, including keyboards and mice
  • More flexible mapping options for complex configurations
  • Cross-platform compatibility (Windows, Linux, macOS)

Cons of AntiMicro

  • Less specialized for DualShock 4 controllers
  • May require more manual configuration for optimal DS4 support
  • Lacks some DS4-specific features like touchpad and gyro support

Code Comparison

DS4Windows (C#):

public void MapAxis(int axisId, int actionId)
{
    // DS4-specific axis mapping logic
}

AntiMicro (C++):

void JoyAxisButton::setChangeSetCondition(SetChangeCondition condition)
{
    // Generic axis mapping for various input devices
}

Both projects aim to improve controller support on PC, but they have different focuses. DS4Windows is tailored specifically for DualShock 4 controllers, offering seamless integration and DS4-specific features. AntiMicro, on the other hand, provides a more versatile solution for mapping various input devices to keyboard and mouse actions, making it suitable for a broader range of controllers and input methods.

The code snippets highlight the difference in approach: DS4Windows has specialized functions for DS4 controllers, while AntiMicro uses more generic methods to accommodate different input devices.

2,584

Primary repository for the x360ce library, front-end and tools.

Pros of x360ce

  • Supports a wider range of controllers, including generic gamepads
  • Offers more granular button mapping and axis configuration
  • Provides a user-friendly graphical interface for controller setup

Cons of x360ce

  • May require more initial setup and configuration
  • Can be less stable with certain games or system configurations
  • Lacks some advanced features like touchpad support for DS4 controllers

Code Comparison

x360ce:

public static string GetProductGuid(string instanceId)
{
    var list = instanceId.Split('&');
    var guid = list.FirstOrDefault(x => x.StartsWith("IG_"));
    return guid?.Substring(3).ToUpper() ?? "";
}

DS4Windows:

public static string GetDeviceProperty(IntPtr deviceInstance, NativeMethods.SPDRP propertyType)
{
    var property = new StringBuilder(1024);
    NativeMethods.SetupDiGetDeviceRegistryProperty(deviceInstance, ref _deviceInfoData, propertyType, out _, property, 1024, out _);
    return property.ToString();
}

Both repositories focus on controller input management, but DS4Windows is specifically tailored for DualShock 4 controllers, while x360ce aims to support a broader range of gamepads. The code snippets demonstrate different approaches to device identification and property retrieval, reflecting their distinct focuses and implementation strategies.

Windows kernel-mode driver emulating well-known USB game controllers.

Pros of ViGEmBus

  • Lower-level driver implementation, providing better system integration
  • Supports a wider range of virtual devices, including Xbox 360 controllers
  • Can be used as a foundation for other input remapping tools

Cons of ViGEmBus

  • Requires more technical knowledge to implement and use effectively
  • Less user-friendly for end-users compared to DS4Windows
  • Lacks a built-in graphical user interface

Code Comparison

DS4Windows (C#):

public static void MapTo360Controller(DS4State state, X360State reportState)
{
    reportState.LX = (byte)((state.LX - 128) * 257 + 32768);
    reportState.LY = (byte)((state.LY - 128) * -257 + 32767);
    // ... more mapping code ...
}

ViGEmBus (C):

VOID DS4_REPORT_INIT(
    _Out_ PDS4_REPORT Report
)
{
    RtlZeroMemory(Report, sizeof(DS4_REPORT));
    Report->bThumbLX = 0x80;
    Report->bThumbLY = 0x80;
    // ... more initialization code ...
}

The code snippets show that DS4Windows focuses on mapping DS4 inputs to Xbox 360 controls, while ViGEmBus provides lower-level report structures for various device types. ViGEmBus offers more flexibility but requires more implementation effort from developers.

Like those other ds4tools, but sexier

Pros of DS4Windows (Ryochan7)

  • More frequent updates and active development
  • Improved compatibility with newer Windows versions
  • Enhanced customization options for controller settings

Cons of DS4Windows (Ryochan7)

  • Slightly steeper learning curve for new users
  • May require additional setup for some specific games

Code Comparison

DS4Windows (Jays2Kings):

public static void RefreshHID()
{
    ReEnableDevice(GUID_DEVINTERFACE_HID, true);
}

DS4Windows (Ryochan7):

public static bool RefreshHID()
{
    bool result = false;
    result = ReEnableDevice(GUID_DEVINTERFACE_HID, true);
    return result;
}

The Ryochan7 version adds a return value to indicate success or failure of the operation, providing more information to the calling function.

Both DS4Windows projects aim to enable DualShock 4 controller support on Windows, but Ryochan7's fork has become the more actively maintained version. It offers improved compatibility and features, making it the preferred choice for many users. However, the Jays2Kings version may still be suitable for those who prefer a simpler interface or have specific compatibility requirements with older setups.

Convert Figma logo designs to code with AI

Visual Copilot

Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.

Try Visual Copilot

README

This version of DS4Windows is no longer maintained and will recieve no future updates. For a newer version and more updates, download Ryochan7's DS4Windows

DS4Windows

Like those other ds4tools, but sexier.

DS4Windows is a portable program that allows you to get the best experience while using a DualShock 4 on your PC. By emulating a Xbox 360 controller, many more games are accessible.

You can find the latest and older versions here

Requirements

Microsoft .NET 4.5 or higher (needed to unzip the driver and for macros to work properly) DS4 Driver (Downloaded & Installed with DS4Windows) Microsoft 360 Driver (link inside DS4Windows, already installed on Windows 7 SP1 and higher or if you've used a 360 controller before) Sony DualShock 4 (This should be obvious) Micro USB cable (Optional)Bluetooth 2.1+, via adapter or built in pc (My recommendation) (Toshiba's bluetooth & Bluetooth adapters using CSR currently does not work)

Note: Hide DS4 currently doesn't work on Windows 10 without a workaround (disabling Network list service and restarting, but this causes serious issues with windows, use caution) You can find more info out at ds4windows.com