Author Topic: 3D GUIs with the Oculus  (Read 4028 times)

IIIDeFeKtIII

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 31
    • View Profile
3D GUIs with the Oculus
« on: July 15, 2013, 03:12:39 PM »
Is rendering to a texture on a separate material and plane in your scene the only way to use NGUI advanced 3d setup? 2D GUIs look great, but once a 3d camera is placed into the scene the screen goes black. I tried the alternate method of rendering to texture and that seems to work, but doesn't seem to look as clean. Any Ideas?

Followed this setup to get it up and running this way.
http://www.beowulf99.com/blog/?p=1014

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: 3D GUIs with the Oculus
« Reply #1 on: July 15, 2013, 07:12:42 PM »
The screen goes black? Pay close attention to the order of your cameras. I know quite a few people have been using NGUI with Occulus, and I should be getting my dev kit in August.

IIIDeFeKtIII

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 31
    • View Profile
Re: 3D GUIs with the Oculus
« Reply #2 on: July 16, 2013, 08:10:22 AM »
Only when using the 3d GUI. I have tried changing the depth on the camera's. If I make the NGUI 3D camera a lower depth and the Oculus camera's higher I see what I'm suppose to, but with no GUI's obviously. If I change the order to have the 3D GUI higher then Oculus camera's I see my GUI text, but with a black background. The only way I've been able to make it work is by using the above link to render to a texture and then apply it to a plane. Which works, but I think it looks like crap when it comes to text readability. However 2D GUI's work just fine from NGUI. If I use an NGUI 2D setup and change it from orthographic to perspective I get the same results. I have clear flags "Depth Only" set as well still.

IIIDeFeKtIII

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 31
    • View Profile
Re: 3D GUIs with the Oculus
« Reply #3 on: July 16, 2013, 08:38:23 AM »
Stupid me. I figured out what the issue was. I was playing with a few settings before I received the Oculus and had the Rendering Path set to Deffered....

IIIDeFeKtIII

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 31
    • View Profile
Re: 3D GUIs with the Oculus
« Reply #4 on: July 16, 2013, 08:56:58 AM »
Actually I'm not sure if this would be the issue..!? I deleted the Oculus Controller Prefab and put it back into the scene and seems to run just fine now even as deferred is set in the player settings.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: 3D GUIs with the Oculus
« Reply #5 on: July 16, 2013, 10:51:17 AM »
Most common cause of things working one way with a default camera and another way with post processing effects / deferred is not clearing the depth with the UI camera.