diff --git a/src/entry_linux.c b/src/entry_linux.c index 6854861..0380b01 100644 --- a/src/entry_linux.c +++ b/src/entry_linux.c @@ -10,10 +10,10 @@ int main(int argc, char **argv) { - u8 *mem = (u8 *)MemAllocZeroed(MB(32)); - Arena *arena = CreateArenaDebug(mem, MB(32), __LINE__); + u8 *mem = (u8 *)MemAllocZeroed(MB(64)); + Arena *arena = CreateArenaDebug(mem, MB(64), __LINE__); - isize renderer_mem_size = MB(8); + isize renderer_mem_size = MB(16); isize game_mem_size = MB(16); rawptr renderer_mem = ArenaAlloc(arena, renderer_mem_size); @@ -29,12 +29,14 @@ int main(int argc, char **argv) WaitForWindowEvent(inputs); - InitializeGame(renderer_arena); + GameContext ctx = {}; + + InitializeGame(renderer_arena, &ctx, game_arena); while (!global_quit) { GetWindowEvents(inputs, &i_count); - RunCycle(game_arena, inputs, i_count); + RunCycle(&ctx, inputs, i_count); } DestroyGame(); diff --git a/src/entry_windows.c b/src/entry_windows.c index da69c31..11413dc 100644 --- a/src/entry_windows.c +++ b/src/entry_windows.c @@ -21,7 +21,7 @@ int CALLBACK WinMain(HINSTANCE instance, HINSTANCE prev_instance, LPSTR cmd_line u8 *mem = (u8 *)MemAllocZeroed(MB(32)); Arena *arena = CreateArenaDebug(mem, MB(32), 1); - isize renderer_mem_size = MB(8); + isize renderer_mem_size = MB(16); isize game_mem_size = MB(16); rawptr renderer_mem = ArenaAlloc(arena, renderer_mem_size); diff --git a/src/file_data/spv.c b/src/file_data/spv.c index 551d512..228bef4 100644 --- a/src/file_data/spv.c +++ b/src/file_data/spv.c @@ -154,17 +154,17 @@ unsigned char shader_gui_frag[] = { unsigned int shader_gui_frag_len = 1808; unsigned char shader_gui_vert[] = { 0x03, 0x02, 0x23, 0x07, 0x00, 0x06, 0x01, 0x00, 0x0b, 0x00, 0x0d, 0x00, - 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x02, 0x00, + 0x83, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x11, 0x00, 0x02, 0x00, 0xe3, 0x14, 0x00, 0x00, 0x0b, 0x00, 0x06, 0x00, 0x01, 0x00, 0x00, 0x00, 0x47, 0x4c, 0x53, 0x4c, 0x2e, 0x73, 0x74, 0x64, 0x2e, 0x34, 0x35, 0x30, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x03, 0x00, 0xe4, 0x14, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x12, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, - 0x6d, 0x61, 0x69, 0x6e, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, - 0x0e, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, 0x31, 0x00, 0x00, 0x00, - 0x3a, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x49, 0x00, 0x00, 0x00, - 0x5b, 0x00, 0x00, 0x00, 0x5e, 0x00, 0x00, 0x00, 0x61, 0x00, 0x00, 0x00, - 0x66, 0x00, 0x00, 0x00, 0x6a, 0x00, 0x00, 0x00, 0x6f, 0x00, 0x00, 0x00, + 0x6d, 0x61, 0x69, 0x6e, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x15, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, 0x4d, 0x00, 0x00, 0x00, + 0x4f, 0x00, 0x00, 0x00, 0x54, 0x00, 0x00, 0x00, 0x5c, 0x00, 0x00, 0x00, + 0x6e, 0x00, 0x00, 0x00, 0x71, 0x00, 0x00, 0x00, 0x74, 0x00, 0x00, 0x00, + 0x79, 0x00, 0x00, 0x00, 0x7d, 0x00, 0x00, 0x00, 0x82, 0x00, 0x00, 0x00, 0x03, 0x00, 0x03, 0x00, 0x02, 0x00, 0x00, 0x00, 0xcc, 0x01, 0x00, 0x00, 0x04, 0x00, 0x07, 0x00, 0x47, 0x4c, 0x5f, 0x45, 0x58, 0x54, 0x5f, 0x62, 0x75, 0x66, 0x66, 0x65, 0x72, 0x5f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, @@ -175,289 +175,314 @@ unsigned char shader_gui_vert[] = { 0x47, 0x4c, 0x5f, 0x47, 0x4f, 0x4f, 0x47, 0x4c, 0x45, 0x5f, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x65, 0x5f, 0x64, 0x69, 0x72, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x00, 0x05, 0x00, 0x04, 0x00, 0x04, 0x00, 0x00, 0x00, - 0x6d, 0x61, 0x69, 0x6e, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x03, 0x00, - 0x09, 0x00, 0x00, 0x00, 0x70, 0x30, 0x00, 0x00, 0x05, 0x00, 0x06, 0x00, - 0x0b, 0x00, 0x00, 0x00, 0x69, 0x6e, 0x5f, 0x67, 0x75, 0x69, 0x5f, 0x70, - 0x6f, 0x73, 0x5f, 0x30, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x03, 0x00, - 0x0d, 0x00, 0x00, 0x00, 0x70, 0x31, 0x00, 0x00, 0x05, 0x00, 0x06, 0x00, - 0x0e, 0x00, 0x00, 0x00, 0x69, 0x6e, 0x5f, 0x67, 0x75, 0x69, 0x5f, 0x70, - 0x6f, 0x73, 0x5f, 0x31, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x03, 0x00, - 0x12, 0x00, 0x00, 0x00, 0x63, 0x6f, 0x6c, 0x00, 0x05, 0x00, 0x04, 0x00, - 0x14, 0x00, 0x00, 0x00, 0x69, 0x6e, 0x5f, 0x63, 0x6f, 0x6c, 0x00, 0x00, - 0x05, 0x00, 0x05, 0x00, 0x1a, 0x00, 0x00, 0x00, 0x76, 0x65, 0x72, 0x74, - 0x69, 0x63, 0x65, 0x73, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x06, 0x00, - 0x22, 0x00, 0x00, 0x00, 0x64, 0x73, 0x74, 0x5f, 0x68, 0x61, 0x6c, 0x66, - 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x00, 0x00, 0x00, 0x05, 0x00, 0x05, 0x00, - 0x28, 0x00, 0x00, 0x00, 0x64, 0x73, 0x74, 0x5f, 0x63, 0x65, 0x6e, 0x74, - 0x65, 0x72, 0x00, 0x00, 0x05, 0x00, 0x04, 0x00, 0x2e, 0x00, 0x00, 0x00, - 0x64, 0x73, 0x74, 0x5f, 0x70, 0x6f, 0x73, 0x00, 0x05, 0x00, 0x06, 0x00, - 0x31, 0x00, 0x00, 0x00, 0x67, 0x6c, 0x5f, 0x56, 0x65, 0x72, 0x74, 0x65, - 0x78, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x00, 0x00, 0x05, 0x00, 0x05, 0x00, - 0x3a, 0x00, 0x00, 0x00, 0x6f, 0x75, 0x74, 0x5f, 0x63, 0x6f, 0x6c, 0x6f, - 0x72, 0x00, 0x00, 0x00, 0x05, 0x00, 0x06, 0x00, 0x3e, 0x00, 0x00, 0x00, - 0x67, 0x6c, 0x5f, 0x50, 0x65, 0x72, 0x56, 0x65, 0x72, 0x74, 0x65, 0x78, - 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0x3e, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x67, 0x6c, 0x5f, 0x50, 0x6f, 0x73, 0x69, 0x74, - 0x69, 0x6f, 0x6e, 0x00, 0x06, 0x00, 0x07, 0x00, 0x3e, 0x00, 0x00, 0x00, - 0x01, 0x00, 0x00, 0x00, 0x67, 0x6c, 0x5f, 0x50, 0x6f, 0x69, 0x6e, 0x74, - 0x53, 0x69, 0x7a, 0x65, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x07, 0x00, - 0x3e, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x67, 0x6c, 0x5f, 0x43, - 0x6c, 0x69, 0x70, 0x44, 0x69, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x00, - 0x06, 0x00, 0x07, 0x00, 0x3e, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, - 0x67, 0x6c, 0x5f, 0x43, 0x75, 0x6c, 0x6c, 0x44, 0x69, 0x73, 0x74, 0x61, - 0x6e, 0x63, 0x65, 0x00, 0x05, 0x00, 0x03, 0x00, 0x40, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x05, 0x00, 0x47, 0x00, 0x00, 0x00, - 0x43, 0x6f, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x74, 0x73, 0x00, 0x00, 0x00, - 0x06, 0x00, 0x04, 0x00, 0x47, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x72, 0x65, 0x73, 0x00, 0x05, 0x00, 0x03, 0x00, 0x49, 0x00, 0x00, 0x00, - 0x50, 0x43, 0x00, 0x00, 0x05, 0x00, 0x06, 0x00, 0x59, 0x00, 0x00, 0x00, - 0x47, 0x6c, 0x6f, 0x62, 0x61, 0x6c, 0x55, 0x6e, 0x69, 0x66, 0x6f, 0x72, - 0x6d, 0x00, 0x00, 0x00, 0x06, 0x00, 0x04, 0x00, 0x59, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x72, 0x65, 0x73, 0x00, 0x05, 0x00, 0x04, 0x00, - 0x5b, 0x00, 0x00, 0x00, 0x47, 0x6c, 0x6f, 0x62, 0x61, 0x6c, 0x73, 0x00, - 0x05, 0x00, 0x06, 0x00, 0x5c, 0x00, 0x00, 0x00, 0x53, 0x68, 0x61, 0x64, - 0x65, 0x72, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x00, 0x00, 0x00, - 0x06, 0x00, 0x06, 0x00, 0x5c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x70, 0x6c, 0x61, 0x63, 0x65, 0x68, 0x6f, 0x6c, 0x64, 0x65, 0x72, 0x00, - 0x05, 0x00, 0x04, 0x00, 0x5e, 0x00, 0x00, 0x00, 0x4f, 0x70, 0x74, 0x69, - 0x6f, 0x6e, 0x73, 0x00, 0x05, 0x00, 0x04, 0x00, 0x61, 0x00, 0x00, 0x00, - 0x69, 0x6d, 0x61, 0x67, 0x65, 0x00, 0x00, 0x00, 0x05, 0x00, 0x05, 0x00, - 0x66, 0x00, 0x00, 0x00, 0x54, 0x65, 0x78, 0x74, 0x75, 0x72, 0x65, 0x73, - 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x04, 0x00, 0x6a, 0x00, 0x00, 0x00, - 0x49, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x00, 0x00, 0x05, 0x00, 0x06, 0x00, - 0x6c, 0x00, 0x00, 0x00, 0x50, 0x42, 0x52, 0x4d, 0x61, 0x74, 0x65, 0x72, - 0x69, 0x61, 0x6c, 0x73, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x05, 0x00, - 0x6c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x61, 0x6c, 0x62, 0x65, - 0x64, 0x6f, 0x00, 0x00, 0x06, 0x00, 0x05, 0x00, 0x6c, 0x00, 0x00, 0x00, - 0x01, 0x00, 0x00, 0x00, 0x6e, 0x6f, 0x72, 0x6d, 0x61, 0x6c, 0x00, 0x00, - 0x06, 0x00, 0x06, 0x00, 0x6c, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, - 0x6d, 0x65, 0x74, 0x61, 0x6c, 0x6c, 0x69, 0x63, 0x00, 0x00, 0x00, 0x00, - 0x06, 0x00, 0x06, 0x00, 0x6c, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, - 0x72, 0x6f, 0x75, 0x67, 0x68, 0x6e, 0x65, 0x73, 0x73, 0x00, 0x00, 0x00, - 0x06, 0x00, 0x04, 0x00, 0x6c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, - 0x61, 0x6f, 0x00, 0x00, 0x05, 0x00, 0x05, 0x00, 0x6f, 0x00, 0x00, 0x00, - 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x73, 0x00, 0x00, 0x00, - 0x47, 0x00, 0x04, 0x00, 0x0b, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x6d, 0x61, 0x69, 0x6e, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x04, 0x00, + 0x09, 0x00, 0x00, 0x00, 0x64, 0x73, 0x74, 0x5f, 0x70, 0x6f, 0x73, 0x00, + 0x05, 0x00, 0x06, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x67, 0x6c, 0x5f, 0x56, + 0x65, 0x72, 0x74, 0x65, 0x78, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x00, 0x00, + 0x05, 0x00, 0x06, 0x00, 0x15, 0x00, 0x00, 0x00, 0x69, 0x6e, 0x5f, 0x67, + 0x75, 0x69, 0x5f, 0x70, 0x6f, 0x73, 0x5f, 0x30, 0x00, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x06, 0x00, 0x1b, 0x00, 0x00, 0x00, 0x69, 0x6e, 0x5f, 0x67, + 0x75, 0x69, 0x5f, 0x70, 0x6f, 0x73, 0x5f, 0x31, 0x00, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x05, 0x00, 0x4d, 0x00, 0x00, 0x00, 0x6f, 0x75, 0x74, 0x5f, + 0x63, 0x6f, 0x6c, 0x6f, 0x72, 0x00, 0x00, 0x00, 0x05, 0x00, 0x04, 0x00, + 0x4f, 0x00, 0x00, 0x00, 0x69, 0x6e, 0x5f, 0x63, 0x6f, 0x6c, 0x00, 0x00, + 0x05, 0x00, 0x06, 0x00, 0x52, 0x00, 0x00, 0x00, 0x67, 0x6c, 0x5f, 0x50, + 0x65, 0x72, 0x56, 0x65, 0x72, 0x74, 0x65, 0x78, 0x00, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x06, 0x00, 0x52, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x67, 0x6c, 0x5f, 0x50, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x00, + 0x06, 0x00, 0x07, 0x00, 0x52, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x67, 0x6c, 0x5f, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x53, 0x69, 0x7a, 0x65, + 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x07, 0x00, 0x52, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x67, 0x6c, 0x5f, 0x43, 0x6c, 0x69, 0x70, 0x44, + 0x69, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x00, 0x06, 0x00, 0x07, 0x00, + 0x52, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x67, 0x6c, 0x5f, 0x43, + 0x75, 0x6c, 0x6c, 0x44, 0x69, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x00, + 0x05, 0x00, 0x03, 0x00, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x05, 0x00, 0x5a, 0x00, 0x00, 0x00, 0x43, 0x6f, 0x6e, 0x73, + 0x74, 0x61, 0x6e, 0x74, 0x73, 0x00, 0x00, 0x00, 0x06, 0x00, 0x04, 0x00, + 0x5a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x72, 0x65, 0x73, 0x00, + 0x05, 0x00, 0x03, 0x00, 0x5c, 0x00, 0x00, 0x00, 0x50, 0x43, 0x00, 0x00, + 0x05, 0x00, 0x06, 0x00, 0x6c, 0x00, 0x00, 0x00, 0x47, 0x6c, 0x6f, 0x62, + 0x61, 0x6c, 0x55, 0x6e, 0x69, 0x66, 0x6f, 0x72, 0x6d, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x04, 0x00, 0x6c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x72, 0x65, 0x73, 0x00, 0x05, 0x00, 0x04, 0x00, 0x6e, 0x00, 0x00, 0x00, + 0x47, 0x6c, 0x6f, 0x62, 0x61, 0x6c, 0x73, 0x00, 0x05, 0x00, 0x06, 0x00, + 0x6f, 0x00, 0x00, 0x00, 0x53, 0x68, 0x61, 0x64, 0x65, 0x72, 0x4f, 0x70, + 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x00, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, + 0x6f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x6c, 0x61, 0x63, + 0x65, 0x68, 0x6f, 0x6c, 0x64, 0x65, 0x72, 0x00, 0x05, 0x00, 0x04, 0x00, + 0x71, 0x00, 0x00, 0x00, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x00, + 0x05, 0x00, 0x04, 0x00, 0x74, 0x00, 0x00, 0x00, 0x69, 0x6d, 0x61, 0x67, + 0x65, 0x00, 0x00, 0x00, 0x05, 0x00, 0x05, 0x00, 0x79, 0x00, 0x00, 0x00, + 0x54, 0x65, 0x78, 0x74, 0x75, 0x72, 0x65, 0x73, 0x00, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x04, 0x00, 0x7d, 0x00, 0x00, 0x00, 0x49, 0x6d, 0x61, 0x67, + 0x65, 0x73, 0x00, 0x00, 0x05, 0x00, 0x06, 0x00, 0x7f, 0x00, 0x00, 0x00, + 0x50, 0x42, 0x52, 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x73, + 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x05, 0x00, 0x7f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x61, 0x6c, 0x62, 0x65, 0x64, 0x6f, 0x00, 0x00, + 0x06, 0x00, 0x05, 0x00, 0x7f, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x6e, 0x6f, 0x72, 0x6d, 0x61, 0x6c, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, + 0x7f, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x6d, 0x65, 0x74, 0x61, + 0x6c, 0x6c, 0x69, 0x63, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, + 0x7f, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x72, 0x6f, 0x75, 0x67, + 0x68, 0x6e, 0x65, 0x73, 0x73, 0x00, 0x00, 0x00, 0x06, 0x00, 0x04, 0x00, + 0x7f, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x61, 0x6f, 0x00, 0x00, + 0x05, 0x00, 0x05, 0x00, 0x82, 0x00, 0x00, 0x00, 0x4d, 0x61, 0x74, 0x65, + 0x72, 0x69, 0x61, 0x6c, 0x73, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, 0x2a, 0x00, 0x00, 0x00, + 0x47, 0x00, 0x04, 0x00, 0x15, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, 0x1b, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, - 0x14, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, - 0x47, 0x00, 0x04, 0x00, 0x31, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, - 0x2a, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, 0x3a, 0x00, 0x00, 0x00, - 0x1e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x03, 0x00, - 0x3e, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, - 0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, 0x3e, 0x00, 0x00, 0x00, - 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, - 0x48, 0x00, 0x05, 0x00, 0x3e, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, - 0x0b, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, - 0x3e, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, - 0x04, 0x00, 0x00, 0x00, 0x47, 0x00, 0x03, 0x00, 0x47, 0x00, 0x00, 0x00, - 0x02, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, 0x47, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x47, 0x00, 0x03, 0x00, 0x59, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, - 0x48, 0x00, 0x05, 0x00, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x23, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, - 0x5b, 0x00, 0x00, 0x00, 0x21, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x47, 0x00, 0x04, 0x00, 0x5b, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x03, 0x00, 0x5c, 0x00, 0x00, 0x00, - 0x02, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, 0x5c, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x47, 0x00, 0x04, 0x00, 0x5e, 0x00, 0x00, 0x00, 0x21, 0x00, 0x00, 0x00, - 0x01, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, 0x5e, 0x00, 0x00, 0x00, - 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, - 0x61, 0x00, 0x00, 0x00, 0x21, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, - 0x47, 0x00, 0x04, 0x00, 0x61, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, 0x66, 0x00, 0x00, 0x00, - 0x21, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, - 0x66, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, - 0x47, 0x00, 0x04, 0x00, 0x6a, 0x00, 0x00, 0x00, 0x21, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, 0x6a, 0x00, 0x00, 0x00, - 0x22, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x47, 0x00, 0x03, 0x00, + 0x4d, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x47, 0x00, 0x04, 0x00, 0x4f, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x47, 0x00, 0x03, 0x00, 0x52, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, 0x52, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x48, 0x00, 0x05, 0x00, 0x52, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, + 0x52, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, 0x52, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x47, 0x00, 0x03, 0x00, 0x5a, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x48, 0x00, 0x05, 0x00, 0x5a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x23, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x03, 0x00, 0x6c, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, 0x6c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, 0x6c, 0x00, 0x00, 0x00, - 0x01, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, - 0x48, 0x00, 0x05, 0x00, 0x6c, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, - 0x23, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, - 0x6c, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, - 0x20, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, 0x6c, 0x00, 0x00, 0x00, - 0x04, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, - 0x47, 0x00, 0x04, 0x00, 0x6f, 0x00, 0x00, 0x00, 0x21, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, 0x6f, 0x00, 0x00, 0x00, - 0x22, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x13, 0x00, 0x02, 0x00, - 0x02, 0x00, 0x00, 0x00, 0x21, 0x00, 0x03, 0x00, 0x03, 0x00, 0x00, 0x00, - 0x02, 0x00, 0x00, 0x00, 0x16, 0x00, 0x03, 0x00, 0x06, 0x00, 0x00, 0x00, - 0x20, 0x00, 0x00, 0x00, 0x17, 0x00, 0x04, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x06, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, - 0x08, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x20, 0x00, 0x04, 0x00, 0x0a, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, - 0x07, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x0a, 0x00, 0x00, 0x00, - 0x0b, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, - 0x0a, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, - 0x17, 0x00, 0x04, 0x00, 0x10, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, - 0x04, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, 0x11, 0x00, 0x00, 0x00, - 0x07, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, - 0x13, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, - 0x3b, 0x00, 0x04, 0x00, 0x13, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, 0x6e, 0x00, 0x00, 0x00, + 0x21, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, + 0x6e, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x47, 0x00, 0x03, 0x00, 0x6f, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x48, 0x00, 0x05, 0x00, 0x6f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x23, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, + 0x71, 0x00, 0x00, 0x00, 0x21, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x47, 0x00, 0x04, 0x00, 0x71, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, 0x74, 0x00, 0x00, 0x00, + 0x21, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, + 0x74, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x47, 0x00, 0x04, 0x00, 0x79, 0x00, 0x00, 0x00, 0x21, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, 0x79, 0x00, 0x00, 0x00, + 0x22, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, + 0x7d, 0x00, 0x00, 0x00, 0x21, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x47, 0x00, 0x04, 0x00, 0x7d, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x47, 0x00, 0x03, 0x00, 0x7f, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, 0x7f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x48, 0x00, 0x05, 0x00, 0x7f, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x23, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, + 0x7f, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0x48, 0x00, 0x05, 0x00, 0x7f, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, + 0x48, 0x00, 0x05, 0x00, 0x7f, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x23, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, 0x47, 0x00, 0x04, 0x00, + 0x82, 0x00, 0x00, 0x00, 0x21, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x47, 0x00, 0x04, 0x00, 0x82, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x13, 0x00, 0x02, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x21, 0x00, 0x03, 0x00, 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x16, 0x00, 0x03, 0x00, 0x06, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, + 0x17, 0x00, 0x04, 0x00, 0x07, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x07, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x15, 0x00, 0x04, 0x00, + 0x0a, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x20, 0x00, 0x04, 0x00, 0x0b, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x0a, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x2b, 0x00, 0x04, 0x00, + 0x0a, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x14, 0x00, 0x02, 0x00, 0x0f, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, + 0x14, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x3b, 0x00, 0x04, 0x00, 0x14, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x15, 0x00, 0x04, 0x00, 0x16, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x2b, 0x00, 0x04, 0x00, - 0x16, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, - 0x1c, 0x00, 0x04, 0x00, 0x18, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x17, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, 0x19, 0x00, 0x00, 0x00, - 0x07, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x2b, 0x00, 0x04, 0x00, - 0x06, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x3f, - 0x2b, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x40, 0x2c, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x1d, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, - 0x2c, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, - 0x1b, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x05, 0x00, - 0x07, 0x00, 0x00, 0x00, 0x1f, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, - 0x1c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x20, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, - 0x2c, 0x00, 0x07, 0x00, 0x18, 0x00, 0x00, 0x00, 0x21, 0x00, 0x00, 0x00, - 0x1d, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x1f, 0x00, 0x00, 0x00, - 0x20, 0x00, 0x00, 0x00, 0x15, 0x00, 0x04, 0x00, 0x2f, 0x00, 0x00, 0x00, - 0x20, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, - 0x30, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x2f, 0x00, 0x00, 0x00, - 0x3b, 0x00, 0x04, 0x00, 0x30, 0x00, 0x00, 0x00, 0x31, 0x00, 0x00, 0x00, - 0x01, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, 0x39, 0x00, 0x00, 0x00, - 0x03, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, - 0x39, 0x00, 0x00, 0x00, 0x3a, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, - 0x2b, 0x00, 0x04, 0x00, 0x16, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, - 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x04, 0x00, 0x3d, 0x00, 0x00, 0x00, - 0x06, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x06, 0x00, - 0x3e, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, - 0x3d, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, - 0x3f, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x00, 0x00, - 0x3b, 0x00, 0x04, 0x00, 0x3f, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, - 0x03, 0x00, 0x00, 0x00, 0x2b, 0x00, 0x04, 0x00, 0x2f, 0x00, 0x00, 0x00, - 0x41, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x2b, 0x00, 0x04, 0x00, - 0x16, 0x00, 0x00, 0x00, 0x42, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x20, 0x00, 0x04, 0x00, 0x43, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x06, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x03, 0x00, 0x47, 0x00, 0x00, 0x00, - 0x07, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, 0x48, 0x00, 0x00, 0x00, - 0x09, 0x00, 0x00, 0x00, 0x47, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, - 0x48, 0x00, 0x00, 0x00, 0x49, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, - 0x20, 0x00, 0x04, 0x00, 0x4a, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x16, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x20, 0x00, 0x04, 0x00, 0x18, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x1b, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x2b, 0x00, 0x04, 0x00, + 0x16, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x2b, 0x00, 0x04, 0x00, 0x0a, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x2b, 0x00, 0x04, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x2e, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x2b, 0x00, 0x04, 0x00, + 0x0a, 0x00, 0x00, 0x00, 0x3a, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x2b, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x45, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x46, 0x00, 0x00, 0x00, 0x45, 0x00, 0x00, 0x00, 0x45, 0x00, 0x00, 0x00, + 0x17, 0x00, 0x04, 0x00, 0x4b, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, 0x4c, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x4b, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, + 0x4c, 0x00, 0x00, 0x00, 0x4d, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x20, 0x00, 0x04, 0x00, 0x4e, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x4b, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x4e, 0x00, 0x00, 0x00, + 0x4f, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x04, 0x00, + 0x51, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x1e, 0x00, 0x06, 0x00, 0x52, 0x00, 0x00, 0x00, 0x4b, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x51, 0x00, 0x00, 0x00, 0x51, 0x00, 0x00, 0x00, + 0x20, 0x00, 0x04, 0x00, 0x53, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x52, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x53, 0x00, 0x00, 0x00, + 0x54, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x2b, 0x00, 0x04, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, + 0x20, 0x00, 0x04, 0x00, 0x56, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x03, 0x00, 0x5a, 0x00, 0x00, 0x00, + 0x07, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, 0x5b, 0x00, 0x00, 0x00, + 0x09, 0x00, 0x00, 0x00, 0x5a, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, + 0x5b, 0x00, 0x00, 0x00, 0x5c, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x20, 0x00, 0x04, 0x00, 0x5d, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x2b, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, - 0x56, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x03, 0x00, - 0x59, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, - 0x5a, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x59, 0x00, 0x00, 0x00, - 0x3b, 0x00, 0x04, 0x00, 0x5a, 0x00, 0x00, 0x00, 0x5b, 0x00, 0x00, 0x00, - 0x02, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x03, 0x00, 0x5c, 0x00, 0x00, 0x00, - 0x06, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, 0x5d, 0x00, 0x00, 0x00, - 0x02, 0x00, 0x00, 0x00, 0x5c, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, - 0x5d, 0x00, 0x00, 0x00, 0x5e, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, - 0x19, 0x00, 0x09, 0x00, 0x5f, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x61, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x3f, 0x1e, 0x00, 0x03, 0x00, + 0x6c, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, + 0x6d, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00, + 0x3b, 0x00, 0x04, 0x00, 0x6d, 0x00, 0x00, 0x00, 0x6e, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x03, 0x00, 0x6f, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, 0x70, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x6f, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, + 0x70, 0x00, 0x00, 0x00, 0x71, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x19, 0x00, 0x09, 0x00, 0x72, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, - 0x20, 0x00, 0x04, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x5f, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x60, 0x00, 0x00, 0x00, - 0x61, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x09, 0x00, - 0x62, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x20, 0x00, 0x04, 0x00, 0x73, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x72, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x73, 0x00, 0x00, 0x00, + 0x74, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x09, 0x00, + 0x75, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x03, 0x00, - 0x63, 0x00, 0x00, 0x00, 0x62, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x04, 0x00, - 0x64, 0x00, 0x00, 0x00, 0x63, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, - 0x20, 0x00, 0x04, 0x00, 0x65, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x64, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x65, 0x00, 0x00, 0x00, - 0x66, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x09, 0x00, - 0x67, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x76, 0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x04, 0x00, + 0x77, 0x00, 0x00, 0x00, 0x76, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x20, 0x00, 0x04, 0x00, 0x78, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x77, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x78, 0x00, 0x00, 0x00, + 0x79, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x09, 0x00, + 0x7a, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x04, 0x00, - 0x68, 0x00, 0x00, 0x00, 0x67, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, - 0x20, 0x00, 0x04, 0x00, 0x69, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x68, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x69, 0x00, 0x00, 0x00, - 0x6a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x04, 0x00, - 0x6b, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, - 0x1e, 0x00, 0x07, 0x00, 0x6c, 0x00, 0x00, 0x00, 0x6b, 0x00, 0x00, 0x00, - 0x6b, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, - 0x06, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x04, 0x00, 0x6d, 0x00, 0x00, 0x00, - 0x6c, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, - 0x6e, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x6d, 0x00, 0x00, 0x00, - 0x3b, 0x00, 0x04, 0x00, 0x6e, 0x00, 0x00, 0x00, 0x6f, 0x00, 0x00, 0x00, + 0x7b, 0x00, 0x00, 0x00, 0x7a, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x20, 0x00, 0x04, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x7b, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x7c, 0x00, 0x00, 0x00, + 0x7d, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x04, 0x00, + 0x7e, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x1e, 0x00, 0x07, 0x00, 0x7f, 0x00, 0x00, 0x00, 0x7e, 0x00, 0x00, 0x00, + 0x7e, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x04, 0x00, 0x80, 0x00, 0x00, 0x00, + 0x7f, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, + 0x81, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, + 0x3b, 0x00, 0x04, 0x00, 0x81, 0x00, 0x00, 0x00, 0x82, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x36, 0x00, 0x05, 0x00, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x02, 0x00, 0x05, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x08, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x3b, 0x00, 0x04, 0x00, 0x08, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, - 0x07, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x11, 0x00, 0x00, 0x00, - 0x12, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, - 0x19, 0x00, 0x00, 0x00, 0x1a, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x3b, 0x00, 0x04, 0x00, 0x08, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00, + 0x3b, 0x00, 0x04, 0x00, 0x08, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, 0x08, 0x00, 0x00, 0x00, - 0x28, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, - 0x08, 0x00, 0x00, 0x00, 0x2e, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x3d, 0x00, 0x04, 0x00, 0x07, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, - 0x0b, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x03, 0x00, 0x09, 0x00, 0x00, 0x00, - 0x0c, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x0f, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x03, 0x00, - 0x0d, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, - 0x10, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, - 0x3e, 0x00, 0x03, 0x00, 0x12, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, - 0x3e, 0x00, 0x03, 0x00, 0x1a, 0x00, 0x00, 0x00, 0x21, 0x00, 0x00, 0x00, - 0x3d, 0x00, 0x04, 0x00, 0x07, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, - 0x0d, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x24, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x83, 0x00, 0x05, 0x00, - 0x07, 0x00, 0x00, 0x00, 0x25, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, - 0x24, 0x00, 0x00, 0x00, 0x50, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x26, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, - 0x88, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, 0x27, 0x00, 0x00, 0x00, - 0x25, 0x00, 0x00, 0x00, 0x26, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x03, 0x00, - 0x22, 0x00, 0x00, 0x00, 0x27, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, - 0x07, 0x00, 0x00, 0x00, 0x29, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, - 0x3d, 0x00, 0x04, 0x00, 0x07, 0x00, 0x00, 0x00, 0x2a, 0x00, 0x00, 0x00, - 0x09, 0x00, 0x00, 0x00, 0x81, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x2b, 0x00, 0x00, 0x00, 0x29, 0x00, 0x00, 0x00, 0x2a, 0x00, 0x00, 0x00, - 0x50, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, - 0x1c, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x88, 0x00, 0x05, 0x00, - 0x07, 0x00, 0x00, 0x00, 0x2d, 0x00, 0x00, 0x00, 0x2b, 0x00, 0x00, 0x00, - 0x2c, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x03, 0x00, 0x28, 0x00, 0x00, 0x00, - 0x2d, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, 0x2f, 0x00, 0x00, 0x00, - 0x32, 0x00, 0x00, 0x00, 0x31, 0x00, 0x00, 0x00, 0x41, 0x00, 0x05, 0x00, - 0x08, 0x00, 0x00, 0x00, 0x33, 0x00, 0x00, 0x00, 0x1a, 0x00, 0x00, 0x00, + 0x24, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x04, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x3b, 0x00, 0x04, 0x00, 0x08, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, + 0x07, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x0d, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0xaa, 0x00, 0x05, 0x00, + 0x0f, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x0e, 0x00, 0x00, 0x00, 0xf7, 0x00, 0x03, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xfa, 0x00, 0x04, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x12, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x02, 0x00, + 0x12, 0x00, 0x00, 0x00, 0x41, 0x00, 0x05, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x19, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x1a, 0x00, 0x00, 0x00, + 0x19, 0x00, 0x00, 0x00, 0x41, 0x00, 0x05, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x1d, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, + 0x1d, 0x00, 0x00, 0x00, 0x50, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x1f, 0x00, 0x00, 0x00, 0x1a, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, + 0x3e, 0x00, 0x03, 0x00, 0x11, 0x00, 0x00, 0x00, 0x1f, 0x00, 0x00, 0x00, + 0xf9, 0x00, 0x02, 0x00, 0x13, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x02, 0x00, + 0x20, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x21, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0xaa, 0x00, 0x05, 0x00, + 0x0f, 0x00, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, 0x21, 0x00, 0x00, 0x00, + 0x22, 0x00, 0x00, 0x00, 0xf7, 0x00, 0x03, 0x00, 0x26, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xfa, 0x00, 0x04, 0x00, 0x23, 0x00, 0x00, 0x00, + 0x25, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x02, 0x00, + 0x25, 0x00, 0x00, 0x00, 0x41, 0x00, 0x05, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x27, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x28, 0x00, 0x00, 0x00, + 0x27, 0x00, 0x00, 0x00, 0x41, 0x00, 0x05, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x29, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x2a, 0x00, 0x00, 0x00, + 0x29, 0x00, 0x00, 0x00, 0x50, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x2b, 0x00, 0x00, 0x00, 0x28, 0x00, 0x00, 0x00, 0x2a, 0x00, 0x00, 0x00, + 0x3e, 0x00, 0x03, 0x00, 0x24, 0x00, 0x00, 0x00, 0x2b, 0x00, 0x00, 0x00, + 0xf9, 0x00, 0x02, 0x00, 0x26, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x02, 0x00, + 0x2c, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x2d, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0xaa, 0x00, 0x05, 0x00, + 0x0f, 0x00, 0x00, 0x00, 0x2f, 0x00, 0x00, 0x00, 0x2d, 0x00, 0x00, 0x00, + 0x2e, 0x00, 0x00, 0x00, 0xf7, 0x00, 0x03, 0x00, 0x32, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xfa, 0x00, 0x04, 0x00, 0x2f, 0x00, 0x00, 0x00, + 0x31, 0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x02, 0x00, + 0x31, 0x00, 0x00, 0x00, 0x41, 0x00, 0x05, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x33, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x34, 0x00, 0x00, 0x00, + 0x33, 0x00, 0x00, 0x00, 0x41, 0x00, 0x05, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x35, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x36, 0x00, 0x00, 0x00, + 0x35, 0x00, 0x00, 0x00, 0x50, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x37, 0x00, 0x00, 0x00, 0x34, 0x00, 0x00, 0x00, 0x36, 0x00, 0x00, 0x00, + 0x3e, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, 0x00, 0x37, 0x00, 0x00, 0x00, + 0xf9, 0x00, 0x02, 0x00, 0x32, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x02, 0x00, + 0x38, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x39, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0xaa, 0x00, 0x05, 0x00, + 0x0f, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x00, 0x00, 0x39, 0x00, 0x00, 0x00, + 0x3a, 0x00, 0x00, 0x00, 0xf7, 0x00, 0x03, 0x00, 0x3e, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xfa, 0x00, 0x04, 0x00, 0x3b, 0x00, 0x00, 0x00, + 0x3d, 0x00, 0x00, 0x00, 0x44, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x02, 0x00, + 0x3d, 0x00, 0x00, 0x00, 0x41, 0x00, 0x05, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x3f, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x3f, 0x00, 0x00, 0x00, 0x41, 0x00, 0x05, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x41, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x42, 0x00, 0x00, 0x00, + 0x41, 0x00, 0x00, 0x00, 0x50, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x43, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x42, 0x00, 0x00, 0x00, + 0x3e, 0x00, 0x03, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, + 0xf9, 0x00, 0x02, 0x00, 0x3e, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x02, 0x00, + 0x44, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x03, 0x00, 0x3c, 0x00, 0x00, 0x00, + 0x46, 0x00, 0x00, 0x00, 0xf9, 0x00, 0x02, 0x00, 0x3e, 0x00, 0x00, 0x00, + 0xf8, 0x00, 0x02, 0x00, 0x3e, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, + 0x07, 0x00, 0x00, 0x00, 0x47, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, + 0x3e, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, 0x00, 0x47, 0x00, 0x00, 0x00, + 0xf9, 0x00, 0x02, 0x00, 0x32, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x02, 0x00, 0x32, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, 0x07, 0x00, 0x00, 0x00, - 0x34, 0x00, 0x00, 0x00, 0x33, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, - 0x07, 0x00, 0x00, 0x00, 0x35, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00, - 0x85, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, 0x36, 0x00, 0x00, 0x00, - 0x34, 0x00, 0x00, 0x00, 0x35, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, - 0x07, 0x00, 0x00, 0x00, 0x37, 0x00, 0x00, 0x00, 0x28, 0x00, 0x00, 0x00, - 0x85, 0x00, 0x05, 0x00, 0x07, 0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, - 0x36, 0x00, 0x00, 0x00, 0x37, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x03, 0x00, - 0x2e, 0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, - 0x10, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, - 0x3e, 0x00, 0x03, 0x00, 0x3a, 0x00, 0x00, 0x00, 0x3b, 0x00, 0x00, 0x00, - 0x41, 0x00, 0x05, 0x00, 0x43, 0x00, 0x00, 0x00, 0x44, 0x00, 0x00, 0x00, - 0x2e, 0x00, 0x00, 0x00, 0x42, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, - 0x06, 0x00, 0x00, 0x00, 0x45, 0x00, 0x00, 0x00, 0x44, 0x00, 0x00, 0x00, - 0x85, 0x00, 0x05, 0x00, 0x06, 0x00, 0x00, 0x00, 0x46, 0x00, 0x00, 0x00, - 0x1c, 0x00, 0x00, 0x00, 0x45, 0x00, 0x00, 0x00, 0x41, 0x00, 0x06, 0x00, - 0x4a, 0x00, 0x00, 0x00, 0x4b, 0x00, 0x00, 0x00, 0x49, 0x00, 0x00, 0x00, - 0x41, 0x00, 0x00, 0x00, 0x42, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, - 0x06, 0x00, 0x00, 0x00, 0x4c, 0x00, 0x00, 0x00, 0x4b, 0x00, 0x00, 0x00, - 0x88, 0x00, 0x05, 0x00, 0x06, 0x00, 0x00, 0x00, 0x4d, 0x00, 0x00, 0x00, - 0x46, 0x00, 0x00, 0x00, 0x4c, 0x00, 0x00, 0x00, 0x83, 0x00, 0x05, 0x00, - 0x06, 0x00, 0x00, 0x00, 0x4e, 0x00, 0x00, 0x00, 0x4d, 0x00, 0x00, 0x00, - 0x1b, 0x00, 0x00, 0x00, 0x41, 0x00, 0x05, 0x00, 0x43, 0x00, 0x00, 0x00, - 0x4f, 0x00, 0x00, 0x00, 0x2e, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, - 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x50, 0x00, 0x00, 0x00, - 0x4f, 0x00, 0x00, 0x00, 0x85, 0x00, 0x05, 0x00, 0x06, 0x00, 0x00, 0x00, - 0x51, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x50, 0x00, 0x00, 0x00, - 0x41, 0x00, 0x06, 0x00, 0x4a, 0x00, 0x00, 0x00, 0x52, 0x00, 0x00, 0x00, - 0x49, 0x00, 0x00, 0x00, 0x41, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, - 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x53, 0x00, 0x00, 0x00, - 0x52, 0x00, 0x00, 0x00, 0x88, 0x00, 0x05, 0x00, 0x06, 0x00, 0x00, 0x00, - 0x54, 0x00, 0x00, 0x00, 0x51, 0x00, 0x00, 0x00, 0x53, 0x00, 0x00, 0x00, - 0x83, 0x00, 0x05, 0x00, 0x06, 0x00, 0x00, 0x00, 0x55, 0x00, 0x00, 0x00, - 0x54, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, 0x50, 0x00, 0x07, 0x00, - 0x10, 0x00, 0x00, 0x00, 0x57, 0x00, 0x00, 0x00, 0x4e, 0x00, 0x00, 0x00, - 0x55, 0x00, 0x00, 0x00, 0x56, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, - 0x41, 0x00, 0x05, 0x00, 0x39, 0x00, 0x00, 0x00, 0x58, 0x00, 0x00, 0x00, - 0x40, 0x00, 0x00, 0x00, 0x41, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x03, 0x00, - 0x58, 0x00, 0x00, 0x00, 0x57, 0x00, 0x00, 0x00, 0xfd, 0x00, 0x01, 0x00, - 0x38, 0x00, 0x01, 0x00 + 0x48, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x03, 0x00, + 0x24, 0x00, 0x00, 0x00, 0x48, 0x00, 0x00, 0x00, 0xf9, 0x00, 0x02, 0x00, + 0x26, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x02, 0x00, 0x26, 0x00, 0x00, 0x00, + 0x3d, 0x00, 0x04, 0x00, 0x07, 0x00, 0x00, 0x00, 0x49, 0x00, 0x00, 0x00, + 0x24, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x03, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x49, 0x00, 0x00, 0x00, 0xf9, 0x00, 0x02, 0x00, 0x13, 0x00, 0x00, 0x00, + 0xf8, 0x00, 0x02, 0x00, 0x13, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, + 0x07, 0x00, 0x00, 0x00, 0x4a, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x3e, 0x00, 0x03, 0x00, 0x09, 0x00, 0x00, 0x00, 0x4a, 0x00, 0x00, 0x00, + 0x3d, 0x00, 0x04, 0x00, 0x4b, 0x00, 0x00, 0x00, 0x50, 0x00, 0x00, 0x00, + 0x4f, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x03, 0x00, 0x4d, 0x00, 0x00, 0x00, + 0x50, 0x00, 0x00, 0x00, 0x41, 0x00, 0x05, 0x00, 0x56, 0x00, 0x00, 0x00, + 0x57, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x58, 0x00, 0x00, 0x00, + 0x57, 0x00, 0x00, 0x00, 0x85, 0x00, 0x05, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x59, 0x00, 0x00, 0x00, 0x55, 0x00, 0x00, 0x00, 0x58, 0x00, 0x00, 0x00, + 0x41, 0x00, 0x06, 0x00, 0x5d, 0x00, 0x00, 0x00, 0x5e, 0x00, 0x00, 0x00, + 0x5c, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, 0x5f, 0x00, 0x00, 0x00, + 0x5e, 0x00, 0x00, 0x00, 0x88, 0x00, 0x05, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x60, 0x00, 0x00, 0x00, 0x59, 0x00, 0x00, 0x00, 0x5f, 0x00, 0x00, 0x00, + 0x83, 0x00, 0x05, 0x00, 0x06, 0x00, 0x00, 0x00, 0x62, 0x00, 0x00, 0x00, + 0x60, 0x00, 0x00, 0x00, 0x61, 0x00, 0x00, 0x00, 0x41, 0x00, 0x05, 0x00, + 0x56, 0x00, 0x00, 0x00, 0x63, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x64, 0x00, 0x00, 0x00, 0x63, 0x00, 0x00, 0x00, 0x85, 0x00, 0x05, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x65, 0x00, 0x00, 0x00, 0x55, 0x00, 0x00, 0x00, + 0x64, 0x00, 0x00, 0x00, 0x41, 0x00, 0x06, 0x00, 0x5d, 0x00, 0x00, 0x00, + 0x66, 0x00, 0x00, 0x00, 0x5c, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0x3d, 0x00, 0x04, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x67, 0x00, 0x00, 0x00, 0x66, 0x00, 0x00, 0x00, 0x88, 0x00, 0x05, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x68, 0x00, 0x00, 0x00, 0x65, 0x00, 0x00, 0x00, + 0x67, 0x00, 0x00, 0x00, 0x83, 0x00, 0x05, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x69, 0x00, 0x00, 0x00, 0x68, 0x00, 0x00, 0x00, 0x61, 0x00, 0x00, 0x00, + 0x50, 0x00, 0x07, 0x00, 0x4b, 0x00, 0x00, 0x00, 0x6a, 0x00, 0x00, 0x00, + 0x62, 0x00, 0x00, 0x00, 0x69, 0x00, 0x00, 0x00, 0x45, 0x00, 0x00, 0x00, + 0x61, 0x00, 0x00, 0x00, 0x41, 0x00, 0x05, 0x00, 0x4c, 0x00, 0x00, 0x00, + 0x6b, 0x00, 0x00, 0x00, 0x54, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x3e, 0x00, 0x03, 0x00, 0x6b, 0x00, 0x00, 0x00, 0x6a, 0x00, 0x00, 0x00, + 0xfd, 0x00, 0x01, 0x00, 0x38, 0x00, 0x01, 0x00 }; -unsigned int shader_gui_vert_len = 3628; +unsigned int shader_gui_vert_len = 3932; unsigned char shader_quad_frag[] = { 0x03, 0x02, 0x23, 0x07, 0x00, 0x06, 0x01, 0x00, 0x0b, 0x00, 0x0d, 0x00, 0x13, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x02, 0x00, diff --git a/src/game.c b/src/game.c index 073131a..d87f4e2 100644 --- a/src/game.c +++ b/src/game.c @@ -1,6 +1,20 @@ -static void InitializeGame(Arena *arena) +static void InitializeGame(Arena *arena, GameContext *ctx, Arena *ctx_arena) { Assert(InitRenderer(arena), "Failed to initialize the renderer"); + + ctx->gui.vertices = ArenaAlloc(ctx_arena, sizeof(GUIVertex) * 128); + ctx->gui.vertices_len = 0; + ctx->gui.indices = ArenaAlloc(ctx_arena, sizeof(u32) * 768); + ctx->gui.indices_len = 0; + ctx->gui.instance_count = 0; + + ctx->window.p0.x = 0.0f; + ctx->window.p0.y = 0.0f; + + ctx->window.p1.x = 100.0f; + ctx->window.p1.y = 100.0f; + + ctx->arena = arena; } static void DestroyGame() @@ -8,54 +22,127 @@ static void DestroyGame() DestroyRenderer(); } -static void RunCycle(Arena *arena, GameInput *inputs, u32 i_count) +u32 selected_rect = 0; +b8 mouse_pressed = false; +i16 mouse_prev_pos_x = 0; +i16 mouse_prev_pos_y = 0; +i16 mouse_pos_x = 0; +i16 mouse_pos_y = 0; + +static void HandleInputs(GameInput *inputs, u32 count) { - GUIContext ctx = { - .vertices = ArenaAlloc(arena, sizeof(GUIVertex) * 128), - .vertices_len = 0, - .indices = ArenaAlloc(arena, sizeof(u32) * 768), - .indices_len = 0, - .instance_count = 0, - }; + for (u32 i = 0; i < count; i++) + { + if (inputs[i].type == GI_KEYBOARD) + { + if (inputs[i].kb_code == KB_1) + { + selected_rect = 0; + break; + } + else if (inputs[i].kb_code == KB_2) + { + selected_rect = 1; + break; + } + else if (inputs[i].kb_code == KB_3) + { + selected_rect = 2; + break; + } + else if (inputs[i].kb_code == KB_4) + { + selected_rect = 3; + break; + } + } + else if (inputs[i].type == GI_MOUSE) + { + if (inputs[i].m_code == M_LEFT_CLICK) + mouse_pressed = inputs[i].pressed; + } + else if (inputs[i].type == GI_MOTION) + { + mouse_prev_pos_x = mouse_pos_x; + mouse_prev_pos_y = mouse_pos_y; + mouse_pos_x = inputs[i].motion_ev.x; + mouse_pos_y = inputs[i].motion_ev.y; + } + } +} - PushConst pc = {}; +static void RunCycle(GameContext *ctx, GameInput *inputs, u32 i_count) +{ + GetViewportSize(&ctx->pc.res); - DrawRect(&ctx, (Vec2){ .x = 0.0f, .y = 0.0f }, (Vec2){ .x = 10.0f, .y = 10.0f }, (Vec4){ .r = 0.0f, .g = 0.3f, .b = 0.7f, .a = 1.0f}); - DrawRect(&ctx, (Vec2){ .x = 20.0f, .y = 0.0f }, (Vec2){ .x = 30.0f, .y = 5.0f }, (Vec4){ .r = 0.0f, .g = 0.3f, .b = 0.7f, .a = 1.0f}); - DrawRect(&ctx, (Vec2){ .x = 35.0f, .y = 10.0f }, (Vec2){ .x = 40.0f, .y = 60.0f }, (Vec4){ .r = 0.0f, .g = 0.3f, .b = 0.7f, .a = 1.0f}); + HandleInputs(inputs, i_count); + + + if (mouse_pressed && !ctx->window.grabbed + && mouse_pos_x > ctx->window.p0.x + && mouse_pos_x < ctx->window.p1.x + && mouse_pos_y > ctx->window.p0.y + && mouse_pos_y < ctx->window.p1.y) + { + ctx->window.grabbed = true; + + ctx->window.grabbed_pos.x = (f32)mouse_pos_x - ctx->window.p0.x; + ctx->window.grabbed_pos.y = (f32)mouse_pos_y - ctx->window.p0.y; + } + else if (!mouse_pressed && ctx->window.grabbed) + { + ctx->window.grabbed = false; + + ctx->window.grabbed_pos.x = 0.0f; + ctx->window.grabbed_pos.y = 0.0f; + } + + if (ctx->window.grabbed) + { + f32 w = ctx->window.p1.x - ctx->window.p0.x; + f32 h = ctx->window.p1.y - ctx->window.p0.y; + + ctx->window.p0.x = (f32)(mouse_pos_x) - ctx->window.grabbed_pos.x; + ctx->window.p0.y = (f32)(mouse_pos_y) - ctx->window.grabbed_pos.y; + ctx->window.p1.x = ctx->window.p0.x + w; + ctx->window.p1.y = ctx->window.p0.y + h; + } + + DrawRect(&ctx->gui, ctx->window.p0, ctx->window.p1, (Vec4){ .r = 0.1f, .g = 0.3f, .b = 0.8f, .a = 1.0f }); RenderBuffer vertex_buffer = { .type = RENDER_BUFFER_TYPE_VERTEX, - .size = sizeof(GUIVertex) * ctx.vertices_len, + .size = sizeof(GUIVertex) * ctx->gui.vertices_len, }; RenderBuffer index_buffer = { .type = RENDER_BUFFER_TYPE_INDEX, - .size = sizeof(u32) * ctx.indices_len, + .size = sizeof(u32) * ctx->gui.indices_len, }; - CreateAndUploadToBuffer(&vertex_buffer, ctx.vertices); - CreateAndUploadToBuffer(&index_buffer, ctx.indices); + CreateAndUploadToBuffer(&vertex_buffer, ctx->gui.vertices); + CreateAndUploadToBuffer(&index_buffer, ctx->gui.indices); BeginFrame(); BindPipeline(PIPELINE_GUI, PIPELINE_TYPE_GRAPHICS); - GetViewportSize(&pc.res); - - SetPushConstants(&pc); + SetPushConstants(&ctx->pc); BindVertexBuffer(&vertex_buffer); BindIndexBuffer(&index_buffer); - DrawIndexed(6, ctx.instance_count); + DrawIndexed(6, ctx->gui.instance_count); FinishFrame(); FreeBuffers(&vertex_buffer, 1); FreeBuffers(&index_buffer, 1); - ArenaFree(arena); + ctx->gui.vertices_len = 0; + ctx->gui.indices_len = 0; + ctx->gui.instance_count = 0; + ArenaFree(ctx->arena); } static void DrawRect(GUIContext *ctx, Vec2 p0, Vec2 p1, Vec4 col) diff --git a/src/game.h b/src/game.h index c8a4b46..a3d8164 100644 --- a/src/game.h +++ b/src/game.h @@ -1,6 +1,23 @@ #pragma once -static void RunCycle(Arena *arena, GameInput *inputs, u32 i_count); -static void InitializeGame(Arena *arena); +typedef struct GUIWindow_t +{ + Vec2 p0; + Vec2 p1; + Vec2 grabbed_pos; + b8 grabbed; +} GUIWindow; + +typedef struct GameContext_t +{ + GUIContext gui; + PushConst pc; + Arena *arena; + GUIWindow window; +} GameContext; + +static void RunCycle(GameContext *ctx, GameInput *inputs, u32 i_count); +static void InitializeGame(Arena *arena, GameContext *ctx, Arena *ctx_arena); static void DestroyGame(); static void DrawRect(GUIContext *ctx, Vec2 p0, Vec2 p1, Vec4 col); +static void HandleInputs(GameInput *inputs, u32 count); diff --git a/src/platform_linux.c b/src/platform_linux.c index f209d7f..fc94ddc 100644 --- a/src/platform_linux.c +++ b/src/platform_linux.c @@ -323,16 +323,56 @@ void HandleWindowEvent(GameInput *inputs, u32 *i_count, b32 wait_for_event) KeyboardInput input = ConvertInputEvent(keysym); if (input != KB_NONE) { - inputs[*i_count].code = input; + inputs[*i_count].kb_code = input; inputs[*i_count].pressed = pressed; + inputs[*i_count].type = GI_KEYBOARD; *i_count += 1; + if (*i_count == 10) has_max_inputs = true; } } break; - // case XCB_BUTTON_PRESS: (mouse input) - // case XCB_BUTTON_RELEASE: + case XCB_BUTTON_PRESS: + case XCB_BUTTON_RELEASE: + { + xcb_button_press_event_t *mouse_ev = (xcb_button_press_event_t *)e; + b8 pressed = e->response_type == XCB_BUTTON_PRESS; + MouseInput input = M_NONE; + + if (mouse_ev->detail == XCB_BUTTON_INDEX_1) + input = M_LEFT_CLICK; + else if (mouse_ev->detail == XCB_BUTTON_INDEX_2) + input = M_MIDDLE_CLICK; + else if (mouse_ev->detail == XCB_BUTTON_INDEX_3) + input = M_RIGHT_CLICK; + + if (input != M_NONE) + { + inputs[*i_count].m_code = input; + inputs[*i_count].pressed = pressed; + inputs[*i_count].type = GI_MOUSE; + *i_count += 1; + + if (*i_count == 10) + has_max_inputs = true; + } + } break; + case XCB_MOTION_NOTIFY: + { + xcb_motion_notify_event_t *move_ev = (xcb_motion_notify_event_t *)e; + + if (move_ev->event_x > 0 || move_ev->event_y > 0) + { + inputs[*i_count].motion_ev.x = move_ev->event_x; + inputs[*i_count].motion_ev.y = move_ev->event_y; + inputs[*i_count].type = GI_MOTION; + + *i_count += 1; + if (*i_count == 10) + has_max_inputs = true; + } + } default: break; } diff --git a/src/platform_linux.h b/src/platform_linux.h index e6c0059..b2b2aca 100644 --- a/src/platform_linux.h +++ b/src/platform_linux.h @@ -15,6 +15,7 @@ #include #include #include +#include // syscall defines #define SYS_ERR -1 diff --git a/src/render_vulkan.c b/src/render_vulkan.c index 361ee5b..eda2d52 100644 --- a/src/render_vulkan.c +++ b/src/render_vulkan.c @@ -766,8 +766,8 @@ static b32 InitVulkan(Arena *arena) Assert(arena != NULL, "Vulkan memory is null"); renderer.perm_arena = arena; - void *mem = ArenaAlloc(arena, MB(4)); - renderer.arena = CreateArena(mem, MB(4)); + void *mem = ArenaAlloc(arena, MB(8)); + renderer.arena = CreateArena(mem, MB(8)); Assert(InitVkGlobalFunctions(), "Unable to load vulkan functions"); { @@ -1296,7 +1296,6 @@ static b32 CreateSwapchain() vkGetPhysicalDeviceSurfaceFormatsKHR(phys_device, surface, &format_count, NULL); VkSurfaceFormatKHR *formats = ArenaAlloc(renderer.arena, sizeof(VkSurfaceFormatKHR) * format_count); vkGetPhysicalDeviceSurfaceFormatsKHR(phys_device, surface, &format_count, formats); - renderer.vk.sc.format = formats[0].format; renderer.vk.sc.color_space = formats[0].colorSpace; diff --git a/src/shaders/glsl/gui.vert.glsl b/src/shaders/glsl/gui.vert.glsl index fbb85a8..369bb75 100644 --- a/src/shaders/glsl/gui.vert.glsl +++ b/src/shaders/glsl/gui.vert.glsl @@ -13,23 +13,13 @@ layout (location = 0) out vec4 out_color; void main() { - vec2 p0 = in_gui_pos_0; - vec2 p1 = in_gui_pos_1; - vec4 col = in_col; - // Draw with 6 indices, gl_VertexIndex will use the appropriate index, iterates through 0-3 and not 0-5 - vec2 vertices[] = { - {1.0, 2.0}, - {1.0, 1.0}, - {2.0, 2.0}, - {2.0, 1.0}, - }; + vec2 dst_pos = gl_VertexIndex == 0 ? vec2(in_gui_pos_0.x, in_gui_pos_1.y) : + gl_VertexIndex == 1 ? vec2(in_gui_pos_0.x, in_gui_pos_0.y) : + gl_VertexIndex == 2 ? vec2(in_gui_pos_1.x, in_gui_pos_1.y) : + gl_VertexIndex == 3 ? vec2(in_gui_pos_1.x, in_gui_pos_0.y) : vec2(0.0, 0.0); - vec2 dst_half_size = (p1 - p0) / 2; - vec2 dst_center = (p1 + p0) / 2; - vec2 dst_pos = (vertices[gl_VertexIndex] * dst_half_size * dst_center); - - out_color = col; + out_color = in_col; gl_Position = vec4(2 * dst_pos.x / PC.res.x - 1, 2 * dst_pos.y / PC.res.y - 1, 0, diff --git a/src/shared_types.h b/src/shared_types.h index 592ed8f..c7aa5ac 100644 --- a/src/shared_types.h +++ b/src/shared_types.h @@ -163,6 +163,22 @@ typedef enum KeyboardInput_e KB_MAX } KeyboardInput; +typedef enum MouseInput_e +{ + M_NONE, + M_LEFT_CLICK, + M_MIDDLE_CLICK, + M_RIGHT_CLICK, +} MouseInput; + +typedef enum GameInputType_e +{ + GI_KEYBOARD, + GI_MOUSE, + GI_MOTION, + GI_GAMEPAD, +} GameInputType; + typedef union { struct { f32 r, g; }; @@ -207,10 +223,22 @@ typedef f64 dMat2[4]; typedef f64 dMat3[9]; typedef f64 dMat4[16]; +typedef struct MouseMotionEvent_t +{ + i16 x; + i16 y; +} MouseMotionEvent; + typedef struct { - KeyboardInput code; + union + { + KeyboardInput kb_code; + MouseInput m_code; + MouseMotionEvent motion_ev; + }; b8 pressed; + GameInputType type; } GameInput; // TODO: add gamepad input typedef struct diff --git a/src/vulkan_config.c b/src/vulkan_config.c index b757ba5..a9ed456 100644 --- a/src/vulkan_config.c +++ b/src/vulkan_config.c @@ -400,26 +400,26 @@ const static VkPipelineViewportStateCreateInfo pipeline_default_viewport_info = #define INIT_PIPELINE_DEFAULTS(pipeline) \ -VkPipelineDynamicStateCreateInfo pipeline##_dynamic_info = PIPELINE_DEFAULT_DYN_STATE_INFO; \ -VkPipelineInputAssemblyStateCreateInfo pipeline##_assembly_info = PIPELINE_DEFAULT_ASSEMBLY_INFO; \ -VkPipelineRasterizationStateCreateInfo pipeline##_rasterization_info = PIPELINE_DEFAULT_RASTERIZATION_INFO; \ -VkPipelineMultisampleStateCreateInfo pipeline##_multisample_info = PIPELINE_DEFAULT_MULTISAMPLE_INFO; \ -VkPipelineDepthStencilStateCreateInfo pipeline##_depth_info = PIPELINE_DEFAULT_DEPTH_INFO; \ -VkPipelineRenderingCreateInfo pipeline##_rendering_info = PIPELINE_DEFAULT_RENDERING_INFO; \ -VkPipelineColorBlendStateCreateInfo pipeline##_blend_info = PIPELINE_DEFAULT_BLEND_INFO; \ -VkPipelineVertexInputStateCreateInfo pipeline##_vertex_info = PIPELINE_DEFAULT_VERTEX_INFO; \ -VkPipelineViewportStateCreateInfo pipeline##_viewport_info = PIPELINE_DEFAULT_VIEWPORT_INFO; \ +VkPipelineDynamicStateCreateInfo pipeline##_default_dynamic_info = PIPELINE_DEFAULT_DYN_STATE_INFO; \ +VkPipelineInputAssemblyStateCreateInfo pipeline##_default_assembly_info = PIPELINE_DEFAULT_ASSEMBLY_INFO; \ +VkPipelineRasterizationStateCreateInfo pipeline##_default_rasterization_info = PIPELINE_DEFAULT_RASTERIZATION_INFO; \ +VkPipelineMultisampleStateCreateInfo pipeline##_default_multisample_info = PIPELINE_DEFAULT_MULTISAMPLE_INFO; \ +VkPipelineDepthStencilStateCreateInfo pipeline##_default_depth_info = PIPELINE_DEFAULT_DEPTH_INFO; \ +VkPipelineRenderingCreateInfo pipeline##_default_rendering_info = PIPELINE_DEFAULT_RENDERING_INFO; \ +VkPipelineColorBlendStateCreateInfo pipeline##_default_blend_info = PIPELINE_DEFAULT_BLEND_INFO; \ +VkPipelineVertexInputStateCreateInfo pipeline##_default_vertex_info = PIPELINE_DEFAULT_VERTEX_INFO; \ +VkPipelineViewportStateCreateInfo pipeline##_default_viewport_info = PIPELINE_DEFAULT_VIEWPORT_INFO; \ VkGraphicsPipelineCreateInfo pipeline##_create_info = { \ .sType = STYPE(GRAPHICS_PIPELINE_CREATE_INFO), \ - .pNext = &pipeline##_rendering_info, \ - .pVertexInputState = &pipeline##_vertex_info, \ - .pInputAssemblyState = &pipeline##_assembly_info, \ - .pViewportState = &pipeline##_viewport_info, \ - .pRasterizationState = &pipeline##_rasterization_info,\ - .pMultisampleState = &pipeline##_multisample_info, \ - .pColorBlendState = &pipeline##_blend_info, \ - .pDepthStencilState = &pipeline##_depth_info, \ - .pDynamicState = &pipeline##_dynamic_info, \ + .pNext = &pipeline##_default_rendering_info, \ + .pVertexInputState = &pipeline##_default_vertex_info, \ + .pInputAssemblyState = &pipeline##_default_assembly_info, \ + .pViewportState = &pipeline##_default_viewport_info, \ + .pRasterizationState = &pipeline##_default_rasterization_info,\ + .pMultisampleState = &pipeline##_default_multisample_info, \ + .pColorBlendState = &pipeline##_default_blend_info, \ + .pDepthStencilState = &pipeline##_default_depth_info, \ + .pDynamicState = &pipeline##_default_dynamic_info, \ }; INIT_PIPELINE_DEFAULTS(cube); @@ -447,7 +447,14 @@ VkPipelineVertexInputStateCreateInfo gui_vertex_input_info = { .pVertexAttributeDescriptions = gui_input_descriptions, }; +VkPipelineInputAssemblyStateCreateInfo gui_assembly_info = { + .sType = STYPE(PIPELINE_INPUT_ASSEMBLY_STATE_CREATE_INFO), + .topology = VK_PRIMITIVE_TOPOLOGY_TRIANGLE_LIST, + .primitiveRestartEnable = VK_FALSE, +}; + static void CustomizePipelines() { gui_create_info.pVertexInputState = &gui_vertex_input_info; + gui_create_info.pInputAssemblyState = &gui_assembly_info; }