{"id":13811575,"url":"https://github.com/agraef/pd-lua","last_synced_at":"2025-04-09T14:08:19.180Z","repository":{"id":65230350,"uuid":"109082422","full_name":"agraef/pd-lua","owner":"agraef","description":"Lua bindings for Pd, updated for Lua 5.3+","archived":false,"fork":false,"pushed_at":"2024-10-18T21:44:18.000Z","size":18892,"stargazers_count":58,"open_issues_count":14,"forks_count":14,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-04-02T12:08:07.193Z","etag":null,"topics":["computer-music","lua","multimedia","pure-data","purr-data"],"latest_commit_sha":null,"homepage":"https://agraef.github.io/pd-lua/","language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/agraef.png","metadata":{"files":{"readme":"README","changelog":null,"contributing":null,"funding":null,"license":"COPYING","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-11-01T03:28:55.000Z","updated_at":"2025-03-28T07:32:26.000Z","dependencies_parsed_at":"2024-01-13T15:37:26.974Z","dependency_job_id":"b5636d3c-1e86-4e26-8cf1-fa97b1157e66","html_url":"https://github.com/agraef/pd-lua","commit_stats":{"total_commits":439,"total_committers":11,"mean_commits":39.90909090909091,"dds":0.4510250569476082,"last_synced_commit":"4301f744a9023ea77b6fe0ba35918ad18e19276f"},"previous_names":[],"tags_count":44,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/agraef%2Fpd-lua","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/agraef%2Fpd-lua/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/agraef%2Fpd-lua/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/agraef%2Fpd-lua/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/agraef","download_url":"https://codeload.github.com/agraef/pd-lua/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248054206,"owners_count":21039952,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["computer-music","lua","multimedia","pure-data","purr-data"],"created_at":"2024-08-04T04:00:23.694Z","updated_at":"2025-04-09T14:08:19.146Z","avatar_url":"https://github.com/agraef.png","language":"HTML","readme":"pdlua -- a Lua embedding for Pd\nCopyright (C) 2007,2008,2009,2013 Claude Heiland-Allen \u003cclaude@mathr.co.uk\u003e\nCopyright (C) 2012 Martin Peach martin.peach@sympatico.ca\n\n\nThis program is free software; you can redistribute it and/or\nmodify it under the terms of the GNU General Public License\nas published by the Free Software Foundation; either version 2\nof the License, or (at your option) any later version.\n\nThis program is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\nGNU General Public License for more details.\n\nYou should have received a copy of the GNU General Public License\nalong with this program; if not, write to the Free Software\nFoundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.\n\n\nCurrent maintainer: Albert Gräf \u003caggraef@gmail.com\u003e\nThis source is available on GitHub: https://github.com/agraef/pd-lua\n\npdlua works with all Pd flavors out there and makes Pd external programming\nincredibly easy (please check the included examples and the tutorial in the\ncorresponding subdirectories). Originally written by Claude Heiland-Allen,\npdlua has gone through the hands of a few people over the years, including\nmrpeach (maintainer since 2011), zmoelnig a.k.a. umlaeute (loader update,\nDebian package), and myself (Arch package, Lua 5.3+ support, Purr Data and\nplugdata support, pdx.lua live-coding extension, tutorial). Please also check\nmy brief account on the history of pd-lua below.\n\nLua 5.4 is highly recommended with the latest version, Lua 5.3 works as\nwell. Reportedly, Lua 5.2 and even 5.1 still work (at least to some extent),\nbut I haven't tested these myself for quite a while, so you may run into\nproblems with these old versions - use at your own risk.\n\nIf you haven't used pdlua before, please make sure to check the included\ntutorial first. See:\n\nhttps://agraef.github.io/pd-lua/tutorial/pd-lua-intro.html\n\nThis contains a fairly gentle introduction to pdlua, walks you through the\ncreation of a basic example, and then goes on to cover most major features of\npdlua, including the special facilities for tables, clocks, receivers, signal\nprocessing, graphics, and live-coding, in quite some detail. This will be\nhelpful when embarking on your own projects, or trying to make sense of the\nincluded examples.\n\n\nHistory and Credits:\n\npdlua was originally written by Claude Heiland-Allen, with contributions by\nFrank Barknecht and Martin Peach, according to the original source.\nPlease check Claude's website at https://mathr.co.uk/, and\nhttps://mathr.co.uk/blog/lua.html for Lua-related content on his blog\n(including pdlua's original announcement).\n\nMartin Peach took over maintenance of pdlua in 2011, you can find that part of\nthe history in Pd's old svn repository at SourceForge, including IOhannes\nZmölnig's loader update for Pd 0.47. See\nhttps://sourceforge.net/p/pure-data/svn/HEAD/tree/trunk/externals/loaders/pdlua/\n\nThe present source is a fork of umlaeute's 0.7.3 version in the Debian package\nrepository at https://anonscm.debian.org/git/pkg-multimedia/pd-lua.git, which\nin turn was based on the 0.7.3 version of pdlua in Pd's svn repository.\n\nThe current version (0.8 and later) is actively maintained by Albert Gräf,\nwith contributions by many people: Claude Heiland-Allen (Lua 5.4 update,\nbugfixes), Alexandre Porres (documentation updates), sebshader (relative path\nloading), Timothy Schoen (plugdata compatibility, signal and graphics\nsupport), and Ben Wesch (multi-channel signal support, Deken tests and uploads\non GitHub). This is also the version included in Purr Data\n(https://github.com/agraef/purr-data) and Timothy Schoen's plugdata\n(https://github.com/plugdata-team/plugdata).\n\nPlease file bugs and requests at https://github.com/agraef/pd-lua. I maintain\na lot of packages and thus it may take a while at times, but I look at all the\nbug reports and pull requests, and try to respond to them eventually. :)\n\n\nReady-Made Packages:\n\nThe latest vanilla binaries for Ubuntu, Mac, and Windows can always be found\non https://github.com/agraef/pd-lua (but see below for the Deken package).\nAlso, both Purr Data and plugdata ship with pdlua, and have it enabled by\ndefault, so no 3rd party package is needed in those environments.\n\nFor vanilla Pd, we recommend installing the Deken package (named `pdlua`),\nreadily available using Pd's `Find externals` menu option. This package was\noriginally uploaded by Alexandre Porres, but Ben Wesch recently added Deken\ntests and uploads to our GitHub workflow, so that the Deken releases are now\nautomatized and always in sync with the GitHub releases. Thanks, Ben!\n\npd-lua is also in the Arch repositories (maintained by dvzrv, thanks David!),\nand in the Debian repositories (maintained by IOhannes Zmölnig, thanks\numlaeute!). (During busy times, these may trail our releases for a little bit,\nbut most of the time they will the latest version.)\n\nMac users please note that the packages I distribute aren't notarized, so on\nrecent macOS versions you'll have to jump through the usual hoops to make them\nusable. Running `xattr -rd com.apple.quarantine` on pdlua.pd_darwin should\nusually do the trick, but check the internet for up-to-date information on\nGatekeeper for details.\n\n\nEnabling pdlua:\n\nAgain, this step is only necessary with vanilla Pd; both Purr Data and\nplugdata have the pdlua loader enabled by default, so it should be ready to go\nimmediately.\n\nWith vanilla Pd, after installing pdlua, the pdlua loader also needs to be\nadded to your startup libraries, before Pd will recognize any Lua object in\nyour patches. This only needs to be done once. (Alternatively, you can also\nuse the `-lib pdlua` option on the Pd command line, or a `declare -lib pdlua`\nobject in a patch with Lua objects.) To make any of this work, you may also\nhave to add the parent directory of the `pdlua` folder to Pd's search path if\npdlua was installed in an unusual location.\n\n\nCompilation Instructions:\n\nYou can also compile pdlua yourself from source, which isn't hard to do.\n\nThe source should compile out of the box on (at least) Linux, macOS and\nWindows, just make sure that you have Lua and Pd installed and run\n`make`. pdlua uses pd-lib-builder by Katja Vetter as its build system, please\ncheck https://github.com/pure-data/pd-lib-builder and the included\nMakefile.pdlibbuilder for details.\n\npdlua works with any reasonably modern Pd flavour, but pd-lib-builder will\nlook for vanilla Pd (http://msp.ucsd.edu/software.html). So you'll need to\nhave that installed, or be prepared to adjust the Makefile accordingly.\n\nIf you compile from git sources and use the included lua submodule (see\nCompilation from Git Sources below), then only Pd will be needed. Otherwise\nyou'll also have to install Lua (https://www.lua.org).\n\nThe following build environments on various platforms are known to work and\nare supported.\n\nLinux: Uses gcc and GNU make. Pd and Lua should be available in your package\nrepositories. If not then it's easy to install them from source.\n\nMac: Uses Xcode. The build requires that you have the Pd header files\nsomewhere under /Applications/Pd-*/Contents/Resources/src (which should be the\ncase if you're running a recent Pd distribution by MSP); otherwise you can set\nthe `PDINCLUDEDIR` make variable accordingly. Lua is available, e.g., in\nHomebrew (https://brew.sh/).\n\nWindows: Uses msys2/mingw (https://www.msys2.org/), which is the Windows\nincarnation of gcc and GNU make. The build assumes that you have a recent Pd\ninstallation as distributed by MSP, so that the header files and pd.dll are\nfound during compilation and linkage, respectively. Lua is available in msys2.\n\n\nCompilation from Git Sources:\n\nThe repository source includes a lua submodule which can be used to compile\nLua alongside pdlua, so no Lua installation is needed to compile the\nexternal. (You'll still need to have Pd installed.) Just make sure to check\nout the submodule with the repository (`git clone --recurse-submodules`).\nIf you already checked out the repository, you can also do `git submodule\nupdate --init` instead. This should get you a fairly recent revision of the\nupstream Lua source.\n\nOnce the lua submodule is checked out, you can just run `make` as usual, it\nwill use the submodule to compile Lua alongside the pdlua module. The\nresulting binary will be statically linked with the Lua interpreter.\n\nAlso note that on the Mac you can build a universal (a.k.a. arm64+x86_64)\nbinary this way, using `arch=\"arm64 x86_64\"` when running `make`. This will\nwork best if Lua is compiled alongside pdlua, since installed Lua libraries\nmay not be universal binaries (in Homebrew at least they aren't).\n\nOtherwise, if the lua submodule isn't checked out, `make` will try\n`pkg-config` to locate an existing Lua installation on your system and link\nagainst that.\n\n\nInstallation:\n\nAfter a successful compile, you can go about installing the external with the\nusual `make install` which copies the external to its own directory named\npdlua. This should generally do something sensible on each of the supported\nplatforms. Note that the installation may require root privileges.\n\nLinux: By default, installation goes into /usr/local/lib/pd-externals, which\nshould be one of the directories on Pd's built-in search path.\n\nMac: Installation goes into ~/Library/Pd by default. Move the pdlua folder to\n/Library/Pd for a system-wide installation.\n\nWindows/mingw: Installation goes into the Pd subdirectory of your %APPDATA%\nfolder by default. Move the pdlua folder to the extra folder of Pd in your\nProgramFiles directory for a system-wide installation.\n\nIn any case, it's possible to override the default installation directory\nusing the PDLIBDIR variable. E.g., on Linux you can install into Pd's\n/usr/lib/pd/extra folder as follows:\n\n    make install PDLIBDIR=/usr/lib/pd/extra\n\nIt's generally advisable to do a staged install using `DESTDIR` first so that\nyou can review the installation directory layout beforehand and adjust it if\nneeded. To these ends, run `make install`, e.g., as follows:\n\n    make install DESTDIR=./build\n\nIt is possible to use DESTDIR along with PDLIBDIR.\n\nAnother possibility is to run `make install objectsdir=./build` which creates\nthe `pdlua` folder directly in the `build` directory from where you can move\nit to any location on Pd's library search path that you see fit. (This option\nis considered deprecated, but it's still the most convenient for a quick\nmanual installation.)\n","funding_links":[],"categories":["Pure Data external development \u0026 scripting"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fagraef%2Fpd-lua","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fagraef%2Fpd-lua","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fagraef%2Fpd-lua/lists"}