Jump to content
  • Advertisement
Sign in to follow this  
_Flecko

AccessViolationException

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

I'm having some trouble getting my Managed DirectX game to run on lower quality graphics cards (it's fairly basic 2D using orthographic projection, so it ought to be able to). The problem is that at times when I'm loading and unloading resources, an AccessViolationException is thrown from within Direct3D, usually inside VertexBuffer.Dispose() - the root of the call stack is presumably the garbage collector. It's unpredictable exactly when it will happen, but it's bound to if you play a few levels. Problem is, that's all the info I have, and I don't know how to approach this to get more info to figure out what went wrong. Last time this happened, it turned out after days of searching that I was using 16 bit indices in my index buffers, which a lot of video cards don't support, but I basically found that through guess and check. If anyone has any leads on this for me - what kind of mistakes commonly cause this type of exception, what it actually means, debugging techniques I might try - I would appreciate it very much.

Share this post


Link to post
Share on other sites
Advertisement
If you've got the DirectX SDK installed on the machines with the low quality cards, have you tried turning on the Direct3D Debug Runtime and watching the messages that it puts out? There's information on how to do this in the Forum FAQ; there might be something useful in it all, for example using an unsupported index buffer format should have shown up immediately.

Share this post


Link to post
Share on other sites
Ok, now I feel dumb for not knowing about this :) I always thought you needed to be able to do unmanaged debugging or something that I couldn't because I only have Visual C# to get this working right...I'm pretty sure I can't get all the same debugging info as everyone else, but just switching to debug mode makes DX actually speak up when I'm doing something wrong instead of just letting it slip until memory gets corrupted. Thanks :)

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

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

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!