seq66
seq66 copied to clipboard
JACK_METADATA_ICON_NAME icon?
If JACK_METADATA_ICON_NAME is set too a "A value with a MIME type of “image/png;base64” that is an encoding of an NxN (with N <=32) image to be used when displaying a visual representation of that client or port." by a client then the icon can show up in other apps such as RaySession.
Clients can set three metadata keys:
- http://jackaudio.org/metadata/icon-name ( JACK_METADATA_ICON_NAME )
- The freedesktop/XDG name of the icon. Not a path, no file extension. e.g: "patroneo"
- http://jackaudio.org/metadata/icon-small ( JACK_METADATA_ICON_SMALL )
-
- Square base64/png image up to 32x32, included.
- http://jackaudio.org/metadata/icon-large ( JACK_METADATA_ICON_LARGE )
- Square base64/png image higher than 32x32 up to 128x128, included.
https://jackaudio.org/api/group__Metadata.html
Question: do the base64 images have to be a single-line, or can the lines be limited in length to 80 columns for better appearance in source code?
Slowly getting clarity on this stuff. But the problem I have right now is that jack_get_uuid_for_client_name() returns small numbers such as 12, 13, 14, .... But jack_uuid_parse() wants this number to have the 31st bit set, and so it fails. Going through the tangle of jack2 code to see what I might be doing wrong. I set the client name to "seq66" and that is what jack_get_client_name() returns and what gets passed to jack_get_uuid_for_client_name().
Have a look at this function to see how to get the jack_uuid_t from your client name
https://github.com/kfoltman/calfbox/commit/dc0b3a6e8cf4dac8e56f1a3cdb4b48ba6c9e5f1b
To be sure, what version of JACK is being used?
I can get a UUID easily using either jack_client_get_uuid() or jack_get_uuid_for_client_name(). The problem is that the UUID is only two digits in length, while JACK_UUID_SIZE is 36. The jack_set_property function wants a numeric UUID, but jack_uuid_parse() fails on a UUID like "12".
If I convert the uuid to an integer 12 in the debugger, then call
int rc = jack_set_property(clienthandle, 12,
"http://jackaudio.org/metadata/icon-name", "qseq66", "text/plain");
then rc = -1 (an error). This is in Jack 2.
Same for jack_set_property(clienthandle, 12, "http://jackaudio.org/metadata/icon-small", "iVBORw0K..." /icon data/, "image/png;base64");
The installed JACK 2 header files don't even define JACK_METADATA_ICON_NAME. There's allegedly two functions that convert a UUID.
Imma just wait for some dust to settle on this one, I think.
-------- diovudau 05:33 Wed 05 Jan --------
Have a look at this function to see how to get the jack_uuid_t from your client name
https://github.com/kfoltman/calfbox/commit/dc0b3a6e8cf4dac8e56f1a3cdb4b48ba6c9e5f1b
-- Reply to this email directly or view it on GitHub: https://github.com/ahlstromcj/seq66/issues/75#issuecomment-1005688634 You are receiving this because you commented.
Message ID: @.***>
-- Someone whom you reject today, will reject you tomorrow.
What JACK2 version number I mean
Hmmm, the Comment button in the browser window doesn't work right now, so I am sending this via Mutt.
The version is JACK 1.9.12. Looking the github code, that is back from 2017! Why so old on Ubuntu?
I really don't want to have to install JACK 2 from source.
-------- Milkii Brewster 09:09 Wed 05 Jan --------
What JACK2 version number I mean
https://kx.studio/Repositories:Extras has an up-to-date JACK2 package
The last time I installed something from kxstudio on Debian, I had some really strange things going on with jack, undoubtedly due to differences in some shared libraries.
Right now the code is in Seq66, but the fact that it doesn't work causes no harm.
Will tilt at this dragon another day. Will likely build jack 2 from source.
Thanks!
-------- Milkii Brewster 09:22 Wed 05 Jan --------
https://kx.studio/Repositories:Extras has an up-to-date JACK2 package
-- You have Egyptian flu: you're going to be a mummy.
Righto, thanks. This is basically the reason I use a rolling release distribution these days.
So I decided to just add kxstudio extras since I'm running Ubuntu 20.4 on this laptop. With this updated (jack 1.9.19), basic audio still works fine with pulseaudio. Also, getting a client UUID yields a more reasonable UUID (8 or so digits), and jack_uuid_parse() translates the string UUID correctly to a jack_uuid_t value. But jack_set_property() still returns an error code (-1).
Also, when I run "jack_lsp -A" or "jack_property -l", I get:
/dev/shm/jack_db/__db.001: Permission denied
Cannot open DB environment: Permission denied
It turns out that the new jack2 creates a bunch of files. Most are owned by ahlstrom:ahlstrom, but for some reason some, like the jack_db directory, are owned by my display manager, lightdm! If I chown /dev/shm's contents to ahlstrom:ahlstrom, I don't get that message. Why does lightdm own these entries?
If I run "jack_lsp -A" or "jack_property -l", as root, I get (in part):
jack server is not running or cannot be started
JackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlock
JackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlock
Error: cannot connect to JACK, server is not running.
And yet qsynth and seq66 detect JACK and use it; playback works fine. Crazy stuff.
I've adjusted configure.ac so that one needs --enable-jack-metadata to use it. Too much churn.
Another minor issue is that, prior to the kxstudio update, jack_lsp -A would show the aliases (device brand name) of the USB devices. After the update, the aliases are no longer available, and seq66 requires a2jmidid --export-hw to be running.