In XNA 3.1 is there any other way to disable depth in 3D Worlds using DirectX models other than

GraphicsDevice.RenderState.DepthBufferEnable = false;

?

The reason for my question is I have quite a huge program which offers a 3D World with a couple of 3D DirectX models inside. Depth was never an issue since it ever worked fine but since a few days after doing some modifications my models are all depth-translucent i.e. depth-buffering and/or culling seems to be disabled.

But in my whole source code I never touch any of the options related to Depth or Culling which means I never turn these settings on explicitly nor turn it off somewhere.

So I am searching for some other statement maybe related to the GraphicsDevice that implicitly turns depth off - but I can't find it.

(Sorry that I don't post any source code but I have too much source code and I simply don't know where to search)

However, there are cases where render states can change automatically.
A common example is the rendering of sprites and 3D objects on the
same graphics device. In this case, the SpriteBatch object changes
various render states when you call End. If you try any 3D rendering
after this step, the results can be unpredictable.

For this reason, you should restore several key render states to their
former settings before you try to render any 3D objects. The following
code demonstrates this approach.

If Begin is called with SaveStateMode set to None, then these states
must be reset by the caller if they are used elsewhere. Calling Begin
with SaveStateMode set to SaveState will reset these values properly,
but may adversely affect performance.

I removed every single call to the Spritebatch.Begin() method (of which I had many) BUT unfortunately nothing has changed: I still have no depth in my model.
–
marc wellmanOct 31 '12 at 22:41

Please see my answer below. Nevertheless i marked your answer as correct because it gave some valuable insight into these things that helped me lot. Thank you for that!
–
marc wellmanOct 31 '12 at 23:42

Just going by your screenshots it looks definitely like a culling issue. Are you usuing primitive to draw the boxes. Did you by any chance change the order in your vertex lists?
–
KenNov 1 '12 at 8:41

The boxes are DirectX models which are drawn in the very standard way as it should be done in XNA (loading Model from Content; iteration over all modelMeshes; iteration over all effects per mesh; setting worldCoordinates, projection and view; and drawing each mesh) ... Nevertheless I did find the faulty statement which was the cause for my trouble -> see my answer below. And again thank you for your comment - you did help me a lot !
–
marc wellmanNov 1 '12 at 9:49

Are you using a SpriteBatch to render your overlay in the second image? If so, SpriteBatch in 3.1 sets render states when drawing (including disabling the depth buffer) that you need to restore before drawing in 3D. See this article for the exact states changed.