Skip to content

Gui

Here we list all the objects that are supported by the GUI module and how to use them inside your web patch.


pd4web just render GUI objects

pd4web don't render objects boxes, object connections, messages, or anything else. Just the GUI objects.

Supported Gui Objects

For now, just these objects are supported:

  • bng: Bang object;
  • tgl: Toggle object;
  • nbx: Number box object;
  • vsl: Vertical slider object;
  • hsl: Horizontal slider object;
  • vradio: Vertical radio object;
  • hradio: Horizontal radio object;
  • vu: Vertical vu object;
  • cnv: Canvas object;
  • text: Comment object;

From external libraries:

  • else/knob: Knob object;
  • else/keyboard: Keyboard object;

How to use this objects?

Thanks to libpd, pd4web intercepts the messages sent by the objects and sends them to the web patch. Connections can't be intercepted, so you need to use send, s or receive, r objects to connect the GUI objects. This is how you can use the toggle object:

Don't use connections

The connections between objects are not intercepted by pd4web. You need to use send and receive objects to connect the GUI objects.

gui


All Gui objects include options to send and receive symbols, which are essential for communication between the Pd Patch and the Website.

  • Sending messages to the Pd Patch: Use the send symbol with a receiver or r object to send messages from the Website to the Pd Patch.
  • Sending messages to the Website: Use the receive symbol with a send or s object to send messages from the Pd Patch to the Website.

Note that pd4web does not automatically intercept connections between objects, so you must explicitly use the send and receive objects to connect the GUI objects for proper communication between the Pd Patch and the Website.