Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

sampling.inl File Reference

Go to the source code of this file.

Functions

sheep::Point2 UniformDiskSampling (sheep::Real xi1, sheep::Real xi2)
 Returns a point chosen uniformly on the surface of the unit disk.

sheep::Point3 UniformSphereSampling (sheep::Real xi1, sheep::Real xi2)
sheep::Point3 UniformHemisphereSampling (sheep::Real xi1, sheep::Real xi2)
sheep::Point3 CosineHemisphereSampling (sheep::Real xi1, sheep::Real xi2)


Function Documentation

sheep::Point3 CosineHemisphereSampling sheep::Real  xi1,
sheep::Real  xi2
[inline]
 

Returns a point chosen with a cosine-weighted distribution on the surface of the unit hemisphere (see above for definition). The vector from the origin to the returned point is unit-length. Note: when doing stratified sampling, there should be 4 times more samples for xi2 than for xi1, since xi2 is used to compute the Phi angle.

Todo:
Turn the multiplication into an addition.

Definition at line 84 of file sampling.inl.

References sheep::Real.

Referenced by toxic::Renderer::final_gathering().

sheep::Point2 UniformDiskSampling sheep::Real  xi1,
sheep::Real  xi2
[inline]
 

Returns a point chosen uniformly on the surface of the unit disk.

Definition at line 24 of file sampling.inl.

References sheep::Real.

Referenced by toxic::ThinLensCamera::ComputeRay(), and toxic::Camera::ComputeRay().

sheep::Point3 UniformHemisphereSampling sheep::Real  xi1,
sheep::Real  xi2
[inline]
 

Returns a point chosen uniformly on the surface of the unit hemisphere (the y >= 0 part of the unit sphere). The vector from the origin to the returned point is unit-length. Note: when doing stratified sampling, there should be 4 times more samples for xi2 than for xi1, since xi2 is used to compute the Phi angle.

Todo:
Turn the multiplication into an addition.

Definition at line 73 of file sampling.inl.

References sheep::Real.

sheep::Point3 UniformSphereSampling sheep::Real  xi1,
sheep::Real  xi2
[inline]
 

Returns a point chosen uniformly on the surface of the unit sphere. The vector from the origin to the returned point is unit-length.

Todo:
Turn the multiplication into an addition.

Turn the multiplication into an addition.

Turn the multiplication into an addition.

Definition at line 62 of file sampling.inl.

References sheep::Real.

Referenced by toxic::Sphere::EvaluateSurface().


Generated on Tue May 11 01:31:53 2004 for toxic by doxygen 1.3.6