Jump to content
  • Advertisement
Sign in to follow this  
Mike.Popoloski

Thread Problem

This topic is 4457 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 seem to be having a problem with multithreading that I just can't figure out. My program crashes when it hits IDirect3DDevice9::SetIndices. I know it is a problem with my threads because if I disable them, it works fine. Also, my new thread that I am spawning doesn't even do anything. I have tried both a blank thread and a thread that just contains Sleep( 0 ). I don't know why Direct3D is crashing, when I am not even touching it on the other thread. I am not settings the MULTITHREAD flag when creating the device, but I thought that was only if I would be using DirectX across multiple threads. What's the deal?

Share this post


Link to post
Share on other sites
Advertisement
I know you said that you haven't created the device with the MULTITHREAD flag but have you tried doing it. If it works then you know your problem does occur when a new thread is created.

It's the only suggestion that I can give you.

I hope this helps.
Take care.

Share this post


Link to post
Share on other sites
I have tried starting and then stopping the thread right in a row, and then continuing as normal. This works fine. However, if I leave the thread running, when I make the call to SetIndices, I get an exception at address 0x00000000, and the dissasembly is all question marks. This isn't the first call I make to DirectX though. Why is this happening?

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!