Sign in to follow this  
browny

DX call freezing my system

Recommended Posts

I have my system laid out like the following FrameBegin(); DrawEverything(); FrameEnd(); Inside FrameBegin() there color buffer and depth buffer are cleared out and mDevice->BeginScene() is called. Inside DrawEverything() a vertexbuffer is locked and filled with data and unlocked and finally rendered. But for some reason the lock freezes my system.... whereas a similar type of lock()/unlock() and rendering works find when i do it inside the FrameBegin() ( just for a test). I m wondering what possible things might cause Lock() to freeze the whole system.

Share this post


Link to post
Share on other sites
We need to see the part of the DrawEverything function where you lock and render, in order to effectively help you.

Most likely cause of the freeze is that you first lock the vertex buffer, then try drawing with it before unlocking it. The graphics card cannot use locked resources, and the situation would cause an internal access violation or a deadlock (both of which could in turn freeze the graphics driver).

In a rarer case, your graphics driver may have a bug where it prevents locking of a vertex buffer currently bound in the card's draw command queue and causes the hang of the graphics driver this way. This seldom happens with new drivers, but is possible (I've seen such bugs in action a few years ago).

Also, check that you use the locked pointers correctly to avoid CPU access violations.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this