Re: [ecasound] ecasound and lua?

From: Philipp Überbacher <hollunder@email-addr-hidden>
Date: Fri Jul 09 2010 - 12:18:12 EEST

Excerpts from Joel Roth's message of 2010-07-09 09:01:23 +0200:
> On Thu, Jul 08, 2010 at 03:47:06PM +0200, Philipp wrote:
> > Hi,
> > I was wondering whether someone has experience with a combination of
> > ecasound and lua.
> >
> > The idea is to write something like a simple DAW with ecasound as
> > backend, some widget toolkit as frontend and lua as glue in between.
> >
> > The reasons for this are manyfold.
> > I want something reliable that has the features I need for my own
> > simple recording purposes. I also want to learn lua, a language which
> > has a strange appeal to me. And I want to learn how to do UI
> > programming, there are so many bad examples out there, there has to be a
> > way to do it right.
>
> Hi Philipp,

Hi Joel, thanks for the nice answer.

> Sounds like an interesting project. A list at
> http://home.pacbell.net/atai/guitool/
> has a number of bindings for Lua. Here's the
> list, minus links:
>
> * lua-gtk and lua-gnome, Lua's gtk+ and GNOME bindings
> * lua-FLTK, Lua FLTK binding
> * wxLua, WxWindows binding for Lua
> * tkLua, tk binding
> * IUP (Portable User Interface), a highly portable toolkit
> for Lua and C, for Windows and X11/Motif.

It's the first time I read about IUP, it looks nice, but I fear it might
not be available in every distribution. The lack of unicode support,
while not immediately a problem, if ever, isn't helping.
This is only relevant if I ever get it to a state where others become
interested in it, but then the possibilities would be missing.

> I used Tk for Nama. Easy to start with, cool in its day,
> irredeemably ugly to many.

It's indeed not pretty. While prettiness isn't the most important thing,
I still think it's part of the user experience.

> I took a look at WxWindows, as least a "hello world"
> example or two. It's beautiful, and has a significant
> learning curve.

I also see it in the 'ugly' corner. Don't know why exactly, but I don't
like it :)

> GTK is very full featured.

I was original exposed to the idea for that kind of DAW by 'kfoltman'
(calf), and his idea was to write a pygtk ecasound frontend. However,
our ideas went in different directions, then my laziness and lack of
time showed up and nothing happened. I trust his judgment that gtk would
be a good choice, but on the other hand it's also a huge monster.

Qt bindings for lua are also available (no 'designer' though), but it's
also a lot more than a graphics toolkit. I think I'd rather learn Qt
than gtk, because it could at some point be useful for helping at
Traverso.

> Be aware that mastering any of these toolkits is a
> significant life investment! (Well, I believe so, not having
> actually mastered one myself :-)
>
> I believe the right way to learn GUI programming is to make
> some mistakes. ;-)

Making mistakes is something I was always afraid to do :)
Maybe I should go with the weirdest choice, IUP, knowing of its
drawbacks. The fact that it's small and really only a graphics toolkit
is very appealing to me at this time.

> For the Ecasound interface, it is relatively easy
> to run Ecasound in server mode, and then handle
> IO to the process via a TCP/IP socket.
>
> ecasound -K --server
>
> The -K flag keeps the process alive indefinitely.
> For debugging you might like to start Ecasound as:
>
> ecasound -c --server
>
> This way you can poke around inside Ecasound using
> Ecasound's command line as well as your Lua/Net-ECI
> interface.
>
> If you add the -ddd flag, you'll get full diagnostics.
>
> You can find all you need about Net-ECI in the Ecasound docs.
> I'll also be glad to send you sample code (in Perl ;-)
> for sending commands and reading results from
> an Ecasound process.

I'm a bit curious, why use Net-ECI? It seems like there are no lua
bindings, but I would have thought that it's not too hard to use C-ECI
from lua. Not that I ever wrote lua-C code, but it's said to be easy.

> btw, Nama is now available as a Debian package, so
> if you get a hankering to fool around with it,
> 'apt-get install nama' (or 'aptitude nama')
> should work.
>
> Regards,
>
> Joel

I'm not on a debian based system, and it seems I need to package nama
myself, but I guess it won't be too hard. I also need to get my
distribution to build ecasound with jack support though.
I heard a lot of good things about nama from Julien, I'll certainly try
it.

Thanks a lot Joel.

-- 
Regards,
Philipp
--
"Wir stehen selbst enttäuscht und sehn betroffen / Den Vorhang zu und alle Fragen offen." Bertolt Brecht, Der gute Mensch von Sezuan
------------------------------------------------------------------------------
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
_______________________________________________
Ecasound-list mailing list
Ecasound-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ecasound-list
Received on Fri Jul 9 16:15:01 2010

This archive was generated by hypermail 2.1.8 : Fri Jul 09 2010 - 16:15:01 EEST