I use Rowmote, the app supports both remote and trackpad styles, I use it both on my iPad Mini and iPhone to control my Mac Mini - mainly use trackpad when using the iPad and Remote mode (i.e. play/pause etc), when using the iPhone.
The devices just need to be on the same WiFi network.....