Viewing Issue Advanced Details Jump to Notes ]
ID Category [?] Severity [?] Reproducibility Date Submitted Last Update
02751 Core Major Always 2008-12-19 21:22 2012-07-31 06:29
Tester mfeingol View Status Public Platform MAME (Official Binary)
Assigned To Resolution Open OS Windows XP/Vista 64-bit
Status [?] Acknowledged   Driver
Version 0.128 Fixed in Version Build 64-bit
Summary 02751: D3D full screen fails with 0x8876086C - Unable to create the Direct3D device
Description I have a new Vista x64 installation with updated Intel INF, nVidia video and RealTek audio drivers. On this system, Mame runs perfectly in windowed mode using D3D, but fails in full-screen mode.

For what it's worth, this system is connected via DVI to an LCD TV. I haven't tested this issue with a standard LCD monitor.

I'll also note that I have another Vista x64 installation on which full-screen mode works just fine (with the same version of the nVidia drivers). So I'm not sure what's special here - e.g. it doesn't seem to be a 64-bit only issue.
Steps To Reproduce The bug looks like this:
C:\Users\Public\Mame>vmame64 pacman -nowindow -verbose
Parsing mame.ini
Parsing mame.ini
Video: Monitor 0000000000010001 = "\\.\DISPLAY1" (primary)
Direct3D: Using Direct3D 9
Direct3D: Configuring adapter #0 = NVIDIA GeForce 7600 GT
Direct3D: Using dynamic textures
Direct3D: YUV format = RGB
Unable to create the Direct3D device (8876086C)
Unable to initialize Direct3D.
Unable to complete window creation

Contrast with...
C:\Users\Public\Mame>vmame64 pacman -verbose
Parsing mame.ini
Parsing mame.ini
Video: Monitor 0000000000010001 = "\\.\DISPLAY1" (primary)
Direct3D: Using Direct3D 9
Direct3D: Configuring adapter #0 = NVIDIA GeForce 7600 GT
DirectSound: Primary buffer: 44100 Hz, 16 bits, 2 channels
RawInput: APIs detected
Input: Adding Mouse #1: Microsoft PS/2 Port Mouse (IntelliPoint)
Input: Adding Gun #1: Microsoft PS/2 Port Mouse (IntelliPoint)
Input: Adding Mouse #2: HID-compliant mouse
Input: Adding Gun #2: HID-compliant mouse
Input: Adding Kbd #1: Standard PS/2 Keyboard
Input: Adding Kbd #2: Microsoft eHome Remote Control Keyboard keys
Input: Adding Kbd #3: Microsoft eHome MCIR Keyboard
Input: Adding Kbd #4: Microsoft eHome MCIR 109 Keyboard
DirectInput: Using DirectInput 7
Input: Changing default joystick map = s8.4s8.44s8.4445
  s8888888s
  4s88888s6
  44s888s66
  444555666
  444555666
  444555666
  44s222s66
  4s22222s6
  s2222222s
Input: Changing default joystick map = s8.4s8.44s8.4445
  s8888888s
  4s88888s6
  44s888s66
  444555666
  444555666
  444555666
  44s222s66
  4s22222s6
  s2222222s
Direct3D: Using dynamic textures
Direct3D: YUV format = RGB
Direct3D: Device created at 671x895
Direct3D: Max texture size = 4096x4096

... which works just fine.
Additional Information I'm happy to help with debugging this. Just let me know what information you'll need or send me debug binaries / PDBs / breakpoints / whatever.
Flags
Regression Version
Affected Sets / Systems
Attached Files
? file icon mame.ini (4,633 bytes)  2008-12-19 23:19 [Show Content]


-  Notes
User avatar (03337)
Robbbert (Developer)
2008-12-19 21:30

Make sure in your cmd options, that it is set as "Window" rather than "Full Screen". The game will still run fullscreen.

If I set it the cmd option to "Full Screen" I get the same error (XP, 32-bit), and the bug (if it is a bug) has been there for a long time.
User avatar (03339)
Tafoid (Administrator)
2008-12-19 22:14
edited on: 2009-05-17 19:39

Sounds suspiciously like the other inconsistent D3D bug which happens when changing Full Screen to Window for some users.
00574

User avatar (03340)
mfeingol (Tester)
2008-12-19 23:21

Robbbert: I've attached my ini\mame.ini file. I think my settings are okay. You can see in the repro steps what my cmd line looks like.

Tafoid: I saw that. Again, if this is intermittent/inconsistent, what I have here is a 100% repro. I'd be glad to help in getting to the bottom of this.
User avatar (03393)
aaron (Developer)
2008-12-25 01:46

The error code says "invalid call", so there is little information to go on. Try it with -window and -nowindow to see if it makes a difference. Also try it with -triplebuffer and -notriplebuffer. Beyond that, I have no other ideas.
User avatar (03398)
mfeingol (Tester)
2008-12-25 19:27

Aaron:

-window always works, regardless of the triplebuffer settings. -nowindow always fails with the same error, regardless of the triplebuffer settings.

If you have a 64-bit debug build, a pdb and a suggested breakpoint, I'd be happy to investigate further, send you a dump, etc.
User avatar (03401)
aaron (Developer)
2008-12-26 07:33

Does the 32-bit version work or fail with the exact same settings?
User avatar (03403)
Haze (Developer)
2008-12-26 11:15

I've seen similar happen on Vista with Aero turned on, where turning it off fixed the problem.

I've also seen it with other apps which attempt to use high resolutions (non-mame) if it doesn't 'like' the monitor (Secure display path or whatever it's called / DRM failure?) Can't remember what it was now, but it would simply fail to start with an 'unknown error' even if the monitor was perfectly capable of that resoltuion.
User avatar (03408)
mfeingol (Tester)
2008-12-26 19:17
edited on: 2008-12-26 19:17

I tried three things:

1) 32-bit vs. 64-bit makes no difference.

2) Changing resolutions makes no difference (I went down as far as 1024x768 on my 1080P TV).

3) When I turn off Aero, mamepp -nowindow suddenly starts working. So Haze is on the money here.

Any ideas on why Aero would make a difference to Mame's usage of D3D?

User avatar (03448)
Iaspis (Tester)
2008-12-31 19:09
edited on: 2008-12-31 19:12

Have you tried connecting another monitor to your system? I used to have a similar problem (bug #00574) when switching (Alt-Enter) between fullscreen and window and when I used another monitor the problem was gone.

User avatar (07155)
rwolfman3000 (Tester)
2011-01-29 09:47

Hi all...just want to enter into this discussion...

I'm getting the "D3D full screen fails with 0x8876086C - Unable to create the Direct3D device' error.

My System:

Windows 98 SE with the 'unofficial' service packs & updates from http://www.mdgx.com/upd98me.php#010711

..with an older gfx card: nvidia g-force fx 5500

the win98 updates contain a lot of hotfixes from micro$oft and perhaps therein lies the problem....will try and run a fresh install of win98 and see if Mame still throws up on me.
User avatar (08833)
RubberBekki (Tester)
2012-07-31 06:29

I've had problems with that "Unable to create the Direct3D device" error. And I'd get that with FCEUX fullscreen as well. I just chalk it up as a D3D corruption after having my desktop on all the time (it's set up running a background FTP daemon and P2P).

A reboot usually allows D3D to start clean on this XP-Pro SP3 system and I don't get the error again for a month or so. It's not a perfect fix but I'm willing to dump my sysinfo and dxdiag logs for further analysis on request.