Soundarray - JakeTurner616/pygame-lua-bindings GitHub Wiki
Pygame Soundarray functions
sndarray_array(sound)
Convert a Pygame sound to a NumPy array and serialize it for Lua.
Parameters:
sound
: A Pygame sound object.
Returns: A serialized Lua table representing the sound's sample data as an array.
sndarray_samples(sound)
Convert a Pygame sound's samples to a NumPy array and serialize it for Lua.
Parameters:
sound
: A Pygame sound object.
Returns: A serialized Lua table representing the sound's samples as an array.
sndarray_make_sound(lua_array)
Create a Pygame sound object from a serialized Lua table.
Parameters:
lua_array
: A serialized Lua table representing the sound's sample data.
Returns: A Pygame sound object created from the Lua table's data.