I am trying to use direct2d in directx11.1 with feature level 11, however i quickly run into problems, when creating a directx10.1 device you use D3D10CreateDevice1, however a similar function for directx11.1 doesn't seem to exist. I look at this example http://msdn.microsof...9(v=vs.85).aspx however they use ComPtr's, And I am not that familiar with using them,
ComPtr<ID3D11Device> device; ComPtr<ID3D11DeviceContext> context;uses the regular D3D11CreateDevice function, and then uses
DX::ThrowIfFailed( device.As(&m_d3dDevice) );where m_d3dDevice is a ID3D11Device1. Is that a regular typecast (in the ComPtr way)? If so is it safe to do use
m_d3dDevice= (ID3D11Device1*)(device);I do not use ComPtrs in my project, so in this example above both are "regular" pointers.