A port of the sfxr sound effect synthesizer to Lua, mainly for usage with the Löve framework - Keywords: library sound love2d https://github.com/nucular/sfxrlua

nucular 822323c8bf Merge pull request #16 from pgimeno/fix-save-as-lua-button 9 년 전
loveframes @ a02fafd902 2ca33bd6d5 Added LoveFrames as a submodule so I can start to build a fancy GUI as a demo 10 년 전
spec 24ad42b0ad Start adding unit testing with busted and Travis-CI 10 년 전
.gitmodules 2ca33bd6d5 Added LoveFrames as a submodule so I can start to build a fancy GUI as a demo 10 년 전
.travis.yml 24ad42b0ad Start adding unit testing with busted and Travis-CI 10 년 전
LICENSE bcb4606b3c Initial commit 10 년 전
README.md 7c7060875a Added Travis-CI badge 10 년 전
conf.lua 593bf96742 Made demo window height larger and added Save/Load/Export buttons 10 년 전
main.lua 43f931ebae Fix save as Lua button 9 년 전
sfxr.lua bc4ebf3728 Reset parameters to default before loading from a file 10 년 전

README.md

sfxr.lua

Build Status

A port of the sfxr sound effect synthesizer to pure Lua, designed to be used together with the awesome Löve game framework.

Example usage

These examples should play a randomly generated sound.

With Löve 0.9.x:

local sfxr = require("sfxr")

function love.load()
    local sound = sfxr.newSound()
    sound:randomize()
    sound:play()
end

With lao:

require("ao")
local sfxr = require("sfxr")

local driverId = ao.defaultDriverId()
local device = ao.openLive(driverId, {bits = 16, rate = 44100, channels = 1})

local sound = sfxr.newSound()
sound:randomize()

local buffer = sound:generateString()
device:play(buffer, #buffer)

More documentation is available at the Project Wiki