LabSmall experiments in rendering, simulation and emulation. Most of them took an evening.More on LinkedIn All 29Emulation 4Gameplay 4Performance 4Rendering 12Simulation 5Ray Tracing in One Weekend on a PSP 3000Rendering, Apr 2026Ray Tracing in One Weekend on a PSP 3000Rendering, April 2026✨ Ported "Raytracing in One Weekend" straight to the PSP 3000See the post Ray Tracing in One Weekend case study GLASM: OpenGL in x64 NASMRendering, Aug 2025GLASM: OpenGL in x64 NASMRendering, August 2025🎨 OpenGL-ASM x64 NASM Project (GLASM)Simple OpenGL 1.1 demo rendering a triangle using GLFW and NASM assembly on x64 platforms.Features:Minimal NASM x64 setupGLFW window creation and managementBasic triangle rendering with OpenGLCross-platform ready (Windows/macOS/Linux)Source on GitHub GLASM case study Game of Life with sparse encodingSimulation, Aug 2025Game of Life with sparse encodingSimulation, August 2025🧩 Conway’s Game of Life: Sparse EncodingInspiration:Huge 264 Conway’s Game Of Life Sim, using Sparse EncodingSee the post CameBoy: a minimalist Game Boy emulator in C99Emulation, Jul 2025CameBoy: a minimalist Game Boy emulator in C99Emulation, July 2025🧩 CameBoy: A Minimalist Game Boy Emulator in C99A clean, from-scratch Game Boy emulator written in pure C99, with a focus on simplicity, clarity, and low-level accuracy.📚 Resources that shaped this projectPan Docs, the most complete technical referenceRodrigo Copetti’s Console Architecture GuideGekkio’s Hardware ResearchThe Ultimate Game Boy Talk (33C3)Game Boy Emulator Dev Series on YouTubeSource on GitHub CameBoy case study Ray Tracing in One WeekendRendering, Jul 2025Ray Tracing in One WeekendRendering, July 2025✨ Ray Tracing in One WeekendA hands‑on journey building a CPU-based ray tracer from scratch, fully in C99, following Ray Tracing in One Weekend by Peter Shirley.Source on GitHub Ray Tracing in One Weekend case study Dura2D and LeveGL on the PSPSimulation, Jul 2025Dura2D and LeveGL on the PSPSimulation, July 2025🕹️ Dura2D + LeveGL on PSPRunning my own 2D physics engine (Dura2D) and minimalist OpenGL-style wrapper (LeveGL) on real Sony PSP hardware.What I’ve pulled off so far:Libraries ported to pspsdk, with all system dependencies replaced.Rendering pipeline and physics adapted for PSP’s fixed-function GPU and tight memory budget.Demos successfully run at full resolution on a PSP 3000.📸 Captured the result in a short recording real-time simulation and rendering, powered entirely by homebrew code.See the post LeveGL case study Explaining ray marching with ray marchingRendering, Jun 2025Explaining ray marching with ray marchingRendering, June 2025🌫️ Explaining Ray Marching… with Ray MarchingA meta-visual experiment: using real-time ray marching to explain how ray marching works, directly in the browser.Features:A minimal SDF-based ray marcher using signed distance fieldsInteractive visualizations: orbit camera, distance debug view, and step tracing overlayEmbedded directly into the blog post. The explanation is the render🎯 Goal: make an intuitive, visual-first introduction to ray marching that teaches by showing, not telling.See the post Ray tracing and the aesthetics of normalsRendering, Jun 2025Ray tracing and the aesthetics of normalsRendering, June 2025✨ Ray Tracing & the Aesthetics of NormalsExploring how surface normals shape the visual soul of ray-traced scenes.See the post MOS 6502 emulator in C99Emulation, Jun 2025MOS 6502 emulator in C99Emulation, June 2025🧩 MOS 6502 Emulator Written in C99A clean and minimal MOS 6502 emulator built entirely in C99, focused on correctness, readability, and low-level understanding.What’s working so far:Full instruction set implemented and verifiedAccurate cycle timing and flag behaviorMemory-mapped bus with support for RAM, ROM, and I/O regionsDesigned to be embedded into other systems or used for standalone programsA foundational project to better understand how 8-bit CPUs work and how to build emulators from the ground up.See the post Game Boy audio visualizerEmulation, Mar 2025Game Boy audio visualizerEmulation, March 2025🔊 GameBoy Audio VisualizerA simple, real-time visualizer for the Game Boy’s four audio channels, designed to help me understand and debug the APU while I add sound to my emulator.See the post CameBoy case study Dura2D running on a Nintendo SwitchSimulation, Mar 2025Dura2D running on a Nintendo SwitchSimulation, March 2025🕹️ Dura2D Running on a Nintendo SwitchGot Dura2D, my custom 2D physics engine, running natively on a modded Nintendo Switch using the devkitPro homebrew toolchain.What’s been achieved:Ported core physics loop.Ran physics demos in real time on handheld mode.Kept it fast, small, and fully self-contained.The project is an exercise in pushing homebrew boundaries while keeping the architecture minimal and portable.See the post Dura2D case study Pathfinding testbed optimizationsPerformance, Nov 2024Pathfinding testbed optimizationsPerformance, November 2024⚡ Pathfinding Performance: A Testbed OptimizationsI built a custom pathfinding testbed and explored 16,310 nodes in about 0.33 ms. Each colored pixel shows low‑level tweaks at work:Key experiments that unlocked speed:Memory layoutPack structs to remove paddingAlign hot functions to cut cache missesPack frequent data tightlyAdd manual prefetching in A* loopsCompute optimizationsInline distance math and use SSE2Ensure proper loop order for better cache localityTask controlSimple fiber‑based job systemTime slicing to balance workDelay result gatheringBig thanks to Perf Ninja for the low‑level inspiration. Still room to push this further.See the post Shader.Vista: multi-pass shader web editorRendering, Nov 2024Shader.Vista: multi-pass shader web editorRendering, November 2024🎨 Shader.Vista: Multi‑Pass Shader Web EditorA browser‑based tool for creating and experimenting with multi‑pass fragment shaders.What’s in place:Monaco Editor integration for code editingWebGL 1 and WebGL 2 contexts with shader compilationMulti‑pass rendering pipeline with framebuffer swappingUI layout styled with Tailwind CSSDrag‑and‑drop ordering of render passes via DnD KitSee the post Actis case study Basic Sony PSP renderingRendering, Oct 2024Basic Sony PSP renderingRendering, October 2024✨ Basic Sony PSP renderingRevisiting my childhood passion by programming graphics on the original PlayStation Portable. Using pspdev/pspsdk and pspgl (an OpenGL ES–like layer) to get native rendering up and running.See the post Dynamic AABB treeSimulation, Sep 2024Dynamic AABB treeSimulation, September 2024🌳 Dynamic AABB TreeI’ve integrated a full dynamic AABB tree system into Dura2D, inspired by Box2D, and the performance boost was immediate.What’s implemented:Surface Area Heuristic (SAH) Balances the tree by minimizing the total surface cost. Instead of using height or node count, SAH makes smarter split and rotation decisions, reducing overlap and traversal steps.Fat AABB Each object has a slightly larger bounding box to allow small movements without triggering tree updates. This reduces the number of insertions and keeps the tree stable.Memory Management Nodes are managed through a fixed-size pool with a free list. No dynamic memory allocation during runtime, which improves stability and frame consistency.Result: The broad-phase is now fast, efficient, and scales well under load. Dura2D handles large scenes more easily, and the tree stays compact and responsive even with constant movement.See the post 2D SDF interactive demoRendering, Jun 20242D SDF interactive demoRendering, June 2024🛠️ 2D SDF Interactive DemoReal‑time 2D Signed Distance Field demo generating smooth shapes and animations purely from simple equations.UE5: multithreading, time slicing and delayed result gatheringPerformance, Apr 2024UE5: multithreading, time slicing and delayed result gatheringPerformance, April 2024🛠️ Unreal Engine 5: Multithreaded + Time Slicing + Delayed Result GatheringExperimenting with FRunnable to speed up line casts on a grid and update an exposure map in UE5. By combining FRunnable, delayed result gathering, and time slicing, I hit some impressive numbers:What’s implemented:FRunnable tasks for parallel line castsDelayed result gathering to avoid main‑thread stallsTime slicing to split work across framesInspiration: Adapted the Unity Job System approach from Ming‑Lun “Allen” Chou’s blog to Unreal Engine.See the post Deferred Jobs case study Chip0u: a CHIP-8 emulator in C++20Emulation, Feb 2024Chip0u: a CHIP-8 emulator in C++20Emulation, February 2024🧩 Chip0u: A CHIP-8 Emulator in C++20 with raylib + ImGuiA playful and modern take on the classic CHIP-8 virtual machine, written in C++20 with a focus on clarity and UX.What’s implemented:Full CHIP-8 instruction set with accurate timing and quirk handlingBuilt-in debugger with step, breakpoint, and memory inspectionUI built with ImGui, rendered using raylibKey remapping and save state supportLoads and runs most public domain ROMs with zero configDesigned to feel light and responsive while offering deep control for learning and experimentation.See the post Dura2D: a 2D physics engine for learningSimulation, Jan 2024Dura2D: a 2D physics engine for learningSimulation, January 2024🚀 Dura2D: Building a 2D Physics Engine for LearningI set out to discover how games simulate rigid bodies and collisions by coding my own 2D physics engine from scratch. Dura2D grew from a question: how do games deliver realistic motion and interactions?Inspired by Pikuma’s course, Ming-Lun "Allen" Chou Game Physics blog posts and Erin Catto’s Box2D code, Dura2D offers:Constraint System for joints and contactsWarm Starting to reuse previous frame impulses and boost stabilityStable, real‑time simulation across different scenariosSee the post Dura2D case study Frustum culling with AABBsRendering, Sep 2023Frustum culling with AABBsRendering, September 2023📦 Frustum Culling + AABBImplemented frustum culling using axis-aligned bounding boxes. Each object’s AABB is tested against the view frustum planes before rendering. Simple, fast, and cut draw calls by over 70% in large scenes.Quadtree spatial partitioningPerformance, Sep 2023Quadtree spatial partitioningPerformance, September 2023🛠️ Quadtree Spatial PartitioningOptimized 2D collision detection and spatial queries using a quadtree in SDL2. Visual debug and performance logging reveal major gains over brute force.Key features:Quadtree nodes with dynamic subdivisionEfficient range queries for nearby objectsSDL2 overlay of quadtree bounds and entitiesBased on The Coding Train’s Quadtree challengeSee the post OpenGL: skyboxRendering, Jul 2023OpenGL: skyboxRendering, July 2023🌌 OpenGL: Skybox ImplementationAdded a skybox system using cube maps in OpenGL. View-locked, depth-tested, and rendered last for proper blending. Clean backdrop, zero artifacts, and ready for HDR probes.Unity: multithreading, time slicing and delayed result gatheringPerformance, Apr 2023Unity: multithreading, time slicing and delayed result gatheringPerformance, April 2023🛠️ Unity: Multithreaded + Time Slicing + Delayed Result GatheringExperimenting with Unity’s Job System and Burst compiler to speed up line casts on a grid and update an exposure map in Unity. By leveraging IJobParallelFor, delayed result gathering, and frame slicing, I’ve hit some impressive numbers:What’s implemented:IJobParallelFor jobs for parallel line castsDelayed result gathering on the main thread to avoid stallsTime slicing to spread work over multiple framesInspiration: Based on Ming‑Lun “Allen” Chou’s approach in Unity’s Job System.See the post Deferred Jobs case study Virtual production: UE5 pipeline fixRendering, Aug 2022Virtual production: UE5 pipeline fixRendering, August 2022🎬 Virtual Production: UE5 Pipeline FixRecorded a virtual production scene in Unreal Engine 5 to debug pipeline issues. Found and fixed a desync between the matte layer and foreground render.Unity: Donut County prototypeGameplay, Jan 2022Unity: Donut County prototypeGameplay, January 2022🕹 Unity: Donut County PrototypeA physics‑driven hole‑digging game prototype inspired by Donut County, built entirely in Unity to test core mechanics and feel.Unity: raymarched sphere on a billboard quadRendering, Apr 2021Unity: raymarched sphere on a billboard quadRendering, April 2021🪐 Unity: Raymarched Sphere on a Billboard QuadUsed simple raymarching on a billboard quad to simulate a 3D sphere. Replaced high-poly planet meshes with a single shader pass. Perfect for educational solar system sims on low-end devices. Clean, fast, and visually solid.Remap function testGameplay, Dec 2020Remap function testGameplay, December 2020🧪 Remap Function Test: Value to Range MappingRan a simple visual test to validate a remap function, converting a value from one range to another in real time.Unity: dynamic camera FoV adapterGameplay, Dec 2020Unity: dynamic camera FoV adapterGameplay, December 2020🛠️ Unity: Dynamic Camera FoV AdapterA code that adjusts the Camera’s field of view at runtime to encompass a set of tracked Transforms within defined margins.Unity: inverse kinematics studyGameplay, Aug 2020Unity: inverse kinematics studyGameplay, August 2020🛠️ Unity: Inverse Kinematics StudyExploring runtime IK solutions in Unity using the Prototype Asset Pack for character rigs. Implemented goal-driven limb positioning with real‑time adjustments.Assets: POLYGON | Prototype Asset Pack by Unity Technologies