fix hot-reload, starting to setup proper rendering again.

* Added hot_reload, measure_text_size to VEFontCache
This commit is contained in:
2024-06-19 02:34:02 -04:00
parent 4b8c4d0c2c
commit 59ed4d9dd6
12 changed files with 549 additions and 58 deletions

View File

@ -2,17 +2,17 @@ package grime
import "base:runtime"
reload_array :: proc( self : [dynamic]$Type, allocator : Allocator ) {
reload_array :: proc( self : ^[dynamic]$Type, allocator : Allocator ) {
raw := transmute(runtime.Raw_Dynamic_Array) self
raw.allocator = allocator
}
reload_queue :: proc( self : Queue($Type), allocator : Allocator ) {
reload_queue :: proc( self : ^Queue($Type), allocator : Allocator ) {
raw_array := transmute(runtime.Raw_Dynamic_Array) self.data
raw_array.allocator = allocator
}
reload_map :: proc( self : map [$KeyType] $EntryType, allocator : Allocator ) {
reload_map :: proc( self : ^map [$KeyType] $EntryType, allocator : Allocator ) {
raw := transmute(runtime.Raw_Map) self
raw.allocator = allocator
}