From: Steinar H. Gunderson Date: Wed, 8 Jan 2014 21:14:42 +0000 (+0100) Subject: Implement GammaExpansionEffect using ALU ops instead of texture lookups. X-Git-Tag: 1.0~95 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;ds=inline;h=9a00101dbb6f98d21c6b8ce4d33200af840ea908;hp=9a00101dbb6f98d21c6b8ce4d33200af840ea908;p=movit Implement GammaExpansionEffect using ALU ops instead of texture lookups. In a standalone benchmark (on a Sandy Bridge laptop), this is pretty much a no-op performance-wise, but when more ops are put into the mix, it's a ~20% FPS win, and but in a more real situation with multiple inputs etc., it's subjectively also a pretty clear win. The reason is probably that we generally are way overloaded on texture operations. Note that we had similar code like this before (before we started using the texture for lookup), but it used pow(), which is markedly slower than our fourth-degree polynomial approximation. We should probably do the same for GammaCompressionEffect. ---