SightLab VR’s new AI 3D Model Spawner demo lets researchers and creators summon fully-textured, grab-ready 3D objects on the fly simply by typing or speaking a prompt—no modeling skills required. By piping those prompts through generative-AI services like Meshy or MasterpieceX, the script spins up geometry in under four minutes, drops it into a chosen VR environment, and immediately ties it into SightLab’s built-in gaze-tracking and grab logging. The result is an on-demand sandbox for rapid stimulus generation, UX testing, classroom demos, or game-design experiments without ever leaving VR. Here is how you can use it to generate 3D models in real time.
Located in ExampleScripts/AI_3D_Model_Spawner
AI 3D Model Spawner allows participants or researchers to spawn objects into a virtual scene on demand, simply by typing text prompts or using speech recognition to speak model requests (e.g. “a glowing mushroom”). The models are created via online APIs, refined, and automatically placed in the VR environment.
pip install mpx-genai-sdk pillow requests
SightLab and Vizard dependencies must already be installed and configured.
In windows search type "cmd" and enter the following
setx MESHY_API_KEY "your-meshy-api-key"
setx MPX_SDK_BEARER_TOKEN "your-mpx-bearer-token"
⚠️ Important: Restart Vizard (or your terminal) after setting these.
Estimated time to model completion: MasterpieceX - 1-2 minutes
Meshy - 2-4 minutes
# ===== Passthrough / AR Settings =====
USE_PASSTHROUGH = False
# ===== Environment Settings =====
ENVIRONMENT_MODEL = 'sightlab_resources/environments/RockyCavern.osgb'
# ===== GUI Options =====
USE_GUI = False
# ===== Speech Recognition =====
USE_SPEECH_RECOGNITION = True
# ===== Model Options =====
MODEL_STARTING_POINT = [0, 1.5, 2]
MODEL_STARTING_POINT_PASSTHROUGH = [0, 1.5, 0.8]
# ===== Data Saving =====
SAVE_DATA = False
Field
Idea Example
🧠 Psychology
Generate phobic stimuli like a spider, a syringe
🦴 Education
Spawn anatomy models: human skull, brain cross-section
➕ Math/Cognition
Test symbolic vs object views: 3 apples, a number line
🧪 UX/VR Dev
Prototype object-based interactions in VR
🎮 Game Studies
On-demand in-scene assets for testing