Articles RSS

Below are some small articles and tutorials I have written. They are mostly about computer graphics, and mathematics that is useful in computer graphics.


How to ray-intersect a transformed geometry, without actually transforming it: a geometric illustration

The goal of this article, is to describe how we can transform some geometry with a transformation matrix, and then compute the intersection between the transformed geometry, and some ray. However, we want to do this without actually transforming the geometry, since this can be expensive.

How to Start Learning Computer Graphics Programming

I will in this post, give my advice to beginners on how to get started with learning Computer Graphics Programming.

How to Sanity Check your Spherical Harmonics Projection Code

In this post, I will show a small sanity check I use to verify that my spherical harmonics code is correct.

Recovering the Scale, Rotation and Translation Matrices from the Model Matrix

I will in this post show how to recover the separate translation, scale, and rotation matrices from the model matrix.

Hierarchical Z-buffer Occlusion Culling: A Brief Explanation

A brief explanation of the Hierarchical Z-buffer Occlusion Culling technique.

Explanation of the paper 'View-warped Multi-view Soft Shadows for Local Area Lights'

I will in this post write down an explanation of the intuition behind the paper 'View-warped Multi-view Soft Shadows for Local Area Lights'.

Explanation of the paper 'As-Rigid-As-Possible Surface Modeling'

I will in this post write down an explanation of the intuition behind the paper 'As-Rigid-As-Possible Surface Modeling'.

TL;DR of the paper 'Revisiting The Vertex Cache: Understanding and Optimizing Vertex Processing on the modern GPU'

I will in this post write down a TL;DR of the paper 'Revisiting The Vertex Cache: Understanding and Optimizing Vertex Processing on the modern GPU'

TL;DR of the paper 'Conservative Z-Prepass for Frustum-Traced Irregular Z-Buffers'

I will in this post write down a TL;DR of the paper 'Conservative Z-Prepass for Frustum-Traced Irregular Z-Buffers'

TL;DR of the paper 'Stratified Sampling of Projected Spherical Caps'

I will in this post write down a TL;DR of the paper 'Stratified Sampling of Projected Spherical Caps'

TL;DR of the paper 'Reconstructing Scenes with Mirror and Glass Surfaces'

I will in this post write down a TL;DR of the paper 'Reconstructing Scenes with Mirror and Glass Surfaces'

TL;DR of the paper 'Collision-Aware and Online Compression of Rigid Body Simulations via Integrated Error Minimization'

I will in this post write down a TL;DR of the paper 'Collision-Aware and Online Compression of Rigid Body Simulations via Integrated Error Minimization'

TL;DR of the paper 'Cube-to-sphere projections for procedural texturing and beyond'

I will in this post write down a TL;DR of the paper 'Cube-to-sphere projections for procedural texturing and beyond'

Smoothly Filling Holes in 3D meshes using Variational Calculus and Surface Fairing

In this article, we describe an approach to smoothly filling holes in broken meshes that is based on variational calculus. However, do note that it is not assumed that the reader has experience in variational calculus, and we will instead introduce the necessary concepts from this topic when they are needed

An Intuitive Explanation of using Poisson Blending for Seamless Copy-and-Paste of Images

In this article, we explain the intuition behind an image processing technique called Poisson Blending. This technique is an image processing operator that allows the user to insert one image into another, without introducing any visually unappealing seams.

A Simple, and Trivially Parallelizable Triangle Rasterization Approach

In this article, a triangle rasterization algorithm that is easy to implement, yet trivial to parallelize is described.

Interviewing for your First Job as a Graphics Programmer: a Checklist of Common Interview Questions

I have recently been interviewing at game companies, trying to land a job as a junior graphics programmer. Having done so, I gained knowledge of what skills game companies expect of a newly graduated graphics programmer, and what questions they are likely to ask during interviews. I will in this article compile these findings into a handy checklist.

Simple Curve Fitting with the Gauss-Newton Algorithm

It is shown how the Gauss-Newton Algorithm can be used to perform simple curve fitting.

Parallelizing the Gauss-Seidel Method using Graph Coloring

In a previous article, we introduced the Jacobi and Gauss-Seidel methods, which are iterative methods for solving linear systems of equation. Specifically, we noted that the Gauss-Seidel method will in general converge towards a solution much quicker than the Jacobi method. The main issue with the Gauss-Seidel method is that it is non-trivial to make into a parallel algorithm. However, it turns out that for a certain class of matrices, it is pretty simple to implement a parallel Gauss-Seidel method.

Showing the Correctness of Quaternion Rotation

In this article, we shall provide an algebraic proof that shows that quaternion rotation is correct.

The Gauss-Seidel and Jacobi Methods for Solving Linear Systems

In this article, we shall explain the Jacobi and Gauss-Seidel methods, which are two iterative methods used for solving systems of linear equations. Our main objective is to describe how the Gauss-Seidel method can be made into a highly parallel algorithm, thus making it feasable for implementation on the GPU, or even on the CPU using SIMD intrinsics.

Computing the Area of a Convex Polygon

In this article, we shall derive a formula that computes the area of a convex polygon

My Master's Thesis: "Comparing a Clipmap to a Sparse Voxel Octree for Global Illumination"

I describe my master's thesis, give a couple of comments, and provide an image gallery.

Implementing Run-length encoding in CUDA

In the paper Fine-Grain Parallelization of Entropy Coding on GPGPUs, Ana Balevic describes how Run-length encoding(hereafter abbreviated RLE) can be implemented on the GPU. Although the paper is very sparse on details, I have been able to implement her approach in CUDA.

Making Faster Fragment Shaders by Using Tessellation Shaders

In the paper Automatic Shader Simplification using Surface Signal Approximation, Wang et al. describes an algorithm that does automatic shader simplification. Put briefly, the algorithm automatically rewrites shaders so that they become much, much faster. They are using several techniques to achieve this, and one of those techniques I'd like to describe in this post.