1
Fork 0
libpulse bindings for use with a GLib Mainloop via LGI. https://docs.sclu1034.dev/lua-libpulse-glib/index.html
Find a file
2022-08-14 16:49:53 +02:00
.ci wip 2022-08-14 16:49:53 +02:00
.github/workflows chore: Initialize repository 2022-04-06 21:29:11 +02:00
.vscode chore: Initialize repository 2022-04-06 21:29:11 +02:00
doc doc: Fix missing function parameter in example 2022-05-20 19:50:24 +02:00
rocks build: Remove unused dependencies 2022-05-15 23:17:36 +02:00
spec bug: Fix installing 2022-08-10 13:07:34 +02:00
src/lua_libpulse_glib wip 2022-08-14 16:49:53 +02:00
tools feat: Implement introspection for sinks and sources 2022-05-15 22:56:55 +02:00
.busted.lua wip 2022-08-14 16:49:53 +02:00
.clang-format chore: Configure tooling 2022-04-21 14:04:18 +02:00
.fdignore chore: Ignore SASS cache 2022-08-10 13:55:48 +02:00
.gitignore chore: Ignore LuaRocks working files 2022-05-15 23:11:00 +02:00
.luacheckrc chore: Initialize repository 2022-04-06 21:29:11 +02:00
bors.toml chore: Initialize repository 2022-04-06 21:29:11 +02:00
COPYING chore: Initialize repository 2022-04-06 21:29:11 +02:00
Makefile wip 2022-08-14 16:49:53 +02:00
README.adoc wip: CI 2022-08-14 12:57:29 +02:00

lua-libpulse-glib

License Build Status (Concourse CI) LuaRocks Package

libpulse bindings for use with a GLib MainLoop via LGI.

The project is still in a development state. It hasnt been fully tested yet, and not all functions from libpulse have a corresponding binding yet. Please do report anything thats missing or not working correctly.

Quick Start

Install lgi and lua_libpulse_glib from LuaRocks:

luarocks install lgi
luarocks install --dev lua-libpulse-glib
local lgi = require("lgi")
local pulseaudio = require("lua_libpulse_glib")
local ppretty = require("pl.pretty")

local pa = pulseaudio.new()
local ctx = pa:context("My Test App")

local loop = lgi.GLib.MainLoop.new()

ctx:connect(nil, function(state)
    if state == 4 then
        print("Connection is ready")

        ctx:get_sinks(function(sinks)
            ppretty.dump(sinks)
            loop:quit()
        end)
    end
end)

loop:run()