Discussion:
[LAU] Custom UI development in Pure Data
Heikki Ketoharju
2013-08-31 19:26:35 UTC
Permalink
Hi everyone!

I don't know if this should be asked in LAD, but I'm fed up with Pure
Data's own gui components, and would like to develop my own gui with
something else (GTK? QT?). I don't have earlier experience with any UI
toolkit, so I don't have any favourites. What is easiest approach to custom
gui development with PD?

I need something like list boxes and buttons with custom text. Nothing too
special.

Heikki
--
http://heikki.ketoharju.info/en/ <http://heikki.ketoharju.info>
Simon Wise
2013-09-01 04:14:35 UTC
Permalink
Post by Heikki Ketoharju
Hi everyone!
I don't know if this should be asked in LAD, but I'm fed up with Pure
Data's own gui components, and would like to develop my own gui with
something else (GTK? QT?). I don't have earlier experience with any UI
toolkit, so I don't have any favourites. What is easiest approach to custom
gui development with PD?
I need something like list boxes and buttons with custom text. Nothing too
special.
You have some choices:

1/ use whatever toolkit you prefer to build your GUI app, and send messages to
PD over a socket. Pd is a language, you don't need to use the GUI parts of it at
all ... it has very mature ways of listening to input of all sorts.

2/ ditto, but send osc or midi instead of native pd messages

3/ ditto, but use real hardware interfaces rather than the somewhat limited
ascii - mouse - screen interface of most toolkits.

4/ use libpd to give access to lots of PD from within the GUI application you
are building

5/ look at droid party for a project that provides another GUI method, using
libpd internally, for making interfaces on Android (and iOS) devices.

http://droidparty.net/


All these have advantages, but of course they all involve more work than just
using the GUI elements built into the language.

Simon
Marc Lavallée
2013-09-01 05:53:24 UTC
Permalink
There's an old method to create a remote GUI for PD,
that uses wxWindows and communicate through sockets.
It's not a replacement GUI, but it helps to create front-ends:
http://crca.ucsd.edu/~jsarlo/gripd/
--
Marc

Sun, 01 Sep 2013 12:14:35 +0800,
Post by Simon Wise
Post by Heikki Ketoharju
Hi everyone!
I don't know if this should be asked in LAD, but I'm fed up with
Pure Data's own gui components, and would like to develop my own
gui with something else (GTK? QT?). I don't have earlier experience
with any UI toolkit, so I don't have any favourites. What is
easiest approach to custom gui development with PD?
I need something like list boxes and buttons with custom text.
Nothing too special.
1/ use whatever toolkit you prefer to build your GUI app, and send
messages to PD over a socket. Pd is a language, you don't need to use
the GUI parts of it at all ... it has very mature ways of listening
to input of all sorts.
2/ ditto, but send osc or midi instead of native pd messages
3/ ditto, but use real hardware interfaces rather than the somewhat
limited ascii - mouse - screen interface of most toolkits.
4/ use libpd to give access to lots of PD from within the GUI
application you are building
5/ look at droid party for a project that provides another GUI
method, using libpd internally, for making interfaces on Android (and
iOS) devices.
http://droidparty.net/
All these have advantages, but of course they all involve more work
than just using the GUI elements built into the language.
Simon
Federico Lopez
2013-09-01 16:30:11 UTC
Permalink
Post by Simon Wise
Post by Heikki Ketoharju
Hi everyone!
I don't know if this should be asked in LAD, but I'm fed up with Pure
Data's own gui components, and would like to develop my own gui with
something else (GTK? QT?). I don't have earlier experience with any UI
toolkit, so I don't have any favourites. What is easiest approach to custom
gui development with PD?
I need something like list boxes and buttons with custom text. Nothing too
special.
1/ use whatever toolkit you prefer to build your GUI app, and send
messages to PD over a socket. Pd is a language, you don't need to use
the GUI parts of it at all ... it has very mature ways of listening to
input of all sorts.
There is a toolkit using WebSockets to communicate Pd and HTML5/javascript

http://dancingbonemachine.elsoftwarehamuerto.org/tutorial.html
Post by Simon Wise
2/ ditto, but send osc or midi instead of native pd messages
3/ ditto, but use real hardware interfaces rather than the somewhat
limited ascii - mouse - screen interface of most toolkits.
4/ use libpd to give access to lots of PD from within the GUI
application you are building
5/ look at droid party for a project that provides another GUI method,
using libpd internally, for making interfaces on Android (and iOS)
devices.
http://droidparty.net/
All these have advantages, but of course they all involve more work
than just using the GUI elements built into the language.
Simon
_______________________________________________
Linux-audio-user mailing list
http://lists.linuxaudio.org/listinfo/linux-audio-user
Marc Lavallée
2013-09-01 18:01:45 UTC
Permalink
Post by Federico Lopez
There is a toolkit using WebSockets to communicate Pd and
HTML5/javascript
http://dancingbonemachine.elsoftwarehamuerto.org/tutorial.html
Interesting. It uses libpd. Id didn't know much about libpd:
https://github.com/libpd/libpd/wiki
There's APIs for many languages and environnements,
including a recent for addon for OpenFrameworks:
https://github.com/danomatika/ofxPd

--
Marc
R. Mattes
2013-09-01 18:17:45 UTC
Permalink
Post by Marc Lavallée
Post by Federico Lopez
There is a toolkit using WebSockets to communicate Pd and
HTML5/javascript
http://dancingbonemachine.elsoftwarehamuerto.org/tutorial.html
https://github.com/libpd/libpd/wiki
There's APIs for many languages and environnements,
https://github.com/danomatika/ofxPd
Just keep in mind: libpd can only _run_ pd patches, you cannot
create/modify patches. Iff this is all you need than libpd might
be a valid replacement for Pd proper. Another obstacle to consider:
libpd doesn't provide any build-in way to handle audio data. You need
to write code to send/receive audio/midi data to your framework-of-choice.
On Linux that means writing quite some jack code (and, since libpd's
model of operation is push/pull, that code isn't really trivial).
That's where the example code is astonishing terse :-) :

----[file: cppTest$/src/main.cpp]------------------------------------

// fill inbuf here
pd.processFloat(1, inbuf, outbuf);
// use outbuf here

---------------------------------------------------------------------

Frankly, I'd rather write my GUI in Qt (or whatever) and communicate whith
a headless pd process by means of OSC or even "raw" pd messages.

Cheers, Ralf Mattes

--
R. Mattes -
Hochschule fuer Musik Freiburg
***@inm.mh-freiburg.de
Marc Lavallée
2013-09-01 18:25:23 UTC
Permalink
Post by R. Mattes
Frankly, I'd rather write my GUI in Qt (or whatever) and communicate
whith a headless pd process by means of OSC or even "raw" pd messages.
That what I used to do when I was programming "interactive art
installations" (~10 years ago). The "raw" pd messages protocol is called
"FUDI"; OSC is useful for handling hierarchically structured messages,
but is overkill in most situations.
--
Marc
Harry van Haaren
2013-09-01 18:59:52 UTC
Permalink
Or hidden away on a github repo...
https://github.com/harryhaaren/openAudioProgrammingTutorials/tree/master/pureDataHost
Post by R. Mattes
Frankly, I'd rather write my GUI in Qt (or whatever) and communicate whith
a headless pd process by means of OSC or even "raw" pd messages.
I have implemented a libPD "front-end", which parses the patch file
manually, and creates a canvas
using GANV[1] and GTK. Note this was an experiment, and I'm no longer
working on this.
Screenshot link:
Loading Image...

HTH, -Harry

[1] http://svn.drobilla.net/lad/trunk/ganv
Gene Heskett
2013-09-01 19:22:18 UTC
Permalink
Post by Harry van Haaren
Or hidden away on a github repo...
https://github.com/harryhaaren/openAudioProgrammingTutorials/tree/master
/pureDataHost
Post by R. Mattes
Frankly, I'd rather write my GUI in Qt (or whatever) and communicate
whith a headless pd process by means of OSC or even "raw" pd
messages.
I have implemented a libPD "front-end", which parses the patch file
manually, and creates a canvas
using GANV[1] and GTK. Note this was an experiment, and I'm no longer
working on this.
https://www.dropbox.com/s/sbd2uxwa7xtwshr/libpdUiFrontend.png
This one is a passing resemblance to a linux gizmo by the name of
rockhopper. It analyses the .hal configuration file of a linuxcnc
installation, and generates a web (http://host:8000) viewable .svg file,
useless because its images are so small for screen reading, file that is a
logic diagram of the control code for a specific cnc controlled machine.
You can save the file and posterize it to print it, tape the prints
together and get a wall poster that is readable. My little toy 7x12 lathe
is 6 landscape pages done that way. Even at 6 pages, its a "busy" diagram.
Post by Harry van Haaren
HTH, -Harry
[1] http://svn.drobilla.net/lad/trunk/ganv
Cheers, Gene
--
"There are four boxes to be used in defense of liberty:
soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
My web page: <http://coyoteden.dyndns-free.com:85/gene> is up!
My views
<http://www.armchairpatriot.com/What%20Has%20America%20Become.shtml>
No problem is so large it can't be fit in somewhere.
A pen in the hand of this president is far more
dangerous than 200 million guns in the hands of
law-abiding citizens.
Heikki Ketoharju
2013-09-01 21:57:21 UTC
Permalink
Thanks everyone!

I think I'll choose some language and toolkit. Maybe this is nice
opportunity to learn Python & GTK... Dancing Bone Machine seemed fun way to
develop UIs to patches but I don't want to run music software in browser.

BTW Harry's Libpd frontend looks nice! I think pd's official UI would be
much better with some other toolkit than tcl...

-Heikki
Post by Gene Heskett
Post by Harry van Haaren
Or hidden away on a github repo...
https://github.com/harryhaaren/openAudioProgrammingTutorials/tree/master
/pureDataHost
Post by R. Mattes
Frankly, I'd rather write my GUI in Qt (or whatever) and communicate
whith a headless pd process by means of OSC or even "raw" pd
messages.
I have implemented a libPD "front-end", which parses the patch file
manually, and creates a canvas
using GANV[1] and GTK. Note this was an experiment, and I'm no longer
working on this.
https://www.dropbox.com/s/sbd2uxwa7xtwshr/libpdUiFrontend.png
This one is a passing resemblance to a linux gizmo by the name of
rockhopper. It analyses the .hal configuration file of a linuxcnc
installation, and generates a web (http://host:8000) viewable .svg file,
useless because its images are so small for screen reading, file that is a
logic diagram of the control code for a specific cnc controlled machine.
You can save the file and posterize it to print it, tape the prints
together and get a wall poster that is readable. My little toy 7x12 lathe
is 6 landscape pages done that way. Even at 6 pages, its a "busy" diagram.
Post by Harry van Haaren
HTH, -Harry
[1] http://svn.drobilla.net/lad/trunk/ganv
Cheers, Gene
--
soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
My web page: <http://coyoteden.dyndns-free.com:85/gene> is up!
My views
<http://www.armchairpatriot.com/What%20Has%20America%20Become.shtml>
No problem is so large it can't be fit in somewhere.
A pen in the hand of this president is far more
dangerous than 200 million guns in the hands of
law-abiding citizens.
_______________________________________________
Linux-audio-user mailing list
http://lists.linuxaudio.org/listinfo/linux-audio-user
--
http://heikki.ketoharju.info
Marc Lavallée
2013-09-01 06:04:25 UTC
Permalink
PD have a new GUI Plugins API:
http://puredata.info/docs/guiplugins/

--
Marc

Sat, 31 Aug 2013 22:26:35 +0300,
Post by Heikki Ketoharju
Hi everyone!
I don't know if this should be asked in LAD, but I'm fed up with Pure
Data's own gui components, and would like to develop my own gui with
something else (GTK? QT?). I don't have earlier experience with any UI
toolkit, so I don't have any favourites. What is easiest approach to
custom gui development with PD?
I need something like list boxes and buttons with custom text.
Nothing too special.
Heikki
Simon Wise
2013-09-01 10:06:44 UTC
Permalink
Post by Marc Lavallée
http://puredata.info/docs/guiplugins/
yes ... the pd interface is much more flexible, you can change the look, change
the behaviour, great work has been done there ... but if you want a different
slider or whatever then you need to write one (or find one), and if you want to
use some other toolkit to build an interface then it is communication with pd or
pd as a library you are after.

One option I forgot to mention is building an interface in pd using GEM windows,
but I was thinking the OP was wanting to use a existing toolkit with the look
and options and pre-built bits that that provides.


Simon
Fero Kiraly
2013-09-04 15:37:05 UTC
Permalink
what about SwingOSC ? it looks nice.

fero

Loading...