cancel
Showing results for 
Search instead for 
Did you mean: 

ovrHmd_AttachToWindow

rupy
Honored Guest
How can one give the runtime a window to render on the direct monitor?
11 REPLIES 11

joan
Protege
This API is no longer part of the SDK. Which version are you using? Have you looked at the samples and how they handle the mirror window?

rupy
Honored Guest
Yeah, thanks but Oculus have removed extended completely, making my DK2 only work with old Runtimes. Luckily I'm not mad at them "bricking" my DK2 for the extended game I'm building because I ordered a Vive and they have extended!

I recommend everyone to switch to Vive before it's too late.

joan
Protege
Maybe you don't realize the pain in the ass that extended mode is for users. Or maybe you don't realize the benefits of Direct mode.

Here is a quote from SteamVR that maybe will have more weight:

SteamVR’s Direct Mode allows direct communication with the Vive’s displays, bypassing the operating system’s typical display communication path. This results in a more consistent experience for Vive users, as its composited view renders independent of other desktop application windows. For example, flashing displays upon headset detection, confused display destinations for desktop applications, and fullscreen compositor warnings are all resolved by Direct Mode. Additionally, Direct Mode allows the headset to go into standby mode, preserving power and display life.

To enable Direct Mode, just update your drivers to 361.75 (NVIDIA) or 1.0.3.16 (AMD) or newer and then make sure you are running SteamVR beta.

CrazyNorman
Protege
I really don't understand what you're getting at. Extended mode is worse for both developers and end users.


  • End Users: Windows shifting around each time you turn the headset on, dealing with moving apps too and from DK2 "monitor", strange performance issues depending upon main monitor

  • Developers: Needing a scheme to handle window positioning, strange performance bugs from end users, needing to manage a window, worrying if user has resolution or orientation set correctly


I don't get it. Direct mode is friendlier for users and friendlier for developers. It only takes a few lines of code to pass textures from your engine to the Oculus (or Vive) sdk. Why would you complain about direct mode and want extended mode? Extended mode needs to go, it was an easy way to get started in the early days but I'm so glad it's gone 😉

rupy
Honored Guest
I can't use direct mode from LWJGL, I would then have to use Unity or Unreal which both cost money and do not give me the full control over rendering and other things.

As a consumer or consumer friendly producer, the choice is easy you build the same stuff as everyone else and make money.

But I'm not in the VR business to make fiat money primarily, I'm in it to build some sort of lowpoly matrix MMO with bitcoin as money; focus on UGC (you should be able to build and sell spaceships) and not getting sick (I know direct mode would help but not as much as being able to control framrates myself = I render at 2x Hz = 150 FPS on DK2 and 180 FPS on Vive)

The point here is, Oculus are afraid of bad consumer experiences (which I completely agree extended cause alot of the time) but they should not forbid some use of their hardware after a while just like that, because then we cannot forsee and plan our projects. Imagine tomorrow they say: Well now only Win 10 is allowed for the Rift, a better way would be to say Win 10 works best but the users can choose whatever they like.

At some point you will be able to access direct mode on any monitor in the OS directly from any language DirectX and OpenGL, and along with that we'll have better performing graphics/display technology (OpenGL/HDMI) too (we'll have to because 16nm is about as small as thing will get, so we need to improve in other ways than just throwing smaller lithography at the problem)...

Everything is ok, I'm really happy Valve/HTC are more "alternative" than Facebook/Microsoft.

CrazyNorman
Protege
That sounds like a very cool project! Now that Oculus has proper OpenGL support I bet you could get direct mode working with LWJGL and have the best of both worlds 🙂

I use direct mode from my custom engine with full control over rendering, no Unity/Unreal here :mrgreen:

I'm curious how 2x FPS helps with sickness. I'd think that Direct Mode with timewarp provides both lower and more consistent latency.

rupy
Honored Guest
Well, I do the warping and chromatic aberration myself, because I want to experiment with different things. So I won't be rendering to a texture that the runtime then distorts and does magic on. Also at some point I will build my own headset and then I need to be able to distort myself.

2x Hz is the lowest latency for rendering you can get with current "dumb" HDMI. I get 5.5 ms latency on rendering while others are at 11 ms for 90Hz. Timewarp actually makes me sicker because it is inconsistent in how it fakes low latency = some movements it can correct, others it can't; and that does not go well with my brain.

jherico
Adventurer
"rupy" wrote:
I can't use direct mode from LWJGL, I would then have to use Unity or Unreal which both cost money and do not give me the full control over rendering and other things.


Yes, you can, and even if you couldn't, switching to Vive wouldn't help, since they're migrating to direct mode as well.

rupy
Honored Guest
I can't add my own window to direct mode no, on neither; Valve is keeping extended as an option which Oculus did not. SteamVR -> Devices -> Direct Mode (does not work on Oculus obviously)