Sign in to follow this  
DroxXodia

CreateDirect3D9 fails when no users are logged in...

Recommended Posts

Title says it all. I have a very strange situation. I need Direct3D applications to run on a Vista PC when no users are logged in, or when the PC is sitting at the Switch User screen is up etc... However CreateDirect3D9 returns NULL and the Device ID returned is 0. so it fails. My hunch is that d3d thinks there are no active adapters at that time, so it can't find them. I know this is a very strange problem. Anyone have any ideas? I'd greatly appreciate it.

Share this post


Link to post
Share on other sites
You could try using D3DDEVTYPE_NULLREF in your CreateDevice call. This will effectively prevent you from doing any actual D3D rendering or useful work, but it will give you a valid device object.

You are correct that when the secure desktop (login screen) is displayed, no adapters are available for display duties. What are you trying to achieve?

Share this post


Link to post
Share on other sites
Thanks for the tip. I'll try it out later when I log into my PC.

I am automating 3D applications and I need them to run on a dedicated machine that no one is logged into.

// EDIT
Do you think there is a way to turn the adapters on via some command or registry key?

Anyways thanks for the tip.

Share this post


Link to post
Share on other sites
Quote:
Original post by DroxXodia
// EDIT
Do you think there is a way to turn the adapters on via some command or registry key?

Anyways thanks for the tip.
This was discussed about a month or so ago here, and the conclusion was that it's not possible due to the way Windows works.

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