Articles by Eric Arnebäck
https://erkaman.github.io/articles.html
Some small articles and tutorials written by Eric ArnebäckHow to Start Learning Computer Graphics Programming
https://erkaman.github.io/posts/beginner_computer_graphics.html
https://erkaman.github.io/posts/beginner_computer_graphics.html
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
https://erkaman.github.io/posts/sh_sanity_check.html
https://erkaman.github.io/posts/sh_sanity_check.html
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
https://erkaman.github.io/posts/model_matrix_recover.html
https://erkaman.github.io/posts/model_matrix_recover.html
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
https://erkaman.github.io/posts/hiz_occlusion_culling.html
https://erkaman.github.io/posts/hiz_occlusion_culling.html
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'
https://erkaman.github.io/posts/marrs2018.html
https://erkaman.github.io/posts/marrs2018.html
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'
https://erkaman.github.io/posts/sorkine2007.html
https://erkaman.github.io/posts/sorkine2007.html
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'
https://erkaman.github.io/posts/kerbl2018_tldr.html
https://erkaman.github.io/posts/kerbl2018_tldr.html
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'
https://erkaman.github.io/posts/tokuyoshi2018_tldr.html
https://erkaman.github.io/posts/tokuyoshi2018_tldr.html
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'
https://erkaman.github.io/posts/urena2018_tldr.html
https://erkaman.github.io/posts/urena2018_tldr.html
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'
https://erkaman.github.io/posts/whelan2018_tldr.html
https://erkaman.github.io/posts/whelan2018_tldr.html
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'
https://erkaman.github.io/posts/jeruzalski2018_tldr.html
https://erkaman.github.io/posts/jeruzalski2018_tldr.html
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'
https://erkaman.github.io/posts/zucker2018_tldr.html
https://erkaman.github.io/posts/zucker2018_tldr.html
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
https://erkaman.github.io/posts/hole_filling.html
https://erkaman.github.io/posts/hole_filling.html
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. Most of the techniques described in this
article are based the description of Surface Fairing in section
4.3 of [1]. In the below image, it is shown how our described
algorithm can be used to smoothly and naturally fill holes in a
broken mesh
An Intuitive Explanation of using Poisson Blending for
Seamless Copy-and-Paste of Images
https://erkaman.github.io/posts/poisson_blending.html
https://erkaman.github.io/posts/poisson_blending.html
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. Furthermore, this technique also makes sure that the
color of the inserted image is also shifted, so that the
inserted object feels as if it is part of the environment of the
target image. So a bright object copy-and-pasted into a rather
dark image, will have its color shifted to a darker color. In
the below image, an image of a kitten has been copy-and-pasted
into an image of a library using poisson blending, and as can be
observed, there are no visible seams.
A Simple, and Trivially Parallelizable Triangle Rasterization Approach
https://erkaman.github.io/posts/fast_triangle_rasterization.html
https://erkaman.github.io/posts/fast_triangle_rasterization.html
In this article, a triangle rasterization algorithm that is easy
to implement, yet trivial to parallelize is described. The
algorithm is as follows: it turns out that it is not difficult
to test whether an arbitrary point is inside a triangle. Armed
with such a test, a triangle can easily be rasterized by first
finding the bounding box of the triangle, and then only
rasterizing the pixels inside this bounding box that pass the
test.
Interviewing for your First Job as a Graphics Programmer: a
Checklist of Common Interview Questions
https://erkaman.github.io/posts/junior_graphics_programmer_interview.html
https://erkaman.github.io/posts/junior_graphics_programmer_interview.html
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. The intention is that
other newly graduated programmers can use this list as a way to
prepare, by providing them with a list of topics that they
should rehearse before going into their first
interview. However, as a disclaimer, I do not recommend just
memorizing a bunch of answers to these questions. The topics in
this list are topics that you need to understand and master in
order to solve the programming problems that you will encounter
as a professional graphics programmer. Always strive to
understand, not to memorize.
Simple Curve Fitting with the Gauss-Newton Algorithm
https://erkaman.github.io/posts/gauss_newton.html
https://erkaman.github.io/posts/gauss_newton.html
In the description of the physically based rendering
implementation of Unreal Engine 4[1], Karis states that instead
of using the classical Fresnel formula
Parallelizing the Gauss-Seidel Method using Graph Coloring
https://erkaman.github.io/posts/gauss_seidel_graph_coloring.html
https://erkaman.github.io/posts/gauss_seidel_graph_coloring.html
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. Consider the below linear system
Showing the Correctness of Quaternion Rotation
https://erkaman.github.io/posts/quaternion_rotation.html
https://erkaman.github.io/posts/quaternion_rotation.html
In this article, we shall provide an algebraic proof that shows
that quaternion rotation is correct. As is well-known, we can
rotate a vector $\vec{v}$ by an angle $\theta$ around the
rotation axis $\vec{u}$ using quaternions. This is done with the
calculation
The Gauss-Seidel and Jacobi Methods for Solving Linear Systems
https://erkaman.github.io/posts/jacobi_and_gauss_seidel.html
https://erkaman.github.io/posts/jacobi_and_gauss_seidel.html
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. But before we can
do that, it is necessary to describe the Gauss-Seidel and Jacobi
methods to the reader.
Computing the Area of a Convex Polygon
https://erkaman.github.io/posts/area_convex_polygon.html
https://erkaman.github.io/posts/area_convex_polygon.html
In this article, we shall derive a formula that computes the
area of a convex polygon. That is, given the vertices
$\mvec{v_0}, \mvec{v_1},\dots,\mvec{v_n}$ of some convex polygon
$P$, we want to compute its area, which we denote $A(P)$. We
will use the below polygon for illustrations:
My Master's Thesis: "Comparing a Clipmap to a Sparse Voxel Octree for Global Illumination"
https://erkaman.github.io/posts/masters_thesis.html
https://erkaman.github.io/posts/masters_thesis.html
Voxel cone tracing is a real-time method that approximates
global illumination using a voxel approximation of the original
scene. However, a high-resolution voxel approximation, which is
necessary for good quality, consumes much memory, and a compact
data structure for storing the voxels is necessary. In this
thesis, as a primary contribution, we provide a comparison of
two such data structures: a Sparse Voxel Octree, and a Clipmap.
Implementing Run-length encoding in CUDA
https://erkaman.github.io/posts/cuda_rle.html
https://erkaman.github.io/posts/cuda_rle.htmlIn 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. For the purpose of
providing a supplementary document to her paper, I would now like
to go through how I implemented this technique in CUDA.
Making Faster Fragment Shaders by Using Tessellation Shaders
https://erkaman.github.io/posts/tess_opt.html
https://erkaman.github.io/posts/tess_opt.htmlIn 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. The
technique is that they are moving expensive operations from the
fragment shader into some earlier shader stage, and by doing so
they greatly reduce the number of times said operation has to be
evaluated. In this article, I shall in much detail describe this
technique.