Due: March 20
For the following problems, please show all your work.
![]() |
We will find a uniform sampling distribution for a cylinder of height h and radius r. First we must compute the marginal and conditional density functions. These are given by: |
|
![]() |
|
|
| Marginal Density | ||
| Conditional Density | ||
| Now we use these to find the sampling function by integrating and inverting: | ||
![]() |
||
| Where u1 and u2 are randomly generated points | ||
| Finally, we can convert to rectilinear coordinates by the standard transformations from cylindrical to rectilinear coordinates: | ||
![]() |
||
![]() |
We will find a uniform sampling distribution for a cone of height h and base radius r. First we must compute the marginal and conditional density functions. These are given by: |
|
![]() |
|
|
| Marginal Density | ||
| Conditional Density | ||
| Now we use these to find the sampling function by integrating and inverting: | ||
![]() |
||
| Where u1 and u2 are randomly generated points | ||
| Finally, we can convert to rectilinear coordinates by the standard transformations from cylindrical to rectilinear coordinates: | ||
![]() |
||
![]() |
We will find a uniform sampling distribution for a sphere of radius r. First we must compute the marginal and conditional density functions. These are given by: |
|
![]() |
|
|
| Marginal Density | ||
| Conditional Density | ||
| Now we use these to find the sampling function by integrating and inverting: | ||
![]() |
||
| NOTE: (1- 2u1) can be replaced by -2u1 | ||
| Where u1 and u2 are randomly generated points | ||
| Finally, we can convert to rectilinear coordinates by the standard transformations from spherical to rectilinear coordinates: | ||
![]() |
||
| In general it is a good idea to sample points in and around the mirror direction for glossy surfaces. This is because this is where the high frequencies occur in the image. For more diffuse areas, the BRDF is changing very slowly and so a low sample rate will suffice. However, this assumes that there is a large enough light source for this. If the light source is too small, then even though the glossy points are being sampled well, it can easily be the case that they are not even contributing much to the resulting image becuase little light is hitting them. In this case, the diffuse areas may be receiving a lot of light, but since the sample rate has been reduced there, imperfections will occur in the image. So, for small light sources, it is more efficient to send rays to the light source rather than biasing the glossiness. |