cancel
Showing results for 
Search instead for 
Did you mean: 

Editor ok, Build crash

jakeslack27
Honored Guest
Hi,

I have a project setup with the following:

- DX9
- Forward rendering
- Linear colour space
- TImeWrap On
- Playing in extended mode

Playing in the editor is absolutely fine and the build was working with this setup previously but now I get a crash as soon as the game starts. I have tried numerous times.

The stack trace is as follows:

========== OUTPUTING STACK TRACE ==================

(0x687318A0) (OculusPlugin): (filename not available): (function-name not available) + 0x0
(0x687316AD) (OculusPlugin): (filename not available): (function-name not available) + 0x0
(0x68732A4D) (OculusPlugin): (filename not available): UnityRenderEvent + 0x4d
(0x00E4FDE7) (PE_Demo): (filename not available): Behaviour::Transfer<StreamedBinaryWrite<0> > + 0x93587
(0x00DCDEFC) (PE_Demo): (filename not available): Behaviour::Transfer<StreamedBinaryWrite<0> > + 0x1169c
(0x0110731B) (PE_Demo): (filename not available): AnimationEvent::Transfer<StreamedBinaryRead<1> > + 0xf10cb
(0x01109DD2) (PE_Demo): (filename not available): AnimationEvent::Transfer<StreamedBinaryRead<1> > + 0xf3b82
(0x00EBA04D) (PE_Demo): (filename not available): Behaviour::Transfer<StreamedBinaryWrite<0> > + 0xfd7ed
(0x75B1338A) (kernel32): (filename not available): BaseThreadInitThunk + 0x12
(0x771A9F72) (ntdll): (filename not available): RtlInitializeExceptionChain + 0x63
(0x771A9F45) (ntdll): (filename not available): RtlInitializeExceptionChain + 0x36

Any ideas or has anyone seen similar?
37 REPLIES 37

ajocular
Honored Guest
Are you using 0.4.1? I was seeing similar errors last night in 0.4.1. I think the compiler has trouble with the directory location of the OculusPlugin.dll file depending upon whether you're building 32-bit or 64-bit. If I remember correctly, that file is located in Assets/Plugins when you first install the integration package. When I moved OculusPlugin.dll to Assets/Plugins/x86, the problem went away. I assume if you're doing a 64-bit build, you would have to use the Assets/Plugins/x86_64 directory instead, but either way this is a pain. Hopefully, this will no longer be necessary in a future release.

vrdaveb
Oculus Staff
Does this still happen for you with 0.4.2? Be sure to use DirectToRift.exe. We recently updated it to be more robust. For us, it fixed an issue like the one you described.

RicochetShooter
Honored Guest
I'm having the same problem but with this call stack

========== OUTPUTING STACK TRACE ==================

(0x00007FFA08EDC39D) (OculusPlugin): (filename not available): ovr_WaitTillTime + 0x60ed

========== END OF STACKTRACE ===========

My error log says

Unity Player [version: Unity 4.5.5f1_7684ad0c5a44]

OculusPlugin.dll caused an Access Violation (0xc0000005)
in module OculusPlugin.dll at 0033:046acbd9.

Error occurred at 2014-11-18_214518.
D:\Dev\Showcase\Showcase.exe, run by Bold Arc.
15% memory in use.
16304 MB physical memory [13767 MB free].
18736 MB paging file [15837 MB free].
134217728 MB user address space [134217200 MB free].
Read from location 00000118 caused an access violation.

Context:
RDI: 0x08c43738 RSI: 0x0c93b3e0 RAX: 0x0072f008
RBX: 0x00000118 RCX: 0x00000118 RDX: 0xffffffff
RIP: 0x046acbd9 RBP: 0x0072ee40 SegCs: 0x00000033
EFlags: 0x00010202 RSP: 0x0072ed40 SegSs: 0x0000002b
R8: 0xffffffff R9: 0x00000004 R10: 0x00000005
R11: 0x046a5df0 R12: 0x0072f4e0 R13: 0x03694d48
R14: 0x00000002 R15: 0x00000000

Bytes at CS:EIP:
48 8b 09 48 85 c9 0f 84 c6 01 00 00 0f 29 70 e8 Module 1
C:\Windows\SYSTEM32\xinput1_3.dll
Image Base: 0x00400000 Image Size: 0x0001e000
File Size: 107368 File Time: 2007-04-04_185422
Version:
Company: Microsoft Corporation
Product: Microsoft® DirectX for Windows®
FileDesc: Microsoft Common Controller API
FileVer: 9.18.944.0
ProdVer: 9.18.944.0


== [end of error.log] ==

I'm working with Unity Pro 4.5.5 and Oculus SDK 0.4.3.1.
When I'm in the editor everything works ok, but when I build at first it was working but after it crashed it crashes now on every boot. Even if I remove the files and rebuild the entire scene.

*EDIT: I think it started to happen after I updated my Nvidia graphics drivers. Updating as I'm writing since there was new drivers released today again.

vferguson
Expert Protege
I started seeing this as soon as I upgraded to 0.4.3.1 and Unity 4.6.0f1 (which was required for D3D11 Extended Mode as per the message box in 0.4.3.1). Unfortunately I don't usually even get a callstack - the .exe usually hangs entirely, anywhere from on the Unity logo itself to about a minute or two in.

Reverting to the 0.4.3 package resolves the problem, but 0.4.3.1 literally doubles the frame rate during the time in which it actually does run (presumably due to the fixes for this: viewtopic.php?f=37&t=16287).

However, the executable using 0.4.3.1 does appear to run in Direct Mode.

RicochetShooter
Honored Guest
The strange part is that I did try to build an empty scene with only some floating blocks and a plane and that crashed as well. At first I thought it was a DirectX issue. But I have updated everything I can update and even built the game on different computers.

I have tried these settings:

- DX9/DX11
- Forward rendering/Deferred rendering
- Extended mode

All give the same result, except DX11 witch doesn't work at all.
Any help would be appreciated since I have a demo to show on Friday.

cybereality
Grand Champion
Maybe this is a long-shot, but did you create a profile w/ the Config Util?

Can you try creating a new one and doing the ipd configuration?

vferguson
Expert Protege
I already had a profile with the Config Util but I created a new one to test and did the IPD configuration. Another hang, unfortunately. Edit: in my executable, not the IPD Config tool.

Anonymous
Not applicable
I've been having this problem as well, and just got around it by creating a new project and copying my whole assets folder in there. That new project makes fine builds.

Strangely, deleting & recreating the Library on the original broken project doesn't fix it. I'll report back on anything that does fix the original project, because this bug is persistent in the git repo (including on other people's machines). Bad news. (But no longer the end of the world.)

I'm on Unity 4.6.0f2 and OVR SDK 0.4.3.1. Here's the stacktrace from builds of the original project:
==error.log:
Unity Player [version: Unity 4.6.0f2_b073107612b7]
OculusPlugin.dll caused an Access Violation (0xc0000005)
in module OculusPlugin.dll at 0023:037aba9c.

==output_log:
========== OUTPUTING STACK TRACE ==================

(0x037ABA9C) (OculusPlugin): (filename not available): ovr_WaitTillTime + 0x61cc
(0x037B3817) (OculusPlugin): (filename not available): ovr_WaitTillTime + 0xdf47
(0x037A538E) (OculusPlugin): (filename not available): ovrHmd_GetTrackingState + 0x3e
(0x0470D3D9) (Mono JIT code): (filename not available): (wrapper managed-to-native) Ovr.Hmd:ovrHmd_GetTrackingState (intptr,double) + 0x39 (0470D3A0 0470D414) [04124E70 - Unity Root Domain] + 0x0
(0x0470D36D) (Mono JIT code): (filename not available): Ovr.Hmd:GetTrackingState (double) + 0x25 (0470D348 0470D38F) [04124E70 - Unity Root Domain] + 0x0
(0x0470D31E) (Mono JIT code): (filename not available): OVRDisplay:get_isPresent () + 0x3e (0470D2E0 0470D33B) [04124E70 - Unity Root Domain] + 0x0
(0x0470F65E) (Mono JIT code): (filename not available): OVRManager:Update () + 0xce (0470F590 0470F76E) [04124E70 - Unity Root Domain] + 0x0
(0x046DE629) (Mono JIT code): (filename not available): (wrapper runtime-invoke) object:runtime_invoke_void__this__ (object,intptr,intptr,intptr) + 0x41 (046DE5E8 046DE67D) [04124E70 - Unity Root Domain] + 0x0
(0x100F0376) (mono): (filename not available): mono_set_defaults + 0x22cb
(0x1005D78C) (mono): (filename not available): mono_runtime_invoke + 0x51
(0x00AC5138) (VRMT): (filename not available): Behaviour::Transfer<StreamedBinaryWrite<0> > + 0x28cb8
(0x00B623D6) (VRMT): (filename not available): Behaviour::Transfer<StreamedBinaryWrite<0> > + 0xc5f56
(0x00B61FA5) (VRMT): (filename not available): Behaviour::Transfer<StreamedBinaryWrite<0> > + 0xc5b25
(0x00AB789B) (VRMT): (filename not available): Behaviour::Transfer<StreamedBinaryWrite<0> > + 0x1b41b
(0x00AB7911) (VRMT): (filename not available): Behaviour::Transfer<StreamedBinaryWrite<0> > + 0x1b491
(0x00AB7927) (VRMT): (filename not available): Behaviour::Transfer<StreamedBinaryWrite<0> > + 0x1b4a7
(0x00B2F709) (VRMT): (filename not available): Behaviour::Transfer<StreamedBinaryWrite<0> > + 0x93289
(0x00BA5A0B) (VRMT): (filename not available): Behaviour::Transfer<StreamedBinaryWrite<0> > + 0x10958b
(0x00BA72D5) (VRMT): (filename not available): Behaviour::Transfer<StreamedBinaryWrite<0> > + 0x10ae55
(0x00E1A448) (VRMT): (filename not available): AnimationEvent::Transfer<StreamedBinaryRead<1> > + 0x121c88
(0x00E4F340) (VRMT): (filename not available): AnimationEvent::Transfer<StreamedBinaryRead<1> > + 0x156b80
(0x7557919F) (KERNEL32): (filename not available): BaseThreadInitThunk + 0xe
(0x77130BBB) (ntdll): (filename not available): RtlInitializeExceptionChain + 0x84
(0x77130B91) (ntdll): (filename not available): RtlInitializeExceptionChain + 0x5a

========== END OF STACKTRACE ===========

**** Crash! ****

cybereality
Grand Champion
Can you guys list your OS, system specs, GPU driver version, etc.?