Skip to content
Häfner edited this page Apr 12, 2021 · 1 revision

A camera defines a viewpoint in space, position and orientation. OpenGL renders the part of the scene as viewed from the viewpoint in -Z direction, and Y as up axis.

Create a new camera and place it in your scene:

cam = VR.Camera('myCam')
VR.find('light').addChild(cam)
cam.activate()

You can change the camera parameters:

cam.setFov(2.0)
cam.setAspect(2.0)
cam.setNear(0.1)
cam.setFar(1000.0)

The camera spans a view frustum based on the horizontal field of view angle, its aspect ratio, its near and far planes. Only geometry inside this frustum is rendered!

Clone this wiki locally