Strand Engine

Strand Engine version UNFINISHED
Download Full Source Code + Examples + Libraries Source on Bitbucket
Library of C(99ish) code for developing real-time applications and games for Linux and Windows. To get started learning look in the 'README.txt' file and 'Engine/examples' folder for code examples of the classes and functions.



Here is a list of some of the C code included:

msvcdef.h - Defines for fixing a few inconsistencies between Microsoft Visual Studio and GCC.

endianness.h - Functions for detecting endianness and reversing byte order.

misc.h - Miscellaneous mix of functions, includes hashing function.

system.h - OS/system related functions, includes threadSleep and mutex locks.

list.h - Dynamic array struct and functions.

hashmap.h - Hashmap lookup struct and functions.

pool.h - Pool struct and functions.

slist.h - Synchronized list for multithread safe list operations, including locking/unlocking for iterating.

vecmath.h - Vec2/vec3/vec4 structs and functions.

rng.h - Random number generator with custom sized seed.

timer.h - Timer system and tick/refresh rate helper.

reflection.h - Macros and functions for manually declaring reflection data.

json.h - Struct and functions for loading and saving JSON data.

http.h - Basic HTTP/1.1 GET call function.

stream.h - Flexible stream struct and functions for reading and writing files, console and memory.

screencapture.h - Screen capture functions.

printftofile.h - Uses a macro to re-route printf to a file, bad for performance but nice for debugging.

bmphelper.h - Helper functions for loading and saving .BMP image files.

pnghelper.h - Helper functions for loading and saving .PNG image files.

compression.h - Binary RLE compression and decompression.

sha1.h - Function for SHA1 hash.

base64.h - Base64 encoding and decoding functions.

database.h - Struct and functions for file based list of objects and hashmap.

nsocket.h - Struct and functions wrapping Linux/Windows sockets.

websocket.h - Functions for opening, reading and writing simple unencrypted websocket connections.

webcam.h - Struct and functions for opening and capturing webcam video.

normalizeunicode.h - Converts unicode text to ASCII.

graphing.h - Struct and functions for drawing 2D graphs and shapes in software.

datapatch.h - Functions for file delta patching.

fouriertransform.h - Fast fourier transform.

cosinetransform.h - Fast cosine transform.

inputcontrol.h - Struct and functions for fake inputs and global keybinds.

processmemory.h - Functions for reading and writing process memory.

processdebug.h - Functions for debugging process threads.

window.h - Struct and functions for handling SDL window and OpenGL context setup.

audio.h - Functions for setting up SDL audio output and outputting raw audio stream.

graphics.h - Struct and functions wrapping OpenGL objects like shaders, meshes, textures, uniform buffers and more.

engine.h - Struct and functions for object component system.

engine_serialization.h - Functions for serializing engine objects.

inputmanager.h - Functions for managing input bindings and loading through JSON.

assets.h - Struct and functions for asset loading system.

assets_base.h - Basic text/binary(.txt/.bin) asset loading functions.

audio_assets.h - Audio(.wav) asset loading functions.

graphics_assets.h - Image(.png/.bmp), font(.otf/.ttf), shader(.glsl/.shader) and mesh(.obj/.fbx/.dae/.gltf/.blend/.3ds) loading functions.

engine_launch.h - Functions for normal engine launch.

editor/engine_editor.h - Functions for engine visual editor launch.

editor/editor_style.h - Editor style options like font, font size, font color, foreground and background color.

editor/addons/ - Editor addon code.


components/graphics/rendering.h - Renderer and graphic components for 2D and 3D rendering.


components/gui/gui.h - GUI and GUI components for extendable 2D GUI rendering.

components/gui/guidraggable.h - Draggable GUI component.

components/gui/guidragview.h - Draggable view panel component.

components/gui/guitext.h - Text component.

components/gui/guitextfield.h - Text input component.


components/physics2d/rigidbody2d.h - Rigid body component for 2D physics engine.

components/physics2d/collider2d.h - Collider component for 2D physics engine, supports box, circle and custom colliders.


The README notes some issues but also be aware there is a giant number of potentially unknown issues or bugs. Use this code and software at your own risk.

Dependencies:
SDL for OpenGL and window/event/os management.
SDL_ttf for pre-rendering fonts.
Freetype for loading fonts.
Zlib for loading PNG images.
Libpng for loading PNG images.
Open Asset Import Library for loading 3D models.
GLEW for OpenGL extension functions.