How to solve "error LNK2001: unresolved external symbol _CLSID_D2D1Blend" when using Direct2d effects?

I am developing a Linux Runtime Component (Visual C ++) drawing to be used in a Windows Store App C # project.

Everything worked as expected until I started adding some effects capabilities to the lib.

When trying to create an effect like the one below:

    m_d2dContext->CreateEffect(CLSID_D2D1Blend, &m_blendEffect)

      

The following error is displayed:

    1>MyLibFile.obj : error LNK2001: unresolved external symbol _CLSID_D2D1Blend

      

I already have these pragma comments on mine pch.h

:

    #pragma comment(lib, "d3d11")
    #pragma comment(lib, "d2d1")

      

I suspect some definitions are missing, but I don't know what #pragma comment(lib, "d2d1")

has already been added in pch.h

.

I am running Windows 10 Technical Preview build 9860 and VS Express 2013 update 3 in a virtual machine - VM-Ware.

This is a sample project using effects and direct 2d: Direct2D-Image-Effects

+3


source to share


1 answer


As it is on MSDN - Blending Effect :Library - d2d1.lib, dxguid.lib

You are missing dxguid.lib



Alternatively, you can use a raw GUID: {81C5B77B-13F8-4CDD-AD20-C890547AC65D}

+4


source







All Articles