Trying to grok rendering

It's humbling when programming with a lower-level language like Zig. This morning I spent an hour trying to figure out how to allocate a two-dimensional array. After a while I just gave up and decided to implement a two-dimensional array from a single dimension. After all, it's just contiguous memory. Which I realized as I was writing this that I could approach it another way: parse the single dimensional array as is and calculate each pixel based on its expected position on the screen. As of now I'm getting consistent and weird gaps when I render my buffer. It's helped me realize how little I really understood programming. The higher-level languages that I was using were doing so much of the heavy lifting. I appreciate them, but I'm also really enjoying these pressure-less mornings where I can just build things from scratch. Including but not limited to two dimensional behaviors on a single dimensional array.

It's not always fun. It only took me a month to get audio to working without crackling and sputtering. It still does on startup, mostly as there is some overlap between the frame and audio rendering. Something along those lines. The debugging situation on Linux is quite bad, I must say. I'm thinking I would like to build a Linux debugger for Zig. I've been looking into the basics of a debugger. Ever since I've started Handmade Hero, I've been building some confidence that I too can build something like a debugger for myself. I have an idea of what I would like the debugger to do. I think I might pivot after a while to building a debugger. As of now, I'm going to continue working on Handmade Hero. I'd like to continue for a while longer. There is a lot more I'd like to understand and gain some clarity on.