Reading list on Z-buffer precision

Nathan Reed recently published a blog article plotting his numerical findings of Z-buffer precision under different uses. On the way he references a couple of previous articles, that also reference other resources; I think it’s a good opportunity to list some of them. They all tell a part of the story and I recommend reading all of them to get the complete picture.

Unreal Engine experimental scene videos

Since the beginning of 2014, there has been a lot of videos demonstrating the realism that can now be achieved with Unreal Engine 4.

Often, these videos showcase a static scene or even concentrate on a single detail: lighting in an architectural structure, the look of rain hitting the ground, or some wet pebble on the beach.

Physically based rendering, global illumination and screen space reflections seem to manage to trick the brain an get it confused between what is real and what isn’t. Even when some artifacts get salient, like reflections popping in and out or changing with camera orientation, we are quick to forget them and find the image very believable.

Here are some of these videos, by Alexander Dracott, Koola, and Benoît Dereau.

Unreal 4 Lighting Study: Forest Day from Alexander Dracott on Vimeo.

Readings on the roles of senior programmer and lead programmer

Here are some of the best articles I have read on the topic. They surely will help you understand what people expect from you and what you should expect from yourself as you become a lead:

Fresnel and the Poisson spot

The casting of the following story is remarkable. The year is 1818. On one side, Augustin Fresnel (1788 – 1827) has just handed to the French Academy of Sciences (Académie des Sciences) an essay defending a theory completely opposed to the widely accepted one; on the other side, François Arago (1786 – 1853), Jean-Baptiste Biot (1774 – 1862), Louis Joseph Gay-Lussac (1778 – 1850), Pierre-Simon Laplace (1749 – 1827) and Siméon Denis Poisson (1781 – 1840) are the panel in charge of assessing it. These are all major theorem names. Men who built Science, the giants whose shoulders we stand upon. But the context is peculiar: the scientists are here to fight, as the battle is raging between partisans of the particle theory and partisans of the wave theory.

Augustin Fresnel

It all starts three years earlier, in July of 1815, when Fresnel (then 27) meets the person who would later become his mentor, Arago. The political background is rough: the Hundred Days have ended just a month before with the defeat of Napoleon at the battle of Waterloo, and Fresnel, a royalist, is under police scrutiny and has been dismissed from his title as a state engineer. The scientific background is the status quo: Isaac Newton’s corpuscular theory of light is prevailing and unshakeable.

Pushed forward by Arago who sees great potential in him, Fresnel performs rudimentary experiments with light diffraction at his mother’s home, in a town north of Caen. There, with gear made by a local worker and consisting of wires and drops of honey serving as lenses, he observes and measures hyperbolic fringed patterns that cannot be explained by the particle theory (which should lead to linear patterns). He thus builds upon the wave theory by Hyugens and on October 26th, sends to the French Academy of Sciences a first paper reporting his observations. He will later send more of these papers, prompting strong reactions from the community, especially Laplace.

The competition organized by the Academy and aimed at rewarding the best work on a given topic is seen as the perfect opportunity to put an end to the battle. Proposed on the 17th of March 1817, and ending on the 1st of August of the next year, it focuses on diffraction phenomenons, and while rigorous, it seems to have been written by a supporter of the corpuscular theory. Opponents to the wave theory are hoping to see someone present a work that will put a stop to it.

Arago, originally convinced by the particle theory, sees Fresnel as the one who can best defend the wave theory. He helps him any way he can, and in particular helps him move to Paris to enter the competition. Even André-Marie Ampère (1775 – 1836), although a openly partisan of Newton’s theory (possibly for political reason related to the Academy), gives him full support. Both push him to publish his new results. The three will become close friends in the process.

Finally this essay handed at the last minute (29th of July 1818) is the only one selected out of two submitted. Natura simplex et fecunda is much more thorough than the previous works, and it is nowadays described as a masterpiece. Going beyond the work of Thomas Young (1773 – 1829), the author proposes a model that predicts with precision the position and size of the fringes, and presents the experiment now known as Fresnel double mirror.

Among the jury, Biot, Laplace and Poisson are the most resolutely opposed to wave theory. Poisson in particular, fascinated by Fresnel’s theory, studies it in detail, looking for weaknesses. From it he derives a counter intuitive result beyond Fresnel’s own predictions: by placing a disc at a certain distance between a source of light and a screen, a bright spot should appear in the center of the disc’s shadow. To Poisson, this apparently absurd consequence is a proof that invalidates Fresnel’s work.

But Arago decides to proceed and perform the experiment. To everyone’s surprise, the spot predicted by Poisson is indeed observed. The anecdote, recorded by Arago, would be the strawberry on the shortcake to Fresnel’s success that day. Ironically, although it still didn’t convince Poisson, the experiment is since then often referred to as the Poisson spot.


Some references:

Augustin Fresnel’s essay used to be available on the website of the Académie des Sciences, but the link seems to be broken recently.

“Mémoire sur la diffraction de la lumière” on the website of the French Academy of Science (fr, PDF)

André Marie Ampère et Augustin Fresnel (fr)

Final word:

Before opening this space specifically dedicated to light and rendering, I was posting from time to (increasingly distant) time on another blog in French. One post that attracted attention was the story of Augustin Fresnel defending his thesis in front of the Académie des Sciences. Given the impact his ground breaking work has on rendering, I thought it made sense to translate it and post it here.

I have tried my best to bring the pieces together from different sources, but some of them were disagreeing on some details, and unfortunately I haven’t noted all the references so it is possible some part isn’t 100% faithful to the events. Please leave a comment if you have some material on the topic.

Reverse engineering the rendering of a frame in Deus Ex: Human Revolution

Earlier this year, Adrian Courrèges wrote an article detailing his findings while reverse engineering the rendering pipeline in Deus Ex: Human Revolution.

Starting from a given frame, he illustrates the different stages in the rendering: creation of the G buffer, shadow map, ambient occlusion, light prepass, how opaque and transparent objects are treated differently, volumetric lights, bloom effect in LDR, anti-aliasing and color correction, the depth of field, and finally the object interaction visual feedback.

Here are a few screenshots stolen from his article:

Normal map

The light pre-pass

Final image

Adrian since then posted a new article, this time breaking down the rendering of a frame in Supreme Commander. The comments also include insights from the programmer then in charge of the rendering, Jon Mavor.

A real-time post-processing crash course

Revision 2015 took place last month, on the Easter weekend as usual. I was lucky enough to attend and experience the great competitions that took place this year; I can’t recommend you enough to check all the good stuff that came out of it.

Like the previous times I shared some insights in a seminar, as an opportunity to practice public talking. Since our post-processing have quite improved with our last demo (Ctrl-Alt-Test : G – Level One), the topic was the implementation of a few post-processing effects in a real-time renderer: glow, lens flare, light streak, motion blur…

Having been fairly busy over the last months though, with work and the organising of Tokyo Demo Fest among others, I couldn’t afford as much time as I wanted to spend on the presentation unfortunately. An hour before the presentation I was still working on the slides, but all in all it went better than expected. I also experimented with doing a live demonstration, hopefully more engaging than some screenshots or even a video capture can be.

Here is the video recording made by the team at Revision (kudos to you guys for the fantastic work this year). I will provide the slides later on, after I properly finish the credits and references part.

Over decades photographers, then filmmakers, have learned to take advantage of optical phenomenons, and perfected the recipe of chemicals used in films, to affect the visual appeal of their images. Transposed to rendering, those lessons can make your image more pleasant to the eye, change its realism, affect its mood, or make it easier to read. In this course we will present different effects that can be implemented in a real-time rendering pipeline, the theory behind them, the implementation details in practice, and how they could fit in your workflow.