xplain VS incbin

Compare xplain vs incbin and see what are their differences.

xplain

Interactive demos (by magcius)

incbin

Include binary files in C/C++ (by graphitemaster)
Our great sponsors
  • SurveyJS - Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
xplain incbin
1 9
709 917
- -
10.0 0.0
almost 4 years ago 4 months ago
JavaScript C
MIT License The Unlicense
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.

xplain

Posts with mentions or reviews of xplain. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2022-09-21.

incbin

Posts with mentions or reviews of incbin. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2024-01-23.
  • Self-contained Linux applications with lone Lisp
    2 projects | news.ycombinator.com | 23 Jan 2024
    OK, yes, that does work. You can totally put application specific stuff in the elf and reflect on it at runtime. Much easier is to embed it directly and point a symbol value at the start of the data.

    See https://github.com/graphitemaster/incbin for a pretty wrapper around that.

    Aside from there being a drastically simpler answer to this problem available in sketchily documented fashion (the asm guys know .incbin is a thing, but higher level languages overcomplicate it), it's a good post. Idea is sound and goal was achieved.

  • The theory versus the practice of “static websites”
    13 projects | news.ycombinator.com | 15 Jul 2023
    Thanks for the link. We also make static websites by direct inclusion their HTML code in the C++ binary of ClickHouse.

    I've tried to use this library but found a bug: https://github.com/graphitemaster/incbin/issues/61

  • Olive.c: a simple graphics library that does not have any dependencies
    14 projects | news.ycombinator.com | 21 Sep 2022
    won't work, since the preprocessor won't interpret directives inside string literals of course.

    In many assemblers, there is a directive called "incbin" which pastes in unstructured binary data at the point of usage. I just found a very clever C and C++ wrapper [1] for that, which gives you an INCBIN() macro. Nice!

    [1]: https://github.com/graphitemaster/incbin

  • embed workaround
    1 project | /r/C_Programming | 10 Aug 2022
    There's always this: https://github.com/graphitemaster/incbin
  • Finally. Embed
    8 projects | news.ycombinator.com | 23 Jul 2022
    Haven't the people making the standards other things to do, like, integrating useful features instead of duplicating incbin.h [0] years after that feature worked?

    https://github.com/graphitemaster/incbin/blob/main/incbin.h

  • How do I embed files or access them without an operating system?
    1 project | /r/C_Programming | 28 Feb 2022
  • Include files into the Sketch automatically with incbin
    1 project | /r/esp32 | 16 Dec 2021
    There is a project "https://github.com/graphitemaster/incbin" that can take a file and put that file content into the sketch ROM segment as constant / resource. It is an even nicer alternative to "xxd -i" or using string literals like: const char bla[] PROGMEM = R"CERT( ... )CERT";

What are some alternatives?

When comparing xplain and incbin you can also consider the following projects:

ComputerGraphics - Basic computer graphics implementation , with linux framebuffer

aoc-2020 - Advent of Code 2020 in 25 Different Languages

tiny-renderer - A tiny sotfware 3D renderer in 100 lines of Python

SuperSimpleGraphics - An SVG generating single header file C library appropriate for "intro to programming" classes in C/C++.

pl_mpeg - Single file C library for decoding MPEG1 Video and MP2 Audio

execfs - Proof of concept userspace filesystem that executes filenames as shell commands and makes the result accessible though reading the file.

abrash-black-book - Markdown source for Michael Abrash's Graphics Programming Black Book

Quake - Quake GPL Source Release

sitepress - Sitepress ruby gems