Ego mecum conjungi …

… Twit­ter!

Twitter_logo_blue

So out of a whim I just embar­rassed myself and tried to write in (prob­a­bly wrong) latin that I joined twit­ter. You can fol­low me under: @aries_code.

If you won­der how this came about, this was my train of thought:

  • Twit­ter has some­thing to do with birds
  • Birds have fan­cy latin species names
  • The species name for Spar­row is Spass­er domes­ti­cus
  • This doesn’t sound too fan­cy ...
  • How do you say ‘I joined twit­ter’ in latin any­way?

But then I dis­cov­ered that I am onto some­thing: Accord­ing to one argu­ment, the brand name of Twit­ter should have been ‘Titi­a­tio’, had it exist­ed in antiq­ui­ty. And accord­ing to anoth­er argu­ment, latin should be an ide­al twit­ter lan­guage, because it is both short and expres­sive.

But I digress. If you are into com­put­er graph­ics, then you know of Johann Hein­rich Lam­bert, the eponym of our beloved Lam­bert­ian ref­electance law. The book where he estab­lished this law, Pho­tome­tria, is writ­ten entire­ly in latin—now this is hard­core!

So, now you know what to do if you want to stand out in your next SIGGRAPH paper …

Yes, sRGB is like µ-law encoding

I vague­ly remem­ber some­one mak­ing a com­ment in a dis­cus­sion about sRGB, that ran along the lines of

So then, is sRGB like µ-law encod­ing?

This com­ment was not about the col­or space itself but about the spe­cif­ic pix­el for­mats nowa­days brand­ed as ‘sRGB’. In this case, the answer should be yes. And while the tech­ni­cal details are not exact­ly the same, that anal­o­gy with the µ-law very much nails it.

When you think of sRGB pix­el for­mats as noth­ing but a spe­cial encod­ing, it becomes clear that using such a for­mat does not make you auto­mat­i­cal­ly “very picky of col­or repro­duc­tion”. This assump­tion was used by hard­ware ven­dors to ratio­nal­ize the deci­sion to lim­it the sup­port of sRGB pix­el for­mats to 8-bit pre­ci­sion, because peo­ple “would nev­er want” to have sRGB sup­port for any­thing less. Not true!Screen Shot 2014-03-06 at 19.02.54I’m going to make a case for this lat­er. But first things first.

Con­tin­ue read­ing

Spellforce 2 Demons of the Past

Spell­force 2 was released in 2006 and will be 8 years old by april. Nev­er­the­less, the third add-on of the series shipped a month ago. Talk about a long sell­er!

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 devel­op­ers include my attribute-less nor­mal map algo­rithm. The orig­i­nal SF2 did not have any nor­mal maps, and there­fore none of the orig­i­nal art assets comes with tan­gent space infor­ma­tion. This is an ide­al sce­nario to pimp up the visu­als with­out touch­ing the geom­e­try, sim­ply by mak­ing a shad­er change and adding nor­mal maps. Con­tin­ue read­ing

Slides of my FMX 2013 presentation on Physically Based Shading

I was kind­ly invit­ed by Wolf­gang from Con­fet­ti FX to speak at the FMX 2013 con­fer­ence about phys­i­cal­ly based shad­ing (with­in the scope of the Real Time Ren­der­ing day). Since I remem­bered the FMX as a con­fer­ence for visu­al arts, I made the pre­sen­ta­tion inten­tion­al­ly non-tech­ni­cal, for fear of alien­at­ing the lis­ten­ers. In ret­ro­spect, my guess was a bit too con­ser­v­a­tive, as there were quite a num­ber of pro­gram­mers in the audi­ence.

Screen Shot 2013-04-24 at 14.53.58

Nev­er­the­less, here are the slides for down­load (with all notes includ­ed). The Keynote for­mat is the orig­i­nal and the Pow­er­point for­mat was export­ed from that and is a lit­tle bro­ken, so you should use the Keynote ver­sion if you can read it.

Down­load “FMX 2013 Slides (Keynote for­mat)” fmx-11.zip – Down­loaded 2249 times – 8 MB


Down­load “FMX 2013 Slides (Pow­er­point for­mat)” fmx-111.zip – Down­loaded 3664 times – 8 MB

Followup: Normal Mapping Without Precomputed Tangents

This post is a fol­low-up to my 2006 ShaderX5 arti­cle [4] about nor­mal map­ping with­out a pre-com­put­ed tan­gent basis. In the time since then I have refined this tech­nique with lessons learned in real life. For those unfa­mil­iar with the top­ic, the moti­va­tion was to con­struct the tan­gent frame on the fly in the pix­el shad­er, which iron­i­cal­ly is the exact oppo­site of the moti­va­tion from [2]:

Since it is not 1997 any­more, doing the tan­gent space on-the-fly has some poten­tial ben­e­fits, such as reduced com­plex­i­ty of asset tools, per-ver­tex band­width and stor­age, attribute inter­po­la­tors, trans­form work for skinned mesh­es and last but not least, the pos­si­bil­i­ty to apply nor­mal maps to any pro­ce­du­ral­ly gen­er­at­ed tex­ture coor­di­nates or non-lin­ear defor­ma­tions. Con­tin­ue read­ing

Velvet Assassin on Mac (Patch)

I just got news that Vel­vet Assas­sin has been port­ed over to the Mac and is avail­able on the App Store! How­ev­er, I was not at all involved in the Mac port and I don’t know the devel­op­ers who did—it came as a sur­prise to me as to any­one else in the for­mer team. Here is a direct iTunes link: http://itunes.apple.com/app/id586878367.

Shader Bug on ATI graphic cards

Unfor­tu­nate­ly there is a shad­er bug with ATI graph­ics chips.  It hap­pened to me while try­ing it out on a 2011 iMac with an ATI Radeon HD 5670. I got reports from friends that this is not a prob­lem of the Mac port itself but it hap­pens on PC too. The prob­lem is relat­ed to ATI chips with dri­vers that are new­er than 2010 or so. Here is a screen­shot:

Screen shot 2013-01-11 at 04.09.06

Con­tin­ue read­ing

FlipCode is back

Kurt has tak­en steps to revive Flip­Code.

Flip­code was a place to dis­cuss gamedev + algo­rithms with a unique flair and an out­stand­ing audi­ence, some­thing IMHO gamedev.net nev­er matched. I, too, was a reg­u­lar vis­i­tor, poster, and also con­tributed the odd arti­cle and an IOTD. Ter­rain engines bor­der­ing on 100k polys with­out HW T&< will be for­ev­er in the past, but the spir­it will live on.

Branchless Matrix to Quaternion Conversion

(EDIT: This arti­cle is a more in-depth write­up of an algo­rithm that I devel­oped around 2005, and first post­ed to Mar­tin Baker’s Euclid­ean Space web­site. That time was the height of the Intel Net­Burst archi­tec­ture, which was noto­ri­ous for its deep pipeline and high branch mis­pre­dic­tion penal­ty. Hence the moti­va­tion to devel­op a branch-free matrix to quater­nion con­ver­sion rou­tine. What fol­lows is the com­plete deriva­tion and analy­sis of this idea.)

The orig­i­nal rou­tine to con­vert a matrix to a quater­nion was giv­en by Ken Shoe­make [1] and is very branchy, as is tests for 4 dif­fer­ent cas­es. There is a way to elim­i­nate these branch­es and arrive at a com­plete­ly branch-free code and high­ly par­al­leliz­able code. The trade off is the intro­duc­tion of 3 addi­tion­al square roots. Jump the analy­sis sec­tion and the end of this arti­cle, or con­tin­ue fist with the math bits.

Con­tin­ue read­ing

OpenGL 4.3

I just got the news about the OpenGL 4.3 spec, which was released today, and is avail­able at http://www.opengl.org/registry/. The spec doc­u­ment has been reor­ga­nized and cleared up con­sid­er­ably and is a lot eas­i­er to fol­low than the pre­vi­ous spec­i­fi­ca­tions. New fea­tures include (ordered by impor­tance for my projects):

  • Queries for inter­nal tex­ture for­mat para­me­ters
  • Debug out­put call­backs
  • Com­pute shaders
  • Tex­ture views
  • and oth­ers

I’m cur­rent­ly on a project where com­pat­i­bil­i­ty and scaleabil­i­ty is prime, so the first two fea­tures are very wel­come as devel­op­ment aids to make the code run robust­ly on a vari­ety of plat­forms. Com­pute shaders and tex­ture views are of course cool, but require the newest hard­ware, so they are low­er in my list.

A nice touch by Nvidia to make to expose the new func­tion­al­i­ty as exten­sions on old­er hard­ware.