WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 06-08-2016, 08:30 AM
willpower2727 willpower2727 is offline
Member
 
Join Date: Feb 2015
Posts: 39
Temporarily cease Oculus DK2 rendering or hide display

I'm wondering if there is a way to momentarily stop rendering on the Oculus DK2? I'm looking to do something analogous to:

Code:
viz.setOption('viz.window.visible', 0)
I've tried this with my current setup and it hides the mirrored window on my PC's monitor but it does nothing to the rendering on the Oculus itself. Here is the code I use to setup the DK2:

Code:
import oculus

hmd = oculus.Rift()
if not hmd.getSensor():
	sys.exit('Oculus Rift not detected')
else:
	profile = hmd.getProfile()
	hmd.setIPD(profile.ipd)


# Setup navigation node and link to main view
global navigationNode
navigationNode = viz.addGroup()
global viewLink
viewLink = viz.link(navigationNode, viz.MainView)
Any ideas or methods I can use to hide/stop rendering on the DK2 without stopping the whole program?
Reply With Quote
  #2  
Old 06-09-2016, 04:53 AM
Jeff Jeff is offline
WorldViz Team Member
 
Join Date: Aug 2008
Posts: 2,471
Does the following work?

Code:
viz.setOption('viz.window.visible', 0)
viz.MainWindow.visible(False)
hmd.remove()
Would rendering a quad over the scene to hide it work for you?
Reply With Quote
  #3  
Old 06-10-2016, 08:23 AM
willpower2727 willpower2727 is offline
Member
 
Join Date: Feb 2015
Posts: 39
None of the options stop rendering or hide it or whatever on the hmd.

Code:
viz.MainWindow.visible(False)
Works at hiding the mirrored window on my PC's monitor but the scene is still being rendered on the HMD. Interestingly
Code:
 hmd.remove()
Doesn't seem to do anything.

I will have difficulty in hiding the scene with a quad since the user is immersed in the scene (subject can walk around and interact with the scene). In order to hide the scene with a quad I'd have to have reliable information about the head position and orientation which in the scenarios where I want to hide things, this data is inaccurate.

Alternatively I think I'll try positioning a black sphere around the head when I want to hide the scene, so that only the position data needs to be robust.
Reply With Quote
  #4  
Old 06-13-2016, 07:00 AM
dcnieho dcnieho is offline
Member
 
Join Date: Feb 2011
Posts: 59
You can use parent=viz.SCREEN to have an object in screen based coordinates instead of int eh virtual world. works with vizshape at least.
Reply With Quote
  #5  
Old 06-15-2016, 07:40 AM
willpower2727 willpower2727 is offline
Member
 
Join Date: Feb 2015
Posts: 39
@dcnieho, that's a great idea, it works great and you were right I don't have to worry about setting the position.

Code:
global HideSphere
HideSphere = vizshape.addQuad(size=[1,1])
HideSphere.setParent(viz.SCREEN)
HideSphere.setPosition(0.5,0.5,0)
HideSphere.color(0,0,0)
Reply With Quote
  #6  
Old 09-07-2016, 08:39 AM
dcnieho dcnieho is offline
Member
 
Join Date: Feb 2011
Posts: 59
Hi Jeff,

I wanted to note that the below:

Quote:
Originally Posted by willpower2727 View Post
None of the options stop rendering or hide it or whatever on the hmd.

Code:
viz.MainWindow.visible(False)
Works at hiding the mirrored window on my PC's monitor but the scene is still being rendered on the HMD.
Is also a symptom of not having access to the screen on the HMD through vizard. It could well be the same underlying problem as getting resolution of HMD, etc. all viz.MainWindow operations are for the window on the desktop, not the HMD screen.
Reply With Quote
Reply

Tags
dk2, hide, oculus, rendering

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
3D text oculus for right to left languages bbb Vizard 2 01-16-2016 07:02 AM
Blank screen on external monitor when running a Vizard script with Oculus DK2 mstan Vizard 4 09-03-2015 05:58 AM
Oculus runtime disrupts clustering to mirror DK2 display performlabrit Vizard 1 01-23-2015 07:00 AM
Duplicate HMD display on primary monitor, with eyetracking info performlabrit Vizard 3 09-19-2014 10:44 AM


All times are GMT -7. The time now is 02:59 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Copyright 2002-2023 WorldViz LLC