I’ve been learning the ropes for a little while (btw, kudos on the great community you have here), and decided to try my hand at this plugin stuff when I found that the HID approach would not work very well for a xbox 360 controller (basically, for some reason the thumbstick clicks were not reporting, and the trigger information was imposible to use)
While I know a little bit of c#, I am by no means a expert programmer, so I took the cowards way out and decided to take velcrome’s space navigator plugin and implement on top of it a wrapper I found for slimDX.XInput, and start erasing all the space navigator code until I only got the xbox stuff. Not the most elegant way, true, but was fast and easy.
It compiled and is running in vvvv – it is by no means done; I still need to check the naming conventions and clean up the code, and to put input pins for the device selection (right now it only works on the controller 0) and for the vibration motors, but it does the job.
However, every time I delete the node on a vvvv patch, it makes vvvv crash, and same thing if I close the patch containing the node. I know just enough c# that to know that probably I am not disposing something right, but not enough to really understand what I need to do.
Can anyone check the code and give me a hint?
edit: sorry, I uploaded the zip file with the compiled code and was a little big. fixed that
Xbox360Controller.zip (27.7 kB)