Nori

Camera Class Reference

Generic camera interface. More...

#include <camera.h>

Inheritance diagram for Camera:
NoriObject

List of all members.

Public Member Functions

virtual Color3f sampleRay (Ray3f &ray, const Point2f &samplePosition, const Point2f &apertureSample) const =0
 Importance sample a ray according to the camera's response function.
const Vector2igetOutputSize () const
 Return the size of the output image in pixels.
const ReconstructionFiltergetReconstructionFilter () const
 Return the camera's reconstruction filter in image space.
EClassType getClassType () const
 Return the type of object (i.e. Mesh/Camera/etc.) provided by this instance.

Protected Attributes

Vector2i m_outputSize
ReconstructionFilterm_rfilter

Detailed Description

Generic camera interface.

This class provides an abstract interface to cameras in Nori and exposes the ability to sample their response function. By default, only a perspective camera implementation exists, but you may choose to implement other types (e.g. an environment camera, or a physically-based camera model that simulates the behavior actual lenses)

Definition at line 36 of file camera.h.


Member Function Documentation

EClassType Camera::getClassType ( ) const [inline, virtual]

Return the type of object (i.e. Mesh/Camera/etc.) provided by this instance.

Implements NoriObject.

Definition at line 72 of file camera.h.

const Vector2i& Camera::getOutputSize ( ) const [inline]

Return the size of the output image in pixels.

Definition at line 63 of file camera.h.

const ReconstructionFilter* Camera::getReconstructionFilter ( ) const [inline]

Return the camera's reconstruction filter in image space.

Definition at line 66 of file camera.h.

virtual Color3f Camera::sampleRay ( Ray3f ray,
const Point2f samplePosition,
const Point2f apertureSample 
) const [pure virtual]

Importance sample a ray according to the camera's response function.

Parameters:
rayA ray data structure to be filled with a position and direction value
samplePositionDenotes the desired sample position on the film expressed in fractional pixel coordinates
apertureSampleA uniformly distributed 2D vector that is used to sample a position on the aperture of the sensor if necessary.
Returns:
An importance weight associated with the sampled ray. This accounts for the difference in the camera response function and the sampling density.

Member Data Documentation

Definition at line 74 of file camera.h.

Definition at line 75 of file camera.h.


The documentation for this class was generated from the following file:
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Defines