Hey so I want to draw text using dx11, so I got the suggestion to use the spriteFont library for that. I followed the Tutorial on GitHub but I get an unresolved external error now which shouldn't happen?:
Reference to unresolved external symbol ""public: __cdecl DirectX::SpriteBatch::SpriteBatch(struct ID3D11DeviceContext *)" (?? 0SpriteBatch@DirectX@@QEAA@PEAUID3D11DeviceContext@@Z)" in function ""class std::unique_ptr<class DirectX::SpriteBatch,struct std::default_delete<class DirectX: :SpriteBatch> > __cdecl std::make_unique<class DirectX::SpriteBatch,struct ID3D11DeviceContext * &,0>(struct ID3D11DeviceContext * &)" (? ?$make_unique@VSpriteBatch@DirectX@@AEAPEAUID3D11DeviceContext@@$0A@@std@@YA?AV?$unique_ptr@VSpriteBatch@DirectX@@U?$default_delete@VSpriteBatch@DirectX@@@std@@0@AEAPEAUID3D11DeviceContext@@Z)".
Code looks like this:
void rD3D11::test()
{
std::unique_ptr<DirectX::SpriteBatch> spriteBatch;
spriteBatch = std::make_unique<DirectX::SpriteBatch>(pContext);
}
If I uncomment the "spriteBatch = .." line the error disappears.
The code is very simple and I don't know what is wrong with it as this shouldn't trigger an unresolved external error? What code do I have to add / change in order to solve this error?