Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.



This topic is 6483 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

anyone successfully used this function to load a .bmp (or other picture file) onto a DX8 surface? I tried this chunk of code, but it fails with D3DERR_INVALIDCALL: HRESULT hr; LPDIRECT3DSURFACE8 pSurf = NULL; D3DXIMAGE_INFO d3dii; hr = D3DXLoadSurfaceFromFile(pSurf, NULL, NULL, fileName, NULL, D3DX_DEFAULT, 0, &d3dii); the variables are all good except I suspect I need to do something with pSurf first, because i get this error in the output window while debugging: D3DX: pDestSurface pointer is invalid I dug through the DX8 examples, but very few use D3DXLoadSurfaceFromFile, and how they allocate pSurf is difficult to pinpoint to say the least. Any ideas what i''m doing wrong?

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!