C++ is not cross platform anymore

As of 2019, C and C++ are the only programming languages that are supported by virtually any platforms on the market. For example both iOS and android support compiling C and C++ directly as part of their official IDEs. This is one of the reason why I decided to write my voxel editor Goxel in C99: I wanted to be able to run it on Linux, Mac, Windows, iOS, and now I am working on a Android port as well....

2019 July 4

Lua vs Duktape for embedded scripting language

I recently started to see how to integrate a generic script language into my voxel editor Goxel. I want to use something light and easily embeddable into a C application. One obvious choice for this is to use Lua, but I also wanted to try Duktape, a lightweight JavaScript interpreter. In this post I’ll give some of my conclusions after trying both. 1. SIMPLICITY TO EMBED Both Lua and Duktape are relatively easy to embed into a C application....

2018 December 22

Creating application icons with inkscape

Yesterday I tried to improve the style of my voxel editor goxel. One thing I wanted to do in particual is have better looking icons in the UI. The current icons looked like that on my non retina screen: This is what I came up with: It’s interesting to work on art for computer screen because for such small size images, the pixels aliasing quality becomes primordial. For example in goxel on a non retina screen, the icons should all have a size of 22x22 pixels....

2018 April 18

Porting Goxel to iOS

I just made the first release of my voxel editor project goxel for iOS, and I wanted to write a bit about the process. It’s not the first time I work on a mobile port of C/C++ application, so the process was quite easy. The only new challenge this time is that I used swift on the platform code (instead of objective-C). The global structure of the code consists of a core written in C (or C++), and a small platform dependant layer on top of it to create the application context and handle the inputs....

2017 July 31

Generating the dodecahedron rotation group with python

I was wondering how to compute the rotations for all the faces of the regular dodecahedron (polyhedron with 12 faces). You can find many resources online about the symmetry group of the dodecahedron, but not much practical information about how you would use it in you code, this is specially annoying for non mathematicians like me who don’t want to go too far down the rabbit hole of group theory just to get my 12 rotations....

2017 June 19

Goxel Voxel Editor Internals - Part 2: voxel data structure

In this second part of my series about goxel voxel editor internals, I will talk about the way voxel data is stored in memory. As usual, all the code is open source and accessible on the github repo. The voxel models are composed of many individual voxel, each of them having a color. For the structure of the voxel I wanted: Optimized memory usage: if a model is large but composed of few voxels I don’t want to use extra memory for the empty spaces....

2017 March 13

Goxel Voxel Editor Internals - Part 1: voxels and pixels

This is the first in a series of posts I want to write about the technical aspect of writing a voxel engine / editor. I wrote a free and open source voxel editor available on github, and I wanted to share the things I learned in the process. Today’s post is just an introduction, where I am going to talk about the evolution of computer graphics and the advent of voxels....

2017 March 9

Introducing Noctua Sky

I just released Noctua Sky, a new project I am working on. This is an online planetarium (or sky map) software similar to the open source project Stellarium made by my brother. The goal of the project is ultimately to provide a set of tools and API for amateur astronomers to share their observations online. The first step toward this is to create a JavaScript planetarium that can run directly on the browser....

2017 March 1

Swift vs C++: lambda functions

Recently I got interested in the new Apple language Swift, that will probably replace objective-c as the language of choice for native iOS and OSX applications. There are many things I like in Swift, and also other things I don’t like. But one thing that I really enjoy is the support for lambdas, specially compared to the way it works in C++. Why do I think the lambdas in swift are better?...

2016 November 12

Hacking Doom code for transparent POV display

Doom (the original version), is not only one of the best game ever made, but it’s also a great example of C code. Thanks to id Software decision to release the code as open source in 1999, anybody can have a look and modify it. I had this project of changing the rendering of doom, to add a border effect to the walls, or cel shading. You can check the video at the end of this post to see why I wanted to do this to start with....

2016 September 2