Επεξεργασία

Κοινή χρήση μέσω


Temperature and tint effect

The CLSID for this effect is CLSID_D2D1TemperatureTint.

Sample code

ComPtr<ID2D1Effect> temperatureTintEffect;
m_d2dContext->CreateEffect(CLSID_D2D1TemperatureTint, &temperatureTintEffect);
 
temperatureTintEffect->SetInput(0, bitmap);
temperatureTintEffect->SetValue(D2D1_TEMPERATUREANDTINT_PROP_TEMPERATURE, 0.5f);
temperatureTintEffect->SetValue(D2D1_TEMPERATUREANDTINT_PROP_TINT, 0.5f);
 
m_d2dContext->BeginDraw();
m_d2dContext->DrawImage(temperatureTintEffect.Get());
m_d2dContext->EndDraw();

Effect properties

The properties for the temperature and tint effect are defined by the D2D1_TEMPERATUREANDTINT_PROP enumeration.

Requirements

Requirement Value
Minimum supported client Windows 10 [desktop apps | Windows Store apps]
Minimum supported server Windows 10 [desktop apps | Windows Store apps]
Header d2d1effects_2.h
Library d2d1.lib, dxguid.lib