Choose a controller connection

Compare direct browser input, native adapters and MIDI relay for gamepads and music controllers.

A gamepad can control a browser instrument directly. You need a local relay when the destination accepts a different kind of input, such as a DAW expecting MIDI. Choose the destination first, then the connection that preserves the controls your app needs.

For a first phrase and an editable trigger-to-MIDI assignment, start with Play music with a game controller.

Choose a path

Your destinationInput pathWhat to check
A browser app with gamepad supportPaired gamepad → browser Gamepad API → appBrowser mapping, focus, button/axis values and optional vibration
A browser app with MIDI supportMIDI controller or relay → OS MIDI input → Web MIDI → appBrowser permission, selected input, channel and message type
A native standalone instrumentGamepad or MIDI device → native host adapter → appThe exact host's device support; a standalone build does not add an adapter
A DAW instrument expecting MIDIGamepad → musical mapping → virtual MIDI source → DAW inputRelay software, virtual-port availability, note ownership and cleanup
An app requiring richer controller dataDevice adapter → agreed controller protocol → appIdentity, signal precision, timing, feedback and connection lifetime

The Gamepad API exposes browser controller input and optional haptics. Web MIDI exposes OS-visible MIDI ports. They are separate APIs with separate access and capability checks. A device appearing in one does not make it an input in the other.

Maru's source SDK supplies direct browser capture and signal-to-MIDI mapping. The source workspace also includes a local controller-app runner with SDL3 capture and an independent virtual-MIDI output. It runs Controller MIDI or Gamepad Chords without a browser page. Building its helper needs an installed SDL3 toolchain; its source distribution's local controller-app guide covers setup and receiver checks. Source-runner verification is separate from packaged Desktop and physical-controller compatibility. Importing the mapping library alone installs no relay service or virtual port. For an executable SDK starting point, use Controllers and musical signals.

Connect to a standalone or plug-in instrument

A musical relay gives the receiving application an ordinary MIDI source. Start the local relay, then select its source in the standalone app's MIDI Input picker, or on a DAW instrument track. Choose the same channel and enable the receiver's monitoring. Test one note-on and note-off before adding expression. Select audio output independently in the standalone app or DAW.

An AU or VST instrument can receive those musical events through its host. Generating MIDI from a plug-in for another instrument is a separate feature. Ableton Live's format comparison lists direct MIDI output for VST2/VST3 and not AU. Use its VST MIDI-output setup when routing a MIDI-generating plug-in. This limitation does not prevent an AU instrument from receiving the relay's MIDI through the DAW.

For CC-controlled effects, learn or assign the incoming CC at the receiver. A moving trigger does not automatically select a filter or mix parameter. Confirm pitch-bend range at both ends. A successful note test does not prove expression or feedback support.

Building an app as standalone, AU or VST compiles its declared audio/MIDI processing. It does not automatically add gamepad discovery or a background controller app. A host must supply those services, including the behavior when the editor closes. Use a relay when the receiver has MIDI input but lacks direct gamepad input.

Keep the device, connection and assignment separate

The device supplies controls: buttons, sticks, triggers, keys, encoders or touch surfaces. The connection carries their input. The assignment gives it meaning: choose a chord, play a tone, move a parameter or send a MIDI message.

A PS5 trigger can control expression directly as a continuous value. A relay can instead turn its travel into CC11 for a MIDI instrument. The receiver sees CC11; those bytes alone do not tell it that a PS5 trigger produced them.

For two identical controllers, keep separate connection identities. Browser indices are attachment slots, and names describe models rather than unique units. If direct capture and a MIDI relay both reach the app, select one path for an assignment to avoid playing each press twice.

Match the input to the musical job

InputUseful musical roleInformation to retain
Button or key gateStart and release a toneBoth edges and the pitch chosen at the attack
Progressive trigger or faderExpression, mix or a continuous parameterFull travel and resting value
Centered stickPitch gesture or two-dimensional controlSigned axes and center/dead zone
Relative encoderChange a parameter from its present valueEvery signed step, including repeated steps
Pressure or touchShape a held phrasePressure amount or contact lifetime where supplied

Manufacturer labels help people find controls. Assignments should retain stable positions or control IDs. On the standard gamepad layout, PlayStation Cross and Xbox A occupy the south position; the musical assignment can stay the same. Recognizing a product name helps label a drawing but does not establish an unknown input layout.

Decide where MIDI conversion belongs

A musical relay produces notes, CC or pitch bend. The receiving instrument plays those messages. Keep chord selection and transposition at the sender if it already applied them; repeating the mapping at the receiver changes the result.

A control relay carries the original gestures for another app to interpret. Both ends need an agreed mapping, identity and version. Ordinary MIDI messages do not define a universal gamepad layout, touch protocol or rumble command.

MIDI conversion can also reduce precision. Ordinary CC has seven-bit values; pitch bend has fourteen-bit values. Higher-resolution control requires a specified encoding and a receiver that understands it. See the MIDI message reference. Keep continuous values intact until the selected output requires conversion.

Input and feedback travel independently

Trigger travel is input. Rumble, LEDs, displays and adaptive trigger resistance are different output features. Receiving button presses does not establish any of those capabilities, and having a MIDI output does not automatically provide them.

Use Controller mappings and feedback to connect signal identities to assignments and visual states. If the connection does not behave as expected, follow Troubleshoot controller input.