The lovr.headset module is where all the magical VR functionality is. With it, you can access connected VR hardware and get information about the available space the player has. Note that all units are reported in meters. Position (0, 0, 0) is the center of the play area.


Functions that return information about the active head mounted display (HMD).

lovr.headset.getNameGet the name of the connected headset display.
lovr.headset.getMirrorTextureGet the Texture containing a view of what's in the headset.
lovr.headset.getDisplayDimensionsGet the dimensions of the headset display.
lovr.headset.getDisplayHeightGet the height of the headset display.
lovr.headset.getDisplayMaskGet a mesh that masks out the visible display area.
lovr.headset.getDisplayWidthGet the width of the headset display.
lovr.headset.getClipDistanceGet the near and far clipping planes of the headset.
lovr.headset.setClipDistanceSet the near and far clipping planes of the headset.
lovr.headset.renderToRender to the headset using a function.
lovr.headset.getOriginTypeGet the type of tracking origin of the headset.
lovr.headset.getDriverGet the VR API currently in use for a device.


Functions for accessing input devices, like controllers, hands, trackers, or gamepads.

lovr.headset.getHandsGet a list of currently tracked hand devices.
lovr.headset.getVelocityGet the linear velocity of a device.
lovr.headset.newModelGet a Model for a device.
lovr.headset.getAngularVelocityGet the angular velocity of a device.
lovr.headset.getPoseGet the pose of a device.
lovr.headset.getPositionGet the position of a device.
lovr.headset.isTouchedCheck if a button on a device is touched.
lovr.headset.isDownGet the state of a button on a device.
lovr.headset.isTrackedCheck if a device is currently tracked.
lovr.headset.getOrientationGet the orientation of a device.
lovr.headset.vibrateMake a device go BZZZ!
lovr.headset.getAxisGet the state of an analog axis on a device.

Play area

Retrieve information about the size and shape of the room the player is in, and provides information about the "chaperone", a visual indicator that appears whenever a player is about to run into a wall.

lovr.headset.getBoundsDepthGet the depth of the play area.
lovr.headset.getBoundsDimensionsGet the size of the play area.
lovr.headset.getBoundsGeometryGet a list of points that make up the play area boundary.
lovr.headset.getBoundsWidthGet the width of the play area.