Reputation: 931
While trying to use raw input specific functions and structures in WINAPI using MinGW in Code::Blocks IDE, I got lots of compiler errors for missing functions and structures:
> ||In function 'void find_devices_input()':| |16|error:
> 'RAWINPUTDEVICELIST' was not declared in this scope| |16|error:
> 'GetRawInputDeviceList' was not declared in this scope| |19|error:
> 'list_devices_input' was not declared in this scope| |19|error:
> expected type-specifier before 'RAWINPUTDEVICELIST'| |19|error:
> expected ';' before 'RAWINPUTDEVICELIST'| |25|error: type '<type
> error>' argument given to 'delete', expected pointer| ||=== Build
> finished: 6 errors, 0 warnings (0 minutes, 0 seconds) ===|
Why does this happen and how can this be fixed?
Upvotes: 0
Views: 556
Reputation: 19232
It happens because
'RAWINPUTDEVICELIST' was not declared in this scope
etc.
The docs say to #include <Windows.h>
Upvotes: 0