/Handmade-Hero-MacOS-Platform-Layer-Non-Video

What if Casey Muratori started Handmade Hero on a Mac? That's what this is.

Primary LanguageObjective-C++

Handmade Hero OSX Platform Layer (Not Following Video Tutorials)

What is it?

This is the repository of my Mac platform layer for Casey Muratori's Handmade Hero where I forge ahead and follow his series.

It used to be a repository that followed my own video series, but I found that format somewhwat limiting and more importantly, time consuming. Getting the video series and the articles I was writing to sync up with Casey's series was simply too much work for a project of this scope, all while I was trying to get further ahead in the series and focus on learning first and foremost.

This repository no longer follows my YoutTube series on the topic. It is simply me working through Handmade Hero on the Mac with my own platform layer. Sometimes I will make changes that aren't necessarily related to what happened on a given day. This was the best approach for me as it was often more useful to just table an issue and push forward to the next day or put some idea on the back burner.

I still plan to do the video series, but it will be more freewheeling in style, just like actual Handmade Hero. When I have time, I'm just going to sit down at my computer, turn on OBS, and work through the thing. You'll see all of my mistakes as well as my successes.

Eventually, my video series will find its natural end and (I hope) seamlessly tie into the rest of the Handmade Hero series. This happens roughly around Day025 of Handmade Hero, when Casey first transitions away from the platform layer and into the cross-platform game itself.

After that point in time, I might throw in some additional content about talking to the GPU on the Mac. Any of you who finish the basic platform layer on the Mac will likely want to know how to use the platform layer to talk to Mac-specific graphics apis like Metal. You won't want to stick with the software renderer for too long.

A note on intellectual property

I will make sure none not to commit any of the game's original source code to this repository.

If a particular day has some part that references the cross-platform c++ code from the game, I'll simply make a note of it in that folder and tell you to go preorder Handmade Hero so you can use Casey's code.

I really want you to support Casey's work by going and preordering the game. He is doing a remarkable service to the community, offering a kind of education that is pretty much impossible to find anywhere else.

Again, my goal is to simply give you a leg up so you can follow the series on the Mac. This repository is simply meant to show you how I would do a Mac platform layer, sticking with the spirit of the series to the best of my abilities.

Acknowledgements

Many of the ideas employed in this series and code repository come from Jeff Buck's Handmade Hero OSX port. Not much of what I'm doing is all that original. I'm playing the messenger and distilling what he's done into a series that is easy to follow for beginners.

Jeff's code is great if you want to dive right into this project and figure it for yourself. I can't say when I'll have all of the tutorials finished, so if you want to see what this will probably look like when it's all done, it's a fantastic resource.

I also have to say thanks for David Gow for his Linux series. Without it, I wouldn't have figured out the Mac platform layer's audio setup. You will discover that the Mac environment is actually much closer to Linux than it is to Windows or anything else. So the series on Linux turns out to have quite a few valuable gems in it.

You will also want to take a look at Mike Oldham's Mac Platform layer. I found it really useful right around Day 20. As a matter of fact, much of the code I used in the early 20s comes directly from his platform layer. It has been a handy resource.

And of course, many thanks to Casey for opening my mind to a new way to build apps and games.

If you haven't already, check out Handmade Hero on YouTube.

Support this work

I have setup a Patreon for Mac-related content to help people interested in building the Mac platform layer for Handmade Hero. I also plan to cover slightly more advanced topics like rendering through Apple's graphics apis like Metal. Everything helps, and as a supporter, you can just ask me to cover some topic in a video and I'll make sure to address it.

Thanks again for all of your support! This has been a fun learning experience thus far.