🎨 Modern 2D/3D - Importer • Exporter • Util - Library, also called (AssetIO)


Build Status Build Status Codacy Badge Coverage Status glTF Badge

Patreon: Become a patron

Brand-new modern 3D asset importer, exporter library. This library will include common 3D utils funcs. It is written with C99 but C++ wrappers or other language bindings can be written in the future.

This library will try to full support COLLADA specs and glTF specs, plus well-known other 3D formats e.g .obj, .stl, .ply...

There is also an optional renderer library called libgk for render AssetKit contents. You can see how to load AssetKit to libgk in assetkit-gl repo.

Documentation (In Progress)

Almost all functions (inline versions) and parameters will be documented inside the corresponding headers.
Complete documentation: http://assetkit.readthedocs.io

Supported Formats

  • Asset Exchange (todo) http://github.com/AssetExchange/spec
  • COLLADA 1.4 and COLLADA 1.4.1
  • COLLADA 1.5
  • glTF 2.0 (Embedded or Separated (.gltf), Binary (.glb), Extensions...)
  • Wavefront Obj (.obj + .mtl)
  • STL (ASCII, Binary)
  • PLY (ASCII, Binary)
  • USD and friends (License?)
  • Alembic (License?)
  • Draco
  • X3D
  • in progress for next...


  • Single interface for glTF 2.0 (with extensions), COLLADA 1.4/1.4.1/1.5, Wavefront Obj and others...
  • Very very small and very fast library
  • Javascript-like API to get URL or ID obj = ak_getObjectById(doc, objectId)...
  • Options to Generate Mesh Normals (Default: enabled)
  • Option to Triangulate Polygons (Default: enabled)
  • Option to change Coordinate System (Default: enabled)
  • Option to calculate Bounding Boxes (Default: enabled)
  • Unique and Flexible Coordinate System
    • Support multiple coordinate system
    • Can convert any coordinate system to another with adding transform or with changing transform, vertex data...
  • Unique and Flexible Memory Management System
    • Hierarchical unique memory management
      • When a node is freed then all sub memories will be freed
    • COLLADA's sid and ID values are mapped to memory nodes itself to reduce memory size and make it easy to manage things.
    • Allow attach ID, sid or user data to a memory node
  • Object-based Asset support; resolve asset element for any element
  • Bugfix some DAE files
  • Will be optimized to be fastest, smallest and most flexible, extendible Asset loader.
  • Uses mmap to load files, you can disable this if needed
  • Documentation
  • Cmake support
  • Tests


CMake (All platforms)

$ mkdir build
$ cd build
$ cmake .. # [Optional] -DAK_SHARED=ON
$ make
$ sudo make install # [Optional]
Cmake options with Defaults:
option(AK_SHARED "Shared build" ON)
option(AK_STATIC "Static build" OFF)
option(AK_USE_TEST "Enable Tests" OFF) # for make check - make test

Use with your CMake project

  • Example:
cmake_minimum_required(VERSION 3.8.2)

project(<Your Project Name>)

add_executable(${PROJECT_NAME} src/main.c)
target_link_libraries(${LIBRARY_NAME} PRIVATE assetkit)


# or you can use find_package() to configure assetkit

Unix (Autotools)

Step 1: First you should build dependencies, do this only once:

$ sh ./build-deps.sh

Step 2: Build, Test and Install AssetKit

$ sh autogen.sh
$ ./configure
$ make
$ make check
$ [sudo] make install

Step 3: Change install name if required, after make finished make automaticall runs sh ./post-build.sh script. It changes install names. You may want to edit build scripts and post-build.sh script if you want to build AssetKit with existing libraries. Default behavior is that AssetKit will look up sub libraries inside .libs folder, if you only need to change .libs name then change it in post-build.sh script file.

Windows (MSBuild)

Windows related build files, project files are located in win folder, make sure you are inside assetkit/win folder. Code Analysis are enabled to it may take awhile to build

git and python commands should be installed/accessible.

$ cd win
$ .\build.bat
$ msbuild assetkit.vcxproj /p:Configuration=Release

if msbuild won't work correctly then try to build with devenv:

$ devenv assetkit.sln /Build Release


glTF and COLLADA and their logos are trademarks of Khronos Group.

  • Can't build library on linux

    Can't build library on linux

    I am running Garuda Linux

    I git clone the repository run cmake/automake as in the tutorial and i get compile errors after I run make.

    Consolidate compiler generated dependencies of target ds
    [  0%] Building C object deps/ds/CMakeFiles/ds.dir/src/util.c.o
    /home/snake/Desktop/AssetKit/deps/ds/src/util.c: In function ‘ds_print_i64’:
    /home/snake/Desktop/AssetKit/deps/ds/src/util.c:122:16: error: format ‘%llu’ expects argument of type ‘long long unsigned int’, but argument 2 has type ‘int64_t’ {aka ‘long int’} [-Werror=format=]
    122 |   printf("\t%llu\n", *(int64_t *)key);
    |             ~~~^     ~~~~~~~~~~~~~~~
    |                |     |
    |                |     int64_t {aka long int}
    |                long long unsigned int
    |             %lu
    /home/snake/Desktop/AssetKit/deps/ds/src/util.c: In function ‘ds_print_ui64’:
    /home/snake/Desktop/AssetKit/deps/ds/src/util.c:128:16: error: format ‘%llu’ expects argument of type ‘long long unsigned int’, but argument 2 has type ‘uint64_t’ {aka ‘long unsigned int’} [-Werror=format=]
    128 |   printf("\t%llu\n", *(uint64_t *)key);
    |             ~~~^     ~~~~~~~~~~~~~~~~
    |                |     |
    |                |     uint64_t {aka long unsigned int}
    |                long long unsigned int
    |             %lu
    cc1: all warnings being treated as errors
    make[2]: *** [deps/ds/CMakeFiles/ds.dir/build.make:104: deps/ds/CMakeFiles/ds.dir/src/util.c.o] Error 1
    make[1]: *** [CMakeFiles/Makefile2:672: deps/ds/CMakeFiles/ds.dir/all] Error 2
    make: *** [Makefile:156: all] Error 2

    If I try to hand fix these errors, a bunch of errors pop up, not just warning, but errors like AK_INLINE, AkFloat3 etc.

    build resolved 
    opened by eLeCtrOssSnake 46
  • Questions about specs

    Questions about specs

    1. Can every element (or every node) have different UP axis? Or one UP axis for entire document?
    2. Camera UP axis: https://forums.khronos.org/showthread.php/13262-COLLADA-1-5-Camera-Orientation
    3. Spotlight: https://github.com/KhronosGroup/glTF/issues/824
    help wanted question 
    opened by recp 13
  • How to compile this? getting error.

    How to compile this? getting error.

    I keep getting this error and have git and python both installed and to PATH....

    Annotation 2020-05-18 003148

    note I am not a developer or coding person, I just want to test this addon ....


    opened by Blenux 4
  • mesh_edit_mesh.c and mesh_edit_mesh_fixup.c are named wrongly

    mesh_edit_mesh.c and mesh_edit_mesh_fixup.c are named wrongly


    Should be mesh_edit_buff.c and mesh_edit_mesh_buff.c after this refactor commit.

    opened by ning-y 1
  • proposal: store joint and weights in mesh

    proposal: store joint and weights in mesh

    In the current design, we store joints and joint weights in skin object. But these data could be stored in mesh instead of skin like glTF design. In this way we could access joints and weights more easily. Render engines could load joints/weights more easily...

    opened by recp 1
  • loading images

    loading images

    Currently AssetKit uses stb_image to load images but maybe creating a separate library for images would be better and give more control for loading images.

    opened by recp 1
  • Make Converting Coord Sys Optional

    Make Converting Coord Sys Optional

    As default behavior, AssetKit tries convert document coordinate system to default coordinate system which is configurable option AK_OPT_COORD. But the problem is that viewer may not want involve to any coord-sys specific operation.

    Making this step optional will improve loading performance

    Default is Y_UP but with an option like ak_opt_set(AK_OPT_USE_DOC_COORD, true); loaded document's coord sys can be considered as default coord-sys e.g. if imported document is Z_UP default will be Z_UP and loader will skip converting coord-sys (geometries, transforms, cameras, lights...)

    AK_OPT_USE_DOC_COORD should not override AK_OPT_COORD option

    opened by recp 1
  • Figure out

    Figure out "Page build failure" warning/error

    The page build failed with the following error:

    The submodule registered for ./lib/libxml2 could not be cloned. Make sure it's using https:// and that it's a public repo. For more information, see https://help.github.com/articles/page-build-failed-invalid-submodule.

    For information on troubleshooting Jekyll see:


    If you have any questions you can contact us by replying to this email.

    NOTE: libxml2 submodule reference link starts with git:// not https://, also GitBook maybe used instead of Jekyll, not sure!

    opened by recp 1
  • Generate Normals

    Generate Normals

    If mesh doesn't contain normals then they must be generated if this option is not disabled.

    This is optional for users. Default behavior is generate normals if needed.

    opened by recp 1
  • fix parsing wavefront-obj (critical)

    fix parsing wavefront-obj (critical)

    Each vertex/normal/textcood now has unique id in wavefont-obj spec, it was separated for each object/group which was wrong in AssetKit. This is fixed now.

    opened by recp 0
  • submodule url for libxml2 is outdated

    submodule url for libxml2 is outdated

    See: https://mail.gnome.org/archives/desktop-devel-list/2018-August/msg00010.html ("git.gnome.org being discontinued: Thursday 23th of August")

    opened by ning-y 0
  • Android Support

    Android Support

    AssetKit must support Android JNI / NDK. Currently I couldn't build AssetKit for Android because of I couldn't build libxml2 for Android.

    Dropping some dependencies is an option to make it more build friendly, especially for Android.

    android build 
    opened by recp 0
  • v0.3.1(Aug 18, 2020)

    AssetKit now provides an option to read files with mmap (Windows also supported). This options is enabled as default. To disable mmap

    ak_opt_set(AK_OPT_USE_MMAP, false);

    New Features:

    • New Option: AK_OPT_USE_MMAP boolean, default is true.
    • Expose mmap api to usable externally
    • mmap-ed memories can be attached to a memory node, unmap will be called before memory node is free-ed
      • ak_mmap_rdonly(int fd, size_t size) - map file as READONLY
      • ak_unmap(void *file, size_t size)- unmap file
      • ak_mmap_attach(void *obj, void *mapped, size_t sized) - attach mmap to memory to unmap automatically
      • ak_unmmap_attached(void *obj) - unmap all attached mmap files

    Bugfixes and Improvements:

    • fix ak_strtok_count_fast for READONLY memory
    • util: remove modes from ak_readfile and make it "rb" globally
    • dae: fix writing READONLY memory
    • memory: fix URL memory extension
    • some other improvements
    Source code(tar.gz)
    Source code(zip)
  • v0.3.0(Aug 14, 2020)

    New Features:

    • AssetKit now supports PLY (both ASCII and Binary) files
    • endian helper to read binary data; use common endian header for all formats (endian.h)
    • documentation

    Bugfixes and Improvements:

    • wobj: fix loading wavefront object if there is no NORMAL (position + texture case)
    • wobj: improve switching between objects (use triangle object if the target is not poly)
    • wobj: join group and object separations
    • add new compare func for ivec3
    • wobj: group/separate primitives by usemtl: mesh primitives created for each usemtl, base buffers and accessors are shared between them
    • reuse postscript functions and files
    • use short names for input semantics; remove _SEMANTIC from enum constants
    • improve byte swap operations and make cross platform
    • rename _assetkit_hide macros to AK_HIDE
    • add common strpool to avoid duplications
    • stl: fix loading normals in Binary STL
    • dae: fix load skin controllers
    • dae: move controller postscripts to separate file
    • drop stb image, let user load images themselves
    • provide callbacks for loading images
    • move dependencies from lib/ folder to deps/
    • remove unused files, suppress warnings, update README
    • remove sample-model sub repo for tests
    Source code(tar.gz)
    Source code(zip)
  • v0.2.0(Jul 14, 2020)

  • v0.1.0(May 17, 2020)

Recep Aslantas
alone with numbers
Recep Aslantas
Creating Unreal Engine infinite landscapes/oceans using the editor shader graph and rendering them using Geometry ClipMap. It also allows to spawn mesh on landscape surface. UE5 required

Procedural Landscapes and Oceans in Unreal Engine 5 using Editor Shader Graph Latest version of this project is available as a plugin for UE 4.26+ on

Maxime Dupart 10 Oct 4, 2021
Russian draughts (also known as checkers or shashki) game

Russian draughts (2011) Russian draughts (also known as checkers or shashki) game. This project was implemented by me as a bachelor thesis in 2011 whe

Valery Kirkizh 1 Nov 12, 2021
A library for high-performance, modern 2D graphics with SDL written in C.

SDL_gpu, a library for making hardware-accelerated 2D graphics easy. by Jonathan Dearborn SDL_gpu is licensed under the terms of the MIT License. See

Jonathan Dearborn 1.1k Dec 29, 2022
Gaming meets modern C++ - a fast and reliable entity component system (ECS) and much more

EnTT is a header-only, tiny and easy to use library for game programming and much more written in modern C++. Among others, it's used in Minecraft by

Michele Caini 7.6k Jan 4, 2023
A lightweight game engine written in modern C++

Halley Game Engine A lightweight game engine written in C++17. It has been used to ship Wargroove, a turn-based strategy game, on Windows, Mac (experi

Rodrigo Braz Monteiro 3.2k Dec 30, 2022
D2DX is a complete solution to make Diablo II run well on modern PCs.

D2DX D2DX is a preservation project for running classic Diablo II/LoD on modern PCs. Version 0.99.403b Mission statement Turn the game into a well beh

null 258 Jan 3, 2023
C++ game engine inspired by quake. Modern rendering and quake mapping tool integration.

Nuake Feel free to join the discord server for updates: What is it Nuake is a game engine written from scratch by myself. It is not meant to be a end-

Antoine Pilote 25 Oct 17, 2022
Exploring the modern rendering landscape

HellTech Engine An WIP exploration of the modern rendering landscape with Vulkan 1.2+ on Windows. REQUIREMENTS: Win10+ Vulkan1.2+ dedicated GPU ( ?, p

null 7 Jul 11, 2022
TrenchBroom is a modern cross-platform level editor for Quake-engine based games.

TrenchBroom is a modern cross-platform level editor for Quake-engine based games.

TrenchBroom 1.3k Jan 8, 2023
This is Pangea Software’s Otto Matic updated to run on modern desktop platforms.🤖

Otto Matic This is Pangea Software’s Otto Matic updated to run on modern desktop platforms. Get builds for macOS, Windows and Linux here: https://gith

Iliyas Jorio 106 Dec 21, 2022
A lightweight but complete ECS implementation for modern C++.

ECS A lightweight but complete ECS implementation for modern C++. Features Cache friendly design implemented on top of an EnTT-like sparse set. Clean,

null 7 Sep 3, 2022
Gaming meets modern C++ - a fast and reliable entity-component system (ECS) and much more

EnTT is a header-only, tiny and easy to use entity-component system (and much more) written in modern C++. Among others, it's also used in Minecraft by Mojang and The Forge by Confetti.

Sean Middleditch 8 Feb 16, 2021
Animation compression is a fundamental aspect of modern video game engines

Animation compression is a fundamental aspect of modern video game engines. Not only is it important to keep the memory footprint down but it is also critical to keep the animation clip sampling performance fast.

Nicholas Frechette 1k Jan 2, 2023
A simple and easy-to-use library to enjoy videogames programming

raylib is a simple and easy-to-use library to enjoy videogames programming. raylib is highly inspired by Borland BGI graphics lib and by XNA framework

Ray 11.3k Jan 4, 2023
Epoxy is a library for handling OpenGL function pointer management for you

Epoxy is a library for handling OpenGL function pointer management for you. It hides the complexity of dlopen(), dlsym(), glXGetProcAddress(), eglGetP

Eric Anholt 578 Dec 30, 2022
Freecell Solver - a C library for automatically solving Freecell and some other variants of card Solitaire

The Freecell Solver Repository Root README Freecell Solver is an open source (distributed under the MIT/Expat licence) library, written in C, for atte

Shlomi Fish 55 Dec 23, 2022
A C math library targeted at games

Kazmath Kazmath is a simple 3D maths library written in C. It was initially coded for use in my book, Beginning OpenGL Game Programming - Second editi

Luke Benstead 506 Dec 31, 2022
Pure C math library for 2D and 3D programming

MATHC MATHC is a simple math library for 2D and 3D programming. Features Vectors (2D, 3D and 4D) (integer type and floating-point type) Quaternions Ma

Felipe da Silva 624 Dec 30, 2022