Submissions by nonchip tagged jack

today I implemented a JACK client moonscript class for my audio player, that allows for really easy usage of the jack api.

see the usage example there: jack_class_test.moon

this will make interfacing with the audio system really easy, so I can focus on doing playlist management and codecs next.

made another example to test playing audio from actual raw audio files.

input format:

  • headerless
  • mono audio
  • IEEE 32bit single precision float
  • must already have the samplerate jackd will be using when playing

see jack_example_rawPCM.moon

was actually pretty easy after I found out where my pointer calculations were messed up and that I was accidentally dealing with stereo input data all the time. also, I like how LuaJIT lets you just cast a whole binary file into a float pointer…


next I'll try to get some code to resample on the fly, then I'll start with the actual modular program, so any new features can be just dropped in as moonscript modules.

"Yet Another Better Audio PLAYER". trying to build a music player that does all the things I'm missing from the ones I've used so far (and the best of those they did).

Some key features it'll have:

  • Moonscript and LuaJIT based
  • makes annoying noise sound via JACK.
  • modular design (need some sound effect / audio codec / "intelligent" playlist provider that guesses the next track based on alcohol levels and annoyed shouts measured by an arduino? write a Moonscript class.)


What I've got so far:

  • libjack bindings for Moonscript
    • ported the "simple client example" to Moonscript
    • wrote a 440Hz sine wave example
  • github repo: nonchip/yabaplayer
  • this post