Projective Geometric Algebra Done Right

In the last chapter of FGED1, I provided a practical introduction to projective Grassmann algebra. Most people working in computer graphics are familiar with four-dimensional homogeneous coordinates, and projective Grassmann algebra extends this concept to a larger algebraic structure under which the wedge and antiwedge products perform geometric manipulations of points, lines, and planes. FGED1 […]

RGB/XYZ Conversion Matrix Accuracy

The second volume of the Foundations of Game Engine Development series (FGED2) contains a derivation of the 3×3 matrices that transform between the standard RGB color space and the CIE XYZ color space. The resulting matrix entries that I published are a little different from the numbers published in both Real-Time Rendering, 3rd edition (RTR3) […]

Dynamic Glyph Dilation

Slug renders glyphs on the GPU directly from the Bézier curves that define them. No matter how complex a glyph is, only a bounding box consisting of two triangles (or a tighter bounding polygon with up to eight vertices and six triangles) is rendered by the GPU, and the pixel shader figures out how much […]

A Mathematical Keyboard Layout

I’ve often found myself typing basic mathematical symbols into Twitter comments, such as subscripts, exponents, infinity, the dot product, the cross product, and especially the minus sign, because I can’t stand using a hyphen to mean negative or subtract. I had enabled hex Unicode input on the numeric keypad, which requires a registry change, and […]

Some Thoughts about Rvalue References in C++

C++ has always had these things called lvalues and rvalues that refer to expressions that can typically appear on the left or right side of an assignment. In C++11, rvalues were divided into two groups called xvalues (“expiring” rvalues) and prvalues (“pure” rvalues) so that the mess now known as rvalue references could be implemented […]

Some Thoughts about Aliasing in C++

The C++ standard explicitly states when pointers can alias at the end of Section 3.10. It does not allow simple things like this: float f;…int i = *reinterpret_cast<int *>(&f); Pointers to int and float are not related in a way that supports aliasing, and this is technically undefined behavior. At the end of Section 5.2.10, […]

Thoughts About the ZP+ Alorithm

A couple of months ago, a paper entitled ZP+: Correct Z-pass Stencil Shadows came across my inbox. I gave it a cursory scan, but nothing earth-shattering jumped out at me, so I didn’t give it much more thought. Recently, the paper has been brought to my attention several more times, so I decided to take […]