[vtkusers] Complementary color LUTs

Jothybasu Selvaraj jothybasu at gmail.com
Wed Apr 20 01:43:12 EDT 2016


Hi All

I am trying to overlay 2 registered images using complementary LUTs
(magenta & green), so that the images will appear white where they match
perfectly. However, I couldn't get the desired results. The image appears
magenta where they match.

Can anyone find any mistakes in this?

Below are the LUTs I use:

// Create a GREEN lookup table

    vtkSmartPointer<vtkLookupTable> table =

            vtkSmartPointer<vtkLookupTable>::New();

    table->SetHueRange(0.33333,0.33333);

    table->SetSaturationRange(1.0,1.0);

    table->SetValueRange(0.0,1.0);

    table->SetAlpha(0.5);

    table->SetRampToLinear();

    table->Build();


// Create a MAGENTA lookup table

    vtkSmartPointer<vtkLookupTable>table2 =

            vtkSmartPointer<vtkLookupTable>::New();

    table2 ->SetHueRange(0.8333,0.8333);

    table2 ->SetSaturationRange(1.0,1.0);

    table2 ->SetValueRange(0.0,1.0);

    table2 ->SetAlpha(0.5);

    table2 ->SetRampToLinear();

    table2 ->Build();


Any help is highly appreciated!



Cheers


Jothy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20160420/ad8a5228/attachment.html>


More information about the vtkusers mailing list