marti.ma...@littlecms.com wrote:
> Quoting Richard Hughes <hughsi...@gmail.com>:
> 
>> I'm playing around with using a ClutterShader to do full screen color
>> management using GLSL on the GPU. I'm aiming to integrate the
>> functionality into future versions of mutter for GNOME 3.
> 
> Hi, if you can implement tetrahedral interpolation as a shader, you can
> make color transforms to fly. The basis are not too complex, you need
> to create a color transform from/to RGB first, Then by using
> cmsSliceSpaceFloat(), build a 3D lookup table by evaluating your tranform
> on each node. Then upload this table plus the image to convert into
> GPU memory. 3D table of 17 points is enough for all but hardly non-linear
> color spaces. 33 points should be enough for everything. As long as the
> color transform is same (sRGB to monitor, for example) you can reuse
> same table. Color transform may involve any intent and many profiles,
> softproofing for example.
> 
> Don't waste time implementing prelinearizations or weird things,
> give first a try to this simple 17-points table. If tetrahedral
> is hard to implement for you due to tetrahedra subdivision, use
> triliner instead.

on a GPU these things are trivial shaders... you do the
prelinearization as a tex1d using in the RGB tripple, followed by a
texture dependant lookup into the 3D texture, this will be done as a
tri-linear interpolation, and should manage a few GB/s on fast
hardware :-)

The post production world  do such things on 2K and 4K data (in stereo
sometimes) at 24+FPS, on modern graphics hardware the problem is not
the shading/texture rate but getting the data to the GPU fast enough.

The OpenEXR source code contains an example playback tool with
programmable shaders to do this kind of thing. It uses half floats
which are usually enough for most display purposes.

Kevin

-- 
| Kevin Wheatley, Cinesite (Europe) Ltd | Nobody thinks this      |
| Senior Technology                     | My employer for certain |
| And Network Systems Architect         | Not even myself         |

Cinesite (Europe) Ltd. Registered Office: HemelOne, Boundary Way, Hemel 
Hempstead, Herts, HP2 7YU Registered in Cardiff No. 2820389 VAT No. 630 5446 60

------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
Lcms-user mailing list
Lcms-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lcms-user

Reply via email to