GL framebuffer from Lua scripts

Hello! Lua scripts can open a dialog. If those dialogs could contain a (rendered) GL framebuffer, users could write their own GUIs or even use GUI libraries which write into that framebuffer. What about this? (maybe I am saying something wrong, I never implemented a GUI from OpenGL)

The hard part with GUIs is interaction (mouse, keyboard events), not drawing.

There are already bindings available to draw. This is used for example with plugin inline-displays (e.g. ACE Inline Spectrogram), or for scalable icons rendered on toolbar script buttons (e.g. split at marker script).

In theory you can also get raw access to the [RGBA] framebuffer used by the cairo surface, but using drawing primitives is usually a lot more convenient.

Anyway, custom GUIs are not yet available. Ideally it would be a simple toolkit abstraction where a image-surface is only one of the available widgets.

Also currently GUI scripts are modal, event loop integration will have to be implemented as well.

Thank you Robin, did not know about Cairo being available from Lua.

I guess that if Ardour could at the very least draw its own widgets something like an in-window piano roll (I-know, I-know! :grinning_face_with_smiling_eyes:) could be implemented via Lua!

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.