

Used to set viewing parametersĪccordingly. HwModel ( str) – Model of the VisualSystemHD in use. Ifįalse, drawing is done with two FBOs containing each eye’s image. This saves video memory butĭoes not permit barrel distortion or monoscopic rendering. Stimuli are drawn directly to the back buffer

You canĪdjust the value to fine-tune the barrel distortion.ĭirectDraw ( bool) – Direct drawing mode. Recommended value will be used for the model of display. Not applying correction will result in pincushionĭistortion which produces a non-rectilinear output.ĭistCoef ( float) – Distortion coefficient for barrel distortion. No distortion will be applied to the output and the entire display Of distortion applied can be specified using distCoef. LensCorrection ( bool) – Apply lens correction (barrel distortion) to the output. Only 2D stimuli about the center of the display as it uses a lessĭiopters ( tuple or list) – Initial diopter values for the left and right eye. Recommended that you use monoscopic mode if you intend to display Possible to set monoscopic mode after the window is created.

If True, the same image will be drawn toīoth eye buffers. Monoscopic ( bool) – Use monoscopic rendering. useLights = False # reset transform to draw text correctly win. draw () # draw the ball # shut the lights, needed to prevent light color from affecting # 2D stim win. useLights = True # switch on lights ball.

setBuffer ( eye ) # change the buffer # setup drawing with perspective win. getTime () for eye in ( 'left', 'right' ): win. setEyeOffset ( iod / 2.0, 'right' ) trialClock = core. setEyeOffset ( - iod / 2.0, 'left' ) win. SphereStim ( win, radius = 0.1, pos = ( 0, 0, - 2 ), color = 'green', useShaders = False ) iod = 6.2 # interocular separation in CM win. ambientLight = ( 0.2, 0.2, 0.2 ) # Initialize some stimuli, note contrast, opacity, ori ball = visual. 7 )) # create scene light at the pivot point win. TextStim ( win, text = "Any key to quit", pos = ( 0,. VisualSystemHD ( fullscr = True, screen = 1, multiSample = True, nSamples = 8 ) # text to display instr = visual. (other projection modes are not implemented or supported right now):įrom psychopy import visual, core, event # Create a visual window win = visual. Set eyeOffset and apply the projection by calling setPerspectiveView. For 3D rendering with perspective, you need quit ()Īs you can see above, there are few changes needed to convert an existing 2DĮxperiment to run on the VSHD. setBuffer ( eye ) # change the buffer grating1. GratingStim ( win, mask = "circle", color = 'white', contrast = 0.5, size = ( 1.0, 1.0 ), sf = ( 4, 0 ), ori = 45, autoLog = False ) grating2 = visual. VisualSystemHD ( fullscr = True, screen = 1 ) # Initialize some stimuli, note contrast, opacity, ori grating1 = visual. Is the binocular version of the dynamic ‘plaid.py’ demo:įrom psychopy import visual, core, event # Create a visual window win = visual. Here is a basic example of 2D rendering using the VisualSystemHD(tm). Window using multiSample=True and numSamples > 1 to smooth out these This class handles drawing differently than the default window class, asĪ result, stimuli autoDraw is not supported.Įdges of the warped image may appear jagged. Rendering is implemented in the base Window class. Which eye to draw to by calling setBuffer, much like how stereoscopic The VSHD is capable of both 2D and stereoscopic 3D rendering. Ensure that the VSHD headset display output is configured inĮxtended desktop mode (eg. Use this class in-place of the Window class for use with the VSHD VisualSystemHD ( monoscopic = False, diopters = - 1, - 1, lensCorrection = True, distCoef = None, directDraw = False, model = 'vshd', * args, ** kwargs ) ¶Ĭlass provides support for NordicNeuralLab’s VisualSystemHD(tm) fMRI
