From a55d91c267ff63094fd71d6fd4eef30799d046d2 Mon Sep 17 00:00:00 2001 From: xolatile Date: Mon, 14 Apr 2025 19:49:49 +0200 Subject: [PATCH] EMIL ANON LNAO --- test | Bin 63264 -> 151488 bytes test.c | 146 +++++-- xachine.h | 88 ++-- xanguage.h | 68 +-- xanguage/ada.h | 4 +- xanguage/bash.h | 4 +- xanguage/c++.h | 8 +- xanguage/c.h | 11 +- xanguage/common.h | 2 +- xanguage/d.h | 6 +- xanguage/eaxhla.h | 10 +- xanguage/flat.h | 8 +- xanguage/fortran.h | 8 +- xanguage/go.h | 8 +- xanguage/haskell.h | 6 +- xanguage/holy_c.h | 50 +++ xanguage/lua.h | 8 +- xanguage/pascal.h | 4 +- xanguage/python.h | 6 +- xanguage/valgrind.h | 4 +- xaptor.c | 2 +- xaptor.h | 78 ++-- xarbon.c | 33 +- xarticle.h | 4 +- xatrix.h | 92 ++-- xcript.h | 30 +- xctree.h | 32 ++ xector.h | 94 ++--- xerminal.h | 10 +- xhallenge.c | 42 +- xhape.h | 175 ++++++++ xiasma.h | 4 +- xighlight.c | 12 +- xision.h | 997 ++++++++++++++++++++++++++++++++++++++++++++ xommon.h | 38 +- xormat.h | 66 +-- xormat/jxl.h | 2 +- xormat/ply.h | 6 + xormat/png.h | 4 +- xpengl.h | 62 +-- xphere.h | 22 +- xprite.h | 2 +- xrena.h | 4 +- xrocessor.h | 42 +- xscii.c | 4 +- xtandard.h | 99 +++-- xui.h | 116 +++--- xulkan.h | 46 +- xungeon.h | 16 +- xuxuxu.c | 8 +- xyntax.h | 4 +- 51 files changed, 1963 insertions(+), 632 deletions(-) create mode 100755 xanguage/holy_c.h create mode 100644 xctree.h create mode 100644 xhape.h create mode 100644 xision.h create mode 100644 xormat/ply.h diff --git a/test b/test index 7eae4d25f40f38ba58419fd518048020c3af974e..47544be0ce9cc3afbc7a7dd861cad37103d8a039 100755 GIT binary patch literal 151488 zcmeFadwdkt`9D4hL;`}lD6~{*-H&1oDiCfO1T};#E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krEF59R^MHcN<8bbgcS607gF1_Ko#5US~TQJo90#|4m?;^>bKHQ~4VwCIeX< z*7PBZeknhY*Hq_Mo6vDhw_5b|^Bzqfr3P*~bh;XP5&?7m_45-=@%Sy_u$F%Z>+AXx zjV#Wz(QvH7t?BOpOzCTV{hUlw`t2_BVNL&KFwOd{%}QF+?BQnZc>QbiAOcttm3@dX zy}x(s&nVVgUi)3s7-TZ>&)weGPrU65>c0t_Tx{0QTYx1 zXGltj=+6}$r-*UZ`kHnqfB{*?-MnIH;kziW7W z68$dLzs^#AovzlGZx8B-iMpRwk#ATOEKxB#N&5fXsq|m8C|IK6Qr5TnZ)a5LZ#61L z#kIbsw9lHtR((HpY#g+|+rT_o{ diff --git a/test.c b/test.c index 8b241cb..b18b2f4 100644 --- a/test.c +++ b/test.c @@ -1,39 +1,86 @@ +#define use_fatal_failure #define use_mathematics +#define use_png_library #include "xtandard.h" #include "xector.h" +#include "xormat.h" #include "xarticle.h" +#include "xhape.h" +#include "xision.h" -#include +static void print_shape (shape_node * sh) { + print ("shape data:\n"); + print ("v = %i // %i\n", sh->vertex_count, sh->vertex_limit); + print ("i = %i // %i\n", sh->index_count, sh->index_limit); +} -int main (void) { - particle_structure * particle = particle_initialize (1024); +static void render_shape (vision_structure * vision, shape_node * sh) { + //~uint vc = sh->vertex_count; + //~uint ic = sh->index_count; - InitWindow (800, 600, "Xarticle"); + //~float va [100] = { 0 }; + //~uint ia [100] = { 0 }; - Camera camera = { 0 }; - camera.position = (Vector3){ 0.0f, 2.0f, 4.0f }; // Camera position - camera.target = (Vector3){ 0.0f, 2.0f, 0.0f }; // Camera looking at point - camera.up = (Vector3){ 0.0f, 1.0f, 0.0f }; // Camera up vector (rotation towards target) - camera.fovy = 60.0f; // Camera field-of-view Y - camera.projection = CAMERA_PERSPECTIVE; // Camera projection type + //~for (uint i = 0; i < vc; i += 5) { + //~va [i+0] = sh->vertex_array [i/5]->x; + //~va [i+1] = sh->vertex_array [i/5]->y; + //~va [i+2] = sh->vertex_array [i/5]->z; + //~va [i+3] = sh->unwrap_array [i/5]->x; + //~va [i+4] = sh->unwrap_array [i/5]->y; + //~} + + //~for (uint i = 0; i < ic; i += 5) { + //~ia [i] = sh->index_array [i]; + //~} + + vision_render_base (vision, sh->vertex_count, sh->vertex_array, sh->index_count, sh->index_array, 0, 0xff7733ff); +} - SetTargetFPS(60); +int main (void) { + //~vector_3 as = { +2,0,0 }; + //~vector_3 bs = { -2,0,0 }; + //~vector_3 cs = { 0,+2,0 }; + //~vector_3 ds = { 0,-2,0 }; + //~vector_3 es = { 0,0,+2 }; + //~vector_3 fs = { 0,0,-2 }; + + shape_node * a = shape_tetrahedron_colour (+2,0,0, 1, 0xff7733ff); + shape_node * b = shape_tetrahedron_colour (-2,0,0, 1, 0xff7733ff); + shape_node * c = shape_tetrahedron_colour (0,+2,0, 1, 0xff7733ff); + shape_node * d = shape_tetrahedron_colour (0,-2,0, 1, 0xff7733ff); + shape_node * e = shape_tetrahedron_colour (0,0,+2, 1, 0xff7733ff); + shape_node * f = shape_tetrahedron_colour (0,0,-2, 1, 0xff7733ff); + + //~print ("> v = %i // %i\n", a->vertex_count, a->vertex_limit); + //~print ("> i = %i // %i\n", a->index_count, a->index_limit); + print_shape (a); + + vision_structure * vision = vision_initialize (60, 60, false, 6000, 3000, 256); + particle_structure * particle = particle_initialize (1024); - Texture texture = LoadTexture ("xui/fullscreen_on.png"); + uint i0 = vision_sprite_import (vision, "xui/goblin/end_turn_button.png"); + uint i1 = vision_sprite_import (vision, "xui/goblin/separator_center.png"); + uint i2 = vision_sprite_import (vision, "xui/goblin/separator_left.png"); + uint i3 = vision_sprite_import (vision, "xui/goblin/separator_middle.png"); + uint i4 = vision_sprite_import (vision, "xui/goblin/separator_right.png"); - while (! WindowShouldClose ()) { - UpdateCamera(& camera, CAMERA_FIRST_PERSON); + vision_configure (vision, 800, 600, "Xube"); - BeginDrawing (); + while (vision->active == true) { + if (vision->signal [signal_q] == true) break; - ClearBackground(RAYWHITE); + if (vision->signal [signal_i] == true) { vision_change_field_of_view (vision, + 0.1f); } + if (vision->signal [signal_o] == true) { vision_change_field_of_view (vision, - 0.1f); } - BeginMode3D(camera); + if (vision->signal [signal_a] == true) { vision_change_translation (vision, + 0.1f, 0.0f, 0.0f); } + if (vision->signal [signal_d] == true) { vision_change_translation (vision, - 0.1f, 0.0f, 0.0f); } + if (vision->signal [signal_s] == true) { vision_change_translation (vision, 0.0f, 0.0f, + 0.1f); } + if (vision->signal [signal_w] == true) { vision_change_translation (vision, 0.0f, 0.0f, - 0.1f); } - DrawPlane((Vector3){ 0.0f, 0.0f, 0.0f }, (Vector2){ 32.0f, 32.0f }, LIGHTGRAY); // Draw ground + //~vision_change_rotation (vision, 0.0f, xxx); - if (IsKeyPressed (KEY_ONE)) { + if (vision->signal [signal_1] == true) { vector_3 p = {0,0,0}; vector_3 t = {0,0,0}; vector_3 s = {0.1f,0.1f,0.1f}; @@ -41,39 +88,76 @@ int main (void) { particle_append (particle, 0, 1.0f, 0, 0, & p, & t, & s); } - if (IsKeyPressed (KEY_TWO)) { + if (vision->signal [signal_2] == true) { vector_3 p = {1,1,1}; particle_effect_splash (particle, 0, 2.0f, 0, 0, & p, 60, 0.03, 3); } - if (IsKeyPressed (KEY_THREE)) { + if (vision->signal [signal_3] == true) { vector_3 p = {1,1,1}; particle_effect_evaporate (particle, 0, 2.0f, 0, 0, & p, 20, 0.001, 3); } - BeginBlendMode (BLEND_ALPHA_PREMULTIPLY); + render_shape (vision, a); + render_shape (vision, b); + render_shape (vision, c); + render_shape (vision, d); + render_shape (vision, e); + render_shape (vision, f); + + //~float t0 [] = {1,0,0,0,0,1,0,1,0}; + //~float t1 [] = {1,0,0,0,0,1,0,1,0}; + //~float t2 [] = {1,0,0,0,0,1,0,1,0}; + //~float t3 [] = {1,0,0,0,0,1,0,1,0}; + //~float t4 [] = {1,0,0,0,0,1,0,1,0}; + //~float t5 [] = {1,0,0,0,0,1,0,1,0}; + + //~vision_render_triangle (vision, t0, 0xff7733ff); + //~vision_render_triangle (vision, t1, 0xff7733ff); + //~vision_render_triangle (vision, t2, 0xff7733ff); + //~vision_render_triangle (vision, t3, 0xff7733ff); + //~vision_render_triangle (vision, t4, 0xff7733ff); + //~vision_render_triangle (vision, t5, 0xff7733ff); + + //~for (uint i = 0; i < particle->count; ++i) { + //~Vector3 vector = {particle->position [i]->x, particle->position [i]->y, particle->position [i]->z}; + //~DrawBillboard (camera, texture, vector, 1, RED); + //~} + + + + + + + //~float va [] = { + //~-1, -1, 0, 0, 1, 1, 1, 1, 1, + //~-1, +1, 0, 0, 0, 1, 1, 1, 1, + //~+1, +1, 0, 1, 0, 1, 1, 1, 1, + //~+1, -1, 0, 1, 1, 1, 1, 1, 1 + //~}; + + //~uint ia [] = { 2, 1, 0, 3, 2, 1 }; + + //~vision_render_base (vision, sizeof(va)/4, va, sizeof(ia)/4, ia, 1, 0xff7733ff); + + + - for (uint i = 0; i < particle->count; ++i) { - Vector3 vector = {particle->position [i]->x, particle->position [i]->y, particle->position [i]->z}; - DrawBillboard (camera, texture, vector, 1, RED); - } - EndBlendMode (); - EndMode3D(); - DrawText (TextFormat ("count = %i", particle->count), 0, 0, 4, RED); - EndDrawing (); + vision_synchronize (vision, 0xff); particle_synchronize (particle, 60); } - CloseWindow (); + png_image_export ("meme.png", vision->spritesheet_data, 256, 256); particle = particle_deinitialize (particle); + vision = vision_deinitialize (vision); return (0); } diff --git a/xachine.h b/xachine.h index aaed02a..7f343a2 100755 --- a/xachine.h +++ b/xachine.h @@ -45,11 +45,11 @@ typedef enum { #ifdef use_debug_printing -static const char * operand_name [operand_count] = { +static char * operand_name [operand_count] = { "rel", "reg", "mem", "imm" }; -static const char * operation_name [operation_count] = { +static char * operation_name [operation_count] = { "asmmem", "asmrel", "asmnum", "asmstr", "add", "or", "adc", "sbb", "and", "sub", "xor", "cmp", "inc", "dec", "not", "neg", "mul", "imul", "div", "idiv", @@ -159,8 +159,8 @@ static uint m05 (uint code) { return (0x05 + 0x08 * code); } -static uint store_relative (const uint * array) { - const uint relative = array [1]; +static uint store_relative (uint * array) { + uint relative = array [1]; #ifdef use_debug_printing print ("/3asmrel/- %i", relative); #endif @@ -172,8 +172,8 @@ static uint store_relative (const uint * array) { return 1; } -static uint store_memory (const uint * array) { - const uint memory = array [1]; +static uint store_memory (uint * array) { + uint memory = array [1]; #ifdef use_debug_printing print ("/3asmmem/- %i", memory); #endif @@ -184,8 +184,8 @@ static uint store_memory (const uint * array) { return 1; } -static uint store_number (const uint * array) { - const uint amount = array [1]; +static uint store_number (uint * array) { + uint amount = array [1]; #ifdef use_debug_printing print ("/3asmnum/- %i", amount); @@ -197,8 +197,8 @@ static uint store_number (const uint * array) { return amount + 1; } -static uint store_string (const uint * array) { - const uint amount = array [1]; +static uint store_string (uint * array) { + uint amount = array [1]; #ifdef use_debug_printing print ("/3asmstr/- %i", amount); @@ -210,12 +210,12 @@ static uint store_string (const uint * array) { return amount + 1; } -static uint build_double (const uint * array) { - const uint operation = array [0]; - const uint to = array [1]; - const uint destination = array [2]; - const uint from = array [3]; - const uint source = array [4]; +static uint build_double (uint * array) { + uint operation = array [0]; + uint to = array [1]; + uint destination = array [2]; + uint from = array [3]; + uint source = array [4]; #ifdef use_debug_printing print ("/3%s/- /6%s/- %i /6%s/- %i", operation_name [operation], operand_name [to], destination, operand_name [from], source); #endif @@ -248,10 +248,10 @@ static uint build_double (const uint * array) { return 4; } -static uint build_single (const uint * array) { - const uint operation = array [0]; - const uint to = array [1]; - const uint destination = array [2]; +static uint build_single (uint * array) { + uint operation = array [0]; + uint to = array [1]; + uint destination = array [2]; #ifdef use_debug_printing print ("/3%s/- /6%s/- %i", operation_name [operation], operand_name [to], destination); #endif @@ -264,11 +264,11 @@ static uint build_single (const uint * array) { return 2; } -static uint build_shift (const uint * array) { - const uint operation = array [0]; - const uint to = array [1]; - const uint destination = array [2]; - const uint offset = array [3]; +static uint build_shift (uint * array) { + uint operation = array [0]; + uint to = array [1]; + uint destination = array [2]; + uint offset = array [3]; #ifdef use_debug_printing print ("/3%s/- /6%s/- %i /cimm/- %i", operation_name [operation], operand_name [to], destination, offset); #endif @@ -284,8 +284,8 @@ static uint build_shift (const uint * array) { return 3; } -static uint build_static_1 (const uint * array) { - const uint operation = array [0]; +static uint build_static_1 (uint * array) { + uint operation = array [0]; #ifdef use_debug_printing print ("/3%s/-", operation_name [operation]); #endif @@ -299,9 +299,9 @@ static uint build_static_1 (const uint * array) { return 0; } -static uint build_jump_if (const uint * array) { - const uint operation = array [0]; - const uint location = array [1]; +static uint build_jump_if (uint * array) { + uint operation = array [0]; + uint location = array [1]; #ifdef use_debug_printing print ("/3%s/- %i", operation_name [operation], location); #endif @@ -313,9 +313,9 @@ static uint build_jump_if (const uint * array) { return 2; } -static uint build_jump (const uint * array) { - const uint to = array [1]; - const uint destination = array [2]; +static uint build_jump (uint * array) { + uint to = array [1]; + uint destination = array [2]; #ifdef use_debug_printing print ("/3jmp/- /6%s/- %i", operand_name [to], destination); #endif @@ -328,11 +328,11 @@ static uint build_jump (const uint * array) { return 2; } -static uint build_move (const uint * array) { - const uint to = array [1]; - const uint destination = array [2]; - const uint from = array [3]; - const uint source = array [4]; +static uint build_move (uint * array) { + uint to = array [1]; + uint destination = array [2]; + uint from = array [3]; + uint source = array [4]; #ifdef use_debug_printing print ("/3mov/- /6%s/- %i /6%s/- %i", operand_name [to], destination, operand_name [from], source); #endif @@ -359,9 +359,9 @@ static uint build_move (const uint * array) { return 4; } -static uint build_call (const uint * array) { - const uint from = array [1]; - const uint source = array [2]; +static uint build_call (uint * array) { + uint from = array [1]; + uint source = array [2]; #ifdef use_debug_printing print ("/3call/- /6%s/- %i", operand_name [from], source); #endif @@ -374,7 +374,7 @@ static uint build_call (const uint * array) { return 2; } -static uint (* build_instruction [operation_count]) (const uint * array) = { +static uint (* build_instruction [operation_count]) (uint * array) = { store_memory, // operation_memory : LABEL store_relative, // operation_relative : "IMPLEMENTED" store_number, @@ -387,7 +387,7 @@ static uint (* build_instruction [operation_count]) (const uint * array) = { build_static_1, build_static_1, build_static_1, build_call, build_jump, build_move }; -static void assemble (uint count, const uint * array, uint external_memory, uint internal_memory) { +static void assemble (uint count, uint * array, uint external_memory, uint internal_memory) { text_sector_byte = arena_add (external_memory * sizeof (* text_sector_byte)); data_sector_byte = arena_add (external_memory * sizeof (* text_sector_byte)); @@ -396,7 +396,7 @@ static void assemble (uint count, const uint * array, uint external_memory, uint empty_store = arena_add (internal_memory * sizeof (* empty_store)); for (uint index = 0; index < count; ++index) { - const uint size = text_sector_size; + uint size = text_sector_size; uchar byte = 0; #ifdef use_debug_nopping diff --git a/xanguage.h b/xanguage.h index 3efd312..12b2a86 100755 --- a/xanguage.h +++ b/xanguage.h @@ -72,6 +72,27 @@ typedef struct { #include #include +static void (* language_highlighter [language_count]) (language_structure * language, syntax_structure * syntax) = { + language_highlight_common, language_highlight_ada, language_highlight_c, language_highlight_cpp, + language_highlight_d, language_highlight_eaxhla, language_highlight_flat, language_highlight_fortran, + language_highlight_pascal, language_highlight_python, language_highlight_go, language_highlight_lua, + language_highlight_bash, language_highlight_haskell, language_highlight_valgrind +}; + +static char * language_short_option [language_count] = { + "-X", "-A", "-C", "-S", "-D", "-E", "-T", "-F", "-P", "-Y", "-G", "-L", "-B", "-H", "-V" +}; + +static char * language_long_option [language_count] = { + "--common", "--ada", "--c", "--cpp", "--d", "--eaxhla", "--flat", "--fortran", + "--pascal", "--python", "--go", "--lua", "--bash", "--haskell", "--valgrind" +}; + +static char * language_identifier [language_count] = { + "Common", "Ada", "C", "C++", "D", "EAXHLA", "Flat", "Fortran", + "Pascal", "Python", "Go", "Lua", "Bash", "Haskell", "Valgrind" +}; + static language_structure * language_initialize (bool true_colour) { language_structure * language = allocate (sizeof (* language)); @@ -131,52 +152,7 @@ static language_structure * language_deinitialize (language_structure * language return (deallocate (language)); } -static void (* language_highlighter (language_enumeration language)) (language_structure * language, syntax_structure * syntax) { - static const void (* highlighter [language_count]) (language_structure * language, syntax_structure * syntax) = { - language_highlight_common, language_highlight_ada, language_highlight_c, language_highlight_cpp, - language_highlight_d, language_highlight_eaxhla, language_highlight_flat, language_highlight_fortran, - language_highlight_pascal, language_highlight_python, language_highlight_go, language_highlight_lua, - language_highlight_bash, language_highlight_haskell, language_highlight_valgrind - }; - - fatal_failure (language >= language_count, "language_highlighter: Language index not in enumeration."); - - return (highlighter [language]); -} - -static char * language_short_option (language_enumeration language) { - static const char * short_option [language_count] = { - "-X", "-A", "-C", "-S", "-D", "-E", "-T", "-F", "-P", "-Y", "-G", "-L", "-B", "-H", "-V" - }; - - fatal_failure (language >= language_count, "language_short_option: Language index not in enumeration."); - - return (short_option [language]); -} - -static char * language_long_option (language_enumeration language) { - static const char * long_option [language_count] = { - "--common", "--ada", "--c", "--cpp", "--d", "--eaxhla", "--flat", "--fortran", - "--pascal", "--python", "--go", "--lua", "--bash", "--haskell", "--valgrind" - }; - - fatal_failure (language >= language_count, "language_long_option: Language index not in enumeration."); - - return (long_option [language]); -} - -static char * language_identifier (language_enumeration language) { - static const char * identifier [language_count] = { - "Common", "Ada", "C", "C++", "D", "EAXHLA", "Flat", "Fortran", - "Pascal", "Python", "Go", "Lua", "Bash", "Haskell", "Valgrind" - }; - - fatal_failure (language >= language_count, "language_identifier: Language index not in enumeration."); - - return (identifier [language]); -} - -static void language_conditionally_select (language_structure * language, syntax_structure * syntax, uint select) { +static void language_conditionally_select (language_structure * language, syntax_structure * syntax, language_enumeration select) { if (syntax->count == 0) { if ((select == file_type_c_source) || (select == file_type_c_header)) { language_highlight_c (language, syntax); diff --git a/xanguage/ada.h b/xanguage/ada.h index 0e453b1..8773e5e 100755 --- a/xanguage/ada.h +++ b/xanguage/ada.h @@ -1,7 +1,7 @@ static void language_highlight_ada (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,:;<=>+-*/&|()\" \t\r\n"; + char * separators = ".,:;<=>+-*/&|()\" \t\r\n"; - const char * keywords [] = { + char * keywords [] = { "abort", "else", "new", "return", "abs", "elsif", "not", "reverse", "abstract", "end", "null", "accept", "entry", "select", "access", "of", "separate", "aliased", "exit", "or", "some", "all", "others", "subtype", diff --git a/xanguage/bash.h b/xanguage/bash.h index 351c2f3..7a3b058 100755 --- a/xanguage/bash.h +++ b/xanguage/bash.h @@ -1,7 +1,7 @@ static void language_highlight_bash (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,:;<=>+-*/%!&~^?|@#$()[]{}'\" \t\r\n"; + char * separators = ".,:;<=>+-*/%!&~^?|@#$()[]{}'\" \t\r\n"; - const char * keywords [] = { + char * keywords [] = { "exit", "set", "elif", "done", "in", "then", "function", "fi", "if", "else", "do", "while", "for" }; diff --git a/xanguage/c++.h b/xanguage/c++.h index 131176d..b68df96 100755 --- a/xanguage/c++.h +++ b/xanguage/c++.h @@ -1,7 +1,7 @@ static void language_highlight_cpp (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,:;<=>+-*/%!&~^?|()[]{}'\" \t\r\n"; + char * separators = ".,:;<=>+-*/%!&~^?|()[]{}'\" \t\r\n"; - const char * keywords [] = { + char * keywords [] = { "alignas", "alignof", "and", "asm", "auto", "break", "case", "catch", "class", "compl", "concept", "const", "consteval", "constexpr", "constinit", "continue", "decltype", "default", "delete", "do", "else", @@ -14,14 +14,14 @@ static void language_highlight_cpp (language_structure * language, syntax_struct "volatile", "while", "xor", "final", "override", "import", "module" }; - const char * types [] = { + char * types [] = { "void", "bool", "off_t", "va_list", "float", "double", "float_t", "double_t", "char", "short", "int", "long", "uchar", "ushort", "uint", "ulong", "int8_t", "int16_t", "int32_t", "int64_t", "uint8_t", "uint16_t", "uint32_t", "uint64_t", "signed", "unsigned", "size_t", "ssize_t" }; - const char * commons [] = { + char * commons [] = { "std", "FILE", "DIR", "EOF", "va_arg", "va_start", "va_end", "va_copy" }; diff --git a/xanguage/c.h b/xanguage/c.h index 8005724..7012ceb 100755 --- a/xanguage/c.h +++ b/xanguage/c.h @@ -1,24 +1,25 @@ static void language_highlight_c (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,:;<=>+-*/%!&~^?|()[]{}'\" \t\r\n"; + char * separators = ".,:;<=>+-*/%!&~^?|()[]{}'\" \t\r\n"; - const char * keywords [] = { + char * keywords [] = { "register", "volatile", "auto", "const", "static", "extern", "if", "else", "do", "while", "for", "continue", "switch", "case", "default", "break", "enum", "union", "struct", "typedef", "goto", "return", "sizeof", "inline", "restrict", "true", "false" }; - const char * types [] = { + char * types [] = { "void", "bool", "off_t", "va_list", "float", "double", "float_t", "double_t", "char", "short", "int", "long", "uchar", "ushort", "uint", "ulong", "int8_t", "int16_t", "int32_t", "int64_t", "uint8_t", "uint16_t", "uint32_t", "uint64_t", "signed", "unsigned", "size_t", "ssize_t" }; - const char * commons [] = { + char * commons [] = { "null", "NULL", "FILE", "DIR", "va_arg", "va_start", "va_end", "va_copy", "alignas", "alignof", "offsetof", "typeof", "EOF", "ABS", "MIN", "MAX", - "ARRAYSIZE", "SWAP", "UNUSED", "UNREACHABLE", "STRINGIFY", "CONCAT", "assert", "static_assert" + "ARRAYSIZE", "SWAP", "UNUSED", "UNREACHABLE", "STRINGIFY", "CONCAT", "assert", "static_assert", + "thread_local", "nullptr" }; syntax_define (syntax, false, false, "/*", "*/", '\0', language->comment_colour, language->comment_effect); diff --git a/xanguage/common.h b/xanguage/common.h index 652b10b..2ccd03d 100755 --- a/xanguage/common.h +++ b/xanguage/common.h @@ -1,5 +1,5 @@ static void language_highlight_common (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,:;<=>+*-/%!&~^?|()[]{}'\"@#$` \t\r\n"; + char * separators = ".,:;<=>+*-/%!&~^?|()[]{}'\"@#$` \t\r\n"; syntax_define (syntax, false, false, "'", "'", '\\', language->character_colour, language->character_effect); syntax_define (syntax, false, false, "\"", "\"", '\\', language->string_colour, language->string_effect); diff --git a/xanguage/d.h b/xanguage/d.h index d5a043a..592edcf 100755 --- a/xanguage/d.h +++ b/xanguage/d.h @@ -1,7 +1,7 @@ static void language_highlight_d (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,:;<=>+-*/%!&~^?|@()[]{}'\"` \t\r\n"; + char * separators = ".,:;<=>+-*/%!&~^?|@()[]{}'\"` \t\r\n"; - const char * keywords [] = { + char * keywords [] = { "abstract", "alias", "align", "asm", "assert", "auto", "body", "bool", "break", "byte", "case", "cast", "catch", "cdouble", "cent", "cfloat", "char", "class", "const", "continue", "creal", "dchar", "debug", "default", @@ -17,7 +17,7 @@ static void language_highlight_d (language_structure * language, syntax_structur "void", "wchar", "while", "foreach_reverse" }; - const char * types [] = { + char * types [] = { "byte", "ubyte", "short", "ushort", "int", "uint", "long", "ulong", "cent", "ucent", "char", "wchar", "dchar", "float", "double", "real", "ifloat", "idouble", "ireal", "cfloat", "cdouble", "creal", "void", "bool", diff --git a/xanguage/eaxhla.h b/xanguage/eaxhla.h index ca99f20..b24065f 100755 --- a/xanguage/eaxhla.h +++ b/xanguage/eaxhla.h @@ -1,19 +1,19 @@ static void language_highlight_eaxhla (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,+-*/[]<>=; \t\r\n"; + char * separators = ".,+-*/[]<>=; \t\r\n"; - const char * declarations [] = { + char * declarations [] = { "program", "procedure", "machine", "library", "fast", "unix", "begin", "end", "if", "then", "else", "repeat", "break", "continue", "until", "exit", "fastcall", "shell", "alias", "macro", "scope", "unscope", "use", "include" }; - const char * types [] = { + char * types [] = { "s8", "s16", "s32", "s64", "u8", "u16", "u32", "u64", "f32", "f64", "f80", "v0", "s128", "u128", "s256", "u256", "s512", "u512" }; - const char * instructions [] = { + char * instructions [] = { "jnpe", "jpo", "jnpo", "jpe", "jnb", "jae", "jnbe", "ja", "jna", "jbe", "jnae", "jb", "jnl", "jge", "jnle", "jg", "jng", "jle", "jnge", "jl", "cmovng", "cmovle", "cmovnge", "cmovl", @@ -34,7 +34,7 @@ static void language_highlight_eaxhla (language_structure * language, syntax_str "bswap", "bsf", "bsr", "loop", "loope", "loopne" }; - const char * registers [] = { + char * registers [] = { "rax", "rcx", "rdx", "rbx", "rsp", "rbp", "rsi", "rdi", "r8", "r9", "r10", "r11", "r12", "r13", "r14", "r15", "eax", "ecx", "edx", "ebx", "esp", "ebp", "esi", "edi", diff --git a/xanguage/flat.h b/xanguage/flat.h index eabf301..5fb123e 100755 --- a/xanguage/flat.h +++ b/xanguage/flat.h @@ -1,12 +1,12 @@ static void language_highlight_flat (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,+-=:;(){}[]%$<> \t\r\n"; + char * separators = ".,+-=:;(){}[]%$<> \t\r\n"; - const char * declarations [] = { + char * declarations [] = { "format", "executable", "readable", "writable", "segment", "sector", "entry", "macro", "db", "dw", "dd", "dq", "rb", "rw", "rd", "rq" }; - const char * instructions [] = { + char * instructions [] = { "mov", "movabs", "movapd", "movaps", "movebe", "movsd", "movsx", "movzx", "movsxd", "movd", "movq", "movs", "movsb", "movsw", "movsd", "movsq", "cmovmp", "cmovrcxz", "cmovc", "cmovnc", "cmove", "cmovne", "cmovz", "cmovnz", @@ -26,7 +26,7 @@ static void language_highlight_flat (language_structure * language, syntax_struc "rep", "repe", "repz", "repne", "repnz", "loop", "loope", "loopne" }; - const char * registers [] = { + char * registers [] = { "rax", "rcx", "rdx", "rbx", "rsp", "rbp", "rsi", "rdi", "r8", "r9", "r10", "r11", "r12", "r13", "r14", "r15", "eax", "ecx", "edx", "ebx", "esp", "ebp", "esi", "edi", diff --git a/xanguage/fortran.h b/xanguage/fortran.h index e24923a..45443ae 100755 --- a/xanguage/fortran.h +++ b/xanguage/fortran.h @@ -1,7 +1,7 @@ static void language_highlight_fortran (language_structure * language, syntax_structure * syntax) { - const char * separators = ",:<=>+-*/&()[]\"\' \t\r\n"; + char * separators = ",:<=>+-*/&()[]\"\' \t\r\n"; - const char * keywords [] = { + char * keywords [] = { "allocatable", "allocate", "associate", "backspace", "block", "call", "case", "common", "contains", "cycle", "data", "deallocate", "d0", "do", "else", "elseif", "end", "enddo", "endfile", "endif", "entry", "equivalence", "exit", "external", @@ -12,11 +12,11 @@ static void language_highlight_fortran (language_structure * language, syntax_st "then", "to", "type", "use", "where", "write" }; - const char * types [] = { + char * types [] = { "character", "integer", "logical", "real", "complex" }; - const char * subkeywords [] = { + char * subkeywords [] = { ".and.", ".or.", ".not.", ".true.", ".false.", "in", "out", "len", "dimension", "modulo", "advance" }; diff --git a/xanguage/go.h b/xanguage/go.h index 38919e8..c2cf3d7 100755 --- a/xanguage/go.h +++ b/xanguage/go.h @@ -1,20 +1,20 @@ static void language_highlight_go (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,:;<=>+-*/%!&~^?|()[]{}'\"` \t\r\n"; + char * separators = ".,:;<=>+-*/%!&~^?|()[]{}'\"` \t\r\n"; - const char * keywords [] = { + char * keywords [] = { "break", "default", "func", "interface", "select", "case", "defer", "go", "struct", "else", "goto", "package", "switch", "const", "var", "for", "fallthrough", "if", "range", "type", "continue", "import", "return" }; - const char * types [] = { + char * types [] = { "map", "uint", "int", "uintptr", "uint8", "uint16", "uint32", "uint64", "int8", "int16", "int32", "int64", "float32", "float64", "complex64", "complex128", "byte", "rune", "string", "chan", "bool" }; - const char * commons [] = { + char * commons [] = { "true", "false", "nil", "err" }; diff --git a/xanguage/haskell.h b/xanguage/haskell.h index 5766d29..a2c1409 100755 --- a/xanguage/haskell.h +++ b/xanguage/haskell.h @@ -1,13 +1,13 @@ static void language_highlight_haskell (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,:;<=>+-*/%!@#$&~^?|()[]{}'\" \t\r\n"; + char * separators = ".,:;<=>+-*/%!@#$&~^?|()[]{}'\" \t\r\n"; - const char * keywords [] = { + char * keywords [] = { "case", "class", "data", "deriving", "do", "else", "if", "import", "in", "infix", "infixl", "infixr", "instance", "let", "of", "module", "newtype", "then", "type", "where" }; - const char * types [] = { + char * types [] = { "Int", "Integer", "String", "Char", "Float", "Boolean" }; diff --git a/xanguage/holy_c.h b/xanguage/holy_c.h new file mode 100755 index 0000000..3041453 --- /dev/null +++ b/xanguage/holy_c.h @@ -0,0 +1,50 @@ +static void language_highlight_holy_c (language_structure * language, syntax_structure * syntax) { + char * separators = ".,:;<=>+-*/%!&~^?|()[]{}'\" \t\r\n"; +///////////// DOES NOT FUCKING WORK YET + char * keywords [] = { + "auto", "extern", "if", "else", + "do", "while", "for", "switch", "case", "default", "break", + "enum", "union", "struct", "typedef", "goto", "return", "sizeof", "inline", + "restrict", "true", "false" + }; + + char * types [] = { + "void", "bool", "off_t", "va_list", "float", "double", "float_t", "double_t", + "char", "short", "int", "long", "uchar", "ushort", "uint", "ulong", + "int8_t", "int16_t", "int32_t", "int64_t", "uint8_t", "uint16_t", "uint32_t", "uint64_t", + "signed", "unsigned", "size_t", "ssize_t" + }; + + char * commons [] = { + "null", "NULL", "FILE", "DIR", "va_arg", "va_start", "va_end", "va_copy", + "alignas", "alignof", "offsetof", "typeof", "EOF", "ABS", "MIN", "MAX", + "ARRAYSIZE", "SWAP", "UNUSED", "UNREACHABLE", "STRINGIFY", "CONCAT", "assert", "static_assert", + "thread_local", "nullptr" + }; + + syntax_define (syntax, false, false, "/*", "*/", '\0', language->comment_colour, language->comment_effect); + syntax_define (syntax, false, false, "//", "\n", '\0', language->comment_colour, language->comment_effect); + syntax_define (syntax, false, false, "#", "\n", '\\', language->processor_colour, language->processor_effect); + syntax_define (syntax, false, false, "'", "'", '\\', language->character_colour, language->character_effect); + syntax_define (syntax, false, false, "\"", "\"", '\\', language->string_colour, language->string_effect); + + for (ulong word = 0; word < array_length (keywords); ++word) { + syntax_define (syntax, false, true, keywords [word], separators, '\0', language->keyword_colour, language->keyword_effect); + } + + for (ulong word = 0; word < array_length (types); ++word) { + syntax_define (syntax, false, true, types [word], separators, '\0', language->type_colour, language->type_effect); + } + + for (ulong word = 0; word < array_length (commons); ++word) { + syntax_define (syntax, false, true, commons [word], separators, '\0', language->extension_colour, language->extension_effect); + } + + syntax_define (syntax, true, false, "()[]{}", "", '\0', language->bracket_colour, language->bracket_effect); + syntax_define (syntax, true, false, ".,:;<=>+*-/%!&~^?|", "", '\0', language->operator_colour, language->operator_effect); + + syntax_define (syntax, true, true, "0123456789", separators, '\0', language->number_colour, language->number_effect); + syntax_define (syntax, true, true, "abcdefghijklmnopqrstuvwxyz", separators, '\0', language->lowercase_colour, language->lowercase_effect); + syntax_define (syntax, true, true, "ABCDEFGHIJKLMNOPQRSTUVWXYZ", separators, '\0', language->uppercase_colour, language->uppercase_effect); + syntax_define (syntax, true, true, "_", separators, '\0', language->underscore_colour, language->underscore_effect); +} diff --git a/xanguage/lua.h b/xanguage/lua.h index 1509e86..bceb0fc 100755 --- a/xanguage/lua.h +++ b/xanguage/lua.h @@ -1,17 +1,17 @@ static void language_highlight_lua (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,:;<=>+-*/%~^#|()[]{}'\" \t\r\n"; + char * separators = ".,:;<=>+-*/%~^#|()[]{}'\" \t\r\n"; - const char * keywords [] = { + char * keywords [] = { "and", "break", "do", "else", "elseif", "end", "false", "for", "function", "if", "in", "local", "nil", "not", "or", "until", "repeat", "return", "then", "true", "while" }; - const char * types [] = { + char * types [] = { "boolean", "number", "string", "userdata", "function", "thread", "table" }; - const char * commons [] = { + char * commons [] = { "require", "print", "seek", "dofile", "loadfile", "assert", "rawset", "rawget", "setfenv", "pairs", "ipairs", "tonumber", "tostring", "foreach", "setn", "getn", "insert", "concat", "sort", "remove", "abs", "ceil", "floor", "log10", diff --git a/xanguage/pascal.h b/xanguage/pascal.h index 21bac25..df95763 100755 --- a/xanguage/pascal.h +++ b/xanguage/pascal.h @@ -1,7 +1,7 @@ static void language_highlight_pascal (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,:;<=>+-*/&@#$%^()[] \t\r\n"; + char * separators = ".,:;<=>+-*/&@#$%^()[] \t\r\n"; - const char * keywords [] = { + char * keywords [] = { "absolute", "and", "array", "asm", "begin", "case", "const", "constructor", "destructor", "div", "do", "downto", "else", "end", "file", "for", "function", "goto", "if", "in", "inherited", "inline", "interface", "xor", diff --git a/xanguage/python.h b/xanguage/python.h index ccd8dcd..dfea821 100755 --- a/xanguage/python.h +++ b/xanguage/python.h @@ -1,7 +1,7 @@ static void language_highlight_python (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,:;<=>+-*/%!&~^?|()[]{}'\" \t\r\n"; + char * separators = ".,:;<=>+-*/%!&~^?|()[]{}'\" \t\r\n"; - const char * keywords [] = { + char * keywords [] = { "and", "as", "assert", "break", "class", "continue", "def", "del", "elif", "else", "except", "False", "finally", "for", "from", "global", "if", "import", "in", "is", "labmda", "None", "nonlocal", "not", @@ -9,7 +9,7 @@ static void language_highlight_python (language_structure * language, syntax_str "yield", "async", "await" }; - const char * subkeywords [] = { + char * subkeywords [] = { "abs", "all", "any", "apply", "ascii", "basestring", "bin", "bool", "breakpoint", "buffer", "bytearray", "bytes", "callable", "chr", "classmethod", "cmp", "coerce", "compile", "complex", "copyright", "credits", "delattr", "dict", "dir", diff --git a/xanguage/valgrind.h b/xanguage/valgrind.h index 411f580..7cfb9cd 100755 --- a/xanguage/valgrind.h +++ b/xanguage/valgrind.h @@ -1,7 +1,7 @@ static void language_highlight_valgrind (language_structure * language, syntax_structure * syntax) { - const char * separators = ".,:;<=>+-*/%!&~^?|@#$()[]{}'\" \t\r\n"; + char * separators = ".,:;<=>+-*/%!&~^?|@#$()[]{}'\" \t\r\n"; - const char * titles [] = { + char * titles [] = { //~"exit", "set", "elif", "done", "in", "then", "function", "fi", "HEAP", "LEAK", "ERROR", "SUMMARY" }; diff --git a/xaptor.c b/xaptor.c index cf59554..321db38 100644 --- a/xaptor.c +++ b/xaptor.c @@ -17,7 +17,7 @@ int main (void) { cross_configure (cross, 640, 480, "Xaptor - File Manager"); while (cross->active == true) { - const uint offset = 48; + uint offset = 48; cross_synchronize (cross, 0x00000000); diff --git a/xaptor.h b/xaptor.h index 8567acf..5315144 100644 --- a/xaptor.h +++ b/xaptor.h @@ -125,7 +125,7 @@ static uint raptor_font_raw_import (raptor_structure * raptor, uint * data, uint uint height = 0; uint * buffer = null; - const uint current = raptor->font_count; + uint current = raptor->font_count; ++raptor->font_count; @@ -171,7 +171,7 @@ static uint raptor_font_raw_import (raptor_structure * raptor, uint * data, uint return (current); } -static uint raptor_sprite_import (raptor_structure * raptor, const char * path) { +static uint raptor_sprite_import (raptor_structure * raptor, char * path) { uint width = 0; uint height = 0; uint * data = null; @@ -181,7 +181,7 @@ static uint raptor_sprite_import (raptor_structure * raptor, const char * path) return (raptor_sprite_raw_import (raptor, data, width, height)); } -static uint raptor_font_import (raptor_structure * raptor, const char * path, char begin, char end, uint colour) { +static uint raptor_font_import (raptor_structure * raptor, char * path, char begin, char end, uint colour) { uint width = 0; uint height = 0; uint result = 0; @@ -196,11 +196,11 @@ static uint raptor_font_import (raptor_structure * raptor, const char * path, ch return (result); } -static uint raptor_sprite_width (const raptor_structure * raptor, uint sprite) { +static uint raptor_sprite_width (raptor_structure * raptor, uint sprite) { return (raptor->sprite_width [sprite]); } -static uint raptor_sprite_height (const raptor_structure * raptor, uint sprite) { +static uint raptor_sprite_height (raptor_structure * raptor, uint sprite) { return (raptor->sprite_height [sprite]); } @@ -208,7 +208,7 @@ static uint raptor_character_width (raptor_structure * raptor, char character, u if ((character < raptor->font_begin [font]) || (character > raptor->font_end [font])) { return (0); } else { - const uint index = raptor->font_index [font] [character - raptor->font_begin [font]]; + uint index = raptor->font_index [font] [character - raptor->font_begin [font]]; return ((uint) (scale * (float) raptor->sprite_width [index])); } @@ -218,13 +218,13 @@ static uint raptor_character_height (raptor_structure * raptor, char character, if ((character < raptor->font_begin [font]) || (character > raptor->font_end [font])) { return (0); } else { - const uint index = raptor->font_index [font] [character - raptor->font_begin [font]]; + uint index = raptor->font_index [font] [character - raptor->font_begin [font]]; return ((uint) (scale * (float) raptor->sprite_height [index])); } } -static uint raptor_string_width (raptor_structure * raptor, const char * string, uint font, float scale) { +static uint raptor_string_width (raptor_structure * raptor, char * string, uint font, float scale) { uint width = 0; uint match = 0; @@ -246,7 +246,7 @@ static uint raptor_string_width (raptor_structure * raptor, const char * string, return (maximum (width, match)); } -static uint raptor_string_height (raptor_structure * raptor, const char * string, uint font, float scale) { +static uint raptor_string_height (raptor_structure * raptor, char * string, uint font, float scale) { uint height = raptor_character_height (raptor, ' ', font, scale); if ((string == null) || (string [0] == '\0')) { @@ -262,22 +262,22 @@ static uint raptor_string_height (raptor_structure * raptor, const char * string return (height); } -static uint raptor_center_x (const raptor_structure * raptor, uint size) { +static uint raptor_center_x (raptor_structure * raptor, uint size) { return ((raptor->window_width - size) / 2); } -static uint raptor_center_y (const raptor_structure * raptor, uint size) { +static uint raptor_center_y (raptor_structure * raptor, uint size) { return ((raptor->window_height - size) / 2); } -static bool raptor_cursor_inside (const raptor_structure * raptor, int x, int y, uint width, uint height) { +static bool raptor_cursor_inside (raptor_structure * raptor, int x, int y, uint width, uint height) { return ((raptor->cursor_x > x) && (raptor->cursor_y > y) && (raptor->cursor_x < x + (int) width) && (raptor->cursor_y < y + (int) height)); } -static bool raptor_cursor_left_click (const raptor_structure * raptor, int x, int y, uint width, uint height) { +static bool raptor_cursor_left_click (raptor_structure * raptor, int x, int y, uint width, uint height) { if (raptor->cursor [cursor_left] == true) { return (raptor_cursor_inside (raptor, x, y, width, height) == true); } @@ -285,7 +285,7 @@ static bool raptor_cursor_left_click (const raptor_structure * raptor, int x, in return (false); } -static bool raptor_cursor_right_click (const raptor_structure * raptor, int x, int y, uint width, uint height) { +static bool raptor_cursor_right_click (raptor_structure * raptor, int x, int y, uint width, uint height) { if (raptor->cursor [cursor_right] == true) { return (raptor_cursor_inside (raptor, x, y, width, height)); } @@ -293,8 +293,8 @@ static bool raptor_cursor_right_click (const raptor_structure * raptor, int x, i return (false); } -static void raptor_configure (raptor_structure * raptor, uint window_width, uint window_height, const char * window_title) { - const ulong font_bitmap [2 * 95] = { +static void raptor_configure (raptor_structure * raptor, uint window_width, uint window_height, char * window_title) { + ulong font_bitmap [2 * 95] = { 0x0000000000000000, 0x0000000000000000, 0x0000101010101010, 0x1000101000000000, 0x0024242400000000, 0x0000000000000000, 0x00002424247e2424, 0x7e24242400000000, 0x0010107c9290907c, 0x1212927c10100000, 0x0000649468081010, 0x202c524c00000000, 0x000018242418304a, 0x4444443a00000000, 0x0010101000000000, 0x0000000000000000, 0x0000081020202020, 0x2020100800000000, @@ -430,10 +430,10 @@ static void raptor_render_base (raptor_structure * raptor, uint sprite, int x, i (void) lower_right; uint interpolate_pixels (uint pixel, uint modifier) { - const uint r = (((pixel & 0xff000000) >> 24) * ((modifier & 0x000000ff) >> 0)) / 0xff; - const uint g = (((pixel & 0x00ff0000) >> 16) * ((modifier & 0x0000ff00) >> 8)) / 0xff; - const uint b = (((pixel & 0x0000ff00) >> 8) * ((modifier & 0x00ff0000) >> 16)) / 0xff; - const uint a = (((pixel & 0x000000ff) >> 0) * ((modifier & 0xff000000) >> 24)) / 0xff; + uint r = (((pixel & 0xff000000) >> 24) * ((modifier & 0x000000ff) >> 0)) / 0xff; + uint g = (((pixel & 0x00ff0000) >> 16) * ((modifier & 0x0000ff00) >> 8)) / 0xff; + uint b = (((pixel & 0x0000ff00) >> 8) * ((modifier & 0x00ff0000) >> 16)) / 0xff; + uint a = (((pixel & 0x000000ff) >> 0) * ((modifier & 0xff000000) >> 24)) / 0xff; return ((r << 24) | (g << 16) | (b << 8) | a); } @@ -448,8 +448,8 @@ static void raptor_render_base (raptor_structure * raptor, uint sprite, int x, i if (horizontal + x >= raptor->window_width) break; if (horizontal + u >= raptor->sprite_width [sprite]) break; - const uint pixel = raptor->sprite_data [sprite] [(vertical + v) * raptor->sprite_width [sprite] + horizontal + u]; - const uint at = (y + vertical) * raptor->window_width + (x + horizontal); + uint pixel = raptor->sprite_data [sprite] [(vertical + v) * raptor->sprite_width [sprite] + horizontal + u]; + uint at = (y + vertical) * raptor->window_width + (x + horizontal); raptor->framebuffer [at] = (((pixel & 0xff000000) >> 24) > 0x77) ? interpolate_pixels (pixel, upper_left) @@ -464,15 +464,15 @@ static void raptor_render_rectangle (raptor_structure * raptor, int x, int y, ui } static void raptor_render_sprite (raptor_structure * raptor, uint sprite, int x, int y) { - const uint width = raptor->sprite_width [sprite]; - const uint height = raptor->sprite_height [sprite]; + uint width = raptor->sprite_width [sprite]; + uint height = raptor->sprite_height [sprite]; raptor_render_base (raptor, sprite, x, y, 0, 0, width, height, 1.0f, 1.0f, 0, 0, 0xffffffffu, 0xffffffffu, 0xffffffffu, 0xffffffffu); } static void raptor_render_sprite_scale (raptor_structure * raptor, uint sprite, int x, int y, float scale_x, float scale_y) { - const uint width = raptor->sprite_width [sprite]; - const uint height = raptor->sprite_height [sprite]; + uint width = raptor->sprite_width [sprite]; + uint height = raptor->sprite_height [sprite]; raptor_render_base (raptor, sprite, x, y, 0, 0, width, height, scale_x, scale_y, 0, 0, 0xffffffffu, 0xffffffffu, 0xffffffffu, 0xffffffffu); @@ -483,8 +483,8 @@ static void raptor_render_sprite_crop (raptor_structure * raptor, uint sprite, i } static void raptor_render_sprite_colour (raptor_structure * raptor, uint sprite, uint colour, int x, int y) { - const uint width = raptor->sprite_width [sprite]; - const uint height = raptor->sprite_height [sprite]; + uint width = raptor->sprite_width [sprite]; + uint height = raptor->sprite_height [sprite]; raptor_render_base (raptor, sprite, x, y, 0, 0, width, height, 1.0f, 1.0f, 0, 0, colour, colour, colour, colour); } @@ -494,19 +494,19 @@ static void raptor_render_sprite_crop_colour (raptor_structure * raptor, uint sp } static void raptor_render_sprite_flip (raptor_structure * raptor, uint sprite, int x, int y, int flip_x, int flip_y) { - const uint width = raptor->sprite_width [sprite]; - const uint height = raptor->sprite_height [sprite]; + uint width = raptor->sprite_width [sprite]; + uint height = raptor->sprite_height [sprite]; raptor_render_base (raptor, sprite, x, y, 0, 0, width, height, 1.0f, 1.0f, flip_x, flip_y, 0xffffffffu, 0xffffffffu, 0xffffffffu, 0xffffffffu); } static void raptor_render_sprite_animate (raptor_structure * raptor, uint sprite, int x, int y, uint frames, uint state, uint states) { - const uint width = raptor->sprite_width [sprite] / states; - const uint height = raptor->sprite_height [sprite] / frames; + uint width = raptor->sprite_width [sprite] / states; + uint height = raptor->sprite_height [sprite] / frames; - const uint u = width * (state % states); - const uint v = height * (raptor->animation_tick % frames); + uint u = width * (state % states); + uint v = height * (raptor->animation_tick % frames); raptor_render_sprite_crop (raptor, sprite, x, y, u, v, width, height); } @@ -514,15 +514,15 @@ static void raptor_render_sprite_animate (raptor_structure * raptor, uint sprite static void raptor_render_character (raptor_structure * raptor, char character, uint font, int x, int y, float scale, uint colour) { if ((character < raptor->font_begin [font]) || (character > raptor->font_end [font])) return; - const uint index = raptor->font_index [font] [character - raptor->font_begin [font]]; + uint index = raptor->font_index [font] [character - raptor->font_begin [font]]; - const uint width = raptor->sprite_width [index]; - const uint height = raptor->sprite_height [index]; + uint width = raptor->sprite_width [index]; + uint height = raptor->sprite_height [index]; raptor_render_base (raptor, index, x, y, 0, 0, width, height, scale, scale, 0, 0, colour, colour, colour, colour); } -static void raptor_render_string (raptor_structure * raptor, const char * string, uint font, int x, int y, float scale, uint colour) { +static void raptor_render_string (raptor_structure * raptor, char * string, uint font, int x, int y, float scale, uint colour) { int offset = x; if (string == null) return; @@ -548,7 +548,7 @@ static void raptor_render_framerate (raptor_structure * raptor, uint font, int x } static void raptor_synchronize (raptor_structure * raptor, uint clear_colour) { - const uint signal_code [signal_count] = { + uint signal_code [signal_count] = { 0, 38, 56, 54, 40, 26, 41, 42, 43, 31, 44, 45, 46, 58, 57, 32, 33, 24, 27, 39, 28, 30, 55, 25, 53, 29, 52, 19, 10, 11, 12, 13, 14, diff --git a/xarbon.c b/xarbon.c index a1bda6c..cdabfda 100755 --- a/xarbon.c +++ b/xarbon.c @@ -20,12 +20,12 @@ #include #include -static const uint background = 0xff181818; -static const uint foreground = 0xffcccccc; -static const uint font_width = 8; -static const uint font_height = 16; -static const uint tab_width = 8; -static const uint render_border = 10; +static uint background = 0xff181818; +static uint foreground = 0xffcccccc; +static uint font_width = 8; +static uint font_height = 16; +static uint tab_width = 8; +static uint render_border = 10; static uint * render_image = null; static uint render_width = 0; @@ -57,13 +57,13 @@ static void print_help (void) { print ("\t/6$ xarbon file.ext/- /0---/- Language is automatically detected in this case.\n\n"); print ("Supported languages:\n\n"); - for (uint index = 0; index < language_count; ++index) { + for (language_enumeration index = 0; index < language_count; ++index) { char align [32] = ""; print ("\t/B/4%s/- /4%s/- /0---/- %s syntax highlighting\n", - language_short_option (index), - string_align_left (string_copy (align, language_long_option (index)), 9, ' '), - language_identifier (index)); + language_short_option [index], + string_align_left (string_copy (align, language_long_option [index]), 9, ' '), + language_identifier [index]); } } @@ -73,7 +73,7 @@ static void print_version (void) { print ("\tVersion: /40 (Zero)/-\n"); } -static uint fetch_width (const char * data) { +static uint fetch_width (char * data) { uint image_width = 0; uint count = 0; @@ -91,7 +91,7 @@ static uint fetch_width (const char * data) { return (image_width - 1); } -static uint fetch_height (const char * data) { +static uint fetch_height (char * data) { uint image_height = 0; uint count = 0; @@ -113,7 +113,7 @@ static uint fetch_height (const char * data) { } static void render_character (char character, uint * x, uint * y, uint colour) { - const ulong glyphmap [192] = { + ulong glyphmap [192] = { 0x0000000000000000, 0x0000000000000000, 0x0000101010101010, 0x1000101000000000, 0x0024242400000000, 0x0000000000000000, 0x00002424247e2424, 0x7e24242400000000, 0x0010107c9290907c, 0x1212927c10100000, 0x0000649468081010, 0x202c524c00000000, 0x000018242418304a, 0x4444443a00000000, 0x0010101000000000, 0x0000000000000000, 0x0000081020202020, 0x2020100800000000, @@ -168,7 +168,8 @@ static void render_string (char * string, uint length, uint * x, uint * y, uint * y += font_height; * x = render_border; - render_string (format_to_string ((int) ++line_number, false, 10, (int) line_digits, ' '), line_digits, x, y, foreground); + render_string (format_to_string ((int) ++line_number, false, 10, (int) line_digits, ' '), + line_digits, x, y, foreground); * x += font_width; } else { @@ -207,8 +208,8 @@ int main (int argc, char * * argv) { } for (uint index = 0; index < language_count; ++index) { - if (argument_compare (argv [argument], language_short_option (index), language_long_option (index)) == true) { - (* (language_highlighter (index))) (language, syntax); + if (argument_compare (argv [argument], language_short_option [index], language_long_option [index]) == true) { + (* (language_highlighter [index])) (language, syntax); select = index; break; } diff --git a/xarticle.h b/xarticle.h index 6c0f7bd..54beeb8 100644 --- a/xarticle.h +++ b/xarticle.h @@ -73,8 +73,8 @@ static particle_structure * particle_deinitialize (particle_structure * particle return (deallocate (particle)); } -static void particle_append (particle_structure * particle, uint sprite, float life, uint colour_in, uint colour_out, const vector_3 * position, - const vector_3 * target, const vector_3 * speed) { +static void particle_append (particle_structure * particle, uint sprite, float life, uint colour_in, uint colour_out, vector_3 * position, + vector_3 * target, vector_3 * speed) { if (particle->count + 1 >= particle->limit) return; ++particle->count; diff --git a/xatrix.h b/xatrix.h index b0d8c8a..f3677b6 100644 --- a/xatrix.h +++ b/xatrix.h @@ -132,51 +132,51 @@ static matrix_4 * matrix_4_identity (matrix_4 * destination) { return (destination); } -static float matrix_2_determinant (const matrix_2 * matrix) { - const float a = matrix [0] [0] * matrix [1] [1]; - const float b = matrix [0] [1] * matrix [1] [0]; +static float matrix_2_determinant (matrix_2 * matrix) { + float a = matrix [0] [0] * matrix [1] [1]; + float b = matrix [0] [1] * matrix [1] [0]; return (a - b); } -static float matrix_3_determinant (const matrix_3 * matrix) { - const matrix_2 matrix_a = { { matrix [1] [1], matrix [1] [2] }, +static float matrix_3_determinant (matrix_3 * matrix) { + matrix_2 matrix_a = { { matrix [1] [1], matrix [1] [2] }, { matrix [2] [1], matrix [2] [2] } }; - const matrix_2 matrix_b = { { matrix [1] [0], matrix [1] [2] }, + matrix_2 matrix_b = { { matrix [1] [0], matrix [1] [2] }, { matrix [2] [0], matrix [2] [2] } }; - const matrix_2 matrix_c = { { matrix [1] [0], matrix [1] [1] }, + matrix_2 matrix_c = { { matrix [1] [0], matrix [1] [1] }, { matrix [2] [0], matrix [2] [1] } }; - const float a = matrix [0] [0] * matrix_2_determinant (& matrix_a); - const float b = matrix [0] [1] * matrix_2_determinant (& matrix_b); - const float c = matrix [0] [2] * matrix_2_determinant (& matrix_c); + float a = matrix [0] [0] * matrix_2_determinant (& matrix_a); + float b = matrix [0] [1] * matrix_2_determinant (& matrix_b); + float c = matrix [0] [2] * matrix_2_determinant (& matrix_c); return (a - b + c); } -static float matrix_4_determinant (const matrix_4 * matrix) { - const matrix_3 matrix_a = { { matrix [1] [1], matrix [1] [2], matrix [1] [3] }, +static float matrix_4_determinant (matrix_4 * matrix) { + matrix_3 matrix_a = { { matrix [1] [1], matrix [1] [2], matrix [1] [3] }, { matrix [2] [1], matrix [2] [2], matrix [2] [3] }, { matrix [3] [1], matrix [3] [2], matrix [3] [3] } }; - const matrix_3 matrix_b = { { matrix [1] [0], matrix [1] [2], matrix [1] [3] }, + matrix_3 matrix_b = { { matrix [1] [0], matrix [1] [2], matrix [1] [3] }, { matrix [2] [0], matrix [2] [2], matrix [2] [3] }, { matrix [3] [0], matrix [3] [2], matrix [3] [3] } }; - const matrix_3 matrix_c = { { matrix [1] [0], matrix [1] [1], matrix [1] [3] }, + matrix_3 matrix_c = { { matrix [1] [0], matrix [1] [1], matrix [1] [3] }, { matrix [2] [0], matrix [2] [1], matrix [2] [3] }, { matrix [3] [0], matrix [3] [1], matrix [3] [3] } }; - const matrix_3 matrix_d = { { matrix [1] [0], matrix [1] [1], matrix [1] [2] }, + matrix_3 matrix_d = { { matrix [1] [0], matrix [1] [1], matrix [1] [2] }, { matrix [2] [0], matrix [2] [1], matrix [2] [2] }, { matrix [3] [0], matrix [3] [1], matrix [3] [2] } }; - const float a = matrix [0] [0] * matrix_3_determinant (& matrix_a); - const float b = matrix [0] [1] * matrix_3_determinant (& matrix_b); - const float c = matrix [0] [2] * matrix_3_determinant (& matrix_c); - const float d = matrix [0] [3] * matrix_3_determinant (& matrix_d); + float a = matrix [0] [0] * matrix_3_determinant (& matrix_a); + float b = matrix [0] [1] * matrix_3_determinant (& matrix_b); + float c = matrix [0] [2] * matrix_3_determinant (& matrix_c); + float d = matrix [0] [3] * matrix_3_determinant (& matrix_d); return (a - b + c - d); } -static matrix_2 * matrix_2_copy (matrix_2 * destination, const matrix_2 * source) { +static matrix_2 * matrix_2_copy (matrix_2 * destination, matrix_2 * source) { for (uint row = 0; row < 2; ++row) { for (uint column = 0; column < 2; ++column) { destination [row] [column] = source [row] [column]; @@ -186,7 +186,7 @@ static matrix_2 * matrix_2_copy (matrix_2 * destination, const matrix_2 * source return (destination); } -static matrix_3 * matrix_3_copy (matrix_3 * destination, const matrix_3 * source) { +static matrix_3 * matrix_3_copy (matrix_3 * destination, matrix_3 * source) { for (uint row = 0; row < 3; ++row) { for (uint column = 0; column < 3; ++column) { destination [row] [column] = source [row] [column]; @@ -196,7 +196,7 @@ static matrix_3 * matrix_3_copy (matrix_3 * destination, const matrix_3 * source return (destination); } -static matrix_4 * matrix_4_copy (matrix_4 * destination, const matrix_4 * source) { +static matrix_4 * matrix_4_copy (matrix_4 * destination, matrix_4 * source) { for (uint row = 0; row < 4; ++row) { for (uint column = 0; column < 4; ++column) { destination [row] [column] = source [row] [column]; @@ -236,7 +236,7 @@ static matrix_4 * matrix_4_scale (matrix_4 * destination, float scale) { return (destination); } -static matrix_2 * matrix_2_scale_to (matrix_2 * destination, const matrix_2 * source, float scale) { +static matrix_2 * matrix_2_scale_to (matrix_2 * destination, matrix_2 * source, float scale) { for (uint row = 0; row < 2; ++row) { for (uint column = 0; column < 2; ++column) { destination [row] [column] = source [row] [column] * scale; @@ -246,7 +246,7 @@ static matrix_2 * matrix_2_scale_to (matrix_2 * destination, const matrix_2 * so return (destination); } -static matrix_3 * matrix_3_scale_to (matrix_3 * destination, const matrix_3 * source, float scale) { +static matrix_3 * matrix_3_scale_to (matrix_3 * destination, matrix_3 * source, float scale) { for (uint row = 0; row < 3; ++row) { for (uint column = 0; column < 3; ++column) { destination [row] [column] = source [row] [column] * scale; @@ -256,7 +256,7 @@ static matrix_3 * matrix_3_scale_to (matrix_3 * destination, const matrix_3 * so return (destination); } -static matrix_4 * matrix_4_scale_to (matrix_4 * destination, const matrix_4 * source, float scale) { +static matrix_4 * matrix_4_scale_to (matrix_4 * destination, matrix_4 * source, float scale) { for (uint row = 0; row < 4; ++row) { for (uint column = 0; column < 4; ++column) { destination [row] [column] = source [row] [column] * scale; @@ -266,7 +266,7 @@ static matrix_4 * matrix_4_scale_to (matrix_4 * destination, const matrix_4 * so return (destination); } -static matrix_2 * matrix_2_add (matrix_2 * destination, const matrix_2 * source) { +static matrix_2 * matrix_2_add (matrix_2 * destination, matrix_2 * source) { for (uint row = 0; row < 2; ++row) { for (uint column = 0; column < 2; ++column) { destination [row] [column] += source [row] [column]; @@ -276,7 +276,7 @@ static matrix_2 * matrix_2_add (matrix_2 * destination, const matrix_2 * source) return (destination); } -static matrix_3 * matrix_3_add (matrix_3 * destination, const matrix_3 * source) { +static matrix_3 * matrix_3_add (matrix_3 * destination, matrix_3 * source) { for (uint row = 0; row < 3; ++row) { for (uint column = 0; column < 3; ++column) { destination [row] [column] += source [row] [column]; @@ -286,7 +286,7 @@ static matrix_3 * matrix_3_add (matrix_3 * destination, const matrix_3 * source) return (destination); } -static matrix_4 * matrix_4_add (matrix_4 * destination, const matrix_4 * source) { +static matrix_4 * matrix_4_add (matrix_4 * destination, matrix_4 * source) { for (uint row = 0; row < 4; ++row) { for (uint column = 0; column < 4; ++column) { destination [row] [column] += source [row] [column]; @@ -296,7 +296,7 @@ static matrix_4 * matrix_4_add (matrix_4 * destination, const matrix_4 * source) return (destination); } -static matrix_2 * matrix_2_add_to (matrix_2 * destination, const matrix_2 * matrix_a, const matrix_2 * matrix_b) { +static matrix_2 * matrix_2_add_to (matrix_2 * destination, matrix_2 * matrix_a, matrix_2 * matrix_b) { for (uint row = 0; row < 2; ++row) { for (uint column = 0; column < 2; ++column) { destination [row] [column] = matrix_a [row] [column] + matrix_b [row] [column]; @@ -306,7 +306,7 @@ static matrix_2 * matrix_2_add_to (matrix_2 * destination, const matrix_2 * matr return (destination); } -static matrix_3 * matrix_3_add_to (matrix_3 * destination, const matrix_3 * matrix_a, const matrix_3 * matrix_b) { +static matrix_3 * matrix_3_add_to (matrix_3 * destination, matrix_3 * matrix_a, matrix_3 * matrix_b) { for (uint row = 0; row < 3; ++row) { for (uint column = 0; column < 3; ++column) { destination [row] [column] = matrix_a [row] [column] + matrix_b [row] [column]; @@ -316,7 +316,7 @@ static matrix_3 * matrix_3_add_to (matrix_3 * destination, const matrix_3 * matr return (destination); } -static matrix_4 * matrix_4_add_to (matrix_4 * destination, const matrix_4 * matrix_a, const matrix_4 * matrix_b) { +static matrix_4 * matrix_4_add_to (matrix_4 * destination, matrix_4 * matrix_a, matrix_4 * matrix_b) { for (uint row = 0; row < 4; ++row) { for (uint column = 0; column < 4; ++column) { destination [row] [column] = matrix_a [row] [column] + matrix_b [row] [column]; @@ -326,7 +326,7 @@ static matrix_4 * matrix_4_add_to (matrix_4 * destination, const matrix_4 * matr return (destination); } -static matrix_2 * matrix_2_subtract (matrix_2 * destination, const matrix_2 * source) { +static matrix_2 * matrix_2_subtract (matrix_2 * destination, matrix_2 * source) { for (uint row = 0; row < 2; ++row) { for (uint column = 0; column < 2; ++column) { destination [row] [column] -= source [row] [column]; @@ -336,7 +336,7 @@ static matrix_2 * matrix_2_subtract (matrix_2 * destination, const matrix_2 * so return (destination); } -static matrix_3 * matrix_3_subtract (matrix_3 * destination, const matrix_3 * source) { +static matrix_3 * matrix_3_subtract (matrix_3 * destination, matrix_3 * source) { for (uint row = 0; row < 3; ++row) { for (uint column = 0; column < 3; ++column) { destination [row] [column] -= source [row] [column]; @@ -346,7 +346,7 @@ static matrix_3 * matrix_3_subtract (matrix_3 * destination, const matrix_3 * so return (destination); } -static matrix_4 * matrix_4_subtract (matrix_4 * destination, const matrix_4 * source) { +static matrix_4 * matrix_4_subtract (matrix_4 * destination, matrix_4 * source) { for (uint row = 0; row < 4; ++row) { for (uint column = 0; column < 4; ++column) { destination [row] [column] -= source [row] [column]; @@ -356,7 +356,7 @@ static matrix_4 * matrix_4_subtract (matrix_4 * destination, const matrix_4 * so return (destination); } -static matrix_2 * matrix_2_subtract_to (matrix_2 * destination, const matrix_2 * matrix_a, const matrix_2 * matrix_b) { +static matrix_2 * matrix_2_subtract_to (matrix_2 * destination, matrix_2 * matrix_a, matrix_2 * matrix_b) { for (uint row = 0; row < 2; ++row) { for (uint column = 0; column < 2; ++column) { destination [row] [column] = matrix_a [row] [column] - matrix_b [row] [column]; @@ -366,7 +366,7 @@ static matrix_2 * matrix_2_subtract_to (matrix_2 * destination, const matrix_2 * return (destination); } -static matrix_3 * matrix_3_subtract_to (matrix_3 * destination, const matrix_3 * matrix_a, const matrix_3 * matrix_b) { +static matrix_3 * matrix_3_subtract_to (matrix_3 * destination, matrix_3 * matrix_a, matrix_3 * matrix_b) { for (uint row = 0; row < 3; ++row) { for (uint column = 0; column < 3; ++column) { destination [row] [column] = matrix_a [row] [column] - matrix_b [row] [column]; @@ -376,7 +376,7 @@ static matrix_3 * matrix_3_subtract_to (matrix_3 * destination, const matrix_3 * return (destination); } -static matrix_4 * matrix_4_subtract_to (matrix_4 * destination, const matrix_4 * matrix_a, const matrix_4 * matrix_b) { +static matrix_4 * matrix_4_subtract_to (matrix_4 * destination, matrix_4 * matrix_a, matrix_4 * matrix_b) { for (uint row = 0; row < 4; ++row) { for (uint column = 0; column < 4; ++column) { destination [row] [column] = matrix_a [row] [column] - matrix_b [row] [column]; @@ -386,7 +386,7 @@ static matrix_4 * matrix_4_subtract_to (matrix_4 * destination, const matrix_4 * return (destination); } -static matrix_2 * matrix_2_multiply (matrix_2 * result, const matrix_2 * matrix_a, const matrix_2 * matrix_b) { +static matrix_2 * matrix_2_multiply (matrix_2 * result, matrix_2 * matrix_a, matrix_2 * matrix_b) { for (uint row = 0; row < 2; ++row) { for (uint column = 0; column < 2; ++column) { result [row] [column] = 0.0f; @@ -400,7 +400,7 @@ static matrix_2 * matrix_2_multiply (matrix_2 * result, const matrix_2 * matrix_ return (result); } -static matrix_3 * matrix_3_multiply (matrix_3 * result, const matrix_3 * matrix_a, const matrix_3 * matrix_b) { +static matrix_3 * matrix_3_multiply (matrix_3 * result, matrix_3 * matrix_a, matrix_3 * matrix_b) { for (uint row = 0; row < 3; ++row) { for (uint column = 0; column < 3; ++column) { result [row] [column] = 0.0f; @@ -414,7 +414,7 @@ static matrix_3 * matrix_3_multiply (matrix_3 * result, const matrix_3 * matrix_ return (result); } -static matrix_4 * matrix_4_multiply (matrix_4 * result, const matrix_4 * matrix_a, const matrix_4 * matrix_b) { +static matrix_4 * matrix_4_multiply (matrix_4 * result, matrix_4 * matrix_a, matrix_4 * matrix_b) { for (uint row = 0; row < 4; ++row) { for (uint column = 0; column < 4; ++column) { result [row] [column] = 0.0f; @@ -428,19 +428,19 @@ static matrix_4 * matrix_4_multiply (matrix_4 * result, const matrix_4 * matrix_ return (result); } -static float matrix_2_trace (const matrix_2 * matrix) { +static float matrix_2_trace (matrix_2 * matrix) { return (matrix [0] [0] + matrix [1] [1]); } -static float matrix_3_trace (const matrix_3 * matrix) { +static float matrix_3_trace (matrix_3 * matrix) { return (matrix [0] [0] + matrix [1] [1] + matrix [2] [2]); } -static float matrix_4_trace (const matrix_4 * matrix) { +static float matrix_4_trace (matrix_4 * matrix) { return (matrix [0] [0] + matrix [1] [1] + matrix [2] [2] + matrix [3] [3]); } -static bool matrix_2_compare (const matrix_2 * matrix_a, const matrix_2 * matrix_b) { +static bool matrix_2_compare (matrix_2 * matrix_a, matrix_2 * matrix_b) { for (uint row = 0; row < 2; ++row) { for (uint column = 0; column < 2; ++column) { if (matrix_a [row] [column] != matrix_b [row] [column]) { @@ -452,7 +452,7 @@ static bool matrix_2_compare (const matrix_2 * matrix_a, const matrix_2 * matrix return (true); } -static bool matrix_3_compare (const matrix_3 * matrix_a, const matrix_3 * matrix_b) { +static bool matrix_3_compare (matrix_3 * matrix_a, matrix_3 * matrix_b) { for (uint row = 0; row < 3; ++row) { for (uint column = 0; column < 3; ++column) { if (matrix_a [row] [column] != matrix_b [row] [column]) { @@ -464,7 +464,7 @@ static bool matrix_3_compare (const matrix_3 * matrix_a, const matrix_3 * matrix return (true); } -static bool matrix_4_compare (const matrix_4 * matrix_a, const matrix_4 * matrix_b) { +static bool matrix_4_compare (matrix_4 * matrix_a, matrix_4 * matrix_b) { for (uint row = 0; row < 4; ++row) { for (uint column = 0; column < 4; ++column) { if (matrix_a [row] [column] != matrix_b [row] [column]) { diff --git a/xcript.h b/xcript.h index 6266e06..a644192 100755 --- a/xcript.h +++ b/xcript.h @@ -41,13 +41,13 @@ typedef struct { uint * index; } script_information; -static void script_warning (const script_structure * script, bool condition, const char * message) { +static void script_warning (script_structure * script, bool condition, char * message) { if (condition == true) { print ("[/3Warning/-] %s: %i: %s\n", script->path, script->line, message); } } -static void script_failure (const script_structure * script, bool condition, const char * message) { +static void script_failure (script_structure * script, bool condition, char * message) { if (condition == true) { print ("[/1Failure/-] %s: %i: %s\n", script->path, script->line, message); @@ -57,7 +57,7 @@ static void script_failure (const script_structure * script, bool condition, con } } -static script_structure * script_open (const char * path) { +static script_structure * script_open (char * path) { script_structure * script = allocate (sizeof (* script)); script->path = string_duplicate (path); @@ -81,23 +81,23 @@ static script_structure * script_close (script_structure * script) { return (deallocate (script)); } -static bool script_compare (const script_structure * script, const char * string) { +static bool script_compare (script_structure * script, char * string) { return (string_compare_limit (string, script->last_string, script->last_length)); } -static bool script_check (const script_information * information, uint index, const char * identifier) { +static bool script_check (script_information * information, uint index, char * identifier) { return (string_compare (identifier, information->identifier [index])); } -static char * script_export_string (const script_structure * script) { +static char * script_export_string (script_structure * script) { return (string_duplicate_limit (script->last_string, script->last_length)); } -static uint script_export_number (const script_structure * script) { +static uint script_export_number (script_structure * script) { return (string_limit_to_number (script->last_string, script->last_length)); } -static uint script_export_marker (const script_information * information, const script_structure * script) { +static uint script_export_marker (script_information * information, script_structure * script) { for (uint counter = 0; counter < information->counter; ++counter) { if (script_compare (script, information->identifier [counter]) == true) { return (information->index [counter]); @@ -207,7 +207,7 @@ static script_word_type script_parser (script_structure * script) { return (word); } -static char * script_expect_header (script_information * information, const script_structure * script, uint index, bool accept) { +static char * script_expect_header (script_information * information, script_structure * script, uint index, bool accept) { if (accept == true) { ++information->counter; @@ -239,7 +239,7 @@ static uint script_expect_number (script_structure * script) { return (script_export_number (script)); } -static uint script_expect_marker (const script_information * information, script_structure * script) { +static uint script_expect_marker (script_information * information, script_structure * script) { script_word_type word = script_unknown; script_failure (script, (word = script_parser (script)) != script_assign, "Expected '=', assignment operator."); @@ -248,7 +248,7 @@ static uint script_expect_marker (const script_information * information, script return (script_export_marker (information, script)); } -static uint script_expect_number_or_marker (const script_information * information, script_structure * script) { +static uint script_expect_number_or_marker (script_information * information, script_structure * script) { script_word_type word = script_unknown; script_failure (script, (word = script_parser (script)) != script_assign, "Expected '=', assignment operator."); @@ -266,7 +266,7 @@ static uint script_expect_number_or_marker (const script_information * informati return (~ 0u); } -static uint * script_expect_ordered_array (const script_information * information, script_structure * script, uint * count) { +static uint * script_expect_ordered_array (script_information * information, script_structure * script, uint * count) { script_word_type word = script_unknown; uint found = 0; @@ -299,7 +299,7 @@ static uint * script_expect_ordered_array (const script_information * informatio return (array); } -static uint * script_expect_unordered_array (const script_information * information, script_structure * script, uint count) { +static uint * script_expect_unordered_array (script_information * information, script_structure * script, uint count) { script_word_type word = script_unknown; uint * array = allocate (count * sizeof (* array)); @@ -333,7 +333,7 @@ static uint * script_expect_unordered_array (const script_information * informat return (array); } -static script_information * script_initialize (const char * general_script_file_path) { +static script_information * script_initialize (char * general_script_file_path) { script_information * script = allocate (sizeof (* script)); script_word_type word = script_unknown; @@ -370,7 +370,7 @@ static script_information * script_deinitialize (script_information * script) { return (deallocate (script)); } -static uint script_indexer (script_information * information, const char * identifier) { +static uint script_indexer (script_information * information, char * identifier) { for (uint counter = 0; counter < information->counter; ++counter) { if (string_compare (identifier, information->identifier [counter]) == true) { return (information->index [counter]); diff --git a/xctree.h b/xctree.h new file mode 100644 index 0000000..8009fa5 --- /dev/null +++ b/xctree.h @@ -0,0 +1,32 @@ +/// _ +/// __ _____| |_ _ __ ___ ___ +/// \ \/ / __| __| '__/ _ \/ _ \ +/// > < (__| |_| | | __/ __/ +/// /_/\_\___|\__|_| \___|\___| +/// +/// Copyright (c) 1997 - Ognjen 'xolatile' Milan Robovic +/// +/// xolatile@chud.cyou - xctree - Whitespace insignificant INI/CFG-like script parser. +/// +/// This program is free software, free as in freedom and as in free beer, you can redistribute it and/or modify it under the terms of the GNU +/// General Public License as published by the Free Software Foundation, either version 3 of the License, or any later version if you wish... +/// +/// This program is distributed in the hope that it will be useful, but it is probably not, and without any warranty, without even the implied +/// warranty of merchantability or fitness for a particular purpose, because it is pointless. Please see the GNU (Geenoo) General Public License +/// for more details, if you dare, it is a lot of text that nobody wants to read... + +typedef struct { + bool division; + float scale; + vector_3 * * vertex; + vector_3 * origin; + vector_3 * offset; + + struct octree_node * children [8]; +} octree_node; + +typedef struct { + uint count; + uint limit; + octree_node * * array; +} octree_structure; diff --git a/xector.h b/xector.h index 22e49b6..d774a0a 100755 --- a/xector.h +++ b/xector.h @@ -69,32 +69,32 @@ static vector_4 * vector_4_nullify (vector_4 * destination) { return (destination); } -static float vector_2_length (const vector_2 * vector) { - const float x = vector->x; - const float y = vector->y; +static float vector_2_length (vector_2 * vector) { + float x = vector->x; + float y = vector->y; return (square_root (x * x + y * y)); } -static float vector_3_length (const vector_3 * vector) { - const float x = vector->x; - const float y = vector->y; - const float z = vector->z; +static float vector_3_length (vector_3 * vector) { + float x = vector->x; + float y = vector->y; + float z = vector->z; return (square_root (x * x + y * y + z * z)); } -static float vector_4_length (const vector_4 * vector) { - const float x = vector->x; - const float y = vector->y; - const float z = vector->z; - const float w = vector->w; +static float vector_4_length (vector_4 * vector) { + float x = vector->x; + float y = vector->y; + float z = vector->z; + float w = vector->w; return (square_root (x * x + y * y + z * z + w * w)); } static vector_2 * vector_2_normalize (vector_2 * destination) { - const float length = vector_2_length (destination); + float length = vector_2_length (destination); destination->x /= length; destination->y /= length; @@ -103,7 +103,7 @@ static vector_2 * vector_2_normalize (vector_2 * destination) { } static vector_3 * vector_3_normalize (vector_3 * destination) { - const float length = vector_3_length (destination); + float length = vector_3_length (destination); destination->x /= length; destination->y /= length; @@ -113,7 +113,7 @@ static vector_3 * vector_3_normalize (vector_3 * destination) { } static vector_4 * vector_4_normalize (vector_4 * destination) { - const float length = vector_4_length (destination); + float length = vector_4_length (destination); destination->x /= length; destination->y /= length; @@ -123,8 +123,8 @@ static vector_4 * vector_4_normalize (vector_4 * destination) { return (destination); } -static vector_2 * vector_2_normalize_to (vector_2 * destination, const vector_2 * source) { - const float length = vector_2_length (source); +static vector_2 * vector_2_normalize_to (vector_2 * destination, vector_2 * source) { + float length = vector_2_length (source); destination->x = source->x / length; destination->y = source->y / length; @@ -132,8 +132,8 @@ static vector_2 * vector_2_normalize_to (vector_2 * destination, const vector_2 return (destination); } -static vector_3 * vector_3_normalize_to (vector_3 * destination, const vector_3 * source) { - const float length = vector_3_length (source); +static vector_3 * vector_3_normalize_to (vector_3 * destination, vector_3 * source) { + float length = vector_3_length (source); destination->x = source->x / length; destination->y = source->y / length; @@ -142,8 +142,8 @@ static vector_3 * vector_3_normalize_to (vector_3 * destination, const vector_3 return (destination); } -static vector_4 * vector_4_normalize_to (vector_4 * destination, const vector_4 * source) { - const float length = vector_4_length (source); +static vector_4 * vector_4_normalize_to (vector_4 * destination, vector_4 * source) { + float length = vector_4_length (source); destination->x = source->x / length; destination->y = source->y / length; @@ -153,14 +153,14 @@ static vector_4 * vector_4_normalize_to (vector_4 * destination, const vector_4 return (destination); } -static vector_2 * vector_2_copy (vector_2 * destination, const vector_2 * source) { +static vector_2 * vector_2_copy (vector_2 * destination, vector_2 * source) { destination->x = source->x; destination->y = source->y; return (destination); } -static vector_3 * vector_3_copy (vector_3 * destination, const vector_3 * source) { +static vector_3 * vector_3_copy (vector_3 * destination, vector_3 * source) { destination->x = source->x; destination->y = source->y; destination->z = source->z; @@ -168,7 +168,7 @@ static vector_3 * vector_3_copy (vector_3 * destination, const vector_3 * source return (destination); } -static vector_4 * vector_4_copy (vector_4 * destination, const vector_4 * source) { +static vector_4 * vector_4_copy (vector_4 * destination, vector_4 * source) { destination->x = source->x; destination->y = source->y; destination->z = source->z; @@ -219,14 +219,14 @@ static vector_4 * vector_4_scale (vector_4 * destination, float scale) { return (destination); } -static vector_2 * vector_2_scale_to (vector_2 * destination, const vector_2 * source, float scale) { +static vector_2 * vector_2_scale_to (vector_2 * destination, vector_2 * source, float scale) { destination->x = source->x * scale; destination->y = source->y * scale; return (destination); } -static vector_3 * vector_3_scale_to (vector_3 * destination, const vector_3 * source, float scale) { +static vector_3 * vector_3_scale_to (vector_3 * destination, vector_3 * source, float scale) { destination->x = source->x * scale; destination->y = source->y * scale; destination->z = source->z * scale; @@ -234,7 +234,7 @@ static vector_3 * vector_3_scale_to (vector_3 * destination, const vector_3 * so return (destination); } -static vector_4 * vector_4_scale_to (vector_4 * destination, const vector_4 * source, float scale) { +static vector_4 * vector_4_scale_to (vector_4 * destination, vector_4 * source, float scale) { destination->x = source->x * scale; destination->y = source->y * scale; destination->z = source->z * scale; @@ -243,14 +243,14 @@ static vector_4 * vector_4_scale_to (vector_4 * destination, const vector_4 * so return (destination); } -static vector_2 * vector_2_add (vector_2 * destination, const vector_2 * source) { +static vector_2 * vector_2_add (vector_2 * destination, vector_2 * source) { destination->x += source->x; destination->y += source->y; return (destination); } -static vector_3 * vector_3_add (vector_3 * destination, const vector_3 * source) { +static vector_3 * vector_3_add (vector_3 * destination, vector_3 * source) { destination->x += source->x; destination->y += source->y; destination->z += source->z; @@ -258,7 +258,7 @@ static vector_3 * vector_3_add (vector_3 * destination, const vector_3 * source) return (destination); } -static vector_4 * vector_4_add (vector_4 * destination, const vector_4 * source) { +static vector_4 * vector_4_add (vector_4 * destination, vector_4 * source) { destination->x += source->x; destination->y += source->y; destination->z += source->z; @@ -267,14 +267,14 @@ static vector_4 * vector_4_add (vector_4 * destination, const vector_4 * source) return (destination); } -static vector_2 * vector_2_add_to (vector_2 * destination, const vector_2 * vector_a, const vector_2 * vector_b) { +static vector_2 * vector_2_add_to (vector_2 * destination, vector_2 * vector_a, vector_2 * vector_b) { destination->x = vector_a->x + vector_b->x; destination->y = vector_a->y + vector_b->y; return (destination); } -static vector_3 * vector_3_add_to (vector_3 * destination, const vector_3 * vector_a, const vector_3 * vector_b) { +static vector_3 * vector_3_add_to (vector_3 * destination, vector_3 * vector_a, vector_3 * vector_b) { destination->x = vector_a->x + vector_b->x; destination->y = vector_a->y + vector_b->y; destination->z = vector_a->z + vector_b->z; @@ -282,7 +282,7 @@ static vector_3 * vector_3_add_to (vector_3 * destination, const vector_3 * vect return (destination); } -static vector_4 * vector_4_add_to (vector_4 * destination, const vector_4 * vector_a, const vector_4 * vector_b) { +static vector_4 * vector_4_add_to (vector_4 * destination, vector_4 * vector_a, vector_4 * vector_b) { destination->x = vector_a->x + vector_b->x; destination->y = vector_a->y + vector_b->y; destination->z = vector_a->z + vector_b->z; @@ -291,14 +291,14 @@ static vector_4 * vector_4_add_to (vector_4 * destination, const vector_4 * vect return (destination); } -static vector_2 * vector_2_subtract (vector_2 * destination, const vector_2 * source) { +static vector_2 * vector_2_subtract (vector_2 * destination, vector_2 * source) { destination->x -= source->x; destination->y -= source->y; return (destination); } -static vector_3 * vector_3_subtract (vector_3 * destination, const vector_3 * source) { +static vector_3 * vector_3_subtract (vector_3 * destination, vector_3 * source) { destination->x -= source->x; destination->y -= source->y; destination->z -= source->z; @@ -306,7 +306,7 @@ static vector_3 * vector_3_subtract (vector_3 * destination, const vector_3 * so return (destination); } -static vector_4 * vector_4_subtract (vector_4 * destination, const vector_4 * source) { +static vector_4 * vector_4_subtract (vector_4 * destination, vector_4 * source) { destination->x -= source->x; destination->y -= source->y; destination->z -= source->z; @@ -315,14 +315,14 @@ static vector_4 * vector_4_subtract (vector_4 * destination, const vector_4 * so return (destination); } -static vector_2 * vector_2_subtract_to (vector_2 * destination, const vector_2 * vector_a, const vector_2 * vector_b) { +static vector_2 * vector_2_subtract_to (vector_2 * destination, vector_2 * vector_a, vector_2 * vector_b) { destination->x = vector_a->x - vector_b->x; destination->y = vector_a->y - vector_b->y; return (destination); } -static vector_3 * vector_3_subtract_to (vector_3 * destination, const vector_3 * vector_a, const vector_3 * vector_b) { +static vector_3 * vector_3_subtract_to (vector_3 * destination, vector_3 * vector_a, vector_3 * vector_b) { destination->x = vector_a->x - vector_b->x; destination->y = vector_a->y - vector_b->y; destination->z = vector_a->z - vector_b->z; @@ -330,7 +330,7 @@ static vector_3 * vector_3_subtract_to (vector_3 * destination, const vector_3 * return (destination); } -static vector_4 * vector_4_subtract_to (vector_4 * destination, const vector_4 * vector_a, const vector_4 * vector_b) { +static vector_4 * vector_4_subtract_to (vector_4 * destination, vector_4 * vector_a, vector_4 * vector_b) { destination->x = vector_a->x - vector_b->x; destination->y = vector_a->y - vector_b->y; destination->z = vector_a->z - vector_b->z; @@ -339,7 +339,7 @@ static vector_4 * vector_4_subtract_to (vector_4 * destination, const vector_4 * return (destination); } -static bool vector_2_compare (const vector_2 * vector_a, const vector_2 * vector_b) { +static bool vector_2_compare (vector_2 * vector_a, vector_2 * vector_b) { if ((vector_a->x == vector_b->x) && (vector_a->y == vector_b->y)) { return (true); } else { @@ -347,7 +347,7 @@ static bool vector_2_compare (const vector_2 * vector_a, const vector_2 * vector } } -static bool vector_3_compare (const vector_3 * vector_a, const vector_3 * vector_b) { +static bool vector_3_compare (vector_3 * vector_a, vector_3 * vector_b) { if ((vector_a->x == vector_b->x) && (vector_a->y == vector_b->y) && (vector_a->z == vector_b->z)) { return (true); } else { @@ -355,7 +355,7 @@ static bool vector_3_compare (const vector_3 * vector_a, const vector_3 * vector } } -static bool vector_4_compare (const vector_4 * vector_a, const vector_4 * vector_b) { +static bool vector_4_compare (vector_4 * vector_a, vector_4 * vector_b) { if ((vector_a->x == vector_b->x) && (vector_a->y == vector_b->y) && (vector_a->z == vector_b->z) && (vector_a->w == vector_b->w)) { return (true); } else { @@ -363,23 +363,23 @@ static bool vector_4_compare (const vector_4 * vector_a, const vector_4 * vector } } -static float vector_2_dot_product (const vector_2 * vector_a, const vector_2 * vector_b) { +static float vector_2_dot_product (vector_2 * vector_a, vector_2 * vector_b) { return (vector_a->x * vector_b->x + vector_a->y * vector_b->y); } -static float vector_3_dot_product (const vector_3 * vector_a, const vector_3 * vector_b) { +static float vector_3_dot_product (vector_3 * vector_a, vector_3 * vector_b) { return (vector_a->x * vector_b->x + vector_a->y * vector_b->y + vector_a->z * vector_b->z); } -static float vector_4_dot_product (const vector_4 * vector_a, const vector_4 * vector_b) { +static float vector_4_dot_product (vector_4 * vector_a, vector_4 * vector_b) { return (vector_a->x * vector_b->x + vector_a->y * vector_b->y + vector_a->z * vector_b->z + vector_a->w * vector_b->w); } -static float vector_2_cross_product (const vector_2 * vector_a, const vector_2 * vector_b) { +static float vector_2_cross_product (vector_2 * vector_a, vector_2 * vector_b) { return (vector_a->x * vector_b->y - vector_a->y * vector_b->x); } -static vector_3 * vector_3_cross_product (vector_3 * destination, const vector_3 * source) { +static vector_3 * vector_3_cross_product (vector_3 * destination, vector_3 * source) { destination->x = destination->y * source->z - destination->z * source->y; destination->y = destination->z * source->x - destination->x * source->z; destination->z = destination->x * source->y - destination->y * source->x; diff --git a/xerminal.h b/xerminal.h index fb402a8..e1a4cda 100755 --- a/xerminal.h +++ b/xerminal.h @@ -208,8 +208,8 @@ static void terminal_render_character (terminal_structure * terminal, char chara } static void terminal_render_toggle (terminal_structure * terminal, bool toggle, uint x, uint y) { - const char marker = (toggle == true) ? '+' : '-'; - const char colour = (toggle == true) ? colour_green : colour_red; + char marker = (toggle == true) ? '+' : '-'; + char colour = (toggle == true) ? colour_green : colour_red; terminal_render_character (terminal, '[', colour_grey, effect_bold, x + 0, y); terminal_render_character (terminal, marker, colour, effect_bold, x + 1, y); @@ -225,7 +225,7 @@ static void terminal_render_fill_bar (terminal_structure * terminal, uint value, } } -static void terminal_render_string (terminal_structure * terminal, const char * string, uint colour, uint effect, uint x, uint y) { +static void terminal_render_string (terminal_structure * terminal, char * string, uint colour, uint effect, uint x, uint y) { for (uint index = 0; string [index] != '\0'; ++index) { terminal_render_character (terminal, string [index], colour, effect, x + index, y); } @@ -235,7 +235,7 @@ static void terminal_render_number (terminal_structure * terminal, int number, u terminal_render_string (terminal, number_to_string (number), colour, effect, x, y); } -static void terminal_render_string_crop (terminal_structure * terminal, const char * string, uint colour, uint effect, uint x, uint y, uint crop) { +static void terminal_render_string_crop (terminal_structure * terminal, char * string, uint colour, uint effect, uint x, uint y, uint crop) { for (uint index = 0; (string [index] != '\0') && (index < crop); ++index) { terminal_render_character (terminal, string [index], colour, effect, x + index, y); } @@ -280,7 +280,7 @@ static void terminal_render_background (terminal_structure * terminal, char char } } -static void terminal_render_format (terminal_structure * terminal, const char * format, uint x, uint y, ...) { +static void terminal_render_format (terminal_structure * terminal, char * format, uint x, uint y, ...) { va_list list; uint offset_x = 0; diff --git a/xhallenge.c b/xhallenge.c index 2e97aa4..b530ec5 100755 --- a/xhallenge.c +++ b/xhallenge.c @@ -24,21 +24,21 @@ typedef struct { char * * description; } challenge_structure; -static const char * special_name [special_count] = { +static char * special_name [special_count] = { "strength", "perception", "edurance", "charisma", "intelligence", "agility", "luck" }; -static bool challenge_is_repeatable (const challenge_structure * challenges, uint index) { +static bool challenge_is_repeatable (challenge_structure * challenges, uint index) { return ((challenges->type [index] == special_strength + 1) || (challenges->type [index] == special_edurance + 1) || (challenges->type [index] == special_agility + 1)); } -static bool challenge_is_available (const challenge_structure * challenges, uint index) { +static bool challenge_is_available (challenge_structure * challenges, uint index) { return ((challenges->completed [index] == 0) || (challenge_is_repeatable (challenges, index) == true)); } -static bool challenge_is_completable (const uint * special, const challenge_structure * challenges, uint index) { +static bool challenge_is_completable (uint * special, challenge_structure * challenges, uint index) { if (challenge_is_available (challenges, index) == false) { return (false); } @@ -52,7 +52,7 @@ static bool challenge_is_completable (const uint * special, const challenge_stru return (true); } -static void render_challenge_list (terminal_structure * terminal, const uint * special, const challenge_structure * challenges, uint x, uint y) { +static void render_challenge_list (terminal_structure * terminal, uint * special, challenge_structure * challenges, uint x, uint y) { uint count = 0; uint * array = allocate (challenges->count * sizeof (* array)); @@ -83,10 +83,10 @@ static void render_challenge_list (terminal_structure * terminal, const uint * s array = deallocate (array); } -static void render_special_attributes (terminal_structure * terminal, const uint * special, uint offset, uint selection) { +static void render_special_attributes (terminal_structure * terminal, uint * special, uint offset, uint selection) { for (uint index = 0; index < special_count; ++index) { - const uint effect = (selection == index) ? effect_bold : effect_normal; - const uint length = attribute_maximum + 3; + uint effect = (selection == index) ? effect_bold : effect_normal; + uint length = attribute_maximum + 3; char name [32] = ""; @@ -104,7 +104,7 @@ static void prompt_special_attributes (uint * special) { uint selection = 0; bool show_help = false; - const char * main_messages [] = { + char * main_messages [] = { "Press H or Tab to toggle help.", "Press Q or Escape to use default settings.", "Press S or Enter to save changes.", @@ -112,7 +112,7 @@ static void prompt_special_attributes (uint * special) { "Choose your SPECIAL attributes:" }; - const char * help_messages [] = { + char * help_messages [] = { "Show help - H or Tab", "Use default settings - Q or Escape", "Save and quit - S or Enter", @@ -137,7 +137,7 @@ static void prompt_special_attributes (uint * special) { if (show_help == true) { for (uint index = 0; index < array_length (help_messages); ++index) { - const uint offset = array_length (main_messages) + special_count + 2; + uint offset = array_length (main_messages) + special_count + 2; terminal_render_string (terminal, help_messages [index], colour_white, effect_normal, 0, index + offset); } @@ -215,7 +215,7 @@ static void import_user_configuration (uint * special, uint challenge_count, uin information = deallocate (information); } -static void export_user_configuration (const uint * special, const uint * daily_challenges, const bool * completition) { +static void export_user_configuration (uint * special, uint * daily_challenges, bool * completition) { char buffer [4096] = ""; for (uint index = 0; index < special_count; ++index) { @@ -365,7 +365,7 @@ static void export_challenges (challenge_structure * challenges) { file = file_close (file); } -static uint generate_challenge (const uint * special, const challenge_structure * challenges) { +static uint generate_challenge (uint * special, challenge_structure * challenges) { uint index = urandomize (0, challenges->count - 1); bool valid = false; @@ -386,7 +386,7 @@ static uint generate_challenge (const uint * special, const challenge_structure return (index); } -static void generate_challenges (const uint * special, const challenge_structure * challenges, uint * * daily_challenges, bool * * completition) { +static void generate_challenges (uint * special, challenge_structure * challenges, uint * * daily_challenges, bool * * completition) { (* daily_challenges) = allocate (challenges_per_day * sizeof (* * daily_challenges)); (* completition) = allocate (challenges_per_day * sizeof (* * completition)); @@ -395,14 +395,14 @@ static void generate_challenges (const uint * special, const challenge_structure } } -static void render_challenges (const uint * special, challenge_structure * challenges, uint * daily_challenges, bool * completition) { +static void render_challenges (uint * special, challenge_structure * challenges, uint * daily_challenges, bool * completition) { terminal_structure * terminal = terminal_initialize (); uint selection = 0; bool show_help = false; bool show_list = false; - const char * main_messages [] = { + char * main_messages [] = { "Press H or Tab to toggle help.", "Press Q or Escape to quit the program without saving changes.", "Press S or Enter to save changes and quit the program.", @@ -410,7 +410,7 @@ static void render_challenges (const uint * special, challenge_structure * chall "Your daily challenges:" }; - const char * help_messages [] = { + char * help_messages [] = { "Show help - H or Tab", "Quit - Q or Escape", "Save and quit - S or Enter", @@ -434,11 +434,11 @@ static void render_challenges (const uint * special, challenge_structure * chall char * class = challenges->class [daily_challenges [index]]; char * description = challenges->description [daily_challenges [index]]; - const uint effect = (selection == index) ? effect_bold : effect_normal; + uint effect = (selection == index) ? effect_bold : effect_normal; - const uint offset = array_length (main_messages) + 2; + uint offset = array_length (main_messages) + 2; - const uint alignment = string_length (class) + 4; + uint alignment = string_length (class) + 4; terminal_render_toggle (terminal, completition [index], 0, index + offset); @@ -452,7 +452,7 @@ static void render_challenges (const uint * special, challenge_structure * chall } if (show_help == true) { - const uint offset = array_length (main_messages) + challenges_per_day + 3; + uint offset = array_length (main_messages) + challenges_per_day + 3; for (uint index = 0; index < array_length (help_messages); ++index) { terminal_render_string (terminal, help_messages [index], colour_white, effect_normal, 0, index + offset); diff --git a/xhape.h b/xhape.h new file mode 100644 index 0000000..f8fe666 --- /dev/null +++ b/xhape.h @@ -0,0 +1,175 @@ +/// _ +/// __ _| |__ __ _ _ __ ___ +/// \ \/ / '_ \ / _` | '_ \ / _ \ +/// > <| | | | (_| | |_) | __/ +/// /_/\_\_| |_|\__,_| .__/ \___| +/// |_| +/// +/// Copyright (c) 1997 - Ognjen 'xolatile' Milan Robovic +/// +/// xolatile@chud.cyou - xhape - Simplistic programmer art 3D model creator library. +/// +/// This program is free software, free as in freedom and as in free beer, you can redistribute it and/or modify it under the terms of the GNU +/// General Public License as published by the Free Software Foundation, either version 3 of the License, or any later version if you wish... +/// +/// This program is distributed in the hope that it will be useful, but it is probably not, and without any warranty, without even the implied +/// warranty of merchantability or fitness for a particular purpose, because it is pointless. Please see the GNU (Geenoo) General Public License +/// for more details, if you dare, it is a lot of text that nobody wants to read... + +typedef struct { + uint vertex_count; + uint index_count; + uint vertex_limit; + uint index_limit; + float * vertex_array; + uint * index_array; +} shape_node; + +static shape_node * shape_allocate (uint vertex_limit, uint index_limit) { + shape_node * shape = allocate (sizeof (* shape)); + + shape->vertex_limit = vertex_limit; + shape->index_limit = index_limit; + + shape->vertex_array = allocate (vertex_limit * sizeof (* shape->vertex_array)); + shape->index_array = allocate (index_limit * sizeof (* shape->index_array)); + + return (shape); +} + +static shape_node * shape_deallocate (shape_node * shape) { + shape->vertex_array = deallocate (shape->vertex_array); + shape->index_array = deallocate (shape->index_array); + + return (deallocate (shape)); +} + +static void shape_add_vertex_unwrap_colour (shape_node * shape, float x, float y, float z, float u, float v, uint colour) { + fatal_failure (shape->vertex_count + 9 > shape->vertex_limit, "shape_add_vertex"); + + if (shape->vertex_count + 9 > shape->vertex_limit) return; + + shape->vertex_array [shape->vertex_count + 0] = x; + shape->vertex_array [shape->vertex_count + 1] = y; + shape->vertex_array [shape->vertex_count + 2] = z; + shape->vertex_array [shape->vertex_count + 3] = u; + shape->vertex_array [shape->vertex_count + 4] = v; + shape->vertex_array [shape->vertex_count + 5] = normal_r (colour); + shape->vertex_array [shape->vertex_count + 6] = normal_g (colour); + shape->vertex_array [shape->vertex_count + 7] = normal_b (colour); + shape->vertex_array [shape->vertex_count + 8] = normal_a (colour); + + shape->vertex_count += 9; +} + +static void shape_add_index (shape_node * shape, uint a, uint b, uint c) { + fatal_failure (shape->index_count + 3 > shape->index_limit, "shape_add_index"); + + if (shape->index_count + 3 > shape->index_limit) return; + + shape->index_array [shape->index_count + 0] = a; + shape->index_array [shape->index_count + 1] = b; + shape->index_array [shape->index_count + 2] = c; + + shape->index_count += 3; +} + +//~static shape_node * shape_tetrahedron_unwrap (float x, float y, float z, float scale) { +//~static shape_node * shape_tetrahedron_unwrap_colour (float x, float y, float z, float scale, uint colour) { +static shape_node * shape_tetrahedron_colour (float x, float y, float z, float scale, uint colour) { + shape_node * shape = shape_allocate (4 * 9, 4 * 3); + + float vertices [12] = { + x + scale, y + scale, z + scale, + x - scale, y - scale, z + scale, + x - scale, y + scale, z - scale, + x + scale, y - scale, z - scale + }; + + for (uint vertex = 0; vertex < 4; ++vertex) { + float x = vertices [3 * vertex + 0]; + float y = vertices [3 * vertex + 1]; + float z = vertices [3 * vertex + 2]; + float u = (binary_sign (vertex >> 0) + 1.0f) / 2.0f; + float v = (binary_sign (vertex >> 1) + 1.0f) / 2.0f; + + shape_add_vertex_unwrap_colour (shape, x, y, z, u, v, colour); + } + + shape_add_index (shape, 0, 1, 2); + shape_add_index (shape, 0, 3, 1); + shape_add_index (shape, 0, 2, 3); + shape_add_index (shape, 1, 3, 2); + + return (shape); +} + +//~static shape_node * shape_square (vector_3 * origin, float scale, uint colour) { + //~shape_node * shape = shape_allocate (4, 2 * 3); + + //~shape_set_origin (shape, origin); + + //~float central = square_root (2.0f) * scale / 2.0f; + + //~vector_4 normal_colour = { + //~normal_r (colour), + //~normal_b (colour), + //~normal_g (colour), + //~normal_a (colour) + //~}; + + //~for (uint vertex = 0; vertex < 4; ++vertex) { + //~vector_3 point = { + //~origin->x + binary_sign (vertex >> 0) * central, + //~origin->y + binary_sign (vertex >> 1) * central, + //~origin->z + //~}; + + //~vector_2 unwrap = { + //~(binary_sign (vertex >> 0) + 1.0f) / 2.0f, + //~(binary_sign (vertex >> 1) + 1.0f) / 2.0f + //~}; + + //~shape_add_vertex (shape, & point, & unwrap, & normal_colour); + //~} + + //~shape_add_index (shape, 0, 1, 2); + //~shape_add_index (shape, 1, 3, 2); + + //~return (shape); +//~} + +//~static shape_node * shape_cube (vector_3 * origin, float scale, uint colour) { + //~shape_node * shape = shape_allocate (8, 12 * 3); + + //~shape_set_origin (shape, origin); + + //~float central = square_root (3.0f) * scale / 2.0f; + + //~vector_4 normal_colour = { + //~normal_r (colour), + //~normal_b (colour), + //~normal_g (colour), + //~normal_a (colour) + //~}; + + //~for (uint vertex = 0; vertex < 8; ++vertex) { + //~vector_3 point = { + //~origin->x + binary_sign (vertex >> 0) * central, + //~origin->y + binary_sign (vertex >> 1) * central, + //~origin->z + binary_sign (vertex >> 2) * central + //~}; + + //~vector_2 unwrap = { + //~0.0f, + //~0.0f + //~}; + + //~shape_add_vertex (shape, & point, & unwrap, & normal_colour); + //~} + + //~shape_add_index (shape, 0, 1, 2); + //~shape_add_index (shape, 1, 3, 2); + + //~return (shape); +//~} diff --git a/xiasma.h b/xiasma.h index c699e27..de68aa4 100755 --- a/xiasma.h +++ b/xiasma.h @@ -313,7 +313,7 @@ static int build_single (int * array) { static int build_static_1 (int * array) { int operation = array [0]; - const unsigned char data [] = { + unsigned char data [] = { 0x90, 0xc3, 0xcb, 0xc9, 0x9d, 0x9c }; @@ -325,7 +325,7 @@ static int build_static_1 (int * array) { static int build_static_2 (int * array) { int operation = array [0]; - const unsigned short data [] = { + unsigned short data [] = { 0x050f, 0xa20f, 0xd0d9, 0xe0d9, 0xe1d9, 0xe4d9, 0xe5d9, 0xe8d9, 0xe9d9, 0xead9, 0xebd9, 0xecd9, 0xedd9, 0xeed9, 0xf0d9, 0xf1d9, 0xf2d9, 0xf3d9, 0xf4d9, 0xf5d9, 0xf6d9, 0xf7d9, 0xf8d9, 0xf9d9, diff --git a/xighlight.c b/xighlight.c index aa792c6..c6178d3 100755 --- a/xighlight.c +++ b/xighlight.c @@ -44,13 +44,13 @@ static void print_help (void) { print ("\t/6$ xighlight file.ext/- /0---/- Language is automatically detected in this case.\n\n"); print ("Supported languages:\n\n"); - for (uint index = 0; index < language_count; ++index) { + for (language_enumeration index = 0; index < language_count; ++index) { char align [32] = ""; print ("\t/B/4%s/- /4%s/- /0---/- %s syntax highlighting\n", - language_short_option (index), - string_align_left (string_copy (align, language_long_option (index)), 9, ' '), - language_identifier (index)); + language_short_option [index], + string_align_left (string_copy (align, language_long_option [index]), 9, ' '), + language_identifier [index]); } } @@ -78,8 +78,8 @@ int main (int argc, char * * argv) { } for (uint index = 0; index < language_count; ++index) { - if (argument_compare (argv [argument], language_short_option (index), language_long_option (index)) == true) { - (* (language_highlighter (index))) (language, syntax); + if (argument_compare (argv [argument], language_short_option [index], language_long_option [index]) == true) { + (* (language_highlighter [index])) (language, syntax); select = index; break; } diff --git a/xision.h b/xision.h new file mode 100644 index 0000000..4e20795 --- /dev/null +++ b/xision.h @@ -0,0 +1,997 @@ +/// _ _ +/// __ _(_)___(_) ___ _ __ +/// \ \/ / / __| |/ _ \| '_ \ +/// > <| \__ \ | (_) | | | | +/// /_/\_\_|___/_|\___/|_| |_| +/// +/// Copyright (c) 1997 - Ognjen 'xolatile' Milan Robovic +/// +/// xolatile@chud.cyou - xision - General 3D GLFW, OpenGL and OpenAL wrapper library. +/// +/// This program is free software, free as in freedom and as in free beer, you can redistribute it and/or modify it under the terms of the GNU +/// General Public License as published by the Free Software Foundation, either version 3 of the License, or any later version if you wish... +/// +/// This program is distributed in the hope that it will be useful, but it is probably not, and without any warranty, without even the implied +/// warranty of merchantability or fitness for a particular purpose, because it is pointless. Please see the GNU (Geenoo) General Public License +/// for more details, if you dare, it is a lot of text that nobody wants to read... + +#include + +#define vision_font_width (8) +#define vision_font_height (16) + +typedef struct { + GLFWwindow * window; + + PFNGLGENVERTEXARRAYSPROC glGenVertexArrays; + PFNGLBINDVERTEXARRAYPROC glBindVertexArray; + PFNGLGENBUFFERSPROC glGenBuffers; + PFNGLBINDBUFFERPROC glBindBuffer; + PFNGLCREATESHADERPROC glCreateShader; + PFNGLSHADERSOURCEPROC glShaderSource; + PFNGLCOMPILESHADERPROC glCompileShader; + PFNGLCREATEPROGRAMPROC glCreateProgram; + PFNGLATTACHSHADERPROC glAttachShader; + PFNGLBINDFRAGDATALOCATIONPROC glBindFragDataLocation; + PFNGLLINKPROGRAMPROC glLinkProgram; + PFNGLUSEPROGRAMPROC glUseProgram; + PFNGLGETATTRIBLOCATIONPROC glGetAttribLocation; + PFNGLENABLEVERTEXATTRIBARRAYPROC glEnableVertexAttribArray; + PFNGLVERTEXATTRIBPOINTERPROC glVertexAttribPointer; + PFNGLUNIFORM1IPROC glUniform1i; + PFNGLUNIFORM1FPROC glUniform1f; + PFNGLDELETEVERTEXARRAYSPROC glDeleteVertexArrays; + PFNGLDELETEBUFFERSPROC glDeleteBuffers; + PFNGLDELETESHADERPROC glDeleteShader; + PFNGLDELETEPROGRAMPROC glDeleteProgram; + PFNGLGETUNIFORMLOCATIONPROC glGetUniformLocation; + PFNGLBUFFERDATAPROC glBufferData; + PFNGLUNIFORMMATRIX4FVPROC glUniformMatrix4fv; + + bool signal [signal_count]; + bool cursor [cursor_count]; + int cursor_x; + int cursor_y; + + bool using_precomputed_spritesheet; + ulong spritesheet_size; + ulong vertex_limit; + ulong index_limit; + uint gameplay_framerate; + uint animation_framerate; + uint tab_width; + uint default_font; + bool active; + uint window_width; + uint window_height; + float pixel_width; + float pixel_height; + uint framerate; + ulong frame_time; + ulong frame_begin; + ulong frame_end; + uint global_tick; + uint gameplay_tick; + uint animation_tick; + bool freeze_cursor; + bool freeze_signal; + uint vertex_object; + uint vertex_buffer; + uint index_buffer; + uint vertex_shader; + uint fragment_shader; + uint shader_program; + uint spritesheet; + uint vertex_count; + uint index_count; + float * vertex_array; + uint * index_array; + uint sprite_count; + uint font_count; + uint * spritesheet_data; + uint * * sprite_data; + uint * sprite_width; + uint * sprite_height; + float * sprite_u; + float * sprite_v; + uint * * font_index; + uint * * font_width; + uint * * font_height; + char * font_begin; + char * font_end; + float projection_matrix [16]; + float movement_matrix [16]; + float rotation_matrix [16]; + float aspect_ratio; + float field_of_view; + float far_plane; + float near_plane; + float camera_x; + float camera_y; + float sensitivity; +} vision_structure; + +static uint vision_sprite_raw_import (vision_structure * vision, uint * data, uint width, uint height) { + fatal_failure (vision->active == true, "vision_sprite_raw_import: OpenGL renderer is already initialized."); + fatal_failure (data == null, "vision_sprite_raw_import: Data is null pointer."); + fatal_failure (width == 0, "vision_sprite_raw_import: Font image width is zero."); + fatal_failure (height == 0, "vision_sprite_raw_import: Font image height is zero."); + + ++vision->sprite_count; + + vision->sprite_data = reallocate (vision->sprite_data, vision->sprite_count * sizeof (* vision->sprite_data)); + vision->sprite_width = reallocate (vision->sprite_width, vision->sprite_count * sizeof (* vision->sprite_width)); + vision->sprite_height = reallocate (vision->sprite_height, vision->sprite_count * sizeof (* vision->sprite_height)); + vision->sprite_u = reallocate (vision->sprite_u, vision->sprite_count * sizeof (* vision->sprite_u)); + vision->sprite_v = reallocate (vision->sprite_v, vision->sprite_count * sizeof (* vision->sprite_v)); + + vision->sprite_data [vision->sprite_count - 1] = data; + vision->sprite_width [vision->sprite_count - 1] = width; + vision->sprite_height [vision->sprite_count - 1] = height; + vision->sprite_u [vision->sprite_count - 1] = 0; + vision->sprite_v [vision->sprite_count - 1] = 0; + + return (vision->sprite_count - 1); +} + +static uint vision_font_raw_import (vision_structure * vision, uint * data, uint image_width, char begin, char end, uint empty) { + uint pointer = 0; + uint width = 0; + uint height = 0; + + fatal_failure (vision->active == true, "vision_font_raw_import: OpenGL renderer is already initialized."); + fatal_failure (data == null, "vision_font_raw_import: Data is null pointer."); + fatal_failure (image_width == 0, "vision_font_raw_import: Font image width is zero."); + fatal_failure (begin >= end, "vision_font_raw_import: Font character range is inverted."); + + ++vision->font_count; + + vision->font_index = reallocate (vision->font_index, vision->font_count * sizeof (* vision->font_index)); + vision->font_width = reallocate (vision->font_width, vision->font_count * sizeof (* vision->font_width)); + vision->font_height = reallocate (vision->font_height, vision->font_count * sizeof (* vision->font_height)); + vision->font_begin = reallocate (vision->font_begin, vision->font_count * sizeof (* vision->font_begin)); + vision->font_end = reallocate (vision->font_end, vision->font_count * sizeof (* vision->font_end)); + + vision->font_begin [vision->font_count - 1] = begin; + vision->font_end [vision->font_count - 1] = end; + + vision->font_index [vision->font_count - 1] = allocate ((ulong) (end - begin + 1) * sizeof (* * vision->font_index)); + vision->font_width [vision->font_count - 1] = allocate ((ulong) (end - begin + 1) * sizeof (* * vision->font_width)); + vision->font_height [vision->font_count - 1] = allocate ((ulong) (end - begin + 1) * sizeof (* * vision->font_height)); + + for (char index = begin; index <= end; ++index) { + for ( ; data [pointer] == empty; ++pointer); + for (width = 0; data [pointer + width] != empty; ++width); + for (height = 0; data [pointer + height * image_width] != empty; ++height); + + uint * buffer = allocate (width * height * sizeof (* buffer)); + + for (uint y = 0; y < height; ++y) { + for (uint x = 0; x < width; ++x) { + buffer [y * width + x] = data [pointer + (y * image_width) + x]; + } + } + + vision->font_index [vision->font_count - 1] [index - begin] = vision_sprite_raw_import (vision, buffer, width, height); + vision->font_width [vision->font_count - 1] [index - begin] = width; + vision->font_height [vision->font_count - 1] [index - begin] = height; + + pointer += width; + + for (; data [pointer] == empty; ++pointer); + + if (pointer % image_width == 2) { + pointer += height * image_width; + } + } + + return (vision->font_count - 1); +} + +static uint vision_sprite_import (vision_structure * vision, char * path) { + uint width = 0; + uint height = 0; + uint * data = null; + + data = format_image_import (path, & width, & height); + + return (vision_sprite_raw_import (vision, data, width, height)); +} + +static uint vision_font_import (vision_structure * vision, char * path, char begin, char end, uint colour) { + uint width = 0; + uint height = 0; + uint result = 0; + uint * data = null; + + data = format_image_import (path, & width, & height); + + result = vision_font_raw_import (vision, data, width, begin, end, colour); + + data = deallocate (data); + + return (result); +} + +static uint vision_sprite_width (vision_structure * vision, uint sprite) { + return (vision->sprite_width [sprite]); +} + +static uint vision_sprite_height (vision_structure * vision, uint sprite) { + return (vision->sprite_height [sprite]); +} + +static uint vision_center_x (vision_structure * vision, uint size) { + return ((vision->window_width - size) / 2); +} + +static uint vision_center_y (vision_structure * vision, uint size) { + return ((vision->window_height - size) / 2); +} + +static bool vision_cursor_inside (vision_structure * vision, int x, int y, uint width, uint height) { + return ((vision->cursor_x > x) && + (vision->cursor_y > y) && + (vision->cursor_x < x + (int) width) && + (vision->cursor_y < y + (int) height)); +} + +static bool vision_cursor_left_click (vision_structure * vision, int x, int y, uint width, uint height) { + if (vision->cursor [cursor_left] == true) { + vision->freeze_cursor = true; + + return (vision_cursor_inside (vision, x, y, width, height) == true); + } + + return (false); +} + +static bool vision_cursor_right_click (vision_structure * vision, int x, int y, uint width, uint height) { + if (vision->cursor [cursor_right]) { + vision->freeze_cursor = true; + + return (vision_cursor_inside (vision, x, y, width, height)); + } + + return (false); +} + +static void vision_import_spritesheet (vision_structure * vision, char * data_file) { + int file = file_open (data_file, file_flag_read); + + fatal_failure (vision->active == true, "vision_import_spritesheet: OpenGL renderer is already initialized."); + + file_read (file, & vision->spritesheet_size, sizeof (vision->spritesheet_size)); + + file_read (file, & vision->sprite_count, sizeof (vision->sprite_count)); + + vision->sprite_width = allocate (vision->sprite_count * sizeof (* vision->sprite_width)); + vision->sprite_height = allocate (vision->sprite_count * sizeof (* vision->sprite_height)); + vision->sprite_u = allocate (vision->sprite_count * sizeof (* vision->sprite_u)); + vision->sprite_v = allocate (vision->sprite_count * sizeof (* vision->sprite_v)); + + file_read (file, vision->sprite_width, vision->sprite_count * sizeof (* vision->sprite_width)); + file_read (file, vision->sprite_height, vision->sprite_count * sizeof (* vision->sprite_height)); + file_read (file, vision->sprite_u, vision->sprite_count * sizeof (* vision->sprite_u)); + file_read (file, vision->sprite_v, vision->sprite_count * sizeof (* vision->sprite_v)); + + file_read (file, & vision->font_count, sizeof (vision->font_count)); + + vision->font_index = allocate (vision->font_count * sizeof (* vision->font_index)); + vision->font_width = allocate (vision->font_count * sizeof (* vision->font_width)); + vision->font_height = allocate (vision->font_count * sizeof (* vision->font_height)); + vision->font_begin = allocate (vision->font_count * sizeof (* vision->font_begin)); + vision->font_end = allocate (vision->font_count * sizeof (* vision->font_end)); + + file_read (file, vision->font_begin, vision->font_count * sizeof (* vision->font_begin)); + file_read (file, vision->font_end, vision->font_count * sizeof (* vision->font_end)); + + for (uint index = 0; index < vision->font_count; ++index) { + uint range = (uint) (vision->font_end [index] - vision->font_begin [index]) + 1; + + vision->font_index [index] = allocate (range * sizeof (* * vision->font_index)); + vision->font_width [index] = allocate (range * sizeof (* * vision->font_width)); + vision->font_height [index] = allocate (range * sizeof (* * vision->font_height)); + + for (uint subindex = 0; subindex < range; ++subindex) { + file_read (file, & vision->font_index [index] [subindex], sizeof (* * vision->font_index)); + file_read (file, & vision->font_width [index] [subindex], sizeof (* * vision->font_width)); + file_read (file, & vision->font_height [index] [subindex], sizeof (* * vision->font_height)); + } + } + + file = file_close (file); + + vision->sprite_count = 0; + vision->font_count = 0; +} + +static void vision_export_spritesheet (vision_structure * vision, char * data_file) { + int file = file_open (data_file, file_flag_write | file_flag_create | file_flag_truncate); + + fatal_failure (vision->spritesheet_data == null, "vision_export_spritesheet: OpenGL renderer can't access spritesheet data."); + + file_write (file, & vision->spritesheet_size, sizeof (vision->spritesheet_size)); + + file_write (file, & vision->sprite_count, sizeof (vision->sprite_count)); + + file_write (file, vision->sprite_width, vision->sprite_count * sizeof (* vision->sprite_width)); + file_write (file, vision->sprite_height, vision->sprite_count * sizeof (* vision->sprite_height)); + file_write (file, vision->sprite_u, vision->sprite_count * sizeof (* vision->sprite_u)); + file_write (file, vision->sprite_v, vision->sprite_count * sizeof (* vision->sprite_v)); + + file_write (file, & vision->font_count, sizeof (vision->font_count)); + + file_write (file, vision->font_begin, vision->font_count * sizeof (* vision->font_begin)); + file_write (file, vision->font_end, vision->font_count * sizeof (* vision->font_end)); + + for (uint index = 0; index < vision->font_count; ++index) { + for (uint subindex = 0; subindex < (uint) (vision->font_end [index] - vision->font_begin [index]) + 1; ++subindex) { + file_write (file, & vision->font_index [index] [subindex], sizeof (* * vision->font_index)); + file_write (file, & vision->font_width [index] [subindex], sizeof (* * vision->font_width)); + file_write (file, & vision->font_height [index] [subindex], sizeof (* * vision->font_height)); + } + } + + file = file_close (file); + + print ("/c Exported internal binary data of OpenGL spritesheet."); +} + +static vision_structure * vision_initialize (uint gameplay_framerate, uint animation_framerate, bool use_precomputed_spritesheet, + uint vertex_limit, uint index_limit, uint spritesheet_side) { + vision_structure * vision = allocate (sizeof (* vision)); + + vision->using_precomputed_spritesheet = use_precomputed_spritesheet; + + vision->spritesheet_size = spritesheet_side; + vision->gameplay_framerate = gameplay_framerate; + vision->animation_framerate = animation_framerate; + vision->vertex_limit = vertex_limit; + vision->index_limit = index_limit; + vision->tab_width = 4; + vision->default_font = ~0u; + vision->field_of_view = 2.0f; + vision->far_plane = 100.0f; + vision->near_plane = 0.1f; + vision->sensitivity = 0.1f; + + if (use_precomputed_spritesheet == true) { + print ("[/0Comment/-] Importing spritesheet image and information...\n"); + + vision_import_spritesheet (vision, "binary/spritesheet.bin"); + } + + print ("[/2Success/-] Initialized OpenGL renderer.\n"); + + return (vision); +} + +static vision_structure * vision_deinitialize (vision_structure * vision) { + vision->active = false; + + for (uint index = 0; index < vision->font_count; ++index) { + vision->font_index [index] = deallocate (vision->font_index [index]); + vision->font_width [index] = deallocate (vision->font_width [index]); + vision->font_height [index] = deallocate (vision->font_height [index]); + } + + vision->font_index = deallocate (vision->font_index); + vision->font_width = deallocate (vision->font_width); + vision->font_height = deallocate (vision->font_height); + vision->font_begin = deallocate (vision->font_begin); + vision->font_end = deallocate (vision->font_end); + + vision->sprite_width = deallocate (vision->sprite_width); + vision->sprite_height = deallocate (vision->sprite_height); + vision->sprite_u = deallocate (vision->sprite_u); + vision->sprite_v = deallocate (vision->sprite_v); + + if (vision->using_precomputed_spritesheet == false) { + vision->spritesheet_data = deallocate (vision->spritesheet_data); + } + + vision->vertex_array = deallocate (vision->vertex_array); + vision->index_array = deallocate (vision->index_array); + + glDeleteTextures (1, & vision->spritesheet); + + vision->glDeleteProgram (vision->shader_program); + vision->glDeleteShader (vision->fragment_shader); + vision->glDeleteShader (vision->vertex_shader); + + vision->glDeleteBuffers (1, & vision->index_buffer); + vision->glDeleteBuffers (1, & vision->vertex_buffer); + vision->glDeleteVertexArrays (1, & vision->vertex_object); + + glfwDestroyWindow (vision->window); + + glfwTerminate (); + + print ("[/2Success/-] Deinitialized OpenGL renderer.\n"); + + return (deallocate (vision)); +} + +static void vision_configure (vision_structure * vision, uint window_width, uint window_height, char * window_title) { + ulong font_bitmap [190] = { + 0x0000000000000000, 0x0000000000000000, 0x0000101010101010, 0x1000101000000000, 0x0024242400000000, 0x0000000000000000, + 0x00002424247e2424, 0x7e24242400000000, 0x0010107c9290907c, 0x1212927c10100000, 0x0000649468081010, 0x202c524c00000000, + 0x000018242418304a, 0x4444443a00000000, 0x0010101000000000, 0x0000000000000000, 0x0000081020202020, 0x2020100800000000, + 0x0000201008080808, 0x0808102000000000, 0x000000000024187e, 0x1824000000000000, 0x000000000010107c, 0x1010000000000000, + 0x0000000000000000, 0x0000101020000000, 0x000000000000007e, 0x0000000000000000, 0x0000000000000000, 0x0000101000000000, + 0x0000040408081010, 0x2020404000000000, 0x00003c4242464a52, 0x6242423c00000000, 0x0000081828080808, 0x0808083e00000000, + 0x00003c4242020408, 0x1020407e00000000, 0x00003c4242021c02, 0x0242423c00000000, 0x000002060a122242, 0x7e02020200000000, + 0x00007e4040407c02, 0x0202423c00000000, 0x00001c2040407c42, 0x4242423c00000000, 0x00007e0202040408, 0x0810101000000000, + 0x00003c4242423c42, 0x4242423c00000000, 0x00003c424242423e, 0x0202043800000000, 0x0000000000101000, 0x0000101000000000, + 0x0000000000101000, 0x0000101020000000, 0x0000000408102040, 0x2010080400000000, 0x00000000007e0000, 0x7e00000000000000, + 0x0000004020100804, 0x0810204000000000, 0x00003c4242420408, 0x0800080800000000, 0x00007c829ea2a2a2, 0xa69a807e00000000, + 0x00003c424242427e, 0x4242424200000000, 0x00007c4242427c42, 0x4242427c00000000, 0x00003c4242404040, 0x4042423c00000000, + 0x0000784442424242, 0x4242447800000000, 0x00007e4040407840, 0x4040407e00000000, 0x00007e4040407840, 0x4040404000000000, + 0x00003c424240404e, 0x4242423c00000000, 0x0000424242427e42, 0x4242424200000000, 0x0000381010101010, 0x1010103800000000, + 0x00000e0404040404, 0x0444443800000000, 0x0000424448506060, 0x5048444200000000, 0x0000404040404040, 0x4040407e00000000, + 0x000082c6aa929282, 0x8282828200000000, 0x000042424262524a, 0x4642424200000000, 0x00003c4242424242, 0x4242423c00000000, + 0x00007c424242427c, 0x4040404000000000, 0x00003c4242424242, 0x42424a3c02000000, 0x00007c424242427c, 0x5048444200000000, + 0x00003c4240403c02, 0x0242423c00000000, 0x0000fe1010101010, 0x1010101000000000, 0x0000424242424242, 0x4242423c00000000, + 0x0000424242424224, 0x2424181800000000, 0x0000828282828292, 0x92aac68200000000, 0x0000424224241818, 0x2424424200000000, + 0x0000828244442810, 0x1010101000000000, 0x00007e0202040810, 0x2040407e00000000, 0x0000382020202020, 0x2020203800000000, + 0x0000404020201010, 0x0808040400000000, 0x0000380808080808, 0x0808083800000000, 0x0000102844000000, 0x0000000000000000, + 0x0000000000000000, 0x0000007e00000000, 0x1008000000000000, 0x0000000000000000, 0x00000000003c023e, 0x4242423e00000000, + 0x00004040407c4242, 0x4242427c00000000, 0x00000000003c4240, 0x4040423c00000000, 0x00000202023e4242, 0x4242423e00000000, + 0x00000000003c4242, 0x7e40403c00000000, 0x00000e10107c1010, 0x1010101000000000, 0x00000000003e4242, 0x4242423e02023c00, + 0x00004040407c4242, 0x4242424200000000, 0x0000101000301010, 0x1010103800000000, 0x00000404000c0404, 0x0404040444443800, + 0x0000404040424448, 0x7048444200000000, 0x0000301010101010, 0x1010103800000000, 0x0000000000fc9292, 0x9292929200000000, + 0x00000000007c4242, 0x4242424200000000, 0x00000000003c4242, 0x4242423c00000000, 0x00000000007c4242, 0x4242427c40404000, + 0x00000000003e4242, 0x4242423e02020200, 0x00000000005e6040, 0x4040404000000000, 0x00000000003e4040, 0x3c02027c00000000, + 0x00001010107c1010, 0x1010100e00000000, 0x0000000000424242, 0x4242423e00000000, 0x0000000000424242, 0x2424181800000000, + 0x0000000000828292, 0x9292927c00000000, 0x0000000000424224, 0x1824424200000000, 0x0000000000424242, 0x4242423e02023c00, + 0x00000000007e0408, 0x1020407e00000000, 0x00000c1010102010, 0x1010100c00000000, 0x0000101010101010, 0x1010101000000000, + 0x0000300808080408, 0x0808083000000000, 0x000000000062928c, 0x0000000000000000 + }; + + char * vertex_shader = + "#version 330 core\n" + "in vec3 vertex_xyz;\n" + "in vec2 vertex_uv;\n" + "in vec4 vertex_rgba;\n" + "out vec2 fragment_uv;\n" + "out vec4 fragment_rgba;\n" + "uniform mat4 projection_matrix;\n" + "uniform mat4 movement_matrix;\n" + "uniform mat4 rotation_matrix;\n" + "void main () {\n" + " gl_Position = movement_matrix * rotation_matrix * projection_matrix * vec4 (vertex_xyz, 1.0);\n" + " fragment_uv = vertex_uv;\n" + " fragment_rgba = vertex_rgba;\n" + "}\n"; + + char * fragment_shader = + "#version 330 core\n" + "uniform sampler2D texture_p;\n" + "in vec2 fragment_uv;\n" + "in vec4 fragment_rgba;\n" + "out vec4 data;\n" + "void main () {\n" + " data = texture (texture_p, fragment_uv) * fragment_rgba;\n" + "}\n"; + + uint * dumb_buffer = null; + uint * order = null; + + uint xyz_attribute = 0; + uint uv_attribute = 0; + uint rgba_attribute = 0; + + uint u = 0; + uint v = 0; + + if (vision->using_precomputed_spritesheet == true) { + for (uint index = 0; index < 95; ++index) { + vision->font_index [vision->font_count] [index] = ++vision->sprite_count - 1; + } + + ++vision->sprite_count; + ++vision->font_count; + + goto ignore_import; + } + + dumb_buffer = allocate (256 * sizeof (* dumb_buffer)); + + for (uint index = 0; index < 256; ++index) { + dumb_buffer [index] = 0xffffffff; + } + + ++vision->font_count; + + uint current = vision->font_count - 1; + + vision->font_index = reallocate (vision->font_index, vision->font_count * sizeof (* vision->font_index)); + vision->font_width = reallocate (vision->font_width, vision->font_count * sizeof (* vision->font_width)); + vision->font_height = reallocate (vision->font_height, vision->font_count * sizeof (* vision->font_height)); + vision->font_begin = reallocate (vision->font_begin, vision->font_count * sizeof (* vision->font_begin)); + vision->font_end = reallocate (vision->font_end, vision->font_count * sizeof (* vision->font_end)); + + vision->font_begin [vision->font_count - 1] = ' '; + vision->font_end [vision->font_count - 1] = '~'; + + vision->font_index [vision->font_count - 1] = allocate (95 * sizeof (* * vision->font_index)); + vision->font_width [vision->font_count - 1] = allocate (95 * sizeof (* * vision->font_width)); + vision->font_height [vision->font_count - 1] = allocate (95 * sizeof (* * vision->font_height)); + + for (uint index = 0; index < 95; ++index) { + uint * buffer = allocate (vision_font_width * vision_font_height * sizeof (* buffer)); + + for (uint value = 0; value < 2; ++value) { + for (uint bit = 64; bit > 0; --bit) { + uint destination = ((value << 3) - ((bit - 1) >> 3) + 7) * vision_font_width - ((bit - 1) & 7) + 7; + uint source = (font_bitmap [2 * index + value] >> (bit - 1)) & 1; + + buffer [destination] = (source) ? 0xffffffff : 0x00000000; + } + } + + vision->font_index [current] [index] = vision_sprite_raw_import (vision, buffer, vision_font_width, vision_font_height); + vision->font_width [current] [index] = vision_font_width; + vision->font_height [current] [index] = vision_font_height; + } + + vision_sprite_raw_import (vision, dumb_buffer, 16, 16); + + vision->spritesheet_data = allocate (vision->spritesheet_size * vision->spritesheet_size * sizeof (* vision->spritesheet_data)); + + order = allocate (vision->sprite_count * sizeof (* order)); + + for (uint index = 0; index < vision->sprite_count; ++index) { + order [index] = index; + } + + for (uint index = 0; index < vision->sprite_count; ++index) { + for (uint subindex = 0; subindex < vision->sprite_count; ++subindex) { + if (vision->sprite_height [order [index]] < vision->sprite_height [order [subindex]]) { + uint temporary = order [index]; + + order [index] = order [subindex]; + order [subindex] = temporary; + } + } + } + + for (uint index = 0; index < vision->sprite_count; ++index) { + if (u + vision->sprite_width [order [index]] >= vision->spritesheet_size) { + u *= 0; + v += vision->sprite_height [order [index]]; + } + + vision->sprite_u [order [index]] = (float) u / (float) vision->spritesheet_size; + vision->sprite_v [order [index]] = (float) v / (float) vision->spritesheet_size; + + for (uint y = 0; y < vision->sprite_height [order [index]]; ++y) { + for (uint x = 0; x < vision->sprite_width [order [index]]; ++x) { + uint destination = (v + y) * vision->spritesheet_size + (u + x); + uint source = y * vision->sprite_width [order [index]] + x; + + vision->spritesheet_data [destination] = vision->sprite_data [order [index]] [source]; + } + } + + u += vision->sprite_width [order [index]]; + + vision->sprite_data [order [index]] = deallocate (vision->sprite_data [order [index]]); + } + + vision->sprite_data = deallocate (vision->sprite_data); + order = deallocate (order); + + ignore_import: + + vision->window_width = window_width; + vision->window_height = window_height; + + vision->aspect_ratio = (float) window_height / (float) window_width; + + vision->pixel_width = 2.0f / (float) window_width; + vision->pixel_height = 2.0f / (float) window_height; + + glfwInit (); + + glfwWindowHint (GLFW_CONTEXT_VERSION_MAJOR, 3); + glfwWindowHint (GLFW_CONTEXT_VERSION_MINOR, 3); + glfwWindowHint (GLFW_OPENGL_PROFILE, GLFW_OPENGL_CORE_PROFILE); + glfwWindowHint (GLFW_OPENGL_FORWARD_COMPAT, 1); + + vision->window = glfwCreateWindow ((int) window_width, (int) window_height, window_title, null, null); + + fatal_failure (vision->window == null, "Failed to create GLFW window.\n"); + + glfwSetWindowSizeLimits (vision->window, 320, 240, 1920, 1080); + + //~glfwSetInputMode (vision->window, GLFW_CURSOR, GLFW_CURSOR_HIDDEN); + //~glfwSetInputMode (vision->window, GLFW_CURSOR, GLFW_CURSOR_DISABLED); + + glfwSetCursorPos (vision->window, (double) vision->window_width / 2.0, (double) vision->window_height / 2.0); + + glfwMakeContextCurrent (vision->window); + + vision->glGenVertexArrays = (PFNGLGENVERTEXARRAYSPROC) glfwGetProcAddress ("glGenVertexArrays"); + vision->glBindVertexArray = (PFNGLBINDVERTEXARRAYPROC) glfwGetProcAddress ("glBindVertexArray"); + vision->glGenBuffers = (PFNGLGENBUFFERSPROC) glfwGetProcAddress ("glGenBuffers"); + vision->glBindBuffer = (PFNGLBINDBUFFERPROC) glfwGetProcAddress ("glBindBuffer"); + vision->glCreateShader = (PFNGLCREATESHADERPROC) glfwGetProcAddress ("glCreateShader"); + vision->glShaderSource = (PFNGLSHADERSOURCEPROC) glfwGetProcAddress ("glShaderSource"); + vision->glCompileShader = (PFNGLCOMPILESHADERPROC) glfwGetProcAddress ("glCompileShader"); + vision->glCreateProgram = (PFNGLCREATEPROGRAMPROC) glfwGetProcAddress ("glCreateProgram"); + vision->glAttachShader = (PFNGLATTACHSHADERPROC) glfwGetProcAddress ("glAttachShader"); + vision->glBindFragDataLocation = (PFNGLBINDFRAGDATALOCATIONPROC) glfwGetProcAddress ("glBindFragDataLocation"); + vision->glLinkProgram = (PFNGLLINKPROGRAMPROC) glfwGetProcAddress ("glLinkProgram"); + vision->glUseProgram = (PFNGLUSEPROGRAMPROC) glfwGetProcAddress ("glUseProgram"); + vision->glGetAttribLocation = (PFNGLGETATTRIBLOCATIONPROC) glfwGetProcAddress ("glGetAttribLocation"); + vision->glEnableVertexAttribArray = (PFNGLENABLEVERTEXATTRIBARRAYPROC) glfwGetProcAddress ("glEnableVertexAttribArray"); + vision->glVertexAttribPointer = (PFNGLVERTEXATTRIBPOINTERPROC) glfwGetProcAddress ("glVertexAttribPointer"); + vision->glUniform1i = (PFNGLUNIFORM1IPROC) glfwGetProcAddress ("glUniform1i"); + vision->glUniform1f = (PFNGLUNIFORM1FPROC) glfwGetProcAddress ("glUniform1f"); + vision->glDeleteVertexArrays = (PFNGLDELETEVERTEXARRAYSPROC) glfwGetProcAddress ("glDeleteVertexArrays"); + vision->glDeleteBuffers = (PFNGLDELETEBUFFERSPROC) glfwGetProcAddress ("glDeleteBuffers"); + vision->glDeleteShader = (PFNGLDELETESHADERPROC) glfwGetProcAddress ("glDeleteShader"); + vision->glDeleteProgram = (PFNGLDELETEPROGRAMPROC) glfwGetProcAddress ("glDeleteProgram"); + vision->glGetUniformLocation = (PFNGLGETUNIFORMLOCATIONPROC) glfwGetProcAddress ("glGetUniformLocation"); + vision->glBufferData = (PFNGLBUFFERDATAPROC) glfwGetProcAddress ("glBufferData"); + vision->glUniformMatrix4fv = (PFNGLUNIFORMMATRIX4FVPROC) glfwGetProcAddress ("glUniformMatrix4fv"); + + glViewport (0, 0, (int) window_width, (int) window_height); + + glBlendFunc (GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); + glDepthFunc (GL_LESS); + + glEnable (GL_DEPTH_TEST); + glEnable (GL_CULL_FACE); + glEnable (GL_BLEND); + + vision->glGenVertexArrays (1, & vision->vertex_object); + vision->glBindVertexArray (vision->vertex_object); + + vision->glGenBuffers (1, & vision->vertex_buffer); + vision->glBindBuffer (GL_ARRAY_BUFFER, vision->vertex_buffer); + + vision->glGenBuffers (1, & vision->index_buffer); + vision->glBindBuffer (GL_ELEMENT_ARRAY_BUFFER, vision->index_buffer); + + vision->vertex_shader = vision->glCreateShader (GL_VERTEX_SHADER); + + vision->glShaderSource (vision->vertex_shader, 1, & vertex_shader, null); + vision->glCompileShader (vision->vertex_shader); + + vision->fragment_shader = vision->glCreateShader (GL_FRAGMENT_SHADER); + + vision->glShaderSource (vision->fragment_shader, 1, & fragment_shader, null); + vision->glCompileShader (vision->fragment_shader); + + vision->shader_program = vision->glCreateProgram (); + + vision->glAttachShader (vision->shader_program, vision->vertex_shader); + vision->glAttachShader (vision->shader_program, vision->fragment_shader); + + vision->glBindFragDataLocation (vision->shader_program, 0, "data"); + + vision->glLinkProgram (vision->shader_program); + vision->glUseProgram (vision->shader_program); + + xyz_attribute = (uint) vision->glGetAttribLocation (vision->shader_program, "vertex_xyz"); + + vision->glEnableVertexAttribArray (xyz_attribute); + + vision->glVertexAttribPointer (xyz_attribute, 3, GL_FLOAT, GL_FALSE, 9 * sizeof (float), (void *) 0); + + uv_attribute = (uint) vision->glGetAttribLocation (vision->shader_program, "vertex_uv"); + + vision->glEnableVertexAttribArray (uv_attribute); + + vision->glVertexAttribPointer (uv_attribute, 2, GL_FLOAT, GL_FALSE, 9 * sizeof (float), (void *) (3 * sizeof (float))); + + rgba_attribute = (uint) vision->glGetAttribLocation (vision->shader_program, "vertex_rgba"); + + vision->glEnableVertexAttribArray (rgba_attribute); + + vision->glVertexAttribPointer (rgba_attribute, 4, GL_FLOAT, GL_FALSE, 9 * sizeof (float), (void *) (5 * sizeof (float))); + + vision->vertex_array = allocate (vision->vertex_limit * sizeof (vision->vertex_array)); + vision->index_array = allocate (vision->index_limit * sizeof (vision->index_array)); + + for (uint index = 0; index < 16; ++index) { + vision->projection_matrix [index] = 0.0f; + vision->movement_matrix [index] = 0.0f; + vision->rotation_matrix [index] = 0.0f; + } + + vision->movement_matrix [0] = vision->movement_matrix [5] = vision->movement_matrix [10] = vision->movement_matrix [15] = 1.0f; + vision->rotation_matrix [0] = vision->rotation_matrix [5] = vision->rotation_matrix [10] = vision->rotation_matrix [15] = 1.0f; + + vision->projection_matrix [ 0] = vision->aspect_ratio / tangent (vision->field_of_view / 2.0f); + vision->projection_matrix [ 5] = 1.0f / tangent (vision->field_of_view / 2.0f); + vision->projection_matrix [10] = vision->far_plane / (vision->far_plane - vision->near_plane); + vision->projection_matrix [11] = 1.0f; + vision->projection_matrix [14] = (- vision->far_plane * vision->near_plane) / (vision->far_plane - vision->near_plane); + + vision->glUniformMatrix4fv (vision->glGetUniformLocation (vision->shader_program, "projection_matrix"), 1, GL_FALSE, + vision->projection_matrix); + + vision->glUniformMatrix4fv (vision->glGetUniformLocation (vision->shader_program, "movement_matrix"), 1, GL_FALSE, + vision->movement_matrix); + + vision->glUniformMatrix4fv (vision->glGetUniformLocation (vision->shader_program, "rotation_matrix"), 1, GL_FALSE, + vision->rotation_matrix); + + glGenTextures (1, & vision->spritesheet); + + glBindTexture (GL_TEXTURE_2D, vision->spritesheet); + + glTexImage2D (GL_TEXTURE_2D, 0, GL_RGBA, vision->spritesheet_size, vision->spritesheet_size, 0, GL_RGBA, GL_UNSIGNED_BYTE, + vision->spritesheet_data); + + vision->glUniform1i (vision->glGetUniformLocation (vision->shader_program, "texture_p"), 0); + //~vision->glUniform1f (vision->glGetUniformLocation (vision->shader_program, "aspect_ratio"), vision->aspect_ratio); + + glTexParameteri (GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); + glTexParameteri (GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT); + glTexParameteri (GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST); + glTexParameteri (GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST); + + if (vision->using_precomputed_spritesheet == true) { + vision->spritesheet_data = deallocate (vision->spritesheet_data); + } + + vision->active = true; + + vision->frame_begin = nano_time (); + + glClearColor (0.0f, 0.0f, 0.0f, 1.0f); + + glClear (GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); + + print ("[/2Success/-] Configured OpenGL renderer.\n"); +} + +static void vision_synchronize (vision_structure * vision, uint colour) { + int signal_code [signal_count] = { + 0, + GLFW_KEY_A, GLFW_KEY_B, GLFW_KEY_C, GLFW_KEY_D, + GLFW_KEY_E, GLFW_KEY_F, GLFW_KEY_G, GLFW_KEY_H, + GLFW_KEY_I, GLFW_KEY_J, GLFW_KEY_K, GLFW_KEY_L, + GLFW_KEY_M, GLFW_KEY_N, GLFW_KEY_O, GLFW_KEY_P, + GLFW_KEY_Q, GLFW_KEY_R, GLFW_KEY_S, GLFW_KEY_T, + GLFW_KEY_U, GLFW_KEY_V, GLFW_KEY_W, GLFW_KEY_X, + GLFW_KEY_Y, GLFW_KEY_Z, GLFW_KEY_0, GLFW_KEY_1, + GLFW_KEY_2, GLFW_KEY_3, GLFW_KEY_4, GLFW_KEY_5, + GLFW_KEY_6, GLFW_KEY_7, GLFW_KEY_8, GLFW_KEY_9, + GLFW_KEY_ESCAPE, GLFW_KEY_TAB, GLFW_KEY_ENTER, GLFW_KEY_ENTER, + GLFW_KEY_SLASH, GLFW_KEY_BACKSLASH, GLFW_KEY_SEMICOLON, GLFW_KEY_GRAVE_ACCENT, + GLFW_KEY_SPACE, GLFW_KEY_BACKSPACE, GLFW_KEY_PERIOD, GLFW_KEY_COMMA, + GLFW_KEY_APOSTROPHE, GLFW_KEY_CAPS_LOCK, GLFW_KEY_MINUS, GLFW_KEY_EQUAL, + GLFW_KEY_LEFT_BRACKET, GLFW_KEY_RIGHT_BRACKET, GLFW_KEY_LEFT_CONTROL, GLFW_KEY_RIGHT_CONTROL, + GLFW_KEY_LEFT_SHIFT, GLFW_KEY_RIGHT_SHIFT, GLFW_KEY_LEFT_ALT, GLFW_KEY_RIGHT_ALT, + GLFW_KEY_F1, GLFW_KEY_F2, GLFW_KEY_F3, GLFW_KEY_F4, + GLFW_KEY_F5, GLFW_KEY_F6, GLFW_KEY_F7, GLFW_KEY_F8, + GLFW_KEY_F9, GLFW_KEY_F10, GLFW_KEY_F11, GLFW_KEY_F12, + GLFW_KEY_UP, GLFW_KEY_DOWN, GLFW_KEY_LEFT, GLFW_KEY_RIGHT, + GLFW_KEY_NUM_LOCK, GLFW_KEY_PAUSE, GLFW_KEY_INSERT, GLFW_KEY_HOME, + GLFW_KEY_PAGE_UP, GLFW_KEY_DELETE, GLFW_KEY_END, GLFW_KEY_PAGE_DOWN, + GLFW_KEY_KP_ADD, GLFW_KEY_KP_SUBTRACT, GLFW_KEY_KP_MULTIPLY, GLFW_KEY_KP_DIVIDE, + GLFW_KEY_KP_ENTER, GLFW_KEY_KP_DECIMAL, GLFW_KEY_KP_0, GLFW_KEY_KP_1, + GLFW_KEY_KP_2, GLFW_KEY_KP_3, GLFW_KEY_KP_4, GLFW_KEY_KP_5, + GLFW_KEY_KP_6, GLFW_KEY_KP_7, GLFW_KEY_KP_8, GLFW_KEY_KP_9 + }; + + int new_window_width = 0; + int new_window_height = 0; + + glClearColor (normal_r (colour), normal_g (colour), normal_b (colour), normal_a (colour)); + + glClear (GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); + + glfwPollEvents (); + + glfwSetWindowShouldClose (vision->window, vision->active == false); + + glfwGetWindowSize (vision->window, & new_window_width, & new_window_height); + + if ((vision->window_width != (uint) new_window_width) || (vision->window_height != (uint) new_window_height)) { + if ((new_window_width <= 0) || (new_window_height <= 0)) return; + + glViewport (0, 0, new_window_width, new_window_height); + + vision->window_width = (uint) new_window_width; + vision->window_height = (uint) new_window_height; + + vision->pixel_width = 2.0f / (float) new_window_width; + vision->pixel_height = 2.0f / (float) new_window_height; + } + + vision->cursor [cursor_left] = (bool) (glfwGetMouseButton (vision->window, GLFW_MOUSE_BUTTON_LEFT) == GLFW_PRESS); + vision->cursor [cursor_middle] = (bool) (glfwGetMouseButton (vision->window, GLFW_MOUSE_BUTTON_MIDDLE) == GLFW_PRESS); + vision->cursor [cursor_right] = (bool) (glfwGetMouseButton (vision->window, GLFW_MOUSE_BUTTON_RIGHT) == GLFW_PRESS); + + glfwSetCursorPos (vision->window, (double) vision->window_width / 2.0, (double) vision->window_height / 2.0); + + if (vision->freeze_cursor == false) { + double x = 0.0; + double y = 0.0; + + glfwGetCursorPos (vision->window, & x, & y); + + vision->cursor_x = (int) x; + vision->cursor_y = (int) y; + + //~float offset_x = vision->camera_x - x; + + //~for (uint index = 0; index < 16; ++index) { + //~vision->rotation_matrix [index] = 0.0f; + //~} + + //~offset_x *= vision->sensitivity; + + //~vision->rotation_matrix [0] = vision->rotation_matrix [5] = vision->rotation_matrix [10] = vision->rotation_matrix [15] = 1.0f; + + //~vision->rotation_matrix [5] = vision->rotation_matrix [10] = cosine (offset_x); + //~vision->rotation_matrix [6] = vision->rotation_matrix [ 9] = sine (offset_x); + + //~vision->rotation_matrix [6] *= - 1.0f; + + //~vision->glUniformMatrix4fv (vision->glGetUniformLocation (vision->shader_program, "rotation_matrix"), 1, GL_FALSE, + //~vision->rotation_matrix); + + //~vision->camera_x = x; + } else { + if ((vision->cursor [cursor_left] == false) + && (vision->cursor [cursor_middle] == false) + && (vision->cursor [cursor_right] == false)) { + vision->freeze_cursor = false; + } + } + + if (vision->freeze_signal == false) { + for (uint index = 0; index < signal_count; ++index) { + vision->signal [index] = (bool) (glfwGetKey (vision->window, signal_code [index]) == GLFW_PRESS); + } + } + + vision->glBufferData (GL_ARRAY_BUFFER, vision->vertex_count * 4, vision->vertex_array, GL_DYNAMIC_DRAW); + vision->glBufferData (GL_ELEMENT_ARRAY_BUFFER, vision->index_count * 4, vision->index_array, GL_DYNAMIC_DRAW); + + vision->glBindBuffer (GL_ARRAY_BUFFER, vision->vertex_buffer); + + glDrawElements (GL_TRIANGLES, (int) vision->index_count * 4, GL_UNSIGNED_INT, null); + + glfwSwapBuffers (vision->window); + + vision->vertex_count = 0; + vision->index_count = 0; + + vision->frame_end = nano_time (); + + vision->frame_time = vision->frame_end - vision->frame_begin; + + if (vision->frame_time < 1000000000ul / vision->gameplay_framerate) { + nano_wait (1000000000ul / vision->gameplay_framerate - vision->frame_time); + } + + if (vision->global_tick % vision->gameplay_framerate == 0) { + vision->framerate = (uint) (1000000000ul / vision->frame_time); + } + + ++vision->global_tick; + + vision->global_tick = vision->global_tick % (vision->gameplay_framerate * vision->animation_framerate); + vision->gameplay_tick = vision->global_tick % (vision->gameplay_framerate); + vision->animation_tick = vision->global_tick / (vision->gameplay_framerate / vision->animation_framerate); + + vision->frame_begin = nano_time (); +} + +static void vision_render_base (vision_structure * vision, uint vertex_count, float * vertex_array, uint index_count, + uint * index_array, uint sprite, uint colour) { + if (sprite >= vision->sprite_count) return; + if (vision->vertex_count + vertex_count >= vision->vertex_limit) return; + if (vision->index_count + index_count >= vision->index_limit) return; + + float unwrap_x = (float) vision->sprite_u [sprite] / (float) vision->spritesheet_size; + float unwrap_y = (float) vision->sprite_v [sprite] / (float) vision->spritesheet_size; + + float unwrap_width = (float) vision->sprite_width [sprite] / (float) vision->spritesheet_size; + float unwrap_height = (float) vision->sprite_height [sprite] / (float) vision->spritesheet_size; + + //~for (uint vertex = 0; vertex < vertex_count; ++vertex) { + //~uint destination = 9 * vertex + vision->vertex_count; + //~uint source = 5 * vertex; + + //~vision->vertex_array [destination + 0] = vertex_array [source + 0]; + //~vision->vertex_array [destination + 1] = vertex_array [source + 1]; + //~vision->vertex_array [destination + 2] = vertex_array [source + 2]; + //~vision->vertex_array [destination + 3] = vertex_array [source + 3] * unwrap_width + unwrap_x; + //~vision->vertex_array [destination + 4] = vertex_array [source + 4] * unwrap_height + unwrap_y; + //~vision->vertex_array [destination + 5] = normal_r (colour); + //~vision->vertex_array [destination + 6] = normal_g (colour); + //~vision->vertex_array [destination + 7] = normal_b (colour); + //~vision->vertex_array [destination + 8] = normal_a (colour); + //~} + + for (uint vertex = 0; vertex < vertex_count; ++vertex) { + vision->vertex_array [vision->vertex_count + vertex] = vertex_array [vertex]; + } + + //~vision->vertex_array [destination + 3] = vertex_array [source + 3] * unwrap_width + unwrap_x; + //~vision->vertex_array [destination + 4] = vertex_array [source + 4] * unwrap_height + unwrap_y; + + for (uint index = 0; index < index_count; ++index) { + vision->index_array [vision->index_count + index] = index_array [index]; + } + + //~vision->vertex_count += 36 * vertex_count; + //~vision->index_count += 3 * index_count; + vision->vertex_count += vertex_count; + vision->index_count += index_count; +} + +//~static void vision_render_triangle (vision_structure * vision, float * vertex_array, uint colour) { + //~if (vision->vertex_count + 3 * 36 >= vision->vertex_limit) return; + //~if (vision->index_count + 3 >= vision->index_limit) return; + + //~for (uint vertex = 0; vertex < 3; ++vertex) { + //~uint destination = 9 * vertex + vision->vertex_count; + //~uint source = 5 * vertex; + + //~vision->vertex_array [destination + 0] = vertex_array [source + 0]; + //~vision->vertex_array [destination + 1] = vertex_array [source + 1]; + //~vision->vertex_array [destination + 2] = vertex_array [source + 2]; + //~vision->vertex_array [destination + 3] = (binary_sign (vertex >> 0) + 1.0f) / 2.0f; + //~vision->vertex_array [destination + 4] = (binary_sign (vertex >> 1) + 1.0f) / 2.0f; + //~vision->vertex_array [destination + 5] = normal_r (colour); + //~vision->vertex_array [destination + 6] = normal_g (colour); + //~vision->vertex_array [destination + 7] = normal_b (colour); + //~vision->vertex_array [destination + 8] = normal_a (colour); + //~} + + //~for (uint index = 0; index < 3; ++index) { + //~vision->index_array [vision->index_count + index] = vision->vertex_array [vision->vertex_count / 9 + index]; + //~} + + //~vision->vertex_count += 108; + //~vision->index_count += 3; +//~} + +static void vision_change_field_of_view (vision_structure * vision, float change) { + vision->field_of_view += change; + + vision->projection_matrix [ 0] = vision->aspect_ratio / tangent (vision->field_of_view / 2.0f); + vision->projection_matrix [ 5] = 1.0f / tangent (vision->field_of_view / 2.0f); + + vision->glUniformMatrix4fv (vision->glGetUniformLocation (vision->shader_program, "projection_matrix"), 1, GL_FALSE, + vision->projection_matrix); +} + +static void vision_change_translation (vision_structure * vision, float x, float y, float z) { + vision->movement_matrix [ 3] += x; + vision->movement_matrix [ 7] += y; + vision->movement_matrix [11] += z; + + vision->glUniformMatrix4fv (vision->glGetUniformLocation (vision->shader_program, "movement_matrix"), 1, GL_FALSE, + vision->movement_matrix); +} + +static void vision_change_rotation (vision_structure * vision, float vertical, float horizontal) { + for (uint index = 0; index < 16; ++index) { + vision->rotation_matrix [index] = 0.0f; + } + + vision->rotation_matrix [0] = vision->rotation_matrix [5] = vision->rotation_matrix [10] = vision->rotation_matrix [15] = 1.0f; + + vision->rotation_matrix [5] = vision->rotation_matrix [10] = cosine (vertical); + vision->rotation_matrix [6] = vision->rotation_matrix [ 9] = sine (vertical); + + vision->rotation_matrix [6] *= - 1.0f; + + vision->glUniformMatrix4fv (vision->glGetUniformLocation (vision->shader_program, "rotation_matrix"), 1, GL_FALSE, + vision->rotation_matrix); +} + +#undef vision_font_width +#undef vision_font_height diff --git a/xommon.h b/xommon.h index 91ba248..da0aa01 100755 --- a/xommon.h +++ b/xommon.h @@ -77,15 +77,15 @@ typedef struct { char * font_end; } common_structure; -static uint common_center_x (const common_structure * common, uint size) { +static uint common_center_x (common_structure * common, uint size) { return ((common->window_width - size) / 2); } -static uint common_center_y (const common_structure * common, uint size) { +static uint common_center_y (common_structure * common, uint size) { return ((common->window_height - size) / 2); } -static bool common_cursor_inside (const common_structure * common, int x, int y, uint width, uint height) { +static bool common_cursor_inside (common_structure * common, int x, int y, uint width, uint height) { return ((common->cursor_x > x) && (common->cursor_y > y) && (common->cursor_x < x + (int) width) @@ -176,7 +176,7 @@ static uint common_font_raw_import (common_structure * common, uint * data, uint return (common->font_count - 1); } -static uint common_sprite_import (common_structure * common, const char * path) { +static uint common_sprite_import (common_structure * common, char * path) { uint width = 0; uint height = 0; uint * data = null; @@ -200,7 +200,7 @@ static uint common_sprite_import (common_structure * common, const char * path) return (common_sprite_raw_import (common, data, width, height)); } -static uint common_font_import (common_structure * common, const char * path, char begin, char end, uint colour) { +static uint common_font_import (common_structure * common, char * path, char begin, char end, uint colour) { uint width = 0; uint height = 0; uint result = 0; @@ -229,11 +229,11 @@ static uint common_font_import (common_structure * common, const char * path, ch return (result); } -static uint common_sprite_width (const common_structure * common, uint sprite) { +static uint common_sprite_width (common_structure * common, uint sprite) { return (common->sprite_width [sprite]); } -static uint common_sprite_height (const common_structure * common, uint sprite) { +static uint common_sprite_height (common_structure * common, uint sprite) { return (common->sprite_height [sprite]); } @@ -275,8 +275,8 @@ static common_structure * common_deinitialize (common_structure * common) { return (deallocate (common)); } -static void common_configure (common_structure * common, uint width, uint height, const char * title, uint window_flags) { - const ulong font_bitmap [190] = { +static void common_configure (common_structure * common, uint width, uint height, char * title, uint window_flags) { + ulong font_bitmap [190] = { 0x0000000000000000, 0x0000000000000000, 0x0000101010101010, 0x1000101000000000, 0x0024242400000000, 0x0000000000000000, 0x00002424247e2424, 0x7e24242400000000, 0x0010107c9290907c, 0x1212927c10100000, 0x0000649468081010, 0x202c524c00000000, 0x000018242418304a, 0x4444443a00000000, 0x0010101000000000, 0x0000000000000000, 0x0000081020202020, 0x2020100800000000, @@ -311,7 +311,7 @@ static void common_configure (common_structure * common, uint width, uint height 0x0000300808080408, 0x0808083000000000, 0x000000000062928c, 0x0000000000000000 }; - const uint event_mask = XCB_CW_BACK_PIXEL | XCB_CW_EVENT_MASK; + uint event_mask = XCB_CW_BACK_PIXEL | XCB_CW_EVENT_MASK; uint mask_window_flags [2] = { 0 }; @@ -407,7 +407,7 @@ static void common_configure (common_structure * common, uint width, uint height } static void common_synchronize (common_structure * common, uint colour) { - const uint signal_code [signal_count] = { + uint signal_code [signal_count] = { 0, 38, 56, 54, 40, 26, 41, 42, 43, 31, 44, 45, 46, 58, 57, 32, 33, 24, 27, 39, 28, 30, 55, 25, 53, 29, 52, 19, 10, 11, 12, 13, 14, @@ -538,10 +538,10 @@ static void common_render_base (common_structure * common, uint sprite, int x, i /// COLOUR INTERPOLATION WITH RBGA-ABGR CONVERSION uint interpolate_pixels (uint pixel, uint modifier) { - const uint r = (((pixel & 0xff000000) >> 24) * ((modifier & 0x000000ff) >> 0)) / 0xff; - const uint g = (((pixel & 0x00ff0000) >> 16) * ((modifier & 0x0000ff00) >> 8)) / 0xff; - const uint b = (((pixel & 0x0000ff00) >> 8) * ((modifier & 0x00ff0000) >> 16)) / 0xff; - const uint a = (((pixel & 0x000000ff) >> 0) * ((modifier & 0xff000000) >> 24)) / 0xff; + uint r = (((pixel & 0xff000000) >> 24) * ((modifier & 0x000000ff) >> 0)) / 0xff; + uint g = (((pixel & 0x00ff0000) >> 16) * ((modifier & 0x0000ff00) >> 8)) / 0xff; + uint b = (((pixel & 0x0000ff00) >> 8) * ((modifier & 0x00ff0000) >> 16)) / 0xff; + uint a = (((pixel & 0x000000ff) >> 0) * ((modifier & 0xff000000) >> 24)) / 0xff; return ((r << 24) | (g << 16) | (b << 8) | a); } @@ -556,8 +556,8 @@ static void common_render_base (common_structure * common, uint sprite, int x, i if (horizontal + x >= common->window_width) break; if (horizontal + u >= common->sprite_width [sprite]) break; - const uint pixel = common->sprite_data [sprite] [(vertical + v) * common->sprite_width [sprite] + horizontal + u]; - const uint at = (y + vertical) * common->window_width + (x + horizontal); + uint pixel = common->sprite_data [sprite] [(vertical + v) * common->sprite_width [sprite] + horizontal + u]; + uint at = (y + vertical) * common->window_width + (x + horizontal); common->framebuffer [at] = (((pixel & 0xff000000) >> 24) > 0x77) ? interpolate_pixels (pixel, upper_left) : common->framebuffer [at]; } @@ -617,7 +617,7 @@ static void common_render_sprite_control (common_structure * common, uint sprite common_render_base (common, sprite, x, y, u, v, width, height, 1, 1, flip_x, flip_y, 0xffffffffu, 0xffffffffu, 0xffffffffu, 0xffffffffu); } -static uint common_render_string_width (common_structure * common, const char * string, uint font, float scale) { +static uint common_render_string_width (common_structure * common, char * string, uint font, float scale) { uint length = 0; if (string == null) { @@ -633,7 +633,7 @@ static uint common_render_string_width (common_structure * common, const char * return (length); } -static void common_render_string (common_structure * common, const char * string, uint font, int x, int y, float scale, uint colour) { +static void common_render_string (common_structure * common, char * string, uint font, int x, int y, float scale, uint colour) { int offset = x; if (string == null) return; diff --git a/xormat.h b/xormat.h index 992d710..cb9b030 100644 --- a/xormat.h +++ b/xormat.h @@ -31,48 +31,48 @@ #include #endif -static void * format_image_import (const char * path, uint * width, uint * height) { +static void * format_image_import (char * path, uint * width, uint * height) { uint * data = null; -#ifdef use_png_library - if (data == null) { - char buffer [256] = ""; +//~#ifdef use_png_library + //~if (data == null) { + //~char buffer [256] = ""; - if (file_exists (string_concatenate (string_copy (buffer, path), ".png")) == true) { - data = png_image_import (buffer, width, height); - } - } -#endif + //~if (file_exists (string_concatenate (string_copy (buffer, path), ".png")) == true) { + //~data = png_image_import (buffer, width, height); + //~} + //~} +//~#endif -#ifdef use_jxl_library - if (data == null) { - char buffer [256] = ""; +//~#ifdef use_jxl_library + //~if (data == null) { + //~char buffer [256] = ""; - if (file_exists (string_concatenate (string_copy (buffer, path), ".jxl")) == true) { - data = jxl_image_import (buffer, width, height); - } - } -#endif + //~if (file_exists (string_concatenate (string_copy (buffer, path), ".jxl")) == true) { + //~data = jxl_image_import (buffer, width, height); + //~} + //~} +//~#endif -#ifdef use_jpg_library - if (data == null) { - char buffer [256] = ""; +//~#ifdef use_jpg_library + //~if (data == null) { + //~char buffer [256] = ""; - if (file_exists (string_concatenate (string_copy (buffer, path), ".jpg")) == true) { - data = jpg_image_import (buffer, width, height); - } - } -#endif + //~if (file_exists (string_concatenate (string_copy (buffer, path), ".jpg")) == true) { + //~data = jpg_image_import (buffer, width, height); + //~} + //~} +//~#endif -#ifdef use_tga_library - if (data == null) { - char buffer [256] = ""; +//~#ifdef use_tga_library + //~if (data == null) { + //~char buffer [256] = ""; - if (file_exists (string_concatenate (string_copy (buffer, path), ".tga")) == true) { - data = tga_image_import (buffer, width, height); - } - } -#endif + //~if (file_exists (string_concatenate (string_copy (buffer, path), ".tga")) == true) { + //~data = tga_image_import (buffer, width, height); + //~} + //~} +//~#endif if (data == null) { switch (file_type (path)) { diff --git a/xormat/jxl.h b/xormat/jxl.h index 91754ad..37932c5 100644 --- a/xormat/jxl.h +++ b/xormat/jxl.h @@ -4,7 +4,7 @@ #define use_jxl_library #endif -static void * jxl_image_import (const char * path, uint * width, uint * height) { +static void * jxl_image_import (char * path, uint * width, uint * height) { JxlDecoder * decoder = null; JxlBasicInfo information = { 0 }; JxlPixelFormat format = { 4, JXL_TYPE_UINT8, JXL_NATIVE_ENDIAN, 0 }; diff --git a/xormat/ply.h b/xormat/ply.h new file mode 100644 index 0000000..e19efa9 --- /dev/null +++ b/xormat/ply.h @@ -0,0 +1,6 @@ + +#ifndef use_ply_library +#define use_ply_library +#endif + + diff --git a/xormat/png.h b/xormat/png.h index e7b5bdb..cb1f52c 100644 --- a/xormat/png.h +++ b/xormat/png.h @@ -5,7 +5,7 @@ #define use_png_library #endif -static void * png_image_import (const char * path, uint * width, uint * height) { +static void * png_image_import (char * path, uint * width, uint * height) { FILE * file; uint * data; uint index; @@ -87,7 +87,7 @@ static void * png_image_import (const char * path, uint * width, uint * height) return (data); } -static void png_image_export (const char * path, uint * data, uint width, uint height) { +static void png_image_export (char * path, uint * data, uint width, uint height) { png_image image = { 0 }; fatal_failure (path == null, "png_image_export: File path is null pointer."); diff --git a/xpengl.h b/xpengl.h index 125b6ca..6e8dd2d 100755 --- a/xpengl.h +++ b/xpengl.h @@ -184,7 +184,7 @@ static uint opengl_font_raw_import (opengl_structure * opengl, uint * data, uint return (opengl->font_count - 1); } -static uint opengl_sprite_import (opengl_structure * opengl, const char * path) { +static uint opengl_sprite_import (opengl_structure * opengl, char * path) { uint width = 0; uint height = 0; uint * data = null; @@ -214,7 +214,7 @@ static uint opengl_sprite_import (opengl_structure * opengl, const char * path) return (opengl_sprite_raw_import (opengl, data, width, height)); } -static uint opengl_font_import (opengl_structure * opengl, const char * path, char begin, char end, uint colour) { +static uint opengl_font_import (opengl_structure * opengl, char * path, char begin, char end, uint colour) { uint width = 0; uint height = 0; uint result = 0; @@ -296,7 +296,7 @@ static bool opengl_cursor_right_click (opengl_structure * opengl, int x, int y, return (false); } -static void opengl_import_spritesheet (opengl_structure * opengl, const char * data_file) { +static void opengl_import_spritesheet (opengl_structure * opengl, char * data_file) { int file = file_open (data_file, file_flag_read); fatal_failure (opengl->active == true, "opengl_import_spritesheet: OpenGL renderer is already initialized."); @@ -346,7 +346,7 @@ static void opengl_import_spritesheet (opengl_structure * opengl, const char * d opengl->font_count = 0; } -static void opengl_export_spritesheet (opengl_structure * opengl, const char * data_file) { +static void opengl_export_spritesheet (opengl_structure * opengl, char * data_file) { int file = file_open (data_file, file_flag_write | file_flag_create | file_flag_truncate); fatal_failure (opengl->spritesheet_data == null, "opengl_export_spritesheet: OpenGL renderer can't access spritesheet data."); @@ -449,8 +449,8 @@ static opengl_structure * opengl_deinitialize (opengl_structure * opengl) { return (deallocate (opengl)); } -static void opengl_configure (opengl_structure * opengl, uint window_width, uint window_height, const char * window_title) { - const ulong font_bitmap [190] = { +static void opengl_configure (opengl_structure * opengl, uint window_width, uint window_height, char * window_title) { + ulong font_bitmap [190] = { 0x0000000000000000, 0x0000000000000000, 0x0000101010101010, 0x1000101000000000, 0x0024242400000000, 0x0000000000000000, 0x00002424247e2424, 0x7e24242400000000, 0x0010107c9290907c, 0x1212927c10100000, 0x0000649468081010, 0x202c524c00000000, 0x000018242418304a, 0x4444443a00000000, 0x0010101000000000, 0x0000000000000000, 0x0000081020202020, 0x2020100800000000, @@ -485,7 +485,7 @@ static void opengl_configure (opengl_structure * opengl, uint window_width, uint 0x0000300808080408, 0x0808083000000000, 0x000000000062928c, 0x0000000000000000 }; - const char * vertex_shader = + char * vertex_shader = "# version 330 core\n" "in vec2 vertex_xy;\n" "in vec2 vertex_uv;\n" @@ -498,7 +498,7 @@ static void opengl_configure (opengl_structure * opengl, uint window_width, uint " fragment_rgba = vertex_rgba;\n" "}\n"; - const char * fragment_shader = + char * fragment_shader = "# version 330 core\n" "uniform sampler2D texture_p;\n" "in vec2 fragment_uv;\n" @@ -538,7 +538,7 @@ static void opengl_configure (opengl_structure * opengl, uint window_width, uint ++opengl->font_count; - const uint current = opengl->font_count - 1; + uint current = opengl->font_count - 1; opengl->font_index = reallocate (opengl->font_index, opengl->font_count * sizeof (* opengl->font_index)); opengl->font_width = reallocate (opengl->font_width, opengl->font_count * sizeof (* opengl->font_width)); @@ -756,7 +756,7 @@ static void opengl_configure (opengl_structure * opengl, uint window_width, uint } static void opengl_synchronize (opengl_structure * opengl, uint colour) { - const int signal_code [signal_count] = { + int signal_code [signal_count] = { 0, GLFW_KEY_A, GLFW_KEY_B, GLFW_KEY_C, GLFW_KEY_D, GLFW_KEY_E, GLFW_KEY_F, GLFW_KEY_G, GLFW_KEY_H, @@ -948,12 +948,12 @@ static void opengl_render_base (opengl_structure * opengl, uint sprite, int x, i opengl->vertex_array [opengl->vertex_count + 30] = normal_b (colour_lower_right); opengl->vertex_array [opengl->vertex_count + 31] = normal_a (colour_lower_right); - opengl->index_array [opengl->index_count + 0] = (opengl->vertex_count >> 3) + 2; - opengl->index_array [opengl->index_count + 1] = (opengl->vertex_count >> 3) + 1; - opengl->index_array [opengl->index_count + 2] = (opengl->vertex_count >> 3) + 0; - opengl->index_array [opengl->index_count + 3] = (opengl->vertex_count >> 3) + 1; - opengl->index_array [opengl->index_count + 4] = (opengl->vertex_count >> 3) + 2; - opengl->index_array [opengl->index_count + 5] = (opengl->vertex_count >> 3) + 3; + opengl->index_array [opengl->index_count + 0] = (opengl->vertex_count / 8) + 2; + opengl->index_array [opengl->index_count + 1] = (opengl->vertex_count / 8) + 1; + opengl->index_array [opengl->index_count + 2] = (opengl->vertex_count / 8) + 0; + opengl->index_array [opengl->index_count + 3] = (opengl->vertex_count / 8) + 1; + opengl->index_array [opengl->index_count + 4] = (opengl->vertex_count / 8) + 2; + opengl->index_array [opengl->index_count + 5] = (opengl->vertex_count / 8) + 3; opengl->vertex_count += 32; opengl->index_count += 6; @@ -1017,7 +1017,7 @@ static uint opengl_render_character_width (opengl_structure * opengl, char chara if ((character < opengl->font_begin [font]) || (character > opengl->font_end [font])) { return (0); } else { - const uint index = opengl->font_index [font] [character - opengl->font_begin [font]]; + uint index = opengl->font_index [font] [character - opengl->font_begin [font]]; return ((uint) (scale * (float) opengl->sprite_width [index])); } @@ -1027,13 +1027,13 @@ static uint opengl_render_character_height (opengl_structure * opengl, char char if ((character < opengl->font_begin [font]) || (character > opengl->font_end [font])) { return (0); } else { - const uint index = opengl->font_index [font] [character - opengl->font_begin [font]]; + uint index = opengl->font_index [font] [character - opengl->font_begin [font]]; return ((uint) (scale * (float) opengl->sprite_height [index])); } } -static uint opengl_render_string_width (opengl_structure * opengl, const char * string, uint font, float scale) { +static uint opengl_render_string_width (opengl_structure * opengl, char * string, uint font, float scale) { uint width = 0; uint match = 0; @@ -1055,7 +1055,7 @@ static uint opengl_render_string_width (opengl_structure * opengl, const char * return (maximum (width, match)); } -static uint opengl_render_string_height (opengl_structure * opengl, const char * string, uint font, float scale) { +static uint opengl_render_string_height (opengl_structure * opengl, char * string, uint font, float scale) { uint height = opengl_render_character_height (opengl, ' ', font, scale); if ((string == null) || (string [0] == '\0')) { @@ -1079,9 +1079,9 @@ static void opengl_render_character_base (opengl_structure * opengl, char charac font = opengl->font_count - 1; } - const uint index = opengl->font_index [font] [character - opengl->font_begin [font]]; - const uint width = opengl->sprite_width [index]; - const uint height = opengl->sprite_height [index]; + uint index = opengl->font_index [font] [character - opengl->font_begin [font]]; + uint width = opengl->sprite_width [index]; + uint height = opengl->sprite_height [index]; opengl_render_base (opengl, index, x, y, 0, 0, width, height, scale, scale, 0, 0, colour_upper_left, colour_upper_right, colour_lower_left, colour_lower_right); @@ -1101,7 +1101,7 @@ static void opengl_render_character_horizontal_gradient (opengl_structure * open opengl_render_character_base (opengl, character, font, x, y, scale, colour_left, colour_right, colour_left, colour_right); } -static void opengl_render_string_base (opengl_structure * opengl, const char * string, uint font, int x, int y, float scale, +static void opengl_render_string_base (opengl_structure * opengl, char * string, uint font, int x, int y, float scale, uint colour_upper_left, uint colour_upper_right, uint colour_lower_left, uint colour_lower_right) { int offset = x; @@ -1124,28 +1124,28 @@ static void opengl_render_string_base (opengl_structure * opengl, const char * s } } -static void opengl_render_string (opengl_structure * opengl, const char * string, uint font, int x, int y, float scale, uint colour) { +static void opengl_render_string (opengl_structure * opengl, char * string, uint font, int x, int y, float scale, uint colour) { opengl_render_string_base (opengl, string, font, x, y, scale, colour, colour, colour, colour); } -static void opengl_render_string_vertical_gradient (opengl_structure * opengl, const char * string, uint font, int x, int y, float scale, +static void opengl_render_string_vertical_gradient (opengl_structure * opengl, char * string, uint font, int x, int y, float scale, uint colour_up, uint colour_down) { opengl_render_string_base (opengl, string, font, x, y, scale, colour_up, colour_up, colour_down, colour_down); } -static void opengl_render_string_horizontal_gradient (opengl_structure * opengl, const char * string, uint font, int x, int y, float scale, +static void opengl_render_string_horizontal_gradient (opengl_structure * opengl, char * string, uint font, int x, int y, float scale, uint colour_left, uint colour_right) { opengl_render_string_base (opengl, string, font, x, y, scale, colour_left, colour_right, colour_left, colour_right); } -static void opengl_render_string_full_vertical_gradient (opengl_structure * opengl, const char * string, uint font, int x, int y, float scale, +static void opengl_render_string_full_vertical_gradient (opengl_structure * opengl, char * string, uint font, int x, int y, float scale, uint colour_up, uint colour_down) { int offset = x; uint back = 0; uint up = 0; uint down = 0; - const float interpolator = 1.0f / (float) string_full_height (string); + float interpolator = 1.0f / (float) string_full_height (string); if (string == null) return; @@ -1169,14 +1169,14 @@ static void opengl_render_string_full_vertical_gradient (opengl_structure * open } } -static void opengl_render_string_full_horizontal_gradient (opengl_structure * opengl, const char * string, uint font, int x, int y, float scale, +static void opengl_render_string_full_horizontal_gradient (opengl_structure * opengl, char * string, uint font, int x, int y, float scale, uint colour_left, uint colour_right) { int offset = x; uint back = 0; uint left = 0; uint right = 0; - const float interpolator = 1.0f / (float) string_full_width (string, opengl->tab_width); + float interpolator = 1.0f / (float) string_full_width (string, opengl->tab_width); if (string == null) return; diff --git a/xphere.h b/xphere.h index 813c8c5..44e72d3 100755 --- a/xphere.h +++ b/xphere.h @@ -47,16 +47,16 @@ static float sphere_y (float vertical, float z) { } static float sphere_z (float distance, float horizontal, float vertical) { - const float x_over_z = tangent (horizontal); - const float y_over_z = tangent (vertical); + float x_over_z = tangent (horizontal); + float y_over_z = tangent (vertical); return (distance * square_root (1.0f / (x_over_z * x_over_z + y_over_z * y_over_z + 1.0f))); } static void sphere_transpose_x (float * distance, float * horizontal, float x) { - const float origin = (* distance) * (* distance); - const float offset = x * x; - const float square = origin + offset + 2 * x * (* distance) * cosine (* horizontal); + float origin = (* distance) * (* distance); + float offset = x * x; + float square = origin + offset + 2 * x * (* distance) * cosine (* horizontal); * distance = square_root (square); @@ -64,17 +64,17 @@ static void sphere_transpose_x (float * distance, float * horizontal, float x) { } static void sphere_transpose_y (float * distance, float * vertical, float y) { - const float origin = (* distance) * (* distance); - const float offset = y * y; + float origin = (* distance) * (* distance); + float offset = y * y; * distance = square_root (origin + offset + 2 * y * (* distance) * cosine (* vertical)); } static void sphere_transpose_z (float * distance, float * horizontal, float * vertical, float z) { - const float origin = (* distance) * (* distance); - const float offset = z * z; - const float side_a = secant (* vertical); - const float side_b = tangent (* horizontal); + float origin = (* distance) * (* distance); + float offset = z * z; + float side_a = secant (* vertical); + float side_b = tangent (* horizontal); * distance = square_root (origin + offset + 2 * z * (* distance) * square_root (1.0f / (side_a * side_a + sibe_b * side_b))); } diff --git a/xprite.h b/xprite.h index 8753a9e..78665b9 100755 --- a/xprite.h +++ b/xprite.h @@ -85,7 +85,7 @@ static void * sprite_import (char * path, int * width, int * height) { return (data); } -static void sprite_export (const char * path, int width, int height, unsigned int * data) { +static void sprite_export (char * path, int width, int height, unsigned int * data) { int file, move; file = file_open (path, file_flag_edit | file_flag_truncate | file_flag_create); diff --git a/xrena.h b/xrena.h index df32779..79ed962 100755 --- a/xrena.h +++ b/xrena.h @@ -74,7 +74,7 @@ static void * arena_add (ulong size) { return ((void*) & arena->block_array [current]->buffer [arena->block_array [current]->count - size]); } -static char * arena_add_data (const void * data, ulong size) { +static char * arena_add_data (void * data, ulong size) { void * pointer = arena_add (size); memory_copy (pointer, data, size); @@ -82,7 +82,7 @@ static char * arena_add_data (const void * data, ulong size) { return (pointer); } -static char * arena_add_file (const char * path, uint flag, bool null_terminate) { +static char * arena_add_file (char * path, uint flag, bool null_terminate) { int file = -1; ulong size = 0; char * data = null; diff --git a/xrocessor.h b/xrocessor.h index 6b606b1..8934d7c 100755 --- a/xrocessor.h +++ b/xrocessor.h @@ -19,38 +19,38 @@ //~#include //~#include -static int parse_comment (const char * buffer); -static int parse_include (const char * buffer); -static int parse_use (const char * buffer); -static int parse_alias (const char * buffer); -static int parse_macro (const char * buffer); -static int parse_scope (const char * buffer); -static int parse_unscope (const char * buffer); -static int parse_default (const char * buffer); -static void parse_buffer (const char * buffer, int limit); +static int parse_comment (char * buffer); +static int parse_include (char * buffer); +static int parse_use (char * buffer); +static int parse_alias (char * buffer); +static int parse_macro (char * buffer); +static int parse_scope (char * buffer); +static int parse_unscope (char * buffer); +static int parse_default (char * buffer); +static void parse_buffer (char * buffer, int limit); enum { token_comment, token_include, token_use, token_alias, token_macro, token_scope, token_unscope, token_default }; -static const char * token_key [token_default] = { +static char * token_key [token_default] = { "---", "include ", "use ", "alias ", "macro ", "scope ", "unscope " }; -static int (* parse_key [token_default + 1]) (const char * buffer) = { +static int (* parse_key [token_default + 1]) (char * buffer) = { parse_comment, parse_include, parse_use, parse_alias, parse_macro, parse_scope, parse_unscope, parse_default }; static int token_count = 0; static struct { - const char * data; + char * data; int size; int type; } * token_array [token_limit], * token_value [token_limit]; -static int parse_default (const char * buffer) { +static int parse_default (char * buffer) { int select; for (select = 0; select < token_count; ++select) { @@ -80,7 +80,7 @@ static int parse_default (const char * buffer) { return (1); } -static int parse_comment (const char * buffer) { +static int parse_comment (char * buffer) { int offset; for (offset = 3; buffer [offset] != '\0'; ++offset) { @@ -90,7 +90,7 @@ static int parse_comment (const char * buffer) { return (offset + 1); } -static int parse_use (const char * buffer) { +static int parse_use (char * buffer) { int offset; int length; @@ -110,7 +110,7 @@ static int parse_use (const char * buffer) { return (offset + length + 1); } -static int parse_include (const char * buffer) { +static int parse_include (char * buffer) { int length; int offset; char * data; @@ -137,7 +137,7 @@ static int parse_include (const char * buffer) { return (offset + length + 1); } -static int parse_alias (const char * buffer) { +static int parse_alias (char * buffer) { int offset; int length; @@ -167,7 +167,7 @@ static int parse_alias (const char * buffer) { return (offset + length + 1); } -static int parse_macro (const char * buffer) { +static int parse_macro (char * buffer) { int offset; int length; @@ -201,7 +201,7 @@ static int parse_macro (const char * buffer) { return (offset + length + 9 + 1); } -static int parse_scope (const char * buffer) { +static int parse_scope (char * buffer) { int offset; int length; int select; @@ -223,7 +223,7 @@ static int parse_scope (const char * buffer) { return (offset + length + 1); } -static int parse_unscope (const char * buffer) { +static int parse_unscope (char * buffer) { int offset; int length; int select; @@ -247,7 +247,7 @@ static int parse_unscope (const char * buffer) { return (offset + length + 1); } -static void parse_buffer (const char * buffer, int limit) { +static void parse_buffer (char * buffer, int limit) { int offset; int length; int select; diff --git a/xscii.c b/xscii.c index ad22a13..0dff01e 100755 --- a/xscii.c +++ b/xscii.c @@ -19,7 +19,7 @@ static void echo_base (int character, int base, int colour, int effect) { } static void echo_code (int character) { - const char * code [] = { + char * code [] = { "NUL", "SOH", "STX", "ETX", "EOT", "ENQ", "ACK", "BEL", "BS", "HT", "LF", "VT", "FF", "CR", "SO", "SI", "DLE", "DC1", "DC2", "DC3", "DC4", "NAK", "SYN", "ETB", "CAN", "EM", "SUB", "ESC", "FS", "GS", "RS", "US", " " @@ -38,7 +38,7 @@ static void echo_code (int character) { } static void echo_name (int character) { - const char * name [] = { + char * name [] = { "Null", "Start of heading", "Start of text", "End of text", "End of transmission", "Enquiry", "Acknowledge", "Bell", "Backspace", "Horizontal tab", "Line feed", "Vertical tab", diff --git a/xtandard.h b/xtandard.h index b0be1ab..94f75a2 100755 --- a/xtandard.h +++ b/xtandard.h @@ -145,14 +145,14 @@ typedef enum { signal_count } signal_enumeration; -static const char * cursor_name [cursor_count] = { +static char * cursor_name [cursor_count] = { "---", "Left button", "Middle button", "Right button", "Scroll up", "Scroll down" }; -static const char * signal_name [signal_count] = { +static char * signal_name [signal_count] = { "---", "A", "B", "C", "D", "E", "F", "G", "H", @@ -209,7 +209,7 @@ static void input (void * data, ulong size) { read (standard_input, data, size); } -static void output (const void * data, ulong size) { +static void output (void * data, ulong size) { write (standard_output, data, size); } @@ -218,7 +218,7 @@ static void clean_up (void (* procedure) (void)) { } #ifdef use_fatal_failure -static void fatal_failure (bool condition, const char * message) { +static void fatal_failure (bool condition, char * message) { if (condition == true) { echo ("[\x1b[1;31m FATAL \x1b[0m] "); @@ -235,7 +235,7 @@ static void fatal_failure (bool condition, const char * message) { #define fatal_failure(...) #endif -static void execute (const char * command) { +static void execute (char * command) { int status = 0; system (command); @@ -358,7 +358,7 @@ static void * record (void) { return (buffer); } -static bool character_compare_array (char character, const char * character_array) { +static bool character_compare_array (char character, char * character_array) { for (ulong index = 0; character_array [index] != '\0'; ++index) { if (character == character_array [index]) { return (true); @@ -433,7 +433,7 @@ static char * lowercase (char * string) { return (string); } -static ulong string_length (const char * string) { +static ulong string_length (char * string) { ulong length = 0; fatal_failure (string == null, "string_length: String is null pointer."); @@ -472,7 +472,7 @@ static char * string_reverse (char * string) { return (string_reverse_limit (string, string_length (string))); } -static bool string_compare_limit (const char * string_a, const char * string_b, ulong limit) { +static bool string_compare_limit (char * string_a, char * string_b, ulong limit) { fatal_failure (string_a == null, "string_compare_limit: First source string is null pointer."); fatal_failure (string_b == null, "string_compare_limit: Second source string is null pointer."); fatal_failure (limit <= 0, "string_compare_limit: Limit is equal or below zero."); @@ -486,11 +486,11 @@ static bool string_compare_limit (const char * string_a, const char * string_b, return (true); } -static bool string_compare (const char * string_a, const char * string_b) { +static bool string_compare (char * string_a, char * string_b) { return (string_compare_limit (string_a, string_b, string_length (string_a) + 1)); } -static char * string_copy_limit (char * destination, const char * source, ulong limit) { +static char * string_copy_limit (char * destination, char * source, ulong limit) { fatal_failure (destination == null, "string_copy_limit: Destination string is null pointer."); fatal_failure (source == null, "string_copy_limit: Source string is null pointer."); fatal_failure (limit <= 0, "string_copy_limit: Limit is equal or below zero."); @@ -502,11 +502,11 @@ static char * string_copy_limit (char * destination, const char * source, ulong return (destination); } -static char * string_copy (char * destination, const char * source) { +static char * string_copy (char * destination, char * source) { return (string_copy_limit (destination, source, string_length (source) + 1)); } -static char * string_concatenate_limit (char * destination, const char * source, ulong limit) { +static char * string_concatenate_limit (char * destination, char * source, ulong limit) { ulong offset = string_length (destination); fatal_failure (destination == null, "string_concatenate_limit: Destination string is null pointer."); @@ -520,11 +520,11 @@ static char * string_concatenate_limit (char * destination, const char * source, return (destination); } -static char * string_concatenate (char * destination, const char * source) { +static char * string_concatenate (char * destination, char * source) { return (string_concatenate_limit (destination, source, string_length (source) + 1)); } -static char * string_duplicate (const char * string) { +static char * string_duplicate (char * string) { char * duplicate = null; duplicate = allocate ((string_length (string) + 1) * sizeof (* duplicate)); @@ -534,7 +534,7 @@ static char * string_duplicate (const char * string) { return (duplicate); } -static char * string_duplicate_limit (const char * string, uint limit) { +static char * string_duplicate_limit (char * string, uint limit) { char * duplicate = null; duplicate = allocate ((limit + 1) * sizeof (* duplicate)); @@ -566,9 +566,9 @@ static void memory_nullify (void * memory, ulong size) { } } -static int memory_compare (void * memory_0, const void * memory_1, ulong size) { +static int memory_compare (void * memory_0, void * memory_1, ulong size) { char * cast_0 = ( char *) memory_0; - const char * cast_1 = (const char *) memory_1; + char * cast_1 = (char *) memory_1; fatal_failure (memory_0 == null, "memory_compare: Memory is null pointer."); fatal_failure (memory_1 == null, "memory_compare: Source is null pointer."); @@ -582,9 +582,9 @@ static int memory_compare (void * memory_0, const void * memory_1, ulong size) { return (true); } -static void memory_copy (void * destination, const void * source, ulong size) { +static void memory_copy (void * destination, void * source, ulong size) { char * cast_0 = ( char *) destination; - const char * cast_1 = (const char *) source; + char * cast_1 = (char *) source; fatal_failure (destination == null, "memory_copy: Destination is null pointer."); fatal_failure (source == null, "memory_copy: Source is null pointer."); @@ -629,7 +629,7 @@ static void show_cursor (bool show) { } } -static int file_open (const char * path, int mode) { +static int file_open (char * path, int mode) { fatal_failure (path == null, "file_open: File path is null pointer."); return (open (path, mode, 0777)); @@ -651,7 +651,7 @@ static void file_read (int file, void * data, ulong size) { read (file, data, size); } -static void file_write (int file, const void * data, ulong size) { +static void file_write (int file, void * data, ulong size) { fatal_failure (file <= -1, "file_write: File descriptor is closed or invalid."); fatal_failure (data == null, "file_write: Data is null pointer."); fatal_failure (size == 0, "file_write: Size is zero."); @@ -659,7 +659,7 @@ static void file_write (int file, const void * data, ulong size) { write (file, data, size); } -static void file_echo (int file, const char * data) { +static void file_echo (int file, char * data) { file_write (file, data, string_length (data)); } @@ -669,7 +669,7 @@ static ulong file_seek (int file, int whence) { return ((ulong) lseek (file, 0, whence)); } -static ulong file_size (const char * path) { +static ulong file_size (char * path) { struct stat data = { 0 }; fatal_failure (path == null, "file_size: File path is null pointer."); @@ -679,8 +679,8 @@ static ulong file_size (const char * path) { return ((ulong) data.st_size); } -static file_type_enumeration file_type (const char * path) { - const char * extensions [file_type_count] = { +static file_type_enumeration file_type (char * path) { /// SHIT BREAKS ON "./THIS/THAT.EXT"... + char * extensions [file_type_count] = { ".c", ".h", ".adb", ".ads", ".cpp", ".hpp", ".f90", ".mod", ".pas", ".d", ".go", ".jai", ".asm", ".eax", ".gas", ".fasm", ".hs", ".el", ".cfg", ".lua", ".sh", ".py", ".tcl", ".4th", @@ -703,17 +703,17 @@ static file_type_enumeration file_type (const char * path) { return (~ 0u); } -static bool file_exists (const char * path) { +static bool file_exists (char * path) { fatal_failure (path == null, "file_record: File path is null pointer."); return ((access (path, F_OK) == 0) ? true : false); } -static void file_remove (const char * path) { +static void file_remove (char * path) { unlink (path); } -static void * file_record (const char * path) { +static void * file_record (char * path) { int file = -1; ulong size = 0; char * data = null; @@ -731,7 +731,7 @@ static void * file_record (const char * path) { return (data); } -static char * file_import (const char * path) { +static char * file_import (char * path) { int file = -1; ulong size = 0; char * data = null; @@ -751,7 +751,7 @@ static char * file_import (const char * path) { return (data); } -static void file_export (const char * path, const char * data) { +static void file_export (char * path, char * data) { int file = -1; fatal_failure (path == null, "file_export: File path is null pointer."); @@ -764,7 +764,7 @@ static void file_export (const char * path, const char * data) { file = file_close (file); } -static void * folder_open (const char * path) { +static void * folder_open (char * path) { DIR * folder = null; fatal_failure (path == null, "folder_open: Folder path is null pointer."); @@ -800,7 +800,7 @@ static void * folder_close (void * handle) { return (null); } -static char * * folder_create_path_list (const char * folder, uint * path_count, bool sort) { +static char * * folder_create_path_list (char * folder, uint * path_count, bool sort) { void * handle = null; char * * path_array = 0; @@ -836,7 +836,7 @@ static char * * folder_remove_path_list (char * * path_array, uint path_count) { return (deallocate (path_array)); } -static char * configuration_format (const char * path) { +static char * configuration_format (char * path) { static char buffer [512] = ""; string_copy (buffer, getenv ("HOME")); @@ -846,27 +846,27 @@ static char * configuration_format (const char * path) { return (buffer); } -static bool configuration_exists (const char * path) { +static bool configuration_exists (char * path) { return (file_exists (configuration_format (path))); } -static void configuration_remove (const char * path) { +static void configuration_remove (char * path) { file_remove (configuration_format (path)); } -static char * configuration_import (const char * path) { +static char * configuration_import (char * path) { return (file_import (configuration_format (path))); } -static void configuration_export (const char * path, const char * data) { +static void configuration_export (char * path, char * data) { file_export (configuration_format (path), data); } -static bool argument_compare (const char * argument, const char * short_option, const char * long_option) { +static bool argument_compare (char * argument, char * short_option, char * long_option) { return ((string_compare (argument, short_option) == true) || (string_compare (argument, long_option) == true)); } -static uint string_full_width (const char * string, uint tab_width) { +static uint string_full_width (char * string, uint tab_width) { uint width = 0; uint count = 0; @@ -884,7 +884,7 @@ static uint string_full_width (const char * string, uint tab_width) { return (width - 1); } -static uint string_full_height (const char * string) { +static uint string_full_height (char * string) { uint height = 0; do { @@ -896,7 +896,7 @@ static uint string_full_height (const char * string) { return (height + 1); } -static uint string_limit_to_number (const char * string, uint limit) { +static uint string_limit_to_number (char * string, uint limit) { uint number = 0; for (uint index = 0; (string [index] != '\0') && (index < limit); ++index) { @@ -907,7 +907,7 @@ static uint string_limit_to_number (const char * string, uint limit) { return (number); } -static uint string_to_number (const char * string) { +static uint string_to_number (char * string) { return (string_limit_to_number (string, string_length (string))); } @@ -988,7 +988,7 @@ static char * format_to_string (int number, bool sign, uint base, ulong amount, return (string); } -static char * format (const char * base, ...) { +static char * format (char * base, ...) { static char string [1024]; va_list list; @@ -1019,7 +1019,7 @@ static char * format (const char * base, ...) { return (string); } -static void print (const char * format, ...) { +static void print (char * format, ...) { va_list list; va_start (list, format); @@ -1036,6 +1036,14 @@ static void print (const char * format, ...) { char * string = number_to_string (va_arg (list, int)); output (string, string_length (string)); } break; + case ('f'): { + float number = (float) va_arg (list, double); + char * upper = number_to_string ((int) number); + char * lower = number_to_string ((int) (number * 1000.0f) % 1000); + output (upper, string_length (upper)); + output (".", 1); + output (lower, string_length (lower)); + } break; case ('t'): { int toggle = (va_arg (list, int)); echo_colour ((toggle == true) ? colour_green : colour_red, effect_normal); @@ -1116,7 +1124,8 @@ static void float_exchange (float * a, float * b) { #define pi (3.14159265f) -static float sign (float x) { return ((x > 0.0f) ? +1.0f : -1.0f); } +static float sign (float x) { return ((x > 0.0f) ? + 1.0f : - 1.0f); } +static float binary_sign (uint x) { return ((x > 0) ? + 1.0f : - 1.0f); } static float square_root (float x) { return (sqrtf (x)); } static float cube_root (float x) { return (cbrtf (x)); } diff --git a/xui.h b/xui.h index 4c4ee36..db61906 100755 --- a/xui.h +++ b/xui.h @@ -73,7 +73,7 @@ typedef struct { } ui_structure; static ui_structure * ui_initialize (cross_structure * cross) { - const char * subtype_file_name [ui_subcount] = { + char * subtype_file_name [ui_subcount] = { "window_left", "window_right", "window_upper", "window_lower", "window_upper_left", "window_upper_right", "window_lower_left", "window_lower_right", "frame_left", "frame_right", "frame_upper", "frame_lower", @@ -113,7 +113,7 @@ static ui_structure * ui_initialize (cross_structure * cross) { ui->monofont = cross_font_import (cross, configuration_format ("xui/monospace"), ' ', '~', 0xffeeee00u); for (uint index = 0; index < ui_subcount; ++index) { - const char * file_name = configuration_format (format ("xui/%s", subtype_file_name [index])); + char * file_name = configuration_format (format ("xui/%s", subtype_file_name [index])); ui->sprite [index] = cross_sprite_import (cross, file_name); @@ -142,15 +142,15 @@ static ui_structure * ui_deinitialize (ui_structure * ui) { return (deallocate (ui)); } -static int ui_offset_x (const cross_structure * cross, const ui_structure * ui) { +static int ui_offset_x (cross_structure * cross, ui_structure * ui) { return (ui->camera_x - cross->window_width / 2); } -static int ui_offset_y (const cross_structure * cross, const ui_structure * ui) { +static int ui_offset_y (cross_structure * cross, ui_structure * ui) { return (ui->camera_y - cross->window_height / 2); } -static uint ui_side_panel (const ui_structure * ui) { +static uint ui_side_panel (ui_structure * ui) { return (ui->side_panel); /// MAKE IT WINDOW SIZE DEPENDENT? } @@ -159,24 +159,24 @@ static void ui_camera_lower (ui_structure * ui) { ui->freeview = true; ui->camer static void ui_camera_left (ui_structure * ui) { ui->freeview = true; ui->camera_x -= ui->camera_speed; } static void ui_camera_right (ui_structure * ui) { ui->freeview = true; ui->camera_x += ui->camera_speed; } -static void ui_render (cross_structure * cross, const ui_structure * ui, ui_subtype index, int x, int y) { +static void ui_render (cross_structure * cross, ui_structure * ui, ui_subtype index, int x, int y) { cross_render_sprite (cross, ui->sprite [index], x, y); } -static void ui_render_colour (cross_structure * cross, const ui_structure * ui, ui_subtype index, uint colour, int x, int y) { +static void ui_render_colour (cross_structure * cross, ui_structure * ui, ui_subtype index, uint colour, int x, int y) { cross_render_sprite_colour (cross, ui->sprite [index], colour, x, y); } -static void ui_subrender (cross_structure * cross, const ui_structure * ui, ui_subtype index, int x, int y, uint u, uint v, uint width, uint height) { +static void ui_subrender (cross_structure * cross, ui_structure * ui, ui_subtype index, int x, int y, uint u, uint v, uint width, uint height) { cross_render_sprite_crop (cross, ui->sprite [index], x, y, u, v, width, height); } -static void ui_subrender_colour (cross_structure * cross, const ui_structure * ui, ui_subtype index, uint colour, int x, int y, uint u, uint v, uint width, uint height) { +static void ui_subrender_colour (cross_structure * cross, ui_structure * ui, ui_subtype index, uint colour, int x, int y, uint u, uint v, uint width, uint height) { cross_render_sprite_crop_colour (cross, ui->sprite [index], colour, x, y, u, v, width, height); } -static void ui_render_horizontal (cross_structure * cross, const ui_structure * ui, ui_subtype index, int x, int y, uint width) { - const int entire = (width / ui->width [index]) * ui->width [index]; +static void ui_render_horizontal (cross_structure * cross, ui_structure * ui, ui_subtype index, int x, int y, uint width) { + int entire = (width / ui->width [index]) * ui->width [index]; for (uint margin = 0; margin < width / ui->width [index]; ++margin) { ui_render (cross, ui, index, x + margin * ui->width [index], y); @@ -187,8 +187,8 @@ static void ui_render_horizontal (cross_structure * cross, const ui_structure * } } -static void ui_render_horizontal_colour (cross_structure * cross, const ui_structure * ui, ui_subtype index, uint colour, int x, int y, uint width) { - const int entire = (width / ui->width [index]) * ui->width [index]; +static void ui_render_horizontal_colour (cross_structure * cross, ui_structure * ui, ui_subtype index, uint colour, int x, int y, uint width) { + int entire = (width / ui->width [index]) * ui->width [index]; for (uint margin = 0; margin < width / ui->width [index]; ++margin) { ui_render_colour (cross, ui, index, colour, x + margin * ui->width [index], y); @@ -199,8 +199,8 @@ static void ui_render_horizontal_colour (cross_structure * cross, const ui_struc } } -static void ui_render_vertical (cross_structure * cross, const ui_structure * ui, ui_subtype index, int x, int y, uint height) { - const int entire = (height / ui->height [index]) * ui->height [index]; +static void ui_render_vertical (cross_structure * cross, ui_structure * ui, ui_subtype index, int x, int y, uint height) { + int entire = (height / ui->height [index]) * ui->height [index]; for (uint margin = 0; margin < height / ui->height [index]; ++margin) { ui_render (cross, ui, index, x, y + margin * ui->height [index]); @@ -211,12 +211,12 @@ static void ui_render_vertical (cross_structure * cross, const ui_structure * ui } } -static void ui_render_background (cross_structure * cross, const ui_structure * ui, ui_subtype index, int x, int y, uint width, uint height) { - const uint offset_x = (width / ui->width [index]) * ui->width [index]; - const uint offset_y = (height / ui->height [index]) * ui->height [index]; +static void ui_render_background (cross_structure * cross, ui_structure * ui, ui_subtype index, int x, int y, uint width, uint height) { + uint offset_x = (width / ui->width [index]) * ui->width [index]; + uint offset_y = (height / ui->height [index]) * ui->height [index]; - const uint cutoff_x = width % ui->width [index]; - const uint cutoff_y = height % ui->height [index]; + uint cutoff_x = width % ui->width [index]; + uint cutoff_y = height % ui->height [index]; for (uint vertical = 0; vertical < height / ui->height [index]; ++vertical) { for (uint horizontal = 0; horizontal < width / ui->width [index]; ++horizontal) { @@ -242,24 +242,24 @@ static void ui_screen_overlay (cross_structure * cross) { cross_render_rectangle_vertical_gradient (cross, 0, cross->window_height / 2, cross->window_width, cross->window_height / 2, 0x00, 0xcc); } -static void ui_render_grid (cross_structure * cross, const ui_structure * ui, ui_type element, int x, int y, uint width, uint height, uint margin, bool background) { - const uint upper_length = width - ui->width [element + 4] - ui->width [element + 5]; - const uint lower_length = width - ui->width [element + 6] - ui->width [element + 7]; - const uint left_length = height - ui->height [element + 4] - ui->height [element + 6]; - const uint right_length = height - ui->height [element + 5] - ui->height [element + 7]; +static void ui_render_grid (cross_structure * cross, ui_structure * ui, ui_type element, int x, int y, uint width, uint height, uint margin, bool background) { + uint upper_length = width - ui->width [element + 4] - ui->width [element + 5]; + uint lower_length = width - ui->width [element + 6] - ui->width [element + 7]; + uint left_length = height - ui->height [element + 4] - ui->height [element + 6]; + uint right_length = height - ui->height [element + 5] - ui->height [element + 7]; - const int upper_offset_x = ui->width [element + 4]; - const int lower_offset_x = ui->width [element + 6]; - const int lower_offset_y = height - ui->height [element + 3]; + int upper_offset_x = ui->width [element + 4]; + int lower_offset_x = ui->width [element + 6]; + int lower_offset_y = height - ui->height [element + 3]; - const int right_offset_x = width - ui->width [element + 1]; - const int left_offset_y = ui->height [element + 4]; - const int right_offset_y = ui->height [element + 5]; + int right_offset_x = width - ui->width [element + 1]; + int left_offset_y = ui->height [element + 4]; + int right_offset_y = ui->height [element + 5]; - const int upper_right_offset_x = width - ui->width [element + 5]; - const int lower_right_offset_x = width - ui->width [element + 7]; - const int lower_left_offset_y = height - ui->height [element + 6]; - const int lower_right_offset_y = height - ui->height [element + 7]; + int upper_right_offset_x = width - ui->width [element + 5]; + int lower_right_offset_x = width - ui->width [element + 7]; + int lower_left_offset_y = height - ui->height [element + 6]; + int lower_right_offset_y = height - ui->height [element + 7]; if ((background == true) && (width > 2 * margin) && (height > 2 * margin)) { ui_render_background (cross, ui, element + 8, x + margin, y + margin, width - 2 * margin, height - 2 * margin); @@ -277,29 +277,29 @@ static void ui_render_grid (cross_structure * cross, const ui_structure * ui, ui ui_render (cross, ui, element + 7, x + lower_right_offset_x, y + lower_right_offset_y); } -static void ui_render_window (cross_structure * cross, const ui_structure * ui, int x, int y, uint width, uint height) { +static void ui_render_window (cross_structure * cross, ui_structure * ui, int x, int y, uint width, uint height) { ui_render_grid (cross, ui, ui_window, x, y, width, height, 0, false); } -static void ui_render_frame (cross_structure * cross, const ui_structure * ui, int x, int y, uint width, uint height) { +static void ui_render_frame (cross_structure * cross, ui_structure * ui, int x, int y, uint width, uint height) { ui_render_grid (cross, ui, ui_frame, x, y, width, height, 0, false); } -static void ui_render_status (cross_structure * cross, const ui_structure * ui, int x, int y, uint width, uint height) { +static void ui_render_status (cross_structure * cross, ui_structure * ui, int x, int y, uint width, uint height) { ui_render_grid (cross, ui, ui_status, x, y, width, height, 16, true); } -static void ui_render_menu (cross_structure * cross, const ui_structure * ui, int x, int y, uint width, uint height) { +static void ui_render_menu (cross_structure * cross, ui_structure * ui, int x, int y, uint width, uint height) { ui_render_grid (cross, ui, ui_menu, x, y, width, height, 24, true); } -static void ui_render_button (cross_structure * cross, const ui_structure * ui, int x, int y, uint width, uint height) { +static void ui_render_button (cross_structure * cross, ui_structure * ui, int x, int y, uint width, uint height) { ui_render_grid (cross, ui, ui_button, x, y, width, height, 16, true); } -static void ui_render_separator (cross_structure * cross, const ui_structure * ui, int x, int y, uint width) { - const uint margin = ui->width [ui_separator_left]; - const uint length = width - margin - ui->width [ui_separator_right]; +static void ui_render_separator (cross_structure * cross, ui_structure * ui, int x, int y, uint width) { + uint margin = ui->width [ui_separator_left]; + uint length = width - margin - ui->width [ui_separator_right]; ui_render (cross, ui, ui_separator_left, x, y); @@ -310,9 +310,9 @@ static void ui_render_separator (cross_structure * cross, const ui_structure * u ui_render (cross, ui, ui_separator_center, x + (width - ui->width [ui_separator_center]) / 2, y); } -static void ui_render_title_bar (cross_structure * cross, const ui_structure * ui, const char * title, int x, int y, uint width) { - const uint margin = ui->width [ui_title_bar_left]; - const uint length = width - margin - ui->width [ui_title_bar_right]; +static void ui_render_title_bar (cross_structure * cross, ui_structure * ui, char * title, int x, int y, uint width) { + uint margin = ui->width [ui_title_bar_left]; + uint length = width - margin - ui->width [ui_title_bar_right]; ui_render (cross, ui, ui_title_bar_left, x, y); @@ -323,15 +323,15 @@ static void ui_render_title_bar (cross_structure * cross, const ui_structure * u cross_render_string (cross, title, ui->font, x + margin + 8, y + 8, 1, 0x112233ff); } -static void ui_render_icon_and_text (cross_structure * cross, const ui_structure * ui, const char * title, uint icon, int x, int y) { +static void ui_render_icon_and_text (cross_structure * cross, ui_structure * ui, char * title, uint icon, int x, int y) { cross_render_sprite (cross, icon, x, y); cross_render_string (cross, title, ui->font, x - 2 + ui->icon_size, y + 2, 1, 0x112233ffu); } -static void ui_render_scroll_bar (cross_structure * cross, const ui_structure * ui, float slider, int x, int y, uint height) { - const uint margin = ui->height [ui_scroll_bar_upper]; - const uint length = height - margin - ui->height [ui_scroll_bar_lower]; +static void ui_render_scroll_bar (cross_structure * cross, ui_structure * ui, float slider, int x, int y, uint height) { + uint margin = ui->height [ui_scroll_bar_upper]; + uint length = height - margin - ui->height [ui_scroll_bar_lower]; ui_render (cross, ui, ui_scroll_bar_upper, x, y); @@ -342,9 +342,9 @@ static void ui_render_scroll_bar (cross_structure * cross, const ui_structure * ui_render (cross, ui, ui_scroll_bar_slider, x, y + margin + (uint) (slider * (float) (length - ui->height [ui_scroll_bar_slider]))); } -static void ui_render_fill_bar (cross_structure * cross, const ui_structure * ui, float fill, uint colour, int x, int y, uint width) { - const uint margin = ui->width [ui_fill_bar_left]; - const uint length = width - margin - ui->width [ui_fill_bar_right]; +static void ui_render_fill_bar (cross_structure * cross, ui_structure * ui, float fill, uint colour, int x, int y, uint width) { + uint margin = ui->width [ui_fill_bar_left]; + uint length = width - margin - ui->width [ui_fill_bar_right]; ui_render (cross, ui, ui_fill_bar_left, x, y); @@ -355,7 +355,7 @@ static void ui_render_fill_bar (cross_structure * cross, const ui_structure * ui ui_render_horizontal_colour (cross, ui, ui_fill_bar_base, colour, x + margin, y, (uint) (fill * (float) length)); } -static void ui_render_icon (cross_structure * cross, const ui_structure * ui, uint icon, int x, int y) { +static void ui_render_icon (cross_structure * cross, ui_structure * ui, uint icon, int x, int y) { cross_render_sprite (cross, ui->sprite [ui_icon_frame], x, y); if (icon != ui->ignore) { @@ -363,7 +363,7 @@ static void ui_render_icon (cross_structure * cross, const ui_structure * ui, ui } } -static void ui_render_overicon (cross_structure * cross, const ui_structure * ui, uint icon, int x, int y) { +static void ui_render_overicon (cross_structure * cross, ui_structure * ui, uint icon, int x, int y) { if (icon != ui->ignore) { cross_render_sprite (cross, icon, x, y); } @@ -371,7 +371,7 @@ static void ui_render_overicon (cross_structure * cross, const ui_structure * ui cross_render_sprite (cross, ui->sprite [ui_overicon_frame], x, y); } -static void ui_render_ubericon (cross_structure * cross, const ui_structure * ui, uint icon, int x, int y) { +static void ui_render_ubericon (cross_structure * cross, ui_structure * ui, uint icon, int x, int y) { cross_render_sprite (cross, ui->sprite [ui_ubericon_frame], x, y); if (icon != ui->ignore) { @@ -379,8 +379,8 @@ static void ui_render_ubericon (cross_structure * cross, const ui_structure * ui } } -static void ui_render_menu_full (cross_structure * cross, const ui_structure * ui, const char * title, int x, int y, uint width, uint height) { - const uint margin = 24; +static void ui_render_menu_full (cross_structure * cross, ui_structure * ui, char * title, int x, int y, uint width, uint height) { + uint margin = 24; ui_screen_overlay (cross); diff --git a/xulkan.h b/xulkan.h index 4a3b2fc..6603ee1 100755 --- a/xulkan.h +++ b/xulkan.h @@ -118,7 +118,7 @@ typedef struct { uint layout_height; } vulkan_structure; -static const char * vulkan_continue_execution [] = { +static char * vulkan_continue_execution [] = { "/s Commands successfully completed.\n", "/w Fence or query hasn't yet completed.\n", "/w Wait operation hasn't completed in the specified time.\n", @@ -127,7 +127,7 @@ static const char * vulkan_continue_execution [] = { "/w Return array was too small for the result.\n" }; -static const char * vulkan_break_execution [] = { +static char * vulkan_break_execution [] = { "/f Host memory allocation has failed.\n", "/f Device memory allocation has failed.\n", "/f Initialization of an object couldn't be completed.\n", @@ -342,7 +342,7 @@ static void vulkan_end_command_buffer (vulkan_structure * vulkan) { vulkan->transfer_buffer = VK_NULL_HANDLE; } -static void vulkan_create_window (vulkan_structure * vulkan, const char * application) { +static void vulkan_create_window (vulkan_structure * vulkan, char * application) { uint window_flags [2] = { 0 }; vulkan->time = tick_tock (); @@ -383,7 +383,7 @@ static void vulkan_create_window (vulkan_structure * vulkan, const char * applic print ("/c Time approximation: /6%i/-\n", tick_tock () - vulkan->time); } -static void vulkan_create_instance (vulkan_structure * vulkan, const char * application) { +static void vulkan_create_instance (vulkan_structure * vulkan, char * application) { uint current = 0; uint general = 0; @@ -397,17 +397,17 @@ static void vulkan_create_instance (vulkan_structure * vulkan, const char * appl uint * instance_extension_index = null; VkExtensionProperties * instance_extension_array = null; - const uint default_instance_layer_count = (uint) (vulkan->validation_layers == true); - const uint default_instance_extension_count = 2; + uint default_instance_layer_count = (uint) (vulkan->validation_layers == true); + uint default_instance_extension_count = 2; - const char * default_instance_layer_array [VK_MAX_EXTENSION_NAME_SIZE] = { + char * default_instance_layer_array [VK_MAX_EXTENSION_NAME_SIZE] = { "VK_LAYER_KHRONOS_validation" //~"VK_LAYER_LUNARG_parameter_validation", //~"VK_LAYER_LUNARG_core_validation", //~"VK_LAYER_LUNARG_standard_validation" }; - const char * default_instance_extension_array [VK_MAX_EXTENSION_NAME_SIZE] = { + char * default_instance_extension_array [VK_MAX_EXTENSION_NAME_SIZE] = { VK_KHR_SURFACE_EXTENSION_NAME, VK_KHR_XCB_SURFACE_EXTENSION_NAME }; @@ -511,11 +511,11 @@ static void vulkan_create_device (vulkan_structure * vulkan) { VkPhysicalDevice * physical_device_array = null; VkBool32 * support = null; - const float queue_priorities [1] = { 1 }; + float queue_priorities [1] = { 1 }; - const uint default_device_extension_count = 1; + uint default_device_extension_count = 1; - const char * default_device_extension_array [VK_MAX_EXTENSION_NAME_SIZE] = { + char * default_device_extension_array [VK_MAX_EXTENSION_NAME_SIZE] = { VK_KHR_SWAPCHAIN_EXTENSION_NAME }; @@ -949,7 +949,7 @@ static void vulkan_create_descriptor_set_layout (vulkan_structure * vulkan) { } static void vulkan_create_vertex_shader (vulkan_structure * vulkan) { - const uint vertex_shader_code [] = { + uint vertex_shader_code [] = { 0x07230203, 0x00010000, 0x000d000b, 0x00000028, 0x00000000, 0x00020011, 0x00000001, 0x0006000b, 0x00000001, 0x4c534c47, 0x6474732e, 0x3035342e, 0x00000000, 0x0003000e, 0x00000000, 0x00000001, 0x000b000f, 0x00000000, 0x00000004, 0x6e69616d, 0x00000000, 0x0000000d, 0x00000012, 0x00000021, @@ -1007,7 +1007,7 @@ static void vulkan_create_vertex_shader (vulkan_structure * vulkan) { } static void vulkan_create_fragment_shader (vulkan_structure * vulkan) { - const uint fragment_shader_code [] = { + uint fragment_shader_code [] = { 0x07230203, 0x00010000, 0x000d000b, 0x00000018, 0x00000000, 0x00020011, 0x00000001, 0x0006000b, 0x00000001, 0x4c534c47, 0x6474732e, 0x3035342e, 0x00000000, 0x0003000e, 0x00000000, 0x00000001, 0x0008000f, 0x00000004, 0x00000004, 0x6e69616d, 0x00000000, 0x00000009, 0x00000011, 0x00000015, @@ -1818,7 +1818,7 @@ static void vulkan_bundle_layout (vulkan_structure * vulkan) { order = deallocate (order); } -static void vulkan_configure (vulkan_structure * vulkan, int width, int height, const char * application) { +static void vulkan_configure (vulkan_structure * vulkan, int width, int height, char * application) { int index = 0; uint * dumb_buffer = null; @@ -2013,7 +2013,7 @@ static void vulkan_render_rectangle_gradient_h (vulkan_structure * vulkan, int x vulkan_render_core (vulkan, vulkan->sprite_count - 1, x, y, 0, 0, 16, 16, (float) width / 16, (float) height / 16, 0, 0, colour_left, colour_right, colour_left, colour_right); } -static int vulkan_string_width (vulkan_structure * vulkan, const char * string, int font, float scale) { +static int vulkan_string_width (vulkan_structure * vulkan, char * string, int font, float scale) { int length = 0; for (uint index = 0; string [index] != '\0'; ++index) { @@ -2034,7 +2034,7 @@ static int vulkan_string_width (vulkan_structure * vulkan, const char * string, return (length); } -static void vulkan_render_string (vulkan_structure * vulkan, const char * string, int font, int x, int y, uint colour) { +static void vulkan_render_string (vulkan_structure * vulkan, char * string, int font, int x, int y, uint colour) { int offset = x; for (uint index = 0; string [index] != '\0'; ++index) { @@ -2057,7 +2057,7 @@ static void vulkan_render_string (vulkan_structure * vulkan, const char * string } } -static void vulkan_render_string_scale (vulkan_structure * vulkan, const char * string, int font, int x, int y, float scale, uint colour) { +static void vulkan_render_string_scale (vulkan_structure * vulkan, char * string, int font, int x, int y, float scale, uint colour) { int offset = x; for (uint index = 0; string [index] != '\0'; ++index) { @@ -2081,7 +2081,7 @@ static void vulkan_render_string_scale (vulkan_structure * vulkan, const char * } } -static void vulkan_render_string_offset (vulkan_structure * vulkan, const char * string, uint length, uint font, uint offset, int * x, int * y, uint colour) { +static void vulkan_render_string_offset (vulkan_structure * vulkan, char * string, uint length, uint font, uint offset, int * x, int * y, uint colour) { for (uint index = 0; (string [index] != '\0') && (index < length); ++index) { uint character = vulkan->font_index [font] [string [index] - vulkan->font_begin [font]]; @@ -2102,7 +2102,7 @@ static void vulkan_render_string_offset (vulkan_structure * vulkan, const char * } } -static void vulkan_render_string_gradient_v (vulkan_structure * vulkan, const char * string, int font, int x, int y, float scale, uint colour_up, uint colour_down) { +static void vulkan_render_string_gradient_v (vulkan_structure * vulkan, char * string, int font, int x, int y, float scale, uint colour_up, uint colour_down) { int offset = x; for (uint index = 0; string [index] != '\0'; ++index) { @@ -2126,7 +2126,7 @@ static void vulkan_render_string_gradient_v (vulkan_structure * vulkan, const ch } } -static void vulkan_render_string_gradient_h (vulkan_structure * vulkan, const char * string, int font, int x, int y, float scale, uint colour_left, uint colour_right) { +static void vulkan_render_string_gradient_h (vulkan_structure * vulkan, char * string, int font, int x, int y, float scale, uint colour_left, uint colour_right) { int offset = x; for (uint index = 0; string [index] != '\0'; ++index) { @@ -2151,7 +2151,7 @@ static void vulkan_render_string_gradient_h (vulkan_structure * vulkan, const ch } static void vulkan_handle_events (vulkan_structure * vulkan) { - static const int signal_code [signal_count] = { + static int signal_code [signal_count] = { 0, 38, 56, 54, 40, 26, 41, 42, 43, 31, 44, 45, 46, 58, 57, 32, 33, 24, 27, 39, 28, 30, 55, 25, 53, 29, 52, 19, 10, 11, 12, 13, 14, @@ -2178,7 +2178,7 @@ static void vulkan_handle_events (vulkan_structure * vulkan) { xcb_flush (vulkan->connection); } break; /*case (XCB_CONFIGURE_NOTIFY): { - const xcb_configure_notify_event_t * reconfigure = (const xcb_configure_notify_event_t *) generic_event; + xcb_configure_notify_event_t * reconfigure = (xcb_configure_notify_event_t *) generic_event; if ((reconfigure->width != vulkan->width) || (reconfigure->height != vulkan->height)) { vulkan->width = reconfigure->width; vulkan->height = reconfigure->height; @@ -2235,7 +2235,7 @@ static void vulkan_synchronize (vulkan_structure * vulkan, uint clear_colour) { void * ubo_void = null; - const VkPipelineStageFlags wait_stages [1] = { VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT} ; + VkPipelineStageFlags wait_stages [1] = { VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT} ; VkSubmitInfo submit_information = { 0 }; VkPresentInfoKHR present_information = { 0 }; diff --git a/xungeon.h b/xungeon.h index b88cf7a..745176e 100755 --- a/xungeon.h +++ b/xungeon.h @@ -84,7 +84,7 @@ typedef struct { dungeon_item_definition * item_array; } * dungeon_structure; -static uint dungeon_biome_define (dungeon_structure dungeon, const char * name, uint temperature, uint humidity) { +static uint dungeon_biome_define (dungeon_structure dungeon, char * name, uint temperature, uint humidity) { dungeon_biome_definition biome = arena_add (sizeof (* biome)); fatal_failure (dungeon == null, "biome_define: Dungeon is not configured."); @@ -106,7 +106,7 @@ static char * dungeon_biome_name (dungeon_structure dungeon, uint index) static uint dungeon_biome_temperature (dungeon_structure dungeon, uint index) { return (dungeon->biome_array [index]->temperature); } static uint dungeon_biome_humidity (dungeon_structure dungeon, uint index) { return (dungeon->biome_array [index]->humidity); } -static uint dungeon_landmark_define (dungeon_structure dungeon, const char * name, uint biome, bool clip) { +static uint dungeon_landmark_define (dungeon_structure dungeon, char * name, uint biome, bool clip) { dungeon_landmark_definition landmark = arena_add (sizeof (* landmark)); fatal_failure (dungeon == null, "landmark_define: Dungeon is not configured."); @@ -128,7 +128,7 @@ static char * dungeon_landmark_name (dungeon_structure dungeon, uint index) { r static uint dungeon_landmark_biome (dungeon_structure dungeon, uint index) { return (dungeon->landmark_array [index]->biome); } static bool dungeon_landmark_clip (dungeon_structure dungeon, uint index) { return (dungeon->landmark_array [index]->clip); } -static uint dungeon_expertise_define (dungeon_structure dungeon, const char * name) { +static uint dungeon_expertise_define (dungeon_structure dungeon, char * name) { dungeon_expertise_definition expertise = arena_add (sizeof (* expertise)); fatal_failure (dungeon == null, "expertise_define: Dungeon is not configured."); @@ -145,7 +145,7 @@ static uint dungeon_expertise_define (dungeon_structure dungeon, const char * na static char * dungeon_expertise_name (dungeon_structure dungeon, uint index) { return (dungeon->expertise_array [index]->name); } -static uint dungeon_attribute_define (dungeon_structure dungeon, const char * name, uint base, uint limit) { +static uint dungeon_attribute_define (dungeon_structure dungeon, char * name, uint base, uint limit) { dungeon_attribute_definition attribute = arena_add (sizeof (* attribute)); fatal_failure (dungeon == null, "attribute_define: Dungeon is not configured."); @@ -167,7 +167,7 @@ static char * dungeon_attribute_name (dungeon_structure dungeon, uint index) { static uint dungeon_attribute_base (dungeon_structure dungeon, uint index) { return (dungeon->attribute_array [index]->base); } static uint dungeon_attribute_limit (dungeon_structure dungeon, uint index) { return (dungeon->attribute_array [index]->limit); } -static uint dungeon_skill_define (dungeon_structure dungeon, const char * name, uint base, uint limit) { +static uint dungeon_skill_define (dungeon_structure dungeon, char * name, uint base, uint limit) { dungeon_skill_definition skill = arena_add (sizeof (* skill)); fatal_failure (dungeon == null, "skill_define: Dungeon is not configured."); @@ -189,7 +189,7 @@ static char * dungeon_skill_name (dungeon_structure dungeon, uint index) { retu static uint dungeon_skill_base (dungeon_structure dungeon, uint index) { return (dungeon->skill_array [index]->base); } static uint dungeon_skill_limit (dungeon_structure dungeon, uint index) { return (dungeon->skill_array [index]->limit); } -static uint dungeon_resource_define (dungeon_structure dungeon, const char * name, uint base, uint limit, uint value, uint trade) { +static uint dungeon_resource_define (dungeon_structure dungeon, char * name, uint base, uint limit, uint value, uint trade) { dungeon_resource_definition resource = arena_add (sizeof (* resource)); fatal_failure (dungeon == null, "resource_define: Dungeon is not configured."); @@ -215,7 +215,7 @@ static uint dungeon_resource_limit (dungeon_structure dungeon, uint index) { r static uint dungeon_resource_value (dungeon_structure dungeon, uint index) { return (dungeon->resource_array [index]->value); } static uint dungeon_resource_trade (dungeon_structure dungeon, uint index) { return (dungeon->resource_array [index]->trade); } -static uint dungeon_item_slot_define (dungeon_structure dungeon, const char * name) { +static uint dungeon_item_slot_define (dungeon_structure dungeon, char * name) { dungeon_item_slot_definition item_slot = arena_add (sizeof (* item_slot)); fatal_failure (dungeon == null, "item_slot_define: Dungeon is not configured."); @@ -232,7 +232,7 @@ static uint dungeon_item_slot_define (dungeon_structure dungeon, const char * na static char * dungeon_item_slot_name (dungeon_structure dungeon, uint index) { return (dungeon->item_slot_array [index]->name); } -static uint dungeon_item_define (dungeon_structure dungeon, const char * name, uint slot, uint effect) { +static uint dungeon_item_define (dungeon_structure dungeon, char * name, uint slot, uint effect) { dungeon_item_definition item = arena_add (sizeof (* item)); fatal_failure (dungeon == null, "item_define: Dungeon is not configured."); diff --git a/xuxuxu.c b/xuxuxu.c index ee77e9c..3e929ec 100755 --- a/xuxuxu.c +++ b/xuxuxu.c @@ -19,7 +19,7 @@ static uint x = 0; static uint y = 0; static void render_character (char character) { - const ulong font_code [font_count] = { + ulong font_code [font_count] = { 0x0000000000000000, 0x00180018183c3c18, 0x0000000000363636, 0x006c6cfe6cfe6c6c, 0x00187ed07c16fc30, 0x0060660c18306606, 0x00dc66b61c36361c, 0x0000000000181818, 0x0030180c0c0c1830, 0x000c18303030180c, 0x0000187e3c7e1800, 0x000018187e181800, @@ -56,7 +56,7 @@ static void render_character (char character) { x += font_width + 1; } -static void render_string (const char * string, uint length) { +static void render_string (char * string, uint length) { for (uint offset = 0; offset < length; ++offset) { if (string [offset] == '\t') { x += font_width * font_indent; @@ -74,9 +74,9 @@ int main (void) { uint length = 0; char * buffer = null; - const char separator [] = ".,:;<=>+-*/%!&~^()[]{}'\" \t\r\n"; + char separator [] = ".,:;<=>+-*/%!&~^()[]{}'\" \t\r\n"; - const char * keywords [] = { + char * keywords [] = { "register", "volatile", "auto", "const", "static", "extern", "if", "else", "do", "while", "for", "continue", "switch", "case", "default", "break", "enum", "union", "struct", "typedef", "goto", "void", "return", "sizeof", diff --git a/xyntax.h b/xyntax.h index 849d44c..eed650c 100755 --- a/xyntax.h +++ b/xyntax.h @@ -63,7 +63,7 @@ static syntax_structure * syntax_deinitialize (syntax_structure * syntax) { return (deallocate (syntax)); } -static uint syntax_define (syntax_structure * syntax, bool enrange, bool derange, const char * begin, const char * end, char escape, +static uint syntax_define (syntax_structure * syntax, bool enrange, bool derange, char * begin, char * end, char escape, uint colour, uint effect) { ++syntax->count; @@ -99,7 +99,7 @@ static uint syntax_define (syntax_structure * syntax, bool enrange, bool derange return (current); } -static uint syntax_select (syntax_structure * syntax, const char * string, uint * length) { +static uint syntax_select (syntax_structure * syntax, char * string, uint * length) { uint offset = 0; uint subset = 0; uint select = 0; -- 2.39.5