Skip to content

Instantly share code, notes, and snippets.

@Sharlock93
Sharlock93 / ttf_rasterization.md
Last active June 6, 2024 14:36
Reading TTF files and rasterizing them using a handmade approach, Part 2: Rasterization

Reading TTF files and rasterizing them using a handmade approach, Part 2: Rasterization

I streamed this entire post writing on twitch.tv/Sharlock93 please do drop by if you want to see someone stumble their way into writing code and learning stuff. If you have any questions don't hesitate to ask here or on twitter @Sharlock93 more than happy to answer everyone.

If you find any mistakes in this post or have any feedback please don't hesitate to let me know.

Introduction

This is the 2nd part to my previous article about Font reading and Rasterization, this part is about rasterizing the outlines. The overall general topics covered in this part is:

@Sharlock93
Sharlock93 / image_layout.md
Created October 15, 2023 09:12
Image Layouts

Huge thanks to Fabian Giesen (Mastadon: @rygorous@mastodon.gamedev.place ) for taking the time to answer my question.

Q: I have been doing a lot of vulkan lately and I was wondering if you knew where "Image Layouts" came from? do they mean anything to the GPU or is this just something the driver takes as a hint?

A: They do mean something. It's mostly (but not exclusively) about additional metadata associated with attachments. If you have access to AMD HW console GPU docs, read up on Cmask, Fmask, Hmask, DCC. That kind of stuff. :) Often related to memory access/bandwidth optimizations that use secondary metadata elsewhere. Color compression, hierarchical Z/stencil, depth compression, multisampling optimizations, fast clears, the works.

@Sharlock93
Sharlock93 / visual_studio_integration.vim
Last active April 3, 2024 06:59
Vim & Visual Studio Integration
vim9script
def SetupDTEContext()
py3 << EOF
import vim
visual_studio_dtes = [0] # 1 based
selected_visual_studio_dte = None
def SetDTE():
global selected_visual_studio_dte