Skip to content
alexus37 edited this page Oct 21, 2015 · 2 revisions

Camera

For rendering an image we need to set up a camera for the rendering

Perspective Camera (type="perspective")

Description

The perspective camera is the idealized model of the pinhole camera.

Properties

Parameter Type Description
toWorld transform Matrix defining the to world transformation.OpenGL lookAt is also supported
fov float flied of view in degrees [0, 180]
width integer Number of pixels in the width
height integer Number of pixels in the height

Code example

<camera type="perspective">
	<transform name="toWorld">
		<lookat origin="20, 20, 50" 
			target="0, 4, 0"
			up="0, 1, 0"/>
	</transform>
	<float name="fov" value="39.3077"/>
	<integer name="width" value="768"/>
	<integer name="height" value="432"/>
</camera>

ToDo

Add maybe more realistic camera modeles

Clone this wiki locally