Hi Guys,
This is probably a stupid one that is staring me in the face.
But, I am failing to create a texture from file
IDirect3DTexture9 *pTexture=NULL;
HRESULT error=D3DXCreateTextureFromFile(d3ddev,"sprite.png",&pTexture);
d3ddev is valid at this point because I can remove the above calls and the scene renders fine.
I have tried the sprite.png file in the same location of the exe file and even hard coded the file to be called from D:\sprite.png.
But, each time HRESULT returns D3DERR_INVALIDCALL
Any help on this would be absolutely awesome :)