These days, I’m trying to import 3D models exported as Wavefront OBJ files in my Vulkan renderer. In order to achieve that effortlessly (kinda), I’m using the very good Assimp (pun not intended) library.
It kinda works well if you stick to a « traditional Blinn-Phong » lighting pipeline (also known as « prehistoric lighting » 😉 ), with ambient/diffuse/specular components and so on. Everything is there. Things become trickier if you try to bring PBR into the mix, with roughness, metallic and ambient occlusion maps for example.
What parameters should you use in Assimp to read those values ? What texture type should be used in order to import those maps ? Turns out it’s not as easy as one would think, because support on both the Wavefront OBJ specification and Assimp is just not there.
I had a problem recently : my scripting experience coming mostly from Linux, I’m much more used to shell scripts than .bat scripts. And despite working on Windows, I still prefer using shell script language mostly for human factors reasons (I find batch syntax ugly and frankly impossible to understand and/or remember).
But contrary to the Linux world, a shell executable (also known as sh.exe, or any other flavor like Bash or Zsh to name a few) is not installed by default on a Windows. You have to install it yourself and do a bunch of wiring so that shell files are automatically executed by the shell executable using some kind of fake Unix environment (Cygwin is a good example).
Working with Python on and off for years now, I had the… opportunity to be the victim of a number of pitfalls inherent to the language, with some of them having caused weird bugs and hard-to-track issues, mostly due to my lack of Python knowledge.
In order to remember them, and perhaps to help you too, reader, if you don’t know them, here are some of my all-time favorites !
I’d like to talk here about two not-so-new features of C++ (auto types and lambda functions) that managed to bite me recently, even though I thought I knew them well enough (I still do!).
According to me, it doesn’t show that one should ditch them into oblivion and neveruse them (but some people make their life easier by doing so), but clearly that they should be handled with care, as they more or less act as syntactic sugar on C++ type system, which can be, unfortunately, both overly rigid (which is why we use them in the first place) and overly flexible (which is usually why bugs get in our way).