I vaguely remember someone making a comment in a discussion about sRGB, that ran along the lines of
So then, is sRGB like µ-law encoding?
This comment was not about the color space itself but about the specific pixel formats nowadays branded as ‘sRGB’. In this case, the answer should be yes. And while the technical details are not exactly the same, that analogy with the µ-law very much nails it.
When you think of sRGB pixel formats as nothing but a special encoding, it becomes clear that using such a format does not make you automatically “very picky of color reproduction”. This assumption was used by hardware vendors to rationalize the decision to limit the support of sRGB pixel formats to 8-bit precision, because people “would never want” to have sRGB support for anything less. Not true!I’m going to make a case for this later. But first things first.
Spellforce 2 was released in 2006 and will be 8 years old by april. Nevertheless, the third add-on of the series shipped a month ago. Talk about a long seller!
Of course I’m attached to SF2 because I wrote many parts of its engine back then. This time I was briefly involved to help the developers include my attribute-less normal map algorithm. The original SF2 did not have any normal maps, and therefore none of the original art assets comes with tangent space information. This is an ideal scenario to pimp up the visuals without touching the geometry, simply by making a shader change and adding normal maps. Continue reading
Sometimes reality looks like if it was taken straight out of Half-Life.
I was kindly invited by Wolfgang from Confetti FX to speak at the FMX 2013 conference about physically based shading (within the scope of the Real Time Rendering day). Since I remembered the FMX as a conference for visual arts, I made the presentation intentionally non-technical, for fear of alienating the listeners. In retrospect, my guess was a bit too conservative, as there were quite a number of programmers in the audience.
Nevertheless, here are the slides for download (with all notes included). The Keynote format is the original and the Powerpoint format was exported from that and is a little broken, so you should use the Keynote version if you can read it.
FMX2013 (Keynote format) (1272)
FMX2013 (Powerpoint format) (2018)
This post is a follow-up to my 2006 ShaderX5 article  about normal mapping without a pre-computed tangent basis. In the time since then I have refined this technique with lessons learned in real life. For those unfamiliar with the topic, the motivation was to construct the tangent frame on the fly in the pixel shader, which ironically is the exact opposite of the motivation from :
Since it is not 1997 anymore, doing the tangent space on-the-fly has some potential benefits, such as reduced complexity of asset tools, per-vertex bandwidth and storage, attribute interpolators, transform work for skinned meshes and last but not least, the possibility to apply normal maps to any procedurally generated texture coordinates or non-linear deformations. Continue reading
I just got news that Velvet Assassin has been ported over to the Mac and is available on the App Store! (It is that game for which I wrote about half of the engine code and the shading model.) However, I was not at all involved in the Mac port and I don’t know the developers who did — it came as a surprise to me as to anyone else in the former team. Here is a direct iTunes link: http://itunes.apple.com/app/id586878367.
Shader Bug on ATI graphic cards
Unfortunately there is a shader bug with ATI graphics chips. It happened to me while trying it out on a 2011 iMac with an ATI Radeon HD 5670. I got reports from friends that this is not a problem of the Mac port itself but it happens on PC too. The problem is related to ATI chips with drivers that are newer than 2010 or so. Here is a screenshot:
Kurt has taken steps to revive FlipCode.
Flipcode was a place to discuss gamedev + algorithms with a unique flair and an outstanding audience, something IMHO gamedev.net never matched. I, too, was a regular visitor, poster, and also contributed the odd article and an IOTD. Terrain engines bordering on 100k polys without HW T&L will be forever in the past, but the spirit will live on.
A routine to convert a matrix to a quaternion was given by Ken Shoemake , and seems to have been accepted as a ‘fact of life’. The code is organized around a switch of four branches, depending on the sign of the diagonal matrix elements. Is it possible to do the conversion entirely without branches? No, not in general, if you must protect against any and all singularities. Is it possible, then, to expand the singularity-free domain of a branchless version so it covers a useful range? Well yes, that’s what this post is about. Continue reading
I just got the news about the OpenGL 4.3 spec, which was released today, and is available at http://www.opengl.org/registry/. The spec document has been reorganized and cleared up considerably and is a lot easier to follow than the previous specifications. New features include (ordered by importance for my projects):
- Queries for internal texture format parameters
- Debug output callbacks
- Compute shaders
- Texture views
- and others
I’m currently on a project where compatibility and scaleability is prime, so the first two features are very welcome as development aids to make the code run robustly on a variety of platforms. Compute shaders and texture views are of course cool, but require the newest hardware, so they are lower in my list.
A nice touch by Nvidia to make to expose the new functionality as extensions on older hardware.
Here are some philosophical and rendering-related questions that I took home from the last vacation. What’s the color of clouds? The standard answer would be, white.
What’s the color of snow? Again, white. Ok, then look at the following picture, where the snow seems considerably whiter. This is the case in almost all photos that I took.
There is an image on Wikipedia from the same general area on which the brightness difference between clouds vs snow is even more pronounced. If you look at the directly lit parts of the snow and consider it white (#ffffff), then the directly lit parts of the clouds are at most 50% grey (#bbbbbb). Is that an evidence of air pollution? Unlikely! (At least not in Tyrol).