December Adventure! Link to heading
2025 Link to heading
This is a cool tradition/idea that you can read more about here.
| MON | TUE | WED | THU | FRI | SAT | SUN |
|---|---|---|---|---|---|---|
| 1 | 2 | 3 | 4 | 5 | 6 | 7 |
| 8 | 9 | 10 | 11 | 12 | 13 | 14 |
| 15 | 16 | 17 | 18 | 19 | 20 | 21 |
| 22 | 23 | 24 | 25 | 26 | 27 | 28 |
| 29 | 30 | 31 |
Goals? Ideas? Link to heading
- Integrate miniaudio and steamaudio
- Paritcipate in 7DFPS
- Explore more SCons things maybe?
- Do Jai stuff?
1 Link to heading
Off to a great start! Absolutely nothing done today because everyone is sick. 😅
2 Link to heading
I briefly attempted to update ziege to zig 0.15x before my ability to cope with the meaninglessness of the exercise overcame me.
3 Link to heading
Nothing today Work was long.
4 Link to heading
Nothing today
Went to a show after work with a friend. Most of the bands were ok, but I saw Creeper for the first time and they were super excellent.
5 Link to heading
Ok! Today I decided I’d make December my EMACSEMBER. :D I really enjoy Sublime Text, it treats me right, it’s fast, it’s simple. But as a former really dedicated Emacs user, it used to be my everything environment.
So what changed? 🤷 But I just stopped using it. And why go back? Because Emacs is doing great, and still open source, and still as capable as it’s ever been. Native compilation for elisp is pretty cool! Treesitter is ok. And when I watch folks like Tsoding using Emacs the way I used to, I remember a simpler time. :D
Also my buddy has been patiently encouraging me to remember the good times.
6 Link to heading
Chose the sketch-white Emacs theme… and began looking at how to connect my content processors to the scons build.
Ok… I spent a lot of time emacs landscaping and noodling.
7 Link to heading
Ok! So once again, no code today. The day was spent yakscaping my Emacs config and trying to get comfy again and feel like I can work quickly and fluently. I don’t know if I can. But whatever.
The other thing I did was “unbrick” an old android tablet. I ended up getting it unlocked and reset, and then I promptly installed LineageOS on it. No google! Feels nice.
My only real complaint though is that there isn’t a really good reader app. They all have little yucky issues and work better for one kind of document than others.
Anyway, I definitely keep ending up on these side-quests. My December adventures are maybe not entirely in the spirit. Oh well.
I did sorta work a bit on exploring SCons and getting the content processors hooked up. I’ll start with the *.gpl palette collector. For the content processors, the gist is that some N files scanned in the source tree will generate an *.h and *.c file containing information or (as in this case) values from the files themselves.
*.gpl files are “GIMP Palette” files. They are an ascii format and easily parsed.
An example:
GIMP Palette
#Palette Name: CMYK Printer
#Description: A pallete based on the CMYK (cyan, magenta, yellow, key) color set used by printers.
#Colors: 5
0 221 255 00ddff
229 0 255 e500ff
255 242 0 fff200
255 255 255 ffffff
0 0 0 000000
8 Link to heading
Happy Bodhi Day!
Unfortunately another day is over and I didn’t really do anything other than work 9 hours and then tried to relax.
9 Link to heading
Spent more time trying to understand how to hook up my code generators to the SCons dependency graph.
I started with the palettes and while the gist of it was pretty straight-forward I’ve quickly discovered that things weren’t working quite the way I thought they were, and then by “fixing” things, I realized that some fundamental misunderstandings were tripping me up.
So I’m looking at the variant dir stuff and trying to understand things correctly.
10 Link to heading
Not much happened today other than work and family stuff. Noodling a bit more with the build.
11 Link to heading
I guess the honeymoon with SCons is over… meson just seems to fit my thought patterns more easily.
12 Link to heading
After some early success with meson I’ve taken the plunge and so far enjoy:
- A test suite concept so I don’t have to write my own
- Built-in unity build… so I don’t have to write my own
- Weird, but serviceable options system that I can live with
- It’s python-esque.. it’s pretty easy to understand
- Automatic scan-build setup!
- Automatic ctags generation
- Automatic compilation database generation
- Was easy to hook up a code generator
- Automatic rpath inclusion for the build tree
Some things I might not like but can live with so far:
- It’s opinions don’t always match mine
- I want to generate code anywhere I want…
- The subproject system is bulky feeling so I opted out of setting that up
- Subprojects can only be defined in a single location
- but at least it’s configurable
- Rpath stripping on install… not sure how to copy libraries to install prefix yet
- … I’m sure there are more to come
My palettes are generated properly now which is nice. I’ll get the audio and tilesets setup next.
13 Link to heading
Started integrating steamaudio and miniaudio today based on the miniaudio example.
14 Link to heading
Success! Noticed that I don’t have the mimalloc stuff wired up incorrectly somehow as it reports a lot of errors and I end up leaking a bit.
So the first takeaway is that … it’s not suuuuper convincing with only the binaural effect applied. Which means it’s time to start spending more time learning and experimenting… but I wish there was any kind of community to talk shop with. Everyone has withdrawn from the world somehow.
I asked a kagi assistant about some basics and while it’s nice to get some ideas… but who knows if any of that is accurate! Asking on mastodon was just crickets. Maybe on bsky I’ll find some folks.
15 Link to heading
VACATION BEGINS
Took the day off from my hobby stuff and went christmas shopping etc. :D It’s now the evening though and I find myself drawn to wobble back over to Jai and do some experiments there. In particular, I now have my C spatial audio test with both miniaudios basic spatialization, and the steamaudio binaural effect. I’d like to make a comparison to the Sound_Player module provided by the Jai release which implements spatial audio using VBAP.
I think that outside of head-tracked headphones (VR, AirPods), I’ll probably not find some magic definitive “THIS IS 3D SOUND I’M SO IMMERSED” experience. A possibly large portion of an interesting auditory environment is just the hard work and practice of solid sound-design fundamentals, and these algorithmic considerations are like the little punch to push things over the ledge a bit.
16 Link to heading
Ok, as usual I sat down to work towards one goal, but then once I was looking at the computer, my as yet to be finished whatever with the jai stuff was sticking out like a sore thumb. So I sloooowly got back into the swing of it and finished up the ascii wpak index reader.
17 Link to heading
With a reader in place I had the situation now that I have two separate binaries (one to “pack” and one that loads and lists content). This seemed a bit pointless, or at least was heading in the wrong direction.
So today I factored things into a single dedicated tool, but setup two modules for implementing the actual interesting bits.
The result of this ended up being that not only do I have a single cli tool for things, I can now leverage the wpak assembly implementation in the build itself, which means a single jai build.jai is enough to build programs and compile content.
This has been a goal from the beginning so it’s really nice to arrive at this point.
18 Link to heading
Got the wpak assembly step worked into the “build” itself. Groovy.
19 Link to heading
Got the audition wpak play cli command working, and now a wpak can be fully inspected even if it’s a bit arduous compared to a graphical tool to list and select stuff.
20 Link to heading
Took a break today. Shared my wpak implementation on the Jai discord server.
21 Link to heading
Started a simple (but impactful) redesign of the wpak format and expectations.
Rather than have the wpak assembly just take a bunch of files and then use a heuristic to name the outputs with a 1:1 wpak:wav split for each format; A wpak can instead serve as an index into multiple data files in which buffers get grouped by format.
Didn’t quite finish before days end; Lot’s of analysis paralysis on how to lay things out.
22 Link to heading
Done! This morning I finished the implementation. The Wav_Pak struct, and the Wav_Pak_Index struct are now separate items. But the effect is that an index is loaded first, and then the Wav_Pak can be initialized with a table of Sound_Data instances.
The next goal is to expand the metaprogram abilities for having the Wpak module be able to generate code with handles to audio data. Ideally you’d have resolved asset information in a game that’s using this then. (Absolutely inspired by the Luxe Engine content pipeline!)
23 Link to heading
No code written today, but I did come to realize that my approach of making many Sound_Data instances was missing the fact that a Sound_Stream already has a play cursor, and sample based start/end fields. Because this works even for compressed sound data it means that there is an opportunity to have wpak support compressed data as well.
24 Link to heading
Merry Christmas !!!
After my realization yesterday, this morning I sat down and made the changes to match my understanding. The result is rev3 of wpak that specifies buffers by sample ranges instead of byte ranges. I had to make some adjustments to the assembly implementation, but the loader was suprisingly easy to update.
Bytes in uncompressed data are: bytes_per_sample := (bits_per_sample / 8) * channels. And for the sample range it’s offset = record_start / bytes_per_sample and len = record_end / bytes_per_sample.
All nice and easy (yes I looked shit up to work that out because it’s early and whatever, I’m a human), but I’m curious what challenges await once I can add compressed data sources.
25 Link to heading
Merry Christmas !!!
No updates for today. Enjoyed hot pot in the city with the family. Watched movies and chilled out at home.
26 Link to heading
No updates for today either. Just read and prepared for some guests.
27 Link to heading
No updates today.
28 Link to heading
No updates today.
29 Link to heading
…. I wonder if I’m done with my adventure this year. Kind of feels like it.
30 Link to heading
No updates :D
31 Link to heading
So long 2025!
Summary Link to heading
Another fun December Adventure is over. It was interesting again to look back at what is basically a journal and see that I divided the month up into basically two projects with one small little idea in the middle.
These were:
- Meson build
- Wpak development
- bonus Get a steamaudio effect working with my miniaudio project.
Meson Link to heading
Once again I’m noticing that I spend a lot of time on things that aren’t really helping me accomplish stuff or bringing me joy. I think maaaaybe looking into ADHD medication is wise for 2026. Because my intense devotion to “"knowing all the ways you can build software reliably” is feeling like being spun out more than it’s feeling like useful working knowledge that benefits me. I just don’t think anybody really cares and it isn’t a marketable skill and I’m sad just writing that because omfg.
Wpak Link to heading
Exploring Jai by just building something (rather than learn every detail about the language) has been fun and I notice my motivation to stick with the language has increased.
From my wpak starting point I have found that being flexible to the shape that the tool takes helped me see what opportunities there were for moving away from byte ranges to sample ranges. I’m pretty motivated to keep pushing forward with this idea of small but complimentary asset tools working together to build a bedrock of answered questions on which I can continue building up from. One tiny step at a time.
Despite not writing any implementation yet, I also spent a great deal of time learning about the qoa format and will push forward with integrating that into the Jai Sound_Player module. I would like to be able to contribute that back to the community but it’s important to make peace with the reality that it is unlikely anyone would find this valuable or worth the time to adopt and support.
Steamaudio Link to heading
Steamaudio is interesting to work with. I’ve been really pushing and learning about spatial audio and this December it was really illuminating to realize that an HRTF alone does not an immersive soundscape make. This is likely the most valuable experience of the month despite not really spending much time actually working with it.
My biggest takeaway is that VBAP or basic stereo panning is so solidly good enough it’s no wonder that’s where most audio systems stop. The amount of craft and artistry that can be put together just using these approaches is wild. The amount of effort and resources needed to get to the next step up is a bit hard to justify I guess. At a minimum an HRTF with a headtracked orientation is a really cool and convincing step forward and barely more work. But you’re instantly limited to VR or macOS / iOS. That’s not the worst thing.
I’m dedicated to my goal though. For 2026 I’ll continue pushing forward. On one hand, I’d like to enable the airpods head tracking for Apple platforms with the Jai Sound_Player, and on an alternative path I’d like to integrate Steamaudio into the module to enable virtual surround sound.