*** Wartungsfenster jeden ersten Mittwoch vormittag im Monat ***

Skip to content
Snippets Groups Projects
Commit 3415627b authored by Adam Celarek's avatar Adam Celarek
Browse files

update assignment sheet

parent 0e9719a0
No related branches found
No related tags found
No related merge requests found
......@@ -13,11 +13,11 @@
\deadline{2021-04-18 23:59}%2020-05-13 23:59
\teaser{
\hspace*{\fill}
\includegraphics[trim={1cm 1cm 1cm 1cm},clip,width=0.32\linewidth]{figures/ref_cbox_ao_uniform.png}
\includegraphics[trim={1cm 1cm 1cm 1cm},clip,width=0.32\linewidth]{figures/cbox_ao_uniform.png}
\hfill
\includegraphics[trim={1cm 1cm 1cm 1cm},clip,width=0.32\linewidth]{figures/ref_cbox_direct_mesh_surface.png}
\includegraphics[trim={1cm 1cm 1cm 1cm},clip,width=0.32\linewidth]{figures/cbox_direct_mesh_surface.png}
\hfill
\includegraphics[trim={1cm 1cm 1cm 1cm},clip,width=0.32\linewidth]{figures/ref_cbox_path_tracer_parallelogram.png}
\includegraphics[trim={1cm 1cm 1cm 1cm},clip,width=0.32\linewidth]{figures/cbox_path_tracer_mesh.png}
\hspace*{\fill}
\label{fig:figintro}
}
......@@ -116,7 +116,7 @@ You can also use our provided unit tests locally (maybe you have to edit the pyt
You should base your code on \texttt{integrator\_ao.cpp} and implement it in \\
\texttt{integrator\_direct\_lighting.cpp}.
\paragraph*{Task 1} Implement the emitter interface (make either a \texttt{parallelogram\_emitter} or \texttt{mesh\_emitter}) and the supporting machinery.
\paragraph*{Task 1} Implement the emitter interface (create either a \texttt{parallelogram\_emitter} or \texttt{mesh\_emitter}) and the supporting machinery.
Emitters need to read their brightness (radiance) and colour from the scene file and store it (this is the least).
A name and debug info might also be good.
If you don't plan to implement the direct sampling, you can use a dummy implementation for Emitter::pdf() and Emitter::sample().
......@@ -130,8 +130,8 @@ If you hit a regular surface instead, make a random ray cast using uniform hemis
If the closest intersected object is a light, compute its contribution using the equations from the lecture, otherwise return zero (black).
This is only a small edit from the \texttt{ao} integrator.
\subsection{Direct light sampling (6 points)}
Direct light sampling, is also important for performant path tracers (it's called "next event estimation" there).
\subsection{Light surface sampling (6 points)}
Light surface sampling is important for performant path tracers (it's called "next event estimation" or "direct light sampling" there).
You will need to sample area lights directly, i.e., you need a function to randomly pick points on the surface of the light.
There are 2 options here:
......@@ -184,41 +184,17 @@ Create a new integrator and call it \texttt{path\_tracer\_recursive}(\texttt{.cp
Start with a copy of the direct lighting integrator.
It might pay off to keep your code clean and make small refactorings while working on it.
\paragraph*{Task 1, starter code (5 easy points)}
\paragraph*{Task 1, Start (5 easy points)}
Use the pseudo code from the path tracing lecture slides.
Create an additional \texttt{Li} function, that also keeps track of the current depth.
Now you can use the pseudo code from the lecture as a template to implement a simple path tracer.
\begin{verbatim}
Li(Scene scene, Ray ray, int depth) {
Color value = 0;
if (!findIntersection(scene, ray))
return value;
Intersection its = getIntersection(scene, ray);
// Take care of emittance
if (isLightSource(its))
value += getLightRadiance(its);
if(depth >= 3)
return value;
// Generally, the BRDF should decide on the next ray (e.g. for specular
// reflections). For now you can assume white diffuse BRDF and uniform
// hemisphere sampling. Therefore, replace the code as you see fit.
BRDF brdf = getBRDF(its);
Color brdfValue = sampleBrdf(brdf, -ray, wo);
// Call recursively for indirect lighting
value += brdfValue * Li(scene, wo, depth + 1);
return value;
}
\end{verbatim}
For the first task, you only have to implement a fixed depth recursion.
You can choose to use a constant in code, or a parameter, but the default must be a depth of 3.
And you can observe how the image becomes more realistic as you increase the depth.
\paragraph*{Task 2, Russian Roulette (1 easy and 2 normal points)}
Implement Russian Roulette with a minimum depth of 4 according to the slides.
This must be parametrised from the scene file.
It's probably easier to implement first a version with fixed probabilities (1 Point).
But the proper way to do it is to keep track of the \textit{throughput}.
......
assignments_2021/assignment1_path_tracing/figures/cbox_ao_uniform.png

361 KiB

assignments_2021/assignment1_path_tracing/figures/cbox_direct_mesh_surface.png

149 KiB

assignments_2021/assignment1_path_tracing/figures/cbox_path_tracer_mesh.png

585 KiB

assignments_2021/assignment1_path_tracing/figures/ref_cbox_ao_uniform.png

403 KiB

0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment