Skip to content

Creating a New Scene

This guide will walk you through the process of creating and setting up a scene in SightLab VR. Whether you're working with 3D models or 360 media, this will help you get started with your project. SightLab experiments can be set up with a GUI, with code, or a combination of both.

Creating a Scene

Setting Up Your Project

The SightLab projects folder is by default in Documents/SightLab2 or Documents/SightLab VR Projects 2.0 for SightLab 2 Beta

  • Create Your Project Folder (can use one of these options):

    • Make a copy of the "BlankProject" folder (recommended).

    • Use the SightLab SampleProject

    • Create a new folder and copy over essential files:

      • SightLab_VR.py
      • SightLabVR_Replay.py
      • A folder called Resources with sub-folders for environments and media

Note: The sightlab_configs, Data, and recordings folders will be created automatically when you first run your session.

While you can place your project folder anywhere on your computer, the recommended location is within the SightLab projects folder.

Key Files

  • SightLab_VR.py: Use this for creating and running your project and leverage the GUI (note that SightLab can also be attached to any existing Vizard or SightLab script).
  • SightLabVR_Replay.py: Use this for replaying your project.
  • SightLabVR_NonGUI.py: A template for creating a scene using only code

Add Resources

  • Add your 3D models to the resources/environments folder (see below for editing the models).

  • Add media files to the resources/media folder.

  • A good place to get started if you don't have any assets is Fab or Sketchfab (download as .glb).

  • Refer to the "Getting Models and Assets" page for more options.
  • Download additional environments and assets pack here.

  • You can also use included assets in the Sample Project or click "Built In" for using the built-in resources (note: "Built In" resources would need to be taken out of the sightlab_resources folder before they can be modified).

If starting from your own folder:

  1. Create a new folder called resources.
  2. Inside resources, create two subfolders:
  3. environments (for 3D models)
  4. media (for 360° media, if needed)

Using the GUI Editor

  1. Open the SightLab VR Script:

    • Double-click SightLab_VR.py in your project folder
    • This will launch the GUI editor.

    Note: If other Python editors are installed on your system, ensure that the file opens in the Vizard Python environment. If the GUI doesn't load, right-click on the script and choose "Open With - Vizard 7" or "Vizard 8" (found at C:\Program Files\WorldViz\Vizard\<versionNumber>\bin\winviz.exe).

  2. Choose Your Hardware Mode:

    • Select Desktop for setting up your experiment.
      • Selecting a headset may make the GUI scene look strange as it will link to the headset tracking. Select your headset after configuration when running the session.

  3. Create a New Project:

    • Click New.
    • Enter a name for your project.
    • Click Save Project.

    Additional Options: - Load existing .stlb files (SightLab experiment files). - Edit your Python script by clicking Edit [filename]. - Open your project folder by clicking the folder icon.

Opening the Experiment Options Editor

  1. In the GUI editor, click Modify to open the Experiment Options editor.
  2. This is where you can edit and open your 3D models or 360 media, as well as set up all your individual trial options (start/stop conditions, tracking, etc.)

Note: You can also run the Inspector 3D model editor directly from the Inspector shortcut in the main SightLab projects folder, or from the "Tools" menu in the Vizard IDE.

Managing 3D Models and Media

  1. View Available Models and Media:

  2. Click the Environment dropdown to see available 3D models.

  3. Select 360 Media for 360 media files.

  4. Change Working Environment:

  5. Click Change to switch the directory within your project.
  6. Click Built-In to use SightLab's included assets.

Editor Controls Overview

  • Left Shift: Toggle scene lock/ROI selection mode (360 media).
  • . (Period)/F1: Hide/show the menu.
  • Mouse: Look around.
  • WASD/Arrow Keys: Move (left/right/forward/backward).
  • Z/X: Move down/up (or PageUp/PageDown).
  • Q/E: Rotate left/right.
  • R: Reset viewpoint.
  • /: Take screenshot.
  • ;: Toggle mouse lock.
  • ,: Toggle scene display.
  • F2: Toggle fullscreen.
  • F3: Toggle rendering/wireframe modes.
  • F4: Show frame rate/performance metrics.
  • Escape: Exit.
  • Ctrl + F6: Dock/undock with code.
  • Spacebar: Toggle media playback (360 media).
  • 1: Select ROIs (360 media).
  • IJKL: Move virtual gaze point (or use mouse).
  • Alt + I: Float window and activate Vizard IDE interactive input.

Editing Models

  1. Open Models in Inspector:

  2. Click Edit in the Experiment Options editor to open a model in Inspector.

  3. Use Inspector to add objects, tag ROIs, set starting points, adjust lighting, etc.
  4. For more on Inspector see this page

  5. Add New Models:

  6. Click + to load new models into your project.

Inspector Controls

  • Left Mouse Drag: Orbit view.
  • Shift + Left Click: Move view to clicked surface.
  • Right Mouse Drag: Pan.
  • Scroll Wheel: Zoom.
  • Z: Zoom to selected node.

For more on Inspector, see Vizard Documentation.

Environment Size Check

  1. Click the root node in the scene graph (top left).
  2. View the size in meters (bottom right).

Setting the Starting Point

  • Add the SIGHTLAB_STARTING_POINT:
  • Use File > Add to include the starting point.
  • Locate it in BlankProject\Resources\scene_objects or C:\Program Files\WorldViz\Sightlab2\resources\sightlab_resources\objects.

Or find shortcut in: Documents\SightLab2\Util_Files\SightLab_Resources.

Transforming Objects

  • Move: Reposition objects.
  • Scale: Resize objects.
  • Rotate: Change orientation.

Adjust the participant's starting position by moving/rotating the SIGHTLAB_START_POINT.

Adding Objects of Interest

  1. Add Objects:
  2. Use File > Add to include objects.
  3. Position and scale objects with transform tools.

Understanding Nodes

  • View and manage nodes in the scene graph (left panel).
  • Group Nodes (red, blue, green) are essential for data collection.

Creating Group Nodes

  • Right-click on a node > Insert Above - Group for data collection.
  • Add transform nodes for positioning objects (right-click > Insert Above - Transform).

Renaming Objects

  1. Right-click on the group node > Rename.
  2. Enter a unique name. Check existing names using Search.

Tip: Use "_env" in the name to automatically exclude an object from data collection.

Adding Regions of Interest (ROIs) to 3D Scenes

Adding ROI Objects

  1. Add ROIs:
  2. Use File > Add and select RegionOfInterest.osgb from scene_objects or the resources folder.

Positioning ROIs

  1. Select rootNode under FixationRegion.
  2. Use transform tools to adjust position, size, and orientation.

Naming ROIs

  1. Right-click the region in the scene graph > Rename.
  2. Name the region (e.g., "PeanutButter").

Creating Multiple ROIs

  • Hold Shift and move an ROI to duplicate.
  • Add lights, backgrounds, etc., via Create > Light.

Saving Changes

  • File > Save your work in Inspector.
  • Refresh in SightLab to apply changes.

Working with 360 Media

Switching to 360 Media Mode

  • Select 360 Media in the Experiment Options editor.

Selecting Media

  • View media in the resources/media folder.
  • Use Change to switch directories.
  • Use Built-In for default 360 media.

Media Options

  • Choose media type (video/image).
  • Select stereo or mono format.

Adding ROIs to 360 Media

  • Press Add or Left Shift to enter ROI mode.

Tip: Press ; to lock the mouse cursor.

Placing and Customizing ROIs

  • Move the virtual gaze point and press 1 to set ROIs.
  • Customize region name, scale, opacity, and color.

Tip: Lower opacity to hide ROIs during the experiment.

Refer to this YouTube Tutorial for more information.

Configuring Trials

  1. Generate Trials: Enter a count and click Generate.
  2. Current Trial: Use the dropdown to edit individual trials.

Trial Parameters

  • Label: Enter trial-specific labels.
  • Start/End Conditions:
    • Key/button press
    • Timer
    • Custom Event
    • Media end
    • Gaze Event (specify object name)
    • None (specified in code)

Finalizing Your Project

  1. Name your project.
  2. Click Save Config.
  3. Use Randomize to randomize the trial order.
  4. Choose combined or per-trial data file saving.

Note: For advanced randomization, use the code.

Thresholds and Options

  • Dwell Time Threshold: Default 500ms (modifiable).
  • Fixation Duration: Default 100ms.
  • Dispersion Angle: Default 1 degree.
  • Noise Reduction: Adjust frame averaging.

Options

  • Screen Record: Records session videos.
  • BIOPAC Markers: Synchronize with Biopac's AcqKnowledge.

Running the Project

Click Continue to test your project. See "Running a Session Single User" or "Running a Session Multi-User"