Updated Direct2D in March DirectX SDK
The March DirectX SDK includes an updated build of Direct2D. Note that this build of Direct2D runs on both Windows 7 and Windows Vista.
https://msdn.microsoft.com/directx
After the Windows 7 Beta release, we received some customer feedback, and made a few minor Direct2D API changes. These changes are present in the March DirectX SDK, but the documentation will not be ready until the Windows 7 RC release. In the interest of getting prelease code into the hands of customers faster, here is a list of breaking changes...
· Refactored some values of D2D1_RENDER_TARGET_USAGE into D2D1_RENDER_TARGET_TYPE for better clarity.
· Added D2D1_FEATURE_LEVEL structure variable to D2D1_RENDER_TARGET_PROPERTIES. Allows the caller to specify a minimum hardware feature level (9, 10, etc) to use.
· Added D2D1_OPACITY_MASK_CONTENT parameter to ID2D1RenderTarget::FillOpacityMask. This tells us what gamma to use.
· Removed D2D1_GAMMA parameter from ID2D1RenderTarget::FillOpacityMask. Based on customer feedback, we determined that this parameter was difficult to understand, and the same information could be gleaned by adding a D2D1_OPACITY_MASK_CONTENT parameter.
I've also attached updated Direct2D samples for use with the March DX SDK. You should be able to simply recompile these samples when the Windows 7 RC SDK is released.
If you're using Visual Studio, install the March DX SDK, and make sure that VS's VC++ directories include the following (for example, x86) ...
Tools | Options | Projects and Solutions | VC++ Directories
Executable Files="c:\Program Files (x86)\Microsoft DirectX SDK (March 2009)\Utilities\Bin\x86"
Include Files="c:\Program Files (x86)\Microsoft DirectX SDK (March 2009)\Include"
Library Files="c:\Program Files (x86)\Microsoft DirectX SDK (March 2009)\Lib\x86"
Link with ...
Project | Properties | Configuration Properties | Linker | Input | Additional Dependencies ...
d2d1_beta.lib dwrite_beta.lib D3D10_1_beta.lib dxgi_beta.lib windowscodecs.lib etc...