Jump to content
  • Advertisement

Archived

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

Teric

LPDIRECT3DDEVICE9->Reset() doing strange things.

This topic is 5402 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

quote:
Original post by Teric
Thanks for the info, Hyena. Just to be sure--what would those ''extra bits'' be? Directories? Leftover files? Registry Entries? I want to make sure I do this right.



Generally you just have to make sure the directory was properly cleaned up. Also check the Add/Remove Programs dialog to see if it still thinks any SDKs are installed. This can happen if you''ve previously installed over older versions.

Stay Casual,

Ken
Drunken Hyena

Share this post


Link to post
Share on other sites
Advertisement
quote:
Original post by Teric
I downloaded the DirectX control panel applet, and I can bring it up now, but...


Where do you get this from? i also don''t have the icon in my control panel, thanks.

Share this post


Link to post
Share on other sites
Follow Drunken Hyena''s instructions above--they worked perfectly for me. I don''t recommend downloading the directx control panel applet; it caused problems for me. Though, if you really want it, you can google for it (that''s what I did).

Hyena--BINGO. That did the trick. Now I can turn on full debugging info for D3D. I ran my program in debug mode, and performed the resolution change, then looked at the debug output. Here are the relevant output lines:

Direct3D9: (ERROR) :All user created stateblocks must be freed before Reset can succeed. Reset Fails.
Direct3D9: (ERROR) :Reset failed and Reset/TestCooperativeLevel/Release are the only legal APIs to be called subsequently

I haven''t created any user-defined state blocks. Any idea what this could mean? Does it mean I haven''t released all of my textures from video memory?

Thanks again! Now I feel like I''m getting somewhere.

Share this post


Link to post
Share on other sites
quote:
Original post by Teric
I haven''t created any user-defined state blocks. Any idea what this could mean? Does it mean I haven''t released all of my textures from video memory?



That probably is the case, i was trying to use reset in my game... and it wouldn''t work until i freed all my vertex buffers/index buffers/textures buffers/etc... bit of a pain, cause you have to re-create them all after the rest...

Share this post


Link to post
Share on other sites
Some D3DX interfaces create state blocks, so you have to call their OnLostDevice (something like that, don't have docs handy) so they free up their internal resources and then a similar function when the device has been reset. I believe both D3DXFont and D3DXSprite do this, others may as well.


Stay Casual,

Ken
Drunken Hyena

[edited by - DrunkenHyena on June 3, 2004 5:02:38 PM]

Share this post


Link to post
Share on other sites
That was it!!! I had a D3DXFont object that I hadn''t released. Once I released it, the reset worked perfectly.

Thank you so much, Hyena!

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.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!