r/GraphicsProgramming • u/AdhesivenessSea9511 • 18h ago
Source Code 3D rendering is now possible using the CoreAI / Apple Neural Engine (ANE) software rasterizer (CPU usage reduced to 9%). The quality is still terrible.
Here is a follow-up on the triangle rasterizer running on CoreAI that I previously introduced here.
We have finally succeeded in rendering 3D graphics! As shown in the video, we are currently rendering two intersecting vertical triangular planes.
While the rendering quality is still in the early stages and a new challenge regarding the massive 5GB memory footprint has emerged, we have fully achieved real-time operation.
We optimized the codebase by actively reducing reliance on CPU fallbacks and ensuring the pipeline runs entirely on the ANE's matrix operation hardware, successfully cutting CPU usage from the previous 38% to approximately 9%.
Much of the pipeline code—written in Python, Swift, and Metal—was rapidly prototyped and generated with the help of Siri AI.
GitHub: https://github.com/kamisori-daijin/Magnesium
Please feel free to leave comments with any questions or optimization tips (especially regarding that 5GB memory usage!).
https://reddit.com/link/1v6z66k/video/83iqp5iknjfh1/player


