IDXLUTBuilder interface

This interface enables you to construct a lookup table for an input DXSurface. A lookup table is a set of four arrays of 256 numbers each, with one array for each color channel and one array for the alpha channel.

Members

The IDXLUTBuilder interface inherits from the IUnknown interface. IDXLUTBuilder also has these types of members:

Methods

The IDXLUTBuilder interface has these methods.

MethodDescription
GetBrightness

Retrieves the settings for the lookup table brightness curve.

GetBuildOrder

Retrieves the order of operations used to build the lookup table.

GetColorBalance

Retrieves the tint curves used for color balance operations on the selected color.

GetContrast

Retrieves the settings for the lookup table contrast curve.

GetGamma

Retrieves the value used for gamma correction.

GetInvert

Retrieves the threshold value used for color inversion.

GetLevelsPerChannel

Retrieves the number of color levels to use for the posterizing operation.

GetNumBuildSteps

Retrieves the number of lookup table operations to perform.

GetOpacity

Retrieves the opacity adjustment for the lookup table.

GetThreshold

Retrieves the value used for threshold filtering operations.

SetBrightness

Sets the values for the lookup table brightness curve.

SetBuildOrder

Sets the order of operations used to build the lookup table.

SetColorBalance

Sets the tint curves for color balance operations on the selected color.

SetContrast

Sets the values for the lookup table contrast curve.

SetGamma

Sets the value used for gamma correction.

SetInvert

Sets the threshold value for color inversion.

SetLevelsPerChannel

Sets the number of color levels to use for the posterizing operation.

SetOpacity

Sets the opacity adjustment for the lookup table.

SetThreshold

Sets the value for threshold filtering operations.

 

Remarks

Each color channel of each sample in an image is modified by a lookup table with the following code:


pBuffer[i].Color   = pColorLookupTable[pBuffer[i].Color];

In effect, this color value is used as an index to the modified color value stored in the lookup table array.

There are a number of standard color corrections that you can perform with Microsoft DirectX Transform lookup tables. These corrections are listed in the OPIDDXLUTBUILDER enumeration. You can also specify any number of color corrections in any order.

To use this interface, call the Component Object Model (COM)CoCreateInstance method as shown in the following code example.


   IDXLUTBuilder*  g_pLUTBuilder;
   hr = CoCreateInstance( CLSID_DXLUTBuilder, NULL, CLSCTX_INPROC,
                             IID_IDXLUTBuilder, (void **)&g_pLUTBuilder );
	...							 
						 
   IDXLookupTable* g_pLUT;
   hr = g_pLUTBuilder->QueryInterface( IID_IDXLookupTable,
                                          (void **)&g_pLUT );


When you implement this interface, the call to the QueryInterface method should return an IDXLookupTable pointer. Use this pointer as a parameter to the IDXSurfaceModifier::SetLookup method to connect your lookup table to the DXSurfaceModifier object.

Requirements

Minimum supported client

Windows XP

Minimum supported server

Windows 2000 Server

Header

Dxtmsft.h

IDL

Dxtmsft.idl

DLL

Dxtrans.dll

 

 

Show: