Skip to content
Snippets Groups Projects
Verified Commit 12359c47 authored by Ole Binder's avatar Ole Binder
Browse files

Feat: add wp script to list ports

parent 6af1c059
No related branches found
No related tags found
1 merge request!8Feat jack support
Pipeline #7172 passed
-- Dump all Wireplumber ports
function dump(o)
if type(o) == 'table' then
local s = '{ '
for k,v in pairs(o) do
if type(k) ~= 'number' then k = '"'..k..'"' end
s = s .. '['..k..'] = ' .. dump(v) .. ',\n'
end
return s .. '} '
else
return tostring(o)
end
end
local port_om = ObjectManager {
Interest {
type = "port",
}
}
port_om:connect("object-added", function (om, port)
print(dump(port.properties) .. '\n\n')
end)
port_om:activate()
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment