Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make extended controller information available for device selection #13896

Open
wants to merge 18 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 11 commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
6b6c374
Raised hidapi requirement to 0.14.0 and devendored the old hidapi 0.1…
JoergAtGithub Nov 11, 2024
0173691
Remove pConfig from BulkEnumerator and Hss1394Enumerator
JoergAtGithub Nov 16, 2024
fe7d799
Removed DeviceCategory class and related code.
JoergAtGithub Nov 16, 2024
faaea4a
Display MIDI, HID, BULK protocol icons in preferences tree
JoergAtGithub Oct 11, 2024
af5f865
New UI with two column layout for device info and mapping info
JoergAtGithub Oct 13, 2024
a8bd097
Added VID/PID hex numbers read from the hardware, that are more trust…
JoergAtGithub Nov 13, 2024
664c9bf
Load and parse HID usage tables from official usb.org JSON (extracted…
JoergAtGithub Nov 14, 2024
e7e560b
Delete all hard coded HID Usage-Page constants
JoergAtGithub Nov 16, 2024
08c0db7
Moved HID constants to mixxx::hid namespace in hidenumerator.cpp
JoergAtGithub Nov 16, 2024
d614e57
Refactor DeviceInfo formatting and update QDebug operator
JoergAtGithub Nov 16, 2024
b23d05a
Added comment about release_number field
JoergAtGithub Nov 16, 2024
84eed81
Updated HidUsageTables to use static data structure from hidusagetabl…
JoergAtGithub Nov 24, 2024
23643e2
Remove default case in switch statement to make warning by -Wswitch v…
JoergAtGithub Nov 24, 2024
62a80f9
Optimizing the temporary allocations in operator<< and directly write…
JoergAtGithub Nov 24, 2024
632d685
Unified physicalTransport enum to string conversion
JoergAtGithub Nov 24, 2024
5c64096
Removed the official usb.org JSON HID Usage Tables file from the sou…
JoergAtGithub Nov 24, 2024
a6fab09
Introduce formatHex in dlgprefcontroller
JoergAtGithub Nov 24, 2024
3882a86
Moved conversion of hidapi bus typte to physical transport protocol e…
JoergAtGithub Nov 24, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 4 additions & 33 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3716,40 +3716,10 @@ find_package(LibUSB)
# USB HID controller support
option(HID "USB HID controller support" ON)
if(HID)
# hidapi 0.11.2 is the first release, that implements hid_get_input_report
# for the Linux hidraw backend.
find_package(hidapi 0.11.2)
# hidapi 0.14.0 is the first release, that contains bus type information
find_package(hidapi 0.14.0)
if(NOT hidapi_FOUND)
message(STATUS "Linking internal libhidapi statically")
add_library(mixxx-hidapi STATIC EXCLUDE_FROM_ALL)
target_include_directories(mixxx-hidapi SYSTEM PUBLIC lib/hidapi/hidapi)
if(WIN32)
target_sources(mixxx-hidapi PRIVATE lib/hidapi/windows/hid.c)
find_library(Setupapi_LIBRARY Setupapi REQUIRED)
target_link_libraries(mixxx-hidapi PUBLIC ${Setupapi_LIBRARY})
elseif(APPLE)
if(IOS)
message(FATAL_ERROR "USB HID controllers are not supported on iOS")
endif()
target_sources(mixxx-hidapi PRIVATE lib/hidapi/mac/hid.c)
find_library(AppKit_LIBRARY AppKit REQUIRED)
target_link_libraries(mixxx-hidapi PUBLIC ${AppKit_LIBRARY})
elseif(UNIX)
if(CMAKE_SYSTEM_NAME STREQUAL Linux)
find_library(libudev_LIBRARY udev REQUIRED)
target_sources(mixxx-hidapi PRIVATE lib/hidapi/linux/hid.c)
target_link_libraries(mixxx-hidapi PRIVATE ${libudev_LIBRARY})
else()
if(NOT LibUSB_FOUND)
message(FATAL_ERROR "USB HID controller support on Unix with statically linked libhidapi-libusb requires libusb 1.0 and its development headers.")
endif()
target_sources(mixxx-hidapi PRIVATE lib/hidapi/libusb/hid.c)
target_link_libraries(mixxx-hidapi PRIVATE LibUSB::LibUSB)
endif()
else()
message(FATAL_ERROR "USB HID controller support only possible on Windows/Mac OS/Linux/BSD.")
endif()
target_link_libraries(mixxx-lib PRIVATE mixxx-hidapi)
message(FATAL_ERROR "hidapi >= 0.14.0 not found!")
else()
# hidapi has two backends on Linux, one using the kernel's hidraw API and one using libusb.
# libusb obviously does not support Bluetooth HID devices, so use the hidraw backend. The
Expand All @@ -3767,6 +3737,7 @@ if(HID)
src/controllers/hid/hidiooutputreport.cpp
src/controllers/hid/hiddevice.cpp
src/controllers/hid/hidenumerator.cpp
src/controllers/hid/hidusagetables.cpp
src/controllers/hid/legacyhidcontrollermapping.cpp
src/controllers/hid/legacyhidcontrollermappingfilehandler.cpp
)
Expand Down
18 changes: 0 additions & 18 deletions lib/hidapi/AUTHORS.txt

This file was deleted.

10 changes: 0 additions & 10 deletions lib/hidapi/HACKING.txt

This file was deleted.

26 changes: 0 additions & 26 deletions lib/hidapi/LICENSE-bsd.txt

This file was deleted.

Loading
Loading