If you like this, you may also like my similar project: raycastlib. These two libraries can very easily be combined together -- here is a proof-of-con

drummyfish/small3dlib: Suckless PD 3D software rasterizer - Codeberg.org

submited by
Style Pass
2024-09-27 02:30:06

If you like this, you may also like my similar project: raycastlib. These two libraries can very easily be combined together -- here is a proof-of-concept gif (environment rendered with raycastlib, cubes with small3dlib):

NOTE: Backwards compatibility isn't a goal of this libraray. It is meant to be an as-is set of tools that the users is welcome to adjust for his specific project. So new features will be preferred to keeping the same interface.

You just need to make a small mini 3D game, quick 3D animation or visualization and don't want to go through the horror of learning and setting up OpenGL or Vulkan, installing drivers, learning complex APIs and libraries? Don't want to be tied to HW, 3rd party API or libraries and their dependencies? Don't want to install gigabytes of heavy super ultra graphics engines just to play around with a few low poly models? You need a simple software renderer as a fallback to your main renderer? You want to create extremely portable 3D graphics that will run on small obscure embedded platforms that don't have OpenGL, good specs, FPU unit or even standard C library? Want to just render something offline simply without caring about highest rendering speed? You want to toy around with modifying something in the rendering pipeline that you can't easily do or debug in big frameworks (such as the rasterization algorithm)? Want to hack around in the demo scene? Want to create something public domain and need a public domain renderer? Or just don't want to be bothered by conditions such as proper attribution or copyleft? You want to create an authentic retro wobbly PS1 style graphics? Then this library may help you.

For start take a look at the helloWorld.c program, then terminalCube and then other examples (e.g. level.c shows simple integration with SDL).

Leave a Comment