I already have a WH_MOUSE_LL hook in my application, but need a different behavior for Mouse and Touchpad.
I know about Raw Input API, but have no idea how to use it
Disassemble some Touchpad driver and see how it works. This is the only way to go, cause drivers might use different methods of mouse emulation. And don't forget to vote for my answer ;).