New Win32 File API Implementation
?
?

Keyboard Navigation

Global Keys

[, < / ], > Jump to previous / next episode
W, K, P / S, J, N Jump to previous / next timestamp
t / T Toggle theatre / SUPERtheatre mode
V Revert filter to original state Y Select link (requires manual Ctrl-c)

Menu toggling

q Quotes r References f Filter y Link c Credits

In-Menu and Index Controls

a
w
s
d
h j k l


Esc Close menu / unfocus timestamp

Quotes and References Menus and Index

Enter Jump to timestamp

Quotes, References and Credits Menus

o Open URL (in new tab)

Filter Menu

x, Space Toggle category and focus next
X, ShiftSpace Toggle category and focus previous
v Invert topics / media as per focus

Filter and Link Menus

z Toggle filter / linking mode

Credits Menu

Enter Open URL (in new tab)
0:27Recap
0:27Recap
0:27Recap
1:10Plan for today
1:10Plan for today
1:10Plan for today
2:23Asset metadata is already loaded, so LoadBitmap and LoadSound reduce to just fetching the data
2:23Asset metadata is already loaded, so LoadBitmap and LoadSound reduce to just fetching the data
2:23Asset metadata is already loaded, so LoadBitmap and LoadSound reduce to just fetching the data
3:58Getting rid of LoadSound
3:58Getting rid of LoadSound
3:58Getting rid of LoadSound
6:22(intermission) Forcing order of reads between checking if an asset is loaded and accessing it
6:22(intermission) Forcing order of reads between checking if an asset is loaded and accessing it
6:22(intermission) Forcing order of reads between checking if an asset is loaded and accessing it
7:57(intermission) Implementing CompletePreviousReadsBeforeFutureReads
7:57(intermission) Implementing CompletePreviousReadsBeforeFutureReads
7:57(intermission) Implementing CompletePreviousReadsBeforeFutureReads
9:55Back to removing LoadSound
9:55Back to removing LoadSound
9:55Back to removing LoadSound
13:34Copying the contents of assets into the right place in memory
13:34Copying the contents of assets into the right place in memory
13:34Copying the contents of assets into the right place in memory
14:21General-purpose memory copy function
14:21General-purpose memory copy function
14:21General-purpose memory copy function
16:21Setting the channel sample pointers
16:21Setting the channel sample pointers
16:21Setting the channel sample pointers
17:57Testing the changes. There's some strange clicking bug going on, probably not related to today's changes. We'll do the debugging later
17:57Testing the changes. There's some strange clicking bug going on, probably not related to today's changes. We'll do the debugging later
17:57Testing the changes. There's some strange clicking bug going on, probably not related to today's changes. We'll do the debugging later
19:41Asset background loader with tag matching in 430 lines of code!
19:41Asset background loader with tag matching in 430 lines of code!
19:41Asset background loader with tag matching in 430 lines of code!
22:58Avoiding loading the entire asset file into memory
22:58Avoiding loading the entire asset file into memory
22:58Avoiding loading the entire asset file into memory
23:24Assets need to be rebased and pointed to the appropriate file through a file index
23:24Assets need to be rebased and pointed to the appropriate file through a file index
23:24Assets need to be rebased and pointed to the appropriate file through a file index
25:16Finding a good place in the code for the asset struct
25:16Finding a good place in the code for the asset struct
25:16Finding a good place in the code for the asset struct
27:34Filling in the asset struct
27:34Filling in the asset struct
27:34Filling in the asset struct
33:36The asset struct is just an hha_asset augmented with a file index
33:36The asset struct is just an hha_asset augmented with a file index
33:36The asset struct is just an hha_asset augmented with a file index
35:09Don't design architecture up-front
35:09Don't design architecture up-front
35:09Don't design architecture up-front
36:50Implementing GetFileHandleFor
36:50Implementing GetFileHandleFor
36:50Implementing GetFileHandleFor
39:08File I/O code is simple. Assuming we don't get it wrong, we'll save time by writing it now and testing it together with the code we just wrote. The alternative would involve writing some extra test code
39:08File I/O code is simple. Assuming we don't get it wrong, we'll save time by writing it now and testing it together with the code we just wrote. The alternative would involve writing some extra test code
39:08File I/O code is simple. Assuming we don't get it wrong, we'll save time by writing it now and testing it together with the code we just wrote. The alternative would involve writing some extra test code
41:36Implementing the platform functions
41:36Implementing the platform functions
41:36Implementing the platform functions
43:23We don't close files, so there's no need for a Win32CloseFile function
43:23We don't close files, so there's no need for a Win32CloseFile function
43:23We don't close files, so there's no need for a Win32CloseFile function
44:05Win32OpenFile
44:05Win32OpenFile
44:05Win32OpenFile
49:13Win32ReadDataFromFile
49:13Win32ReadDataFromFile
49:13Win32ReadDataFromFile
50:21Overlapped I/O
50:21Overlapped I/O
50:21Overlapped I/O
53:45Windows can't do reads bigger than 4GB. We don't plan on reading assets of that size, but let's assert against that situation, just in case
53:45Windows can't do reads bigger than 4GB. We don't plan on reading assets of that size, but let's assert against that situation, just in case
53:45Windows can't do reads bigger than 4GB. We don't plan on reading assets of that size, but let's assert against that situation, just in case
55:23Win32FileError
55:23Win32FileError
55:23Win32FileError
56:47Ignoring file operations on bad handles
56:47Ignoring file operations on bad handles
56:47Ignoring file operations on bad handles
58:08Testing today's code
58:08Testing today's code
58:08Testing today's code
59:09Quick step-through
59:09Quick step-through
59:09Quick step-through
1:00:00We hadn't read the header yet!
1:00:00We hadn't read the header yet!
1:00:00We hadn't read the header yet!
1:02:14Visual Studio fails to show size information on symbols outside the current running executable
1:02:14Visual Studio fails to show size information on symbols outside the current running executable
1:02:14Visual Studio fails to show size information on symbols outside the current running executable
1:05:00The null asset triggers an assertion. We ignore it for the moment
1:05:00The null asset triggers an assertion. We ignore it for the moment
1:05:00The null asset triggers an assertion. We ignore it for the moment
1:05:46It (mostly) works!
1:05:46It (mostly) works!
1:05:46It (mostly) works!
1:06:25Q&A
🗩
1:06:25Q&A
🗩
1:06:25Q&A
🗩
1:07:25bigmonachus What do you use when you need something more dynamic than arenas? Default to VirtualAlloc/malloc? Something completely different?
🗪
1:07:25bigmonachus What do you use when you need something more dynamic than arenas? Default to VirtualAlloc/malloc? Something completely different?
🗪
1:07:25bigmonachus What do you use when you need something more dynamic than arenas? Default to VirtualAlloc/malloc? Something completely different?
🗪
1:09:33insofaras How "handmade" are you going to go on the Linux version?
🗪
1:09:33insofaras How "handmade" are you going to go on the Linux version?
🗪
1:09:33insofaras How "handmade" are you going to go on the Linux version?
🗪
1:10:50quatzequatel Kind of off-topic do you usually have that much luck not getting bugs?
🗪
1:10:50quatzequatel Kind of off-topic do you usually have that much luck not getting bugs?
🗪
1:10:50quatzequatel Kind of off-topic do you usually have that much luck not getting bugs?
🗪
1:13:02plain_flavored Do you usually design an API by just implementing it, or do you try to define the interface first?
🗪
1:13:02plain_flavored Do you usually design an API by just implementing it, or do you try to define the interface first?
🗪
1:13:02plain_flavored Do you usually design an API by just implementing it, or do you try to define the interface first?
🗪
1:15:49kknewkles What is "usage code"? Basically everything down the line that awaits to be fed data?
🗪
1:15:49kknewkles What is "usage code"? Basically everything down the line that awaits to be fed data?
🗪
1:15:49kknewkles What is "usage code"? Basically everything down the line that awaits to be fed data?
🗪
1:27:22general_tach Do you feel that a lot of the common programs today have "bloated" code (much unnecessary code or something along those lines), and/or that coders need to learn to simplify/barebone their code?
🗪
1:27:22general_tach Do you feel that a lot of the common programs today have "bloated" code (much unnecessary code or something along those lines), and/or that coders need to learn to simplify/barebone their code?
🗪
1:27:22general_tach Do you feel that a lot of the common programs today have "bloated" code (much unnecessary code or something along those lines), and/or that coders need to learn to simplify/barebone their code?
🗪
1:27:42gasto5 Doesn't anticipating the usage of the API require decades of work?
🗪
1:27:42gasto5 Doesn't anticipating the usage of the API require decades of work?
🗪
1:27:42gasto5 Doesn't anticipating the usage of the API require decades of work?
🗪
1:33:14kknewkles So basically when you're about to make shoes for a monster, you don't assume how many legs or toes it has, let it stomp around and then use the footprints to make the shoes
🗪
1:33:14kknewkles So basically when you're about to make shoes for a monster, you don't assume how many legs or toes it has, let it stomp around and then use the footprints to make the shoes
🗪
1:33:14kknewkles So basically when you're about to make shoes for a monster, you don't assume how many legs or toes it has, let it stomp around and then use the footprints to make the shoes
🗪
1:33:44jameswidman Suggestion: call this "Snuffy-oriented programming"
🗪
1:33:44jameswidman Suggestion: call this "Snuffy-oriented programming"
🗪
1:33:44jameswidman Suggestion: call this "Snuffy-oriented programming"
🗪