Sampling Methods

Using multi sampling we estimate the colour of a pixel by sampling the scene with multiple rays through that pixel and average the colours. This provides a simple means of anti-aliasing.

I have implemented two sampling methods, random and stratified sampling.

With random sampling the points suffer from bunching or areas of emptiness within the unit square and may give an inaccurate estimate to the average pixel colour.

Stratified sampling provides a more uniform samples, by evenly dividing the unit square into and n by n sub squares and each sample generate is inside one of these sub squares. The simplest form is called regular sampling, which places a sample at the centre of each of the sub squares. With jittered sampling the samples are random, but still within each sub square.

Below shows the 16 samples within a unit square produced with each method.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s