diff --git a/assignments_2022/assignment0_intro/figures/bunny_normal.png b/assignments_2022/assignment0_intro/figures/bunny_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..e7afa902a8d54f448da5dc96c0bea56198274adc Binary files /dev/null and b/assignments_2022/assignment0_intro/figures/bunny_normal.png differ diff --git a/assignments_2022/assignment0_intro/main.tex b/assignments_2022/assignment0_intro/main.tex new file mode 100644 index 0000000000000000000000000000000000000000..d937a642d3f802470e460995e323a0ef44bb1110 --- /dev/null +++ b/assignments_2022/assignment0_intro/main.tex @@ -0,0 +1,64 @@ +\documentclass{rtg} + +\usepackage{graphicx} +\usepackage{xspace} +\usepackage{subcaption} +\newcommand{\OpenGL}{OpenGL\xspace} + + +\title{Assignment 0: Setting up Nori (1 point)} +\deadline{2021-03-31 23:59} +\teaser{ +\hspace*{\fill} +\includegraphics[width=0.42\linewidth]{figures/untitled.png} +\hspace*{\fill} +\label{fig:figintro} +} + +\setcounter{section}{1} + +\begin{document} + +\maketitle + +In this task, you will take your first steps with Nori and create your first integrator. + +\section*{Setting up Nori (1 point)} +Download the framework provided in the submission GitLab and set up a working environment. +You will at least need \texttt{git}, \texttt{cmake} and a reasonably recent version of a good C++ compiler (MSVC, gcc or similar). +Get to know Nori by following the steps for Assignment 1 at \url{https://wjakob.github.io/nori/}. +You can skip the instructions regarding GitHub and GitHub classroom since we use our own GitLab (\url{https://submission.cg.tuwien.ac.at}). +Your first steps will look something like: +\begin{verbatim} +git clone git@submission.cg.tuwien.ac.at:Your/Repository.git assignments +cd assignments +git submodule update --init --recursive +cd .. +mkdir assignments_build # or continue with your IDE of choice.. +cd assignments_build +cmake -S ../assignments -B ./ +make -j8 +\end{verbatim} +Make sure to implement the \texttt{NormalIntegrator} class as instructed. +However, instead of using the \texttt{abs} function for the integrated color value, compute it as $\frac{n}{2} + 0.5$. +This makes debugging easier, but obviously the resulting image will look different. +Note that our test files are in slightly different locations. +The bunny test files are located in \texttt{scenes/assignment0}. + + +\subsection*{Submission format} + +%To be announced. +\input{submission.tex} + + +\subsection*{Words of wisdom} +\begin{itemize} +\item The framework is using Eigen under the hood for vectors and matrices etc. Be careful when using \texttt{auto} in your code \href{https://eigen.tuxfamily.org/dox/TopicPitfalls.html}{(Read here why)}. +\item If you have questions, please use TUWEL, but refrain from posting critical code sections. +\item To reduce the waiting time, Nori runs multi-threaded by default. To make debugging easier, you will want to set the number of threads to 1. To do so, simply execute Nori with the additional arguments \texttt{-t 1}. +\end{itemize} + +\end{document} + + diff --git a/assignments_2022/assignment0_intro/math.sty b/assignments_2022/assignment0_intro/math.sty new file mode 100644 index 0000000000000000000000000000000000000000..baee2134995a388ef323cba87c6efc1f9b5c9677 --- /dev/null +++ b/assignments_2022/assignment0_intro/math.sty @@ -0,0 +1,40 @@ + + + +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{math}[2013/10/22 v0.1 vector math] + +\usepackage{amsmath} +\usepackage{amssymb} +\usepackage{amsfonts} + + +\DeclareMathOperator{\const}{const} + +\DeclareMathOperator{\ld}{ld} + +\newcommand{\mvec}[1]{\begin{bmatrix}#1\end{bmatrix}} +\newcommand{\mmat}[1]{\begin{bmatrix}#1\end{bmatrix}} + +\renewcommand{\vec}[1]{\mathrm{\mathbf{#1}}} +\newcommand{\mat}[1]{\mathrm{\mathbf{#1}}} + +\newcommand{\T}[1]{{#1}^T} + +\newcommand{\abs}[1]{\left|#1\right|} + +\newcommand{\length}[1]{\left\|#1\right\|} +\newcommand{\nrm}[1]{\frac{#1}{\length{#1}}} + +\newcommand{\cross}{\times} + +\newcommand{\expect}[1]{\E\left\{#1\right\}} + +\newcommand{\qed}{\hfill\ensuremath{\Box}} + +\newcommand{\N}{\mathbb{N}} +\newcommand{\R}{\mathbb{R}} +\newcommand{\Z}{\mathbb{Z}} + +\newcommand{\wildcard}{{}\cdot{}} + diff --git a/assignments_2022/assignment0_intro/rtg.bib b/assignments_2022/assignment0_intro/rtg.bib new file mode 100644 index 0000000000000000000000000000000000000000..f45c230ad9f1e17d93c9247ee993e6cefa4f129c --- /dev/null +++ b/assignments_2022/assignment0_intro/rtg.bib @@ -0,0 +1,20 @@ + +@book{rtr, + title = {Real-Time Rendering}, + edition = {3}, + author = {Akenine-Möller, Tomas and Haines, Eric and Hoffman, Naty}, + isbn = {978-1-56881-424-7}, + year = {2008}, + publisher = {A K Peters} +} + +@book{lengyel2004mathematics, + title = {Mathematics for 3D Game Programming and Computer Graphics}, + edition = {2}, + author = {Lengyel, Eric}, +% editor = {Pallai, David}, +% series = {Game Development Series}, + isbn = {1-58450-277-0}, + year = {2004}, + publisher = {Charles River Media} +} diff --git a/assignments_2022/assignment0_intro/rtg.cls b/assignments_2022/assignment0_intro/rtg.cls new file mode 100644 index 0000000000000000000000000000000000000000..58e74c5de8958af257916c9a0015e8ed3de3f47f --- /dev/null +++ b/assignments_2022/assignment0_intro/rtg.cls @@ -0,0 +1,188 @@ + + + +\NeedsTeXFormat{LaTeX2e} +\ProvidesClass{rtg}[2013/09/16 v0.1 rtg document] + + +\LoadClass[a4paper,11pt,parskip]{scrartcl} + +\addtokomafont{caption}{\small} +\setcapindent{0pt} + + +\RequirePackage[utf8]{inputenc} +\RequirePackage[T1]{fontenc} + +\RequirePackage[english]{babel} + +\RequirePackage{fouriernc} +\RequirePackage{helvet} +\RequirePackage{zi4} + +\RequirePackage{hyperref} +\RequirePackage{microtype} + + +%\AtBeginDocument{ +% \hypersetup{ +% pdftitle={\@title}, +% pdfauthor={\@author}, +% pdfkeywords={\@keywords} +% } +%} + + +\def\deadline#1{\gdef\@deadline{#1}} +%\deadline{} + +\newcommand{\teaser}[1]{\gdef\@teaser{#1}} +%\teaser{} + +\renewcommand{\maketitle}{% +\begin{center} + \@ifundefined{@teaser}{\vspace*{12ex}}{ + \small + \@teaser + \vspace*{10ex} \\ + } + \textsf{\bfseries\huge\@title} \\ + \@ifundefined{@deadline}{}{ + \vspace{1ex} + \textsf{Deadline: \@deadline} \\ + } + \vspace{7ex} +\end{center} +} + + + +\RequirePackage{math} + +\RequirePackage{csquotes} +\RequirePackage{collectbox} +\RequirePackage{xspace} +\RequirePackage{listings} +\RequirePackage{color} + +\usepackage[backend=biber,style=numeric,sorting=nyt,maxbibnames=99]{biblatex} + +\definecolor{dkgreen}{rgb}{0,0.6,0} +\definecolor{gray}{rgb}{0.5,0.5,0.5} +\definecolor{mauve}{rgb}{0.58,0,0.82} +\definecolor{dkred}{rgb}{0.6,0.0,0} +\definecolor{teal}{rgb}{0.0,0.5,0.5} +\definecolor{turquoise}{rgb}{0.1,0.60,0.60} + + +\lstdefinelanguage{GLSL} +{ + morekeywords=[1]{const, in, out, attribute, uniform, varying, buffer, shared, centroid, sample, patch}, + morekeywords=[4]{void, bool, int, uint, float, double, vec2, vec3, vec4, dvec2, dvec3, dvec4, bvec2, bvec3, bvec4, ivec2, ivec3, ivec4, uvec2, uvec3, uvec4, mat2, mat3, mat4, mat2x2, mat2x3, mat2x4, mat3x2, mat3x3, mat3x4, mat4x2, mat4x3, mat4x4, dmat2, dmat3, dmat4, dmat2x2, dmat2x3, dmat2x4, dmat3x2, dmat3x3, dmat3x4, dmat4x2, dmat4x3, dmat4x4}, + morekeywords=[5]{sampler1D, image1D, sampler2D, image2D, sampler3D, image3D, samplerCube, imageCube, sampler2DRect, image2DRect, sampler1DArray, image1DArray, sampler2DArray, image2DArray, samplerBuffer, imageBuffer, sampler2DMS, image2DMS, sampler2DMSArray, image2DMSArray, samplerCubeArray, imageCubeArray, sampler1DShadow, sampler2DShadow, sampler2DRectShadow, sampler1DArrayShadow, sampler2DArrayShadow, samplerCubeShadow, samplerCubeArrayShadow, isampler1D, iimage1D, isampler2D, iimage2D, isampler3D, iimage3D, isamplerCube, iimageCube, isampler2DRect, iimage2DRect, isampler2DArray, iimage2DArray, isamplerBuffer, iimageBuffer, isampler2DMS, iimage2DMS, isampler2DMSArray, iimage2DMSArray, isamplerCubeArray, iimageCubeArray, usampler1D, uimage1D, usampler2D, uimage2D, usampler3D, uimage3D, usamplerCube, uimageCube, usampler2DRect, uimage2DRect, usampler2DArray, uimage2DArray, usamplerBuffer, uimageBuffer, usampler2DMS, uimage2DMS, usampler2DMSArray, uimage2DMSArray, usamplerCubeArray, uimageCubeArray, atomic_uint} + morecomment=[l]{//}, + morecomment=[s]{/*}{*/}, +} + +\lstdefinelanguage{WavefrontOBJ} +{ + morecomment=[l]{\#} +} + + +\lstdefinestyle{listing} +{ +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1]\color{blue}, + keywordstyle=[4]\color{blue}, + keywordstyle=[5]\color{blue}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=single, + numbers=left, + numberstyle=\ttfamily\small\color{gray}, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false, +} + +\lstdefinestyle{inlinecode}{% +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1], %\color{black}, + keywordstyle=[4], %\color{black}, + keywordstyle=[5], %\it\color{black}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=none, + numbers=none, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false +} + +\lstdefinestyle{declaration}{% +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1]\color{blue}, + keywordstyle=[4]\color{blue}, + keywordstyle=[5]\it\color{blue}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=none, + numbers=none, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false +} + +\lstnewenvironment{declaration}[1][C++]{% + \lstset{style=declaration,language=#1}% + \collectbox{% + \begin{center}% + \BOXCONTENT% + \end{center}% + }\bgroup +} +{ +\egroup +} + +\lstnewenvironment{declarationleft}[1][C++]{% + \lstset{style=declaration,language=#1}% + \collectbox{% + \begin{flushleft}% + \BOXCONTENT% + \end{flushleft}% + }\bgroup +} +{ +\egroup +} + +\lstnewenvironment{code}[1][C++]{% + \lstset{style=listing,language=#1}% +}{} + +\newcommand{\icode}[1]{\texttt{#1}} +\newcommand{\id}[1]{\texttt{#1}} +\newcommand{\type}[1]{\texttt{#1}} + +\newcommand{\filename}[1]{«\texttt{#1}»} +\newcommand{\fspath}[1]{«\texttt{#1}»} + +\newcommand{\term}[1]{\emph{#1}} + +\newcommand{\eg}{e.\,g.\xspace} +\newcommand{\ie}{i.\,e.\xspace} +\newcommand{\cf}{cf.\xspace} +\newcommand{\etc}{etc.\xspace} +\newcommand{\etal}{et~al.\xspace} +\newcommand{\na}{n.\,a.\xspace} +\newcommand{\naive}{na\"{\i}ve\xspace} + + diff --git a/assignments_2022/assignment0_intro/submission.tex b/assignments_2022/assignment0_intro/submission.tex new file mode 100644 index 0000000000000000000000000000000000000000..9b443f88e054c24ee9421d06f5b6e21e7cbc1cc8 --- /dev/null +++ b/assignments_2022/assignment0_intro/submission.tex @@ -0,0 +1,21 @@ +To store or submit your code, please use our own, institute-hosted submission Gitlab \url{https://submission.cg.tuwien.ac.at}. +You will receive a mail with your account and assignment repository as soon as they are ready. +\textbf{The \texttt{master} branch is for development only.} +You should push there while you are experimenting with the assignment and don't want to lose your work. +Once your solution works and you believe it is ready to be graded, please use the branch \texttt{submission<X>} where \texttt{<X>} is the assignment number. +\textbf{E.g., in order to submit your solution for the intro assignment (0), push to \texttt{submission0}.} + +If you push to a \texttt{submission} branch, the server will trigger automatic compilation and some testing for your code. +You can track the state of new submissions being processed on the GitLab page for your repository under "CI/CD > Pipelines". +If a stage fails, click on it to receive additional output and system information from the executing server. +If everything worked, you will shortly find a report with your test results in the "CI/CD" pipeline section, when checking the artifacts of the "report" stage. +You can submit multiple times until the deadline, but don't clog the system by, e.g., using the submission server for debugging. +The last submission that was pushed before the deadline counts, regardless of the results from automatic testing. They are only meant for your convenience and to provide some automated feedback. + +\textbf{Please make sure to NOT add unnecessary files (project folders, temporary compiler results), as your application will be created from your code and CMake setup only}. Examples of files that are usually relevant: +\begin{itemize} + \item \textbf{changed or added} CMakeLists.txt files + \item \textbf{changed or added} code files (.h, .cpp) + \item \textbf{changed or added} test cases if you want to show off advanced solutions +\end{itemize} +Make sure to keep the directory structure in your submitted archive the same as in the framework. diff --git a/assignments_2022/assignment1_path_tracing/figures/cbox_ao_uniform.png b/assignments_2022/assignment1_path_tracing/figures/cbox_ao_uniform.png new file mode 100644 index 0000000000000000000000000000000000000000..c2a694ead115143b2cb0b91617b2273426746764 Binary files /dev/null and b/assignments_2022/assignment1_path_tracing/figures/cbox_ao_uniform.png differ diff --git a/assignments_2022/assignment1_path_tracing/figures/cbox_direct_mesh_surface.png b/assignments_2022/assignment1_path_tracing/figures/cbox_direct_mesh_surface.png new file mode 100644 index 0000000000000000000000000000000000000000..078144a24034069f123e399f818fbf7435493a72 Binary files /dev/null and b/assignments_2022/assignment1_path_tracing/figures/cbox_direct_mesh_surface.png differ diff --git a/assignments_2022/assignment1_path_tracing/figures/cbox_path_tracer_mesh.png b/assignments_2022/assignment1_path_tracing/figures/cbox_path_tracer_mesh.png new file mode 100644 index 0000000000000000000000000000000000000000..170a51e9bbe84308742b148c4d246cbb33a6afa2 Binary files /dev/null and b/assignments_2022/assignment1_path_tracing/figures/cbox_path_tracer_mesh.png differ diff --git a/assignments_2022/assignment1_path_tracing/main.tex b/assignments_2022/assignment1_path_tracing/main.tex new file mode 100644 index 0000000000000000000000000000000000000000..2d30dfedc84af1a890747277dca9fe51304e70fb --- /dev/null +++ b/assignments_2022/assignment1_path_tracing/main.tex @@ -0,0 +1,278 @@ +\documentclass{rtg} + +\usepackage{graphicx} +\usepackage{xspace} +\usepackage{xcolor} +\usepackage{subcaption} +\newcommand{\OpenGL}{OpenGL\xspace} +\newcommand*\diff{\mathop{}\!\mathrm{d}} +\newcommand{\f}[1]{\operatorname{#1}} +\newcommand{\todo}[1]{\textcolor{red}{\textbf{#1}}} + +\title{Assignment 1: Monte Carlo Integration and Path Tracing} +\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/cbox_ao_uniform.png} +\hfill +\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/cbox_path_tracer_mesh.png} +\hspace*{\fill} +\label{fig:figintro} +} + +\setcounter{section}{0} + +\begin{document} + +\maketitle + +In this assignment you will implement all of the crucial parts to get a Monte Carlo based rendering system. +The result will be 1. an ambient occlusion integrator, 2. a direct light renderer, and 3. a simple path tracer. +The assignments build up upon each other, be sure to test everything before continuing. +For most points in this assignment you can ignore the material BRDF and just assume white diffuse materials ($\rho = \{1,1,1\}$). + +\textbf{We have updated the \texttt{assignments} repository. Please merge all upstream changes before starting to work.} +\begin{verbatim} +git checkout master +git pull +git merge submission1 # just to be sure +git push # just in case something fails, make a backup +git remote add upstream git@submission.cg.tuwien.ac.at:rendering-2020/assignments.git +git pull upstream master +# resolve any merge conflict, or just confirm the merge. +git push +\end{verbatim} + +\textbf{Important:} As you have seen in assignment 0, you have to register a name for your integrators (and any other additions) with Nori framework. Our test system expects pre-defined names and attributes when invoking Nori via your solution. Please study the given scene xml files and choose the correct names for registration. It is recommended that you run the test files for yourself before submission. + +\section{Completing Nori's MC Intestines} +Nori is an almost complete Monte Carlo integrator. +But we have left out some crucial parts for you to complete. +By doing so, you'll get a short tour of the main MC machinery. + +The main loop structure of our renderer looks something like this: +\begin{verbatim} +/* For each pixel and pixel sample */ +for (y=0; y<height; ++y) { + for (x=0; x<width; ++x) { + for (i=0; i<N; ++i) { // N = Target sample count per pixel + ray = compute_random_camera_ray_for_pixel(x, y) + value = Li(ray, other, stuff) + pixel[y][x] += value + } + pixel[y][x] /= N + } +} +\end{verbatim} + +Obviously, the code will be slightly different longer in practise due to parallelisation, filtering (something we will learn later) and general architectural design. +Look into the code, try to understand how things are done and complete the following functions (all changes are a single line): +\begin{description} + \item[main.cpp, renderBlock()] Iterate over all required samples (target count stored in \texttt{sampler}) + \item[block.cpp, ImageBlock::put(Point2f, Color3f)] Accumulate samples and sample count + \item[block.cpp, ImageBlock::toBitmap()] Divide RGB color by accumulated sample count (look at Color4f, if the count is in member \texttt{.w}, there is a function you can use) +\end{description} + +For the normals integrator from last time, these changes shouldn't make a difference. +However, for the techniques that you will implement in this assignment, they provide the basis for proper MC integration to resolve the noise in your images. +Beyond implementing them, make sure that you understand how they interconnect and how Nori converts ray samples into output pixel colors. + +As mentioned during the lecture, beyond the main loop you do not need another sample generating loop inside the integrators. +If you were to do that in a path tracer, there would be the problem of an ever-exploding number of samples (curse of dimensionality). + +\section{Ambient occlusion (3 easy points)} +Implement ambient occlusion! +Its rendering equation is +\begin{align} + L_i(x) = \int_{\Omega} \frac{1}{\pi} \f{V}(x, x + \alpha \omega) \cos(\theta) \diff \omega, +\end{align} +where $L_i$ is the brightness, $x$ a position on the surface, $\f{V}$ the visibility function, $\alpha$ a constant, and $\theta$ the angle between $\omega$ and the surface normal at $x$. +The visibility function is 1 or 0, depending on whether the ray from $x$ to $x+\alpha \omega$ reaches its destination without interference. This is also commonly referred to as a shadow ray. +$\alpha$ should be configurable via XML and default to \texttt{scene->getBoundingBox().getExtents().norm()} if no value is provided (experiment with it!). +$\frac{1}{\pi}$ represents a simple white diffuse BRDF, as we explained in the lecture about light when we talked about the furnace test. + +For integration, you should sample the hemisphere surface around point $x$ uniformly. +Since Nori's main loop already takes care of computing the mean for MC integration, the function should return one sample of the integrand, divided $\f{p}(x)$. The proper value for $\f{p}(x)$ for uniform sampling was discussed in the lecture. +In addition, you will need a function that can turn a uniformly random 2D value between 0 and 1 into a uniform hemisphere sample $\omega$. +This transformation is called warping. +You can draw the 2D random values from the \texttt{sampler}. +Apply the formulas from the lecture or look at \texttt{Vector3f Warp::squareToUniformHemisphere(const Point2f \&sample)} inside \texttt{warp.cpp} and \texttt{warp.h} to generate $\omega$. +Make sure to bring $\omega$ to world space before tracing (\texttt{.shFrame.toWorld}). + +Pay attention to the individual mathematical factors (including those inside $\f{p}(x)$), some of them cancel out and don't need to be computed at all! + +Altogether, this should be about 20 lines in a new \texttt{integrator\_ao.cpp} file (not counting boiler plate code). +Compare results with different sample counts (16, 64, 256...), do you see an improvement? +If not, go back to Completing Nori's MC Intestines! + +\section{Direct lighting (up to 9 Points)} +Check the slides about light and the recaps in Monte Carlo integration and Path Tracing for the correct integrals. +There are two possibilities on how to implement direct lighting: hemisphere sampling and light source sampling. +Hemisphere sampling works well only for very very large lights (sky), while light source sampling works especially well with small lights. +To make sure that both methods can be used, our scenes will contain area lights. +If we had point or directional lights, hemisphere sampling would not work and we could only use light source sampling (can you guess why?). +All these sampling methods can be combined using MIS (you will learn about that later). + +You should start with uniform hemisphere sampling (it's very similar to ambient occlusion in terms of code structure). +Once hemisphere sampling works, you can continue with light source sampling and check whether the two methods converge to the same image when using a high number of samples. +If they don't, you have a bug, since both rendering methods are based on the same physical concepts and should eventually produce the same image (although one might be noisier than the other with low sample counts). + +\subsection{Hemisphere sampling (3 easy points)} +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 (create either a \texttt{parallelogram\_emitter} or \texttt{mesh\_emitter} class) and the supporting machinery. +Emitters need to read their brightness (radiance) and colour from the scene file and store it (minimum requirements for an emitter). +A name and debug info might also be good. +If you don't plan to implement light source sampling, you can use a dummy implementation for \texttt{Emitter::pdf()} and \texttt{Emitter::sample()}. + +\paragraph*{Task 2} +Implement the integrator. +First, you need to check whether the camera ray directly hits a light source (emitter). +If so, return its colour and be done. +This is not completely correct, but you can ignore direct illumination of light sources for now. +If you hit a regular surface instead, cast a random ray according to uniform hemisphere sampling, similar to ambient occlusion (no maximum ray length this time!). +If the closest intersected object is a light, compute its contribution using the equations from the lecture, otherwise return zero (black). +This should only require a small edit from the \texttt{ao} integrator. + +\subsection{Light surface sampling (up to 6 points)} +Light surface sampling is important for performant path tracers. +It's referenced as "next event estimation" or "direct light sampling" there (you will have the chance to implement it in a later assignment). +In contrast to hemisphere sampling, you are not simply shooting rays around the hemisphere and hope to find light. +Instead, you try to connect hit points directly to light sources and check if that connection is possible. +If you implement it, you should see improvements immediately. +You will need to sample area light surfaces, i.e., you need a function to pick uniformly random points on the surface of each light. +There are 2 options, of which you should choose \textbf{one} for your implementation: +\begin{enumerate} + \item \textbf{Parallelogram lights (3 points)} + Parallelograms are very easy to sample uniformly, just use a linear combination $k_1 a + k_2 b$ of its side vectors $a, b$ with coefficients $k_1,k_2$ where $0\leq k_1, k_2 < 1$. Obviously, this option will restrict you to using rather basic light source shapes in your scene. + + \item \textbf{Triangle mesh lights (6 points)} + This can give very cool results, i.e., imagine a glowing mesh. + Mesh sampling is not that hard either: Select the triangle according to its surface area (larger triangles are more often selected). + The implementation in \texttt{nori/dpdf.h} will be useful here. + Once you have selected a triangle, sample a point on it (\url{http://mathworld.wolfram.com/TrianglePointPicking.html}). + + Be careful when you reuse random numbers! Example: 2 triangles, \texttt{s = rand(0, 1) < 0.5} would give you the first triangle. + If you want to reuse \texttt{s} for sampling the position (after using it for discretely sampling the triangle), clearly you will only ever sample the first half of the first and the second half of the second triangle. + In order to avoid artefacts, \texttt{s} needs to be shifted and scaled! + \texttt{DiscretePDF::sampleReuse} is precisely for that. + Later on, you could use it for sampling the light as well (it's enough to query one random light per sample if you normalise properly). + But if you are uncertain, you can always just draw additional fresh random numbers from \texttt{sampler}. + + %More complex samplers would be needed for large meshes, for instance such that do importance sampling based on distance, cosine, etc. + %Please don't go that far for now. +\end{enumerate} +You can get 3 points for parallelogram or 6 points for triangle mesh lights, \textbf{but not both}. + +\paragraph*{Task 3} +Implement sampling. +The parallelogram, mesh, or emitter classes would be good places (your choice). +You need to implement something like \texttt{samplePosition} (taking random numbers, returning a position and its surface normal) and \texttt{pdf} (taking a position and returning the sample probability density). + +\paragraph*{Task 4} +To pick one of the available light sources for sampling, you will need a list of emitters in the scene. +Hook into \texttt{Scene::addChild}. +In our assignments, surface emitters are always children of meshes. +The switch emitter case is for point lights or other emitters without physical surface, you can ignore it for now. +Additionally, the emitter object needs a reference to the geometry (mesh or parallelogram, otherwise the sampling code has no data). +Don't be afraid to add stuff to headers or create new ones, it's your design now. + +\paragraph*{Task 5} +Implement the direct lighting integrator for light source sampling. +Pick a light, either uniformly or according to the emitted light (importance sampling), and then sample a point on its surface. +Once you have a point, cast a shadow ray and compute the contribution, if any ($\f{f}(x)$ divided by joint pdf). +If there are multiple lights, make sure to compensate for the fact that you chose a particular one! +Add a boolean property to allow switching between hemisphere sampling and surface sampling. + +\section{Simple Path Tracing (15 Points + 15 Bonus)} +\subsection{Implement the recursive path tracing algorithm (8 points)} +Create a new integrator and call it \texttt{path\_tracer\_recursive}(\texttt{.cpp}). +Start with a copy of the direct lighting integrator. +It might pay off to keep your code clean so you can easily make small adjustments when we improve it in future assignments. + +\paragraph*{Task 1, Start (5 easy points)} +Start with the pseudocode from the path tracing lecture slides. +Since Nori's main loop has no \texttt{depth} parameter, let \texttt{Li} be a stub that calls an additional, recursive function that can keep track of the current depth. +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 in the scene files, but the default if no parameters are given must be a depth of 3. +During development, you should experiment with this number and 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 guaranteed depth of 4. +Whether or not Russian roulette is used must be parameterisasble via boolean \texttt{rr} from the scene file. +You can start with a version that uses a fixed continuation probability in each bounce (1 Point). Check the slides for details. + +However, the proper way to do it is to keep track of the \textit{throughput}. +With every bounce, the importance emitted from the camera is attenuated, and the probability for continuation should become lower. +You should keep track of this throughput in a Color3f vector, and use its largest coefficient for Russian Roulette (2 Points). Check the slides for details. + +\subsection{Implement and use the Diffuse BRDF / BSDF (2 points)} +Encapsulate uniform hemisphere sampling of diffuse materials in \texttt{diffuse.cpp}. +The test cases already use it, so you can store and use its albedo to generate colour! +These 2 points are only valid in conjunction with a working path tracer. +Check slides for details. + +\subsection{Implement path tracing in a loop (5 points)} +Every recursive algorithm can be written in a loop as well. +Sometimes a stack is needed, but in the path tracer that is not necessary. +The loop form is much friendlier to the processor, and you can avoid stack overflows (which could happen with very deep recursions). + +The code should be pretty similar. +You already keep track of the throughput, if you implemented Russian roulette. +Now you should get roughly something like this: +\begin{verbatim} +Li(Scene scene, Ray ray, int depth) { + Color value = 0; + Color throughput = 1; + // .. some other stuff + + while (true) { + // stuff + throughput *= "something <= 1" + + // stuff + value += throughput * something + + if (something) + break; + } + return value; +} +\end{verbatim} + +You might \textit{break}, or add things to \textit{value} in more than one place, or in a different order. +This is just the basic idea. + +\subsection{Implement a higher-dimensional path tracing effect (15 bonus points)} + +Implement either motion blur or depth-of-field effects. For motion blur, you will need to give something in your scene the ability to move (scene objects, camera). For each path, you will need an additional uniformly random time variable \texttt{t} and consider it when you perform intersection with your scene. To implement depth-of-field, you will need two additional uniformly random \texttt{u,v} variables for each path and consider them in the setup of your camera ray. You can gain 15 bonus points for either effect, \textbf{but not for both}. + +\subsection*{Submission format} + +%To be announced. +\input{submission.tex} + + +\subsection*{Words of wisdom} +\begin{itemize} +\item Remember that you don't need all points to get the best grade. The workload of 3 ECTS counts on taking the exam, which gives a lot of points. +\item Nori provides you with a \texttt{Sampler} that is passed in to the functions that produce the integrator input. Use this class to draw values from a canonic random variable. +\item Be careful of so-called "self-intersections". These happen when you immediately hit the +same surface that you started your ray from, due to +inaccuracies in floating point computations. You can avoid these by +offsetting rays in the normal direction of the surface with a small $\epsilon$. +Use \texttt{Epsilon} defined in \texttt{nori/common.h}. +\item Hemisphere sampling and light source sampling are two methods to compute the same integral. Therefore, given enough samples, they both should converge to the same result. +\item The framework is using Eigen under the hood for vectors and matrices etc. Be careful when using \texttt{auto} in your code \href{https://eigen.tuxfamily.org/dox/TopicPitfalls.html}{(Read here why)}. +\item Please use TUWEL for questions, but refrain from posting critical code sections. +\item You are encouraged to write new test cases to experiment with challenging scenarios. +\item Tracing rays is expensive. You don't want to render high resolution images or complex scenes for testing. You may also want to avoid the \texttt{Debug} mode if you don't actually need it (use a release with debug info build!). +\item To reduce the waiting time, Nori runs multi-threaded by default. To make debugging easier, you will want to set the number of threads to 1. To do so, simply execute Nori with the additional arguments \texttt{-t 1}. +\end{itemize} + +\end{document} + + diff --git a/assignments_2022/assignment1_path_tracing/math.sty b/assignments_2022/assignment1_path_tracing/math.sty new file mode 100644 index 0000000000000000000000000000000000000000..baee2134995a388ef323cba87c6efc1f9b5c9677 --- /dev/null +++ b/assignments_2022/assignment1_path_tracing/math.sty @@ -0,0 +1,40 @@ + + + +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{math}[2013/10/22 v0.1 vector math] + +\usepackage{amsmath} +\usepackage{amssymb} +\usepackage{amsfonts} + + +\DeclareMathOperator{\const}{const} + +\DeclareMathOperator{\ld}{ld} + +\newcommand{\mvec}[1]{\begin{bmatrix}#1\end{bmatrix}} +\newcommand{\mmat}[1]{\begin{bmatrix}#1\end{bmatrix}} + +\renewcommand{\vec}[1]{\mathrm{\mathbf{#1}}} +\newcommand{\mat}[1]{\mathrm{\mathbf{#1}}} + +\newcommand{\T}[1]{{#1}^T} + +\newcommand{\abs}[1]{\left|#1\right|} + +\newcommand{\length}[1]{\left\|#1\right\|} +\newcommand{\nrm}[1]{\frac{#1}{\length{#1}}} + +\newcommand{\cross}{\times} + +\newcommand{\expect}[1]{\E\left\{#1\right\}} + +\newcommand{\qed}{\hfill\ensuremath{\Box}} + +\newcommand{\N}{\mathbb{N}} +\newcommand{\R}{\mathbb{R}} +\newcommand{\Z}{\mathbb{Z}} + +\newcommand{\wildcard}{{}\cdot{}} + diff --git a/assignments_2022/assignment1_path_tracing/rtg.bib b/assignments_2022/assignment1_path_tracing/rtg.bib new file mode 100644 index 0000000000000000000000000000000000000000..f45c230ad9f1e17d93c9247ee993e6cefa4f129c --- /dev/null +++ b/assignments_2022/assignment1_path_tracing/rtg.bib @@ -0,0 +1,20 @@ + +@book{rtr, + title = {Real-Time Rendering}, + edition = {3}, + author = {Akenine-Möller, Tomas and Haines, Eric and Hoffman, Naty}, + isbn = {978-1-56881-424-7}, + year = {2008}, + publisher = {A K Peters} +} + +@book{lengyel2004mathematics, + title = {Mathematics for 3D Game Programming and Computer Graphics}, + edition = {2}, + author = {Lengyel, Eric}, +% editor = {Pallai, David}, +% series = {Game Development Series}, + isbn = {1-58450-277-0}, + year = {2004}, + publisher = {Charles River Media} +} diff --git a/assignments_2022/assignment1_path_tracing/rtg.cls b/assignments_2022/assignment1_path_tracing/rtg.cls new file mode 100644 index 0000000000000000000000000000000000000000..58e74c5de8958af257916c9a0015e8ed3de3f47f --- /dev/null +++ b/assignments_2022/assignment1_path_tracing/rtg.cls @@ -0,0 +1,188 @@ + + + +\NeedsTeXFormat{LaTeX2e} +\ProvidesClass{rtg}[2013/09/16 v0.1 rtg document] + + +\LoadClass[a4paper,11pt,parskip]{scrartcl} + +\addtokomafont{caption}{\small} +\setcapindent{0pt} + + +\RequirePackage[utf8]{inputenc} +\RequirePackage[T1]{fontenc} + +\RequirePackage[english]{babel} + +\RequirePackage{fouriernc} +\RequirePackage{helvet} +\RequirePackage{zi4} + +\RequirePackage{hyperref} +\RequirePackage{microtype} + + +%\AtBeginDocument{ +% \hypersetup{ +% pdftitle={\@title}, +% pdfauthor={\@author}, +% pdfkeywords={\@keywords} +% } +%} + + +\def\deadline#1{\gdef\@deadline{#1}} +%\deadline{} + +\newcommand{\teaser}[1]{\gdef\@teaser{#1}} +%\teaser{} + +\renewcommand{\maketitle}{% +\begin{center} + \@ifundefined{@teaser}{\vspace*{12ex}}{ + \small + \@teaser + \vspace*{10ex} \\ + } + \textsf{\bfseries\huge\@title} \\ + \@ifundefined{@deadline}{}{ + \vspace{1ex} + \textsf{Deadline: \@deadline} \\ + } + \vspace{7ex} +\end{center} +} + + + +\RequirePackage{math} + +\RequirePackage{csquotes} +\RequirePackage{collectbox} +\RequirePackage{xspace} +\RequirePackage{listings} +\RequirePackage{color} + +\usepackage[backend=biber,style=numeric,sorting=nyt,maxbibnames=99]{biblatex} + +\definecolor{dkgreen}{rgb}{0,0.6,0} +\definecolor{gray}{rgb}{0.5,0.5,0.5} +\definecolor{mauve}{rgb}{0.58,0,0.82} +\definecolor{dkred}{rgb}{0.6,0.0,0} +\definecolor{teal}{rgb}{0.0,0.5,0.5} +\definecolor{turquoise}{rgb}{0.1,0.60,0.60} + + +\lstdefinelanguage{GLSL} +{ + morekeywords=[1]{const, in, out, attribute, uniform, varying, buffer, shared, centroid, sample, patch}, + morekeywords=[4]{void, bool, int, uint, float, double, vec2, vec3, vec4, dvec2, dvec3, dvec4, bvec2, bvec3, bvec4, ivec2, ivec3, ivec4, uvec2, uvec3, uvec4, mat2, mat3, mat4, mat2x2, mat2x3, mat2x4, mat3x2, mat3x3, mat3x4, mat4x2, mat4x3, mat4x4, dmat2, dmat3, dmat4, dmat2x2, dmat2x3, dmat2x4, dmat3x2, dmat3x3, dmat3x4, dmat4x2, dmat4x3, dmat4x4}, + morekeywords=[5]{sampler1D, image1D, sampler2D, image2D, sampler3D, image3D, samplerCube, imageCube, sampler2DRect, image2DRect, sampler1DArray, image1DArray, sampler2DArray, image2DArray, samplerBuffer, imageBuffer, sampler2DMS, image2DMS, sampler2DMSArray, image2DMSArray, samplerCubeArray, imageCubeArray, sampler1DShadow, sampler2DShadow, sampler2DRectShadow, sampler1DArrayShadow, sampler2DArrayShadow, samplerCubeShadow, samplerCubeArrayShadow, isampler1D, iimage1D, isampler2D, iimage2D, isampler3D, iimage3D, isamplerCube, iimageCube, isampler2DRect, iimage2DRect, isampler2DArray, iimage2DArray, isamplerBuffer, iimageBuffer, isampler2DMS, iimage2DMS, isampler2DMSArray, iimage2DMSArray, isamplerCubeArray, iimageCubeArray, usampler1D, uimage1D, usampler2D, uimage2D, usampler3D, uimage3D, usamplerCube, uimageCube, usampler2DRect, uimage2DRect, usampler2DArray, uimage2DArray, usamplerBuffer, uimageBuffer, usampler2DMS, uimage2DMS, usampler2DMSArray, uimage2DMSArray, usamplerCubeArray, uimageCubeArray, atomic_uint} + morecomment=[l]{//}, + morecomment=[s]{/*}{*/}, +} + +\lstdefinelanguage{WavefrontOBJ} +{ + morecomment=[l]{\#} +} + + +\lstdefinestyle{listing} +{ +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1]\color{blue}, + keywordstyle=[4]\color{blue}, + keywordstyle=[5]\color{blue}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=single, + numbers=left, + numberstyle=\ttfamily\small\color{gray}, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false, +} + +\lstdefinestyle{inlinecode}{% +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1], %\color{black}, + keywordstyle=[4], %\color{black}, + keywordstyle=[5], %\it\color{black}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=none, + numbers=none, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false +} + +\lstdefinestyle{declaration}{% +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1]\color{blue}, + keywordstyle=[4]\color{blue}, + keywordstyle=[5]\it\color{blue}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=none, + numbers=none, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false +} + +\lstnewenvironment{declaration}[1][C++]{% + \lstset{style=declaration,language=#1}% + \collectbox{% + \begin{center}% + \BOXCONTENT% + \end{center}% + }\bgroup +} +{ +\egroup +} + +\lstnewenvironment{declarationleft}[1][C++]{% + \lstset{style=declaration,language=#1}% + \collectbox{% + \begin{flushleft}% + \BOXCONTENT% + \end{flushleft}% + }\bgroup +} +{ +\egroup +} + +\lstnewenvironment{code}[1][C++]{% + \lstset{style=listing,language=#1}% +}{} + +\newcommand{\icode}[1]{\texttt{#1}} +\newcommand{\id}[1]{\texttt{#1}} +\newcommand{\type}[1]{\texttt{#1}} + +\newcommand{\filename}[1]{«\texttt{#1}»} +\newcommand{\fspath}[1]{«\texttt{#1}»} + +\newcommand{\term}[1]{\emph{#1}} + +\newcommand{\eg}{e.\,g.\xspace} +\newcommand{\ie}{i.\,e.\xspace} +\newcommand{\cf}{cf.\xspace} +\newcommand{\etc}{etc.\xspace} +\newcommand{\etal}{et~al.\xspace} +\newcommand{\na}{n.\,a.\xspace} +\newcommand{\naive}{na\"{\i}ve\xspace} + + diff --git a/assignments_2022/assignment1_path_tracing/submission.tex b/assignments_2022/assignment1_path_tracing/submission.tex new file mode 100644 index 0000000000000000000000000000000000000000..195c6e66113f3e63e2cc4e305a341d5418281693 --- /dev/null +++ b/assignments_2022/assignment1_path_tracing/submission.tex @@ -0,0 +1,23 @@ +\textbf{Put a short PDF or text file called \texttt{submission<X>} into your git root directory and state all the points that you think you should get. This does not need to be long. Also mention the code files, where you implemented something if it is not obvious.} + +To store or submit your code, please use our own, institute-hosted submission Gitlab \url{https://submission.cg.tuwien.ac.at}. +You will receive a mail with your account and assignment repository as soon as they are ready. +The \texttt{master} branch is for development only. +You should push there while you are experimenting with the assignment and don't want to lose your work. +Once your solution works and you believe it is ready to be graded, please use the branch \texttt{submission<X>} where \texttt{<X>} is the assignment number. +E.g., in order to submit your solution for this assignment, push to \texttt{submission1}. + +If you push to a \texttt{submission} branch, the server will trigger automatic compilation and some testing for your code. +You can track the state of new submissions being processed on the GitLab page for your repository under "CI/CD > Pipelines". +If a stage fails, click on it to receive additional output and system information from the executing server. +If everything worked, you will shortly find a report with your test results in the "CI/CD" pipeline section, when checking the artifacts of the "report" stage. +You can submit multiple times until the deadline, but don't clog the system by, e.g., using the submission server for debugging. +The last submission that was pushed before the deadline counts, regardless of the results from automatic testing. They are only meant for your convenience and to provide some automated feedback. + +\textbf{Please make sure to NOT add unnecessary files (project folders, temporary compiler results), as your application will be created from your code and CMake setup only}. Examples of files that are usually relevant: +\begin{itemize} + \item \textbf{changed or added} CMakeLists.txt files + \item \textbf{changed or added} code files (.h, .cpp) + \item \textbf{changed or added} test cases if you want to show off advanced solutions +\end{itemize} +Make sure to keep the directory structure in your submitted archive the same as in the framework. diff --git a/assignments_2022/assignment2_bvh/figures/Capture.PNG b/assignments_2022/assignment2_bvh/figures/Capture.PNG new file mode 100644 index 0000000000000000000000000000000000000000..a9de78083aade14d7c88e57b65ca14b7cb716725 Binary files /dev/null and b/assignments_2022/assignment2_bvh/figures/Capture.PNG differ diff --git a/assignments_2022/assignment2_bvh/figures/Capture2.PNG b/assignments_2022/assignment2_bvh/figures/Capture2.PNG new file mode 100644 index 0000000000000000000000000000000000000000..f90f1f613c6a1a45dbea7c6ab712560813141bd1 Binary files /dev/null and b/assignments_2022/assignment2_bvh/figures/Capture2.PNG differ diff --git a/assignments_2022/assignment2_bvh/figures/cbox-ajax-bunny-pt.png b/assignments_2022/assignment2_bvh/figures/cbox-ajax-bunny-pt.png new file mode 100644 index 0000000000000000000000000000000000000000..4ded8f24c8295c070da50dcbf21a540b4ab0e9e3 Binary files /dev/null and b/assignments_2022/assignment2_bvh/figures/cbox-ajax-bunny-pt.png differ diff --git a/assignments_2022/assignment2_bvh/figures/cbox_ajax_bunny_intersections.png b/assignments_2022/assignment2_bvh/figures/cbox_ajax_bunny_intersections.png new file mode 100644 index 0000000000000000000000000000000000000000..187ef5628633f692dbec16597bc26b3abbcb605f Binary files /dev/null and b/assignments_2022/assignment2_bvh/figures/cbox_ajax_bunny_intersections.png differ diff --git a/assignments_2022/assignment2_bvh/main.tex b/assignments_2022/assignment2_bvh/main.tex new file mode 100644 index 0000000000000000000000000000000000000000..4eda8eed44e6cc38e8d477da7779ad1ad2d37087 --- /dev/null +++ b/assignments_2022/assignment2_bvh/main.tex @@ -0,0 +1,104 @@ + +\documentclass{rtg} + +\usepackage{graphicx} +\usepackage{xspace} +\usepackage{subcaption} +\newcommand{\OpenGL}{OpenGL\xspace} + + +\title{Assignment 2: BVH Building \& Traversal} +\deadline{2021-05-12 23:59} +\teaser{ +\hspace*{\fill} +\includegraphics[trim={1cm 1cm 1cm 1cm},clip,width=0.42\linewidth]{figures/cbox_ajax_bunny_intersections.png} +\hfill +\includegraphics[trim={1cm 1cm 1cm 1cm},clip,width=0.42\linewidth]{figures/cbox-ajax-bunny-pt.png} +\hspace*{\fill} +\label{fig:figintro} +} + +\setcounter{section}{1} + +\begin{document} + +\maketitle + +%\todo{use the normal integrator for debugging. that is the fastest one and you see whether the normals are pointing into the right direction (?)} + +In this task, you will implement a spatial acceleration structure inside the Nori rendering framework. +This will speed up rendering, which is crucial for complex scenes with a lot of geometry. +Proper acceleration structures reduce the number of intersection tests during traversal (see above, red = high, blue = low) and can cut render time, e.g., from 40 minutes to 6 seconds. + +\textbf{We have updated the \texttt{assignments} repository. Please merge all upstream changes before starting to work.} +\begin{verbatim} +git checkout master +git pull +git merge submission1 # just to be sure +git push # just in case something fails, make a backup +git remote add upstream git@submission.cg.tuwien.ac.at:rendering-2020/assignments.git +git pull upstream master +# resolve any merge conflict, or just confirm the merge. +git push +\end{verbatim} + +\section*{BVH Building + Traversal (up to 25 points)} +Use the information provided in the lecture and accompanying slide set to build a reasonably fast BVH. +Implementing the BVH requires adding two behaviors: BVH building and BVH traversal. +Both of these changes can be made in the \texttt{accel.h} and \texttt{accel.cpp} exclusively. +We have added the \texttt{intersection integrator} to Nori. +Using it in your scene will produce a color-coded output (red=high, blue=low, compare with image on page 1), showing you how many ray-triangle intersections were performed during traversal in each pixel. +This should be a good indicator how your acceleration structure is doing in terms of ray tracing performance. +Depending on your effort with BVH building, we will award points as follows: +\begin{description} + \item[Spatial median split] max. 10 pts + \item[Object median split] max. 15 pts + \item[Sweep SAH split] max. 20 pts +\end{description} + +Since there are not that many meshes in our test scenes, it suffices to build a separate BVH for each mesh and perform traversal on them one after the other. + +Using the fast traversal presented in the lecture (checking nearest node first) gives 5\ points. +You should also try to optimize for the overall tracing performance for rendering detailed models like the Ajax. +Caching pre-computed, high-quality BHVs is of course not allowed and will not be useful, since we will run our own tests on your code. +We will make a competition of the solutions that required the least amount of time to build and trace arbitrary scenes! +The results will be published in a hall-of-fame on the rendering website. +We can anonymise your result if you prefer not to leave a trace. +Write a mail to Adam in that case. + +\section*{Bonus Tasks} + +There are also several options for earning additional points. +The information to get started on these can be found in the lecture slides or by checking the references on the last slide: +\begin{description} + \item[Adding a k-d tree variant] +10 pts + \item[Implement dual-split trees] \href{http://www.cemyuksel.com/research/papers/dualsplittrees_i3d2019.pdf}{(click for link)} +10 pts + \item[Build an über BVH over the per-mesh BVHs (layered)] +5 pts + \item[Create a faster solution than our reference builder] +20 pts + \item[Use the provided \texttt{tbb} library to do multi-threaded BVH building] +10 pts +\end{description} + +If you choose to implement one or multiple of the above, please make sure to submit along with your code a \texttt{report.pdf} in the root directory of your repository that explains what you did and how we can enable your alternative solutions. +For testing your layered BVH, you can download a scene from the internet (e.g. blendswap), and use the rudimentary blender export plugin ("ext/plugin"). +If you are tired of waiting for your results or going for the high-score, the last bonus task will be very interesting as it can quickly speed up building by $\times10$ or more, depending on your CPU! +\subsection*{Submission format} + +%To be announced. +\input{submission.tex} + + +\subsection*{Words of wisdom} +\begin{itemize} +\item Remember, that you need at least 15 points for each assignment! +\item The framework is using Eigen under the hood for vectors and matrices etc. Be careful when using \texttt{auto} in your code \href{https://eigen.tuxfamily.org/dox/TopicPitfalls.html}{(Read here why)}. +\item The lecture slides should you provide with the information you need to implement a simple or elaborate BVH. +\item If you are having trouble with performance, consider changing the resolution and/or number of samples for your test cases. +\item If you have questions, please use TUWEL, but refrain from posting critical code sections. +\item You are encouraged to write your own test cases to experiment with challenging scenarios. +\item Tracing rays is expensive. If your acceleration structure is not yet working, you don't want to render high resolution images or complex scenes. You may also want to avoid the \texttt{Debug} mode if you don't actually need it (use a release with debug info build!). +\item To reduce the waiting time, Nori runs multi-threaded by default. To make debugging easier, you will want to set the number of threads to 1. To do so, simply execute Nori with the additional arguments \texttt{-t 1}. +\end{itemize} + +\end{document} + + diff --git a/assignments_2022/assignment2_bvh/math.sty b/assignments_2022/assignment2_bvh/math.sty new file mode 100644 index 0000000000000000000000000000000000000000..baee2134995a388ef323cba87c6efc1f9b5c9677 --- /dev/null +++ b/assignments_2022/assignment2_bvh/math.sty @@ -0,0 +1,40 @@ + + + +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{math}[2013/10/22 v0.1 vector math] + +\usepackage{amsmath} +\usepackage{amssymb} +\usepackage{amsfonts} + + +\DeclareMathOperator{\const}{const} + +\DeclareMathOperator{\ld}{ld} + +\newcommand{\mvec}[1]{\begin{bmatrix}#1\end{bmatrix}} +\newcommand{\mmat}[1]{\begin{bmatrix}#1\end{bmatrix}} + +\renewcommand{\vec}[1]{\mathrm{\mathbf{#1}}} +\newcommand{\mat}[1]{\mathrm{\mathbf{#1}}} + +\newcommand{\T}[1]{{#1}^T} + +\newcommand{\abs}[1]{\left|#1\right|} + +\newcommand{\length}[1]{\left\|#1\right\|} +\newcommand{\nrm}[1]{\frac{#1}{\length{#1}}} + +\newcommand{\cross}{\times} + +\newcommand{\expect}[1]{\E\left\{#1\right\}} + +\newcommand{\qed}{\hfill\ensuremath{\Box}} + +\newcommand{\N}{\mathbb{N}} +\newcommand{\R}{\mathbb{R}} +\newcommand{\Z}{\mathbb{Z}} + +\newcommand{\wildcard}{{}\cdot{}} + diff --git a/assignments_2022/assignment2_bvh/rtg.bib b/assignments_2022/assignment2_bvh/rtg.bib new file mode 100644 index 0000000000000000000000000000000000000000..f45c230ad9f1e17d93c9247ee993e6cefa4f129c --- /dev/null +++ b/assignments_2022/assignment2_bvh/rtg.bib @@ -0,0 +1,20 @@ + +@book{rtr, + title = {Real-Time Rendering}, + edition = {3}, + author = {Akenine-Möller, Tomas and Haines, Eric and Hoffman, Naty}, + isbn = {978-1-56881-424-7}, + year = {2008}, + publisher = {A K Peters} +} + +@book{lengyel2004mathematics, + title = {Mathematics for 3D Game Programming and Computer Graphics}, + edition = {2}, + author = {Lengyel, Eric}, +% editor = {Pallai, David}, +% series = {Game Development Series}, + isbn = {1-58450-277-0}, + year = {2004}, + publisher = {Charles River Media} +} diff --git a/assignments_2022/assignment2_bvh/rtg.cls b/assignments_2022/assignment2_bvh/rtg.cls new file mode 100644 index 0000000000000000000000000000000000000000..58e74c5de8958af257916c9a0015e8ed3de3f47f --- /dev/null +++ b/assignments_2022/assignment2_bvh/rtg.cls @@ -0,0 +1,188 @@ + + + +\NeedsTeXFormat{LaTeX2e} +\ProvidesClass{rtg}[2013/09/16 v0.1 rtg document] + + +\LoadClass[a4paper,11pt,parskip]{scrartcl} + +\addtokomafont{caption}{\small} +\setcapindent{0pt} + + +\RequirePackage[utf8]{inputenc} +\RequirePackage[T1]{fontenc} + +\RequirePackage[english]{babel} + +\RequirePackage{fouriernc} +\RequirePackage{helvet} +\RequirePackage{zi4} + +\RequirePackage{hyperref} +\RequirePackage{microtype} + + +%\AtBeginDocument{ +% \hypersetup{ +% pdftitle={\@title}, +% pdfauthor={\@author}, +% pdfkeywords={\@keywords} +% } +%} + + +\def\deadline#1{\gdef\@deadline{#1}} +%\deadline{} + +\newcommand{\teaser}[1]{\gdef\@teaser{#1}} +%\teaser{} + +\renewcommand{\maketitle}{% +\begin{center} + \@ifundefined{@teaser}{\vspace*{12ex}}{ + \small + \@teaser + \vspace*{10ex} \\ + } + \textsf{\bfseries\huge\@title} \\ + \@ifundefined{@deadline}{}{ + \vspace{1ex} + \textsf{Deadline: \@deadline} \\ + } + \vspace{7ex} +\end{center} +} + + + +\RequirePackage{math} + +\RequirePackage{csquotes} +\RequirePackage{collectbox} +\RequirePackage{xspace} +\RequirePackage{listings} +\RequirePackage{color} + +\usepackage[backend=biber,style=numeric,sorting=nyt,maxbibnames=99]{biblatex} + +\definecolor{dkgreen}{rgb}{0,0.6,0} +\definecolor{gray}{rgb}{0.5,0.5,0.5} +\definecolor{mauve}{rgb}{0.58,0,0.82} +\definecolor{dkred}{rgb}{0.6,0.0,0} +\definecolor{teal}{rgb}{0.0,0.5,0.5} +\definecolor{turquoise}{rgb}{0.1,0.60,0.60} + + +\lstdefinelanguage{GLSL} +{ + morekeywords=[1]{const, in, out, attribute, uniform, varying, buffer, shared, centroid, sample, patch}, + morekeywords=[4]{void, bool, int, uint, float, double, vec2, vec3, vec4, dvec2, dvec3, dvec4, bvec2, bvec3, bvec4, ivec2, ivec3, ivec4, uvec2, uvec3, uvec4, mat2, mat3, mat4, mat2x2, mat2x3, mat2x4, mat3x2, mat3x3, mat3x4, mat4x2, mat4x3, mat4x4, dmat2, dmat3, dmat4, dmat2x2, dmat2x3, dmat2x4, dmat3x2, dmat3x3, dmat3x4, dmat4x2, dmat4x3, dmat4x4}, + morekeywords=[5]{sampler1D, image1D, sampler2D, image2D, sampler3D, image3D, samplerCube, imageCube, sampler2DRect, image2DRect, sampler1DArray, image1DArray, sampler2DArray, image2DArray, samplerBuffer, imageBuffer, sampler2DMS, image2DMS, sampler2DMSArray, image2DMSArray, samplerCubeArray, imageCubeArray, sampler1DShadow, sampler2DShadow, sampler2DRectShadow, sampler1DArrayShadow, sampler2DArrayShadow, samplerCubeShadow, samplerCubeArrayShadow, isampler1D, iimage1D, isampler2D, iimage2D, isampler3D, iimage3D, isamplerCube, iimageCube, isampler2DRect, iimage2DRect, isampler2DArray, iimage2DArray, isamplerBuffer, iimageBuffer, isampler2DMS, iimage2DMS, isampler2DMSArray, iimage2DMSArray, isamplerCubeArray, iimageCubeArray, usampler1D, uimage1D, usampler2D, uimage2D, usampler3D, uimage3D, usamplerCube, uimageCube, usampler2DRect, uimage2DRect, usampler2DArray, uimage2DArray, usamplerBuffer, uimageBuffer, usampler2DMS, uimage2DMS, usampler2DMSArray, uimage2DMSArray, usamplerCubeArray, uimageCubeArray, atomic_uint} + morecomment=[l]{//}, + morecomment=[s]{/*}{*/}, +} + +\lstdefinelanguage{WavefrontOBJ} +{ + morecomment=[l]{\#} +} + + +\lstdefinestyle{listing} +{ +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1]\color{blue}, + keywordstyle=[4]\color{blue}, + keywordstyle=[5]\color{blue}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=single, + numbers=left, + numberstyle=\ttfamily\small\color{gray}, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false, +} + +\lstdefinestyle{inlinecode}{% +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1], %\color{black}, + keywordstyle=[4], %\color{black}, + keywordstyle=[5], %\it\color{black}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=none, + numbers=none, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false +} + +\lstdefinestyle{declaration}{% +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1]\color{blue}, + keywordstyle=[4]\color{blue}, + keywordstyle=[5]\it\color{blue}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=none, + numbers=none, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false +} + +\lstnewenvironment{declaration}[1][C++]{% + \lstset{style=declaration,language=#1}% + \collectbox{% + \begin{center}% + \BOXCONTENT% + \end{center}% + }\bgroup +} +{ +\egroup +} + +\lstnewenvironment{declarationleft}[1][C++]{% + \lstset{style=declaration,language=#1}% + \collectbox{% + \begin{flushleft}% + \BOXCONTENT% + \end{flushleft}% + }\bgroup +} +{ +\egroup +} + +\lstnewenvironment{code}[1][C++]{% + \lstset{style=listing,language=#1}% +}{} + +\newcommand{\icode}[1]{\texttt{#1}} +\newcommand{\id}[1]{\texttt{#1}} +\newcommand{\type}[1]{\texttt{#1}} + +\newcommand{\filename}[1]{«\texttt{#1}»} +\newcommand{\fspath}[1]{«\texttt{#1}»} + +\newcommand{\term}[1]{\emph{#1}} + +\newcommand{\eg}{e.\,g.\xspace} +\newcommand{\ie}{i.\,e.\xspace} +\newcommand{\cf}{cf.\xspace} +\newcommand{\etc}{etc.\xspace} +\newcommand{\etal}{et~al.\xspace} +\newcommand{\na}{n.\,a.\xspace} +\newcommand{\naive}{na\"{\i}ve\xspace} + + diff --git a/assignments_2022/assignment2_bvh/submission.tex b/assignments_2022/assignment2_bvh/submission.tex new file mode 100644 index 0000000000000000000000000000000000000000..2f266ef18908a5d81f5066c98ce0d7347eee16b6 --- /dev/null +++ b/assignments_2022/assignment2_bvh/submission.tex @@ -0,0 +1,21 @@ +To store or submit your code, please use our own, institute-hosted submission Gitlab \url{https://submission.cg.tuwien.ac.at}. +You will receive a mail with your account and assignment repository as soon as they are ready. +The \texttt{master} branch is for development only. +You should push there while you are experimenting with the assignment and don't want to lose your work. +Once your solution works and you believe it is ready to be graded, please use the branch \texttt{submission<X>} where \texttt{<X>} is the assignment number. +E.g., in order to submit your solution for the first assignment, push to \texttt{submission1}. + +If you push to a \texttt{submission} branch, the server will trigger automatic compilation and some testing for your code. +You can track the state of new submissions being processed on the GitLab page for your repository under "CI/CD > Pipelines". +If a stage fails, click on it to receive additional output and system information from the executing server. +If everything worked, you will shortly find a report with your test results in the "CI/CD" pipeline section, when checking the artifacts of the "report" stage. +You can submit multiple times until the deadline, but don't clog the system by, e.g., using the submission server for debugging. +The last submission that was pushed before the deadline counts, regardless of the results from automatic testing. They are only meant for your convenience and to provide some automated feedback. + +\textbf{Please make sure to NOT add unnecessary files (project folders, temporary compiler results), as your application will be created from your code and CMake setup only}. Examples of files that are usually relevant: +\begin{itemize} + \item \textbf{changed or added} CMakeLists.txt files + \item \textbf{changed or added} code files (.h, .cpp) + \item \textbf{changed or added} test cases if you want to show off advanced solutions +\end{itemize} +Make sure to keep the directory structure in your submitted archive the same as in the framework. diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture.PNG b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture.PNG new file mode 100644 index 0000000000000000000000000000000000000000..7dc807879110a07dd5eb6df95cf89e537a6dc303 Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture.PNG differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture1.PNG b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture1.PNG new file mode 100644 index 0000000000000000000000000000000000000000..1e21ffe281a62d4814ac539f425b71ad3e1c5b8e Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture1.PNG differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture2.PNG b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture2.PNG new file mode 100644 index 0000000000000000000000000000000000000000..217196496c5a522bf945d0b55066a35e3cdd9120 Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture2.PNG differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture3.PNG b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture3.PNG new file mode 100644 index 0000000000000000000000000000000000000000..71082f982562419f453af7dca3c053dd55ae2b09 Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture3.PNG differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture4.PNG b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture4.PNG new file mode 100644 index 0000000000000000000000000000000000000000..c202c0d9530f905c6672deabbf966ee6487290bf Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture4.PNG differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture5.PNG b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture5.PNG new file mode 100644 index 0000000000000000000000000000000000000000..d3ab7095e2dd77f62674fc33dcb2dabf2ded5a5f Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/Capture5.PNG differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax-2arealights.png b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax-2arealights.png new file mode 100644 index 0000000000000000000000000000000000000000..c396077e2fd589478bb9d3be53c13a0de2b21e91 Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax-2arealights.png differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax-ao.png b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax-ao.png new file mode 100644 index 0000000000000000000000000000000000000000..27cbfd470961a7ff878c5d19949083dff118e01d Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax-ao.png differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax-arealight.png b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax-arealight.png new file mode 100644 index 0000000000000000000000000000000000000000..1cbd3cf00d31ade79f0ff4c1812ac5c50c260110 Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax-arealight.png differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_hemi.png b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_hemi.png new file mode 100644 index 0000000000000000000000000000000000000000..f4fac93e27459844855838771ec28ef66bc00664 Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_hemi.png differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_mis.png b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_mis.png new file mode 100644 index 0000000000000000000000000000000000000000..13cb2f09299d586942ba572d43a9e7695fc32dad Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_mis.png differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_pt_cosine.png b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_pt_cosine.png new file mode 100644 index 0000000000000000000000000000000000000000..b2985b8872a49627fc288c977562ce643df00762 Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_pt_cosine.png differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_pt_nee.png b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_pt_nee.png new file mode 100644 index 0000000000000000000000000000000000000000..0fa8c47c38b799f12f39ecb23f8125cc2914bd3f Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_pt_nee.png differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_pt_uniform.png b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_pt_uniform.png new file mode 100644 index 0000000000000000000000000000000000000000..d61f42aef6a42a91f1faf89f2da5dc037888cfe4 Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_pt_uniform.png differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_surface.png b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_surface.png new file mode 100644 index 0000000000000000000000000000000000000000..e0e6e75823d99b93c784bdaf3ca6cf356ca8f24b Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/ajax_surface.png differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/cbox.png b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/cbox.png new file mode 100644 index 0000000000000000000000000000000000000000..7ddd39f1adda5d5636445937358392fef7b1fff9 Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/cbox.png differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/cbox_is.png b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/cbox_is.png new file mode 100644 index 0000000000000000000000000000000000000000..24e1725528ad39f711a32ab51eeddaec866878fa Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/cbox_is.png differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/cbox_nee.png b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/cbox_nee.png new file mode 100644 index 0000000000000000000000000000000000000000..fabe8d6bfa9bd8de52a10318d7052c880d57ab57 Binary files /dev/null and b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/figures/cbox_nee.png differ diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/main.tex b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/main.tex new file mode 100644 index 0000000000000000000000000000000000000000..f338c042e0caa1f5ed37827c0861b6422fa6afb6 --- /dev/null +++ b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/main.tex @@ -0,0 +1,162 @@ +\documentclass{rtg} + +\usepackage{amsmath} +\usepackage{graphicx} +\usepackage{xspace} +\usepackage{subcaption} +\newcommand{\OpenGL}{OpenGL\xspace} +\newcommand*\diff{\mathop{}\!\mathrm{d}} +\newcommand{\f}[1]{\operatorname{#1}} +\newcommand{\todo}[1]{\color[red]{\textbf{#1}}} + +\title{Assignment 3: Importance Sampling} +\deadline{2021-06-02 23:59}%2020-05-13 23:59 +\teaser{ +\hspace*{\fill} +\includegraphics[width=0.32\linewidth]{figures/ajax_pt_uniform.png} +\hfill +\includegraphics[width=0.32\linewidth]{figures/ajax_pt_cosine.png} +\hfill +\includegraphics[width=0.32\linewidth]{figures/ajax_pt_nee.png} +\hspace*{\fill} +\label{fig:figintro} +} + +\setcounter{section}{0} + +\begin{document} + +\maketitle + +In this assignment you will extend the Monte Carlo rendering system from the last assignment with importance sampling of various functions and next event estimation. In the above image, we see what these methods can do: the left scene is rendered with uniform hemisphere sampling. In the center, we use cosine-weighted hemisphere sampling (importance sampling). On the right, we use next event estimation to perform surface sampling in a recursive path tracer. Images were rendered with the same number of samples per pixel (32). + +\textbf{We have updated the \texttt{assignments} repository. Please merge all upstream changes before starting to work.} +\begin{verbatim} +git checkout master +git pull +git merge submission2 # just to be sure +git push # just in case something fails, make a backup +git remote add upstream git@submission.cg.tuwien.ac.at:rendering-2020/assignments.git +git pull upstream master +# resolve any merge conflict, or just confirm the merge. +git push +\end{verbatim} +We also provide a reference implementation for assignment 2, you can download it from TUWEL. + +\section{Sample Warping (7 easy points, 9 bonus points)} +Random numbers are often generated uniformly in the range between 0 and 1. We can combine multiple such random numbers to sample cartesian domains uniformly, but different distributions are needed, e.g., to get uniform distribution in a non-cartesian domain (for recursive rendering, we need to sample the hemisphere for instance), or for importance sampling techniques. This task can be fully solved in \texttt{warp.cpp}. + +The process of \emph{changing} an existing distribution is called warping. +In this assignment, you will start with easily obtainable, canonic random inputs, and convert them to new, useful distributions. +The input to all warping functions are two uniformly distributed ([0, 1)) random numbers, and the output are samples on the target domain. +The input is always a 2D vector with values of two canonical random variables $\xi_1, \xi_2$. + +In many cases, we may have an existing sample and need to obtain its PDF value for a given sampling strategy, thus a method to produce the PDF from input samples is also required. +The input is always a sample $x$, 2D or 3D, for which a PDF value $p(x)$ value should be computed. + +To visualize and check your implementations, we will be using the \texttt{warptest} executable, which is part of the Nori framework. +You should complete several of the warping functions that it tests. +For an introduction on how to use \texttt{warptest} and what each distribution is supposed to do, please refer to the Assignment 3, Part 1 from the Nori home page (\url{https://wjakob.github.io/nori/}). +\textbf{Note that our scoring system is different, please find it below}. +\texttt{SquareToUniformHemisphere} is already there, some of you were already cleverly using it in the first assignment to do uniform hemisphere sampling. + +\begin{description} + \item[squareToTent] 2 points, test your basic Monte Carlo sampling knowledge, \textbf{bonus} + \item[squareToUniformDisk] 3 points, \textbf{required} + + \textbf{Sampling:} + Use the input canonic variables to generate samples $(r,\theta)$ in polar coordinates where $r \in [0, 1)$ and $\theta \in [0, 2\pi)$, such that they are uniformly distributed when transformed to Cartesian coordinates $(x,y)$. + Return the current sample $(x, y)$ at the end of the function body. + + \begin{figure}[h] + \includegraphics[trim={0 0 5cm 1cm},clip,height=4.7cm]{figures/Capture3.png} + \hfill + \includegraphics[trim={0 0 5cm 1cm},clip,height=4.7cm]{figures/Capture2.png} + \caption{Reference solutions for uniformly distributed samples on the unit disk} + \end{figure} + + \textbf{PDF:} The input is a 2D vector with a sample location in Cartesian coordinates $(x,y)$ on a square, with $x,y \in [-1, 1)$ . + Return the proper value for the corresponding result from the uniform distribution PDF $p(x,y)$ on the disk. + Note: For a uniform distribution, the PDF is constant. + Just make sure that the sample location is valid! + + \item[squareToUniformSphere] 2 points, can use it to implement spherical lights, \textbf{bonus} + + \item[squareToCosineHemisphere] 4 points if inversion method, 1 point if Malley's, \textbf{required} + + \textbf{Sampling:} The input is a 2D vector \texttt{sample} that holds values of two canonical random variables $\xi_1, \xi_2$. + Use them to generate samples $(\theta, \phi)$ on the unit hemisphere such that they have a distribution proportional to $\cos(\theta)$ (i.e., more samples the closer we get to the pole of the hemisphere) and convert them to $\omega$ with the transformation for spherical coordinates. + Return the sample $(x,y,z)$ at the end of the function body. + + \begin{figure}[h] + \includegraphics[trim={0 0 5cm 1cm},clip,height=4.7cm]{figures/Capture5.png} + \hfill + \includegraphics[trim={0 0 5cm 1cm},clip,height=4.7cm]{figures/Capture.png} + \end{figure} + + \textbf{PDF:} Input is a 3D vector with a sample location $\omega$ on the unit \textbf{sphere} in Cartesian coordinates $(x,y,z)$ with all values in range $[0, 1)$ and $\sqrt{x^2+y^2+z^2} = 1$ ($z$ is up). + Return the appropriate result for the PDF value $p(\omega)$. + Compute and return the appropriate result for a PDF with distribution $p(\omega) \propto \cos(\theta)$. + + \item[squareToBeckmann] 5 points, used for materials (needed in last assignment!), \textbf{bonus} + + + +\end{description} + +\section{Importance Sampling (18 points, 20 bonus points)} +\paragraph*{Use cosine-weighted hemisphere samples for diffuse materials (8 easy points)} +Use the cosine-weighted hemisphere sampling method, as described in the lecture. First make sure that your direct lighting and path tracing integrators use the diffuse BSDF class appropriately, then extend the diffuse BSDF with cosine-weighted hemisphere sampling. Ideally, you can reuse your warping solutions from the first part of this assignment! The BSDF should switch between using cosine-weighted and uniform hemisphere sampling, depending on the value of the \texttt{use\_cosine} flag provided by each object's material (default: \texttt{false}). Note that this affects both the sampling and PDF computation! Confirm for yourself that cosine-weighted hemisphere sampling can reduce the noise in your scenes. To test this, compare the output of the test scenes that end in \texttt{uniform} with the ones that end in \texttt{cosine}. The latter use cosine-weighted hemisphere sampling and should give slightly cleaner results. + +\paragraph*{Bonus: Multiple Importance Sampling for Direct Lighting (10 points)} +Implement MIS between hemisphere sampling and light surface sampling using the balance heuristic in your direct lighting integrator. +Whether or not MIS is used should be parameterizable via boolean \texttt{mis\_sampling} (default \texttt{false}) in the test files. +Choose between the two sampling strategies with equal proability, generate the sample using the chosen method and compute the sample's probability with both methods. +Make sure that you use the surface's BSDF to generate the hemisphere samples to benefit from cosine-weighted hemisphere sampling if it is enabled by a material. +Then use the equations from the lecture to compute the proper MIS weight. Return the contribution that you would get with the chosen method, multiplied by the MIS weight and a (simple!) compensation term for the choice you made when picking one method over the other. +You should use the balance heuristic, simpler heuristics will count but not give full points. +You can test MIS on the \texttt{ajax-2lights\_dl*.xml} scenes, where you should be able to observe the following: the small area light is better suited for surface sampling, while the larger one is better with cosine-weighted hemisphere sampling, but MIS can give you the best of both worlds. +%The Sponza and San Miguel Scenes also have large skydomes in addition to a sun (but work only with the mesh based sampler). +Feel free to also explore ideas that we didn't describe here (rays that miss are black by default, but you could use a sky colour or an environment map). +These things do not go unseen :) + +\paragraph*{Next Event Estimation (10 points, 10 bonus points)} +Implement next event estimation (NEE) for your diffuse path tracer, according to the lecture slides. It should be active depending on a boolen \texttt{nee} in the test file (default \texttt{false}). +That is, on every bounce, you create one light surface sample and try to connect to compute direct lighting with surface sampling. +Another ray is then sent out to retrieve indirect light in the next bounce. Make sure that you use the BSDF to generate the indirect sample to benefit from cosine-weighted hemisphere sampling of indirect light on materials that use it. +If you implement NEE, be careful not to erroneously count the emittance twice (i.e., first when doing the light surface sampling and then when hitting a light source randomly). +To get a correct image, the emittant surface points that your ray hits should only be considered on the first intersection or if the last material did not support hemisphere sampling (e.g., mirrors!). +For all other light, the illumination is computed via direct lighting, i.e., one bounce in the future (hence, "next event"). +For further details, please see the lecture slides. Just as a heads-up: implementing NEE will dramatically improve the quality of your renderings! In combination with spatial acceleration structures, you should now be able to render impressive scenes fast! To test this, compare the output of the test scenes that end in \texttt{uniform} or \texttt{cosine} with the ones that end in \texttt{nee}. The latter use next event estimation and should give significantly cleaner results. + +If you pay close attention, you may see that NEE is just a very special case of multiple importance sampling! The way that NEE was described in the lecture was using the 0/1 heuristic of MIS: at the first hit, we choose hemisphere sampling for light sources, afterwards we use light surface sampling. Hence, we can say that we use MIS weights for both techniques that are either 0 or 1, depending on the recursion depth. Instead of this 0/1 heuristic, you may also implement NEE with the balance heuristic (10 bonus points). This is a somewhat challenging exercise, not so much in code, but to get to the correct solution mathematically and making sense of it. It is mostly for you to test your limits on combining multiple complex concepts! + +\section{Further Bonus Points} + +\paragraph{Metropolis-Hastings for Cosine-Weighted Hemisphere Sampling (10 points)} +The Metropolis-Hastings algorithm is an advanced and very essential achievement of computer science. It actually enables you to importance-sample functions whose distribution you don't know! +However, depending on the problem you pose it, it might not be the most efficient method for getting a solution. For this task, familiarize yourself with the Metropolis-Hastings algorithm and Metropolis Sampling (Wikipedia and PBR book, chapter 13). Use the Metropolis-Hastings algorithm to perform cosine-weighted hemisphere sampling without relying on a closed-form solution. +How does it compare to your previous solution for cosine-weighted hemisphere sampling? + +\paragraph{Metropolis Light Transport (up to 1000 points)} +Metropolis Sampling is the basis of the Metropolis Light Transport algorithm. If you have too much time on your hands and want to go down as a hero in the history of this lecture, feel free to attempt an implementation of it. Chapter 16 of the PBR book contains some introductory information, but you will have to spend additional effort researching the required backgrounds. For something special like this you may take your time until the end of the semester (or even beyond). Contact us for details if you need further guidance or suggestions. Good luck! + +\section*{Submission format} + +%To be announced. +\input{submission.tex} + +\section*{Words of wisdom} +\begin{itemize} +\item If you are having trouble with performance, consider changing the resolution and/or number of samples for your test cases. +\item The warp tests only check if the samples you generate match the corresponding PDFs you define. Best start with the PDFs and then try to match them with sampling. +\item Hemisphere sampling, next event estimation and MIS are all methods for integrating the same integral. Given enough samples, they all should converge to the same result. +\item If you have questions, please use TUWEL, but refrain from posting critical code sections. +\item You are encouraged to write your own test cases to experiment with challenging scenarios. +\item Tracing rays is expensive. You don't want to render high resolution images or complex scenes for testing. You may also want to avoid the \texttt{Debug} mode if you don't actually need it (use a release with debug info build!). +\item To reduce the waiting time, Nori runs multi-threaded by default. To make debugging easier, you will want to set the number of threads to 1. To do so, simply execute Nori with the additional arguments \texttt{-t 1}. +\end{itemize} + +\end{document} + + diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/math.sty b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/math.sty new file mode 100644 index 0000000000000000000000000000000000000000..baee2134995a388ef323cba87c6efc1f9b5c9677 --- /dev/null +++ b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/math.sty @@ -0,0 +1,40 @@ + + + +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{math}[2013/10/22 v0.1 vector math] + +\usepackage{amsmath} +\usepackage{amssymb} +\usepackage{amsfonts} + + +\DeclareMathOperator{\const}{const} + +\DeclareMathOperator{\ld}{ld} + +\newcommand{\mvec}[1]{\begin{bmatrix}#1\end{bmatrix}} +\newcommand{\mmat}[1]{\begin{bmatrix}#1\end{bmatrix}} + +\renewcommand{\vec}[1]{\mathrm{\mathbf{#1}}} +\newcommand{\mat}[1]{\mathrm{\mathbf{#1}}} + +\newcommand{\T}[1]{{#1}^T} + +\newcommand{\abs}[1]{\left|#1\right|} + +\newcommand{\length}[1]{\left\|#1\right\|} +\newcommand{\nrm}[1]{\frac{#1}{\length{#1}}} + +\newcommand{\cross}{\times} + +\newcommand{\expect}[1]{\E\left\{#1\right\}} + +\newcommand{\qed}{\hfill\ensuremath{\Box}} + +\newcommand{\N}{\mathbb{N}} +\newcommand{\R}{\mathbb{R}} +\newcommand{\Z}{\mathbb{Z}} + +\newcommand{\wildcard}{{}\cdot{}} + diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/rtg.bib b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/rtg.bib new file mode 100644 index 0000000000000000000000000000000000000000..f45c230ad9f1e17d93c9247ee993e6cefa4f129c --- /dev/null +++ b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/rtg.bib @@ -0,0 +1,20 @@ + +@book{rtr, + title = {Real-Time Rendering}, + edition = {3}, + author = {Akenine-Möller, Tomas and Haines, Eric and Hoffman, Naty}, + isbn = {978-1-56881-424-7}, + year = {2008}, + publisher = {A K Peters} +} + +@book{lengyel2004mathematics, + title = {Mathematics for 3D Game Programming and Computer Graphics}, + edition = {2}, + author = {Lengyel, Eric}, +% editor = {Pallai, David}, +% series = {Game Development Series}, + isbn = {1-58450-277-0}, + year = {2004}, + publisher = {Charles River Media} +} diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/rtg.cls b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/rtg.cls new file mode 100644 index 0000000000000000000000000000000000000000..58e74c5de8958af257916c9a0015e8ed3de3f47f --- /dev/null +++ b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/rtg.cls @@ -0,0 +1,188 @@ + + + +\NeedsTeXFormat{LaTeX2e} +\ProvidesClass{rtg}[2013/09/16 v0.1 rtg document] + + +\LoadClass[a4paper,11pt,parskip]{scrartcl} + +\addtokomafont{caption}{\small} +\setcapindent{0pt} + + +\RequirePackage[utf8]{inputenc} +\RequirePackage[T1]{fontenc} + +\RequirePackage[english]{babel} + +\RequirePackage{fouriernc} +\RequirePackage{helvet} +\RequirePackage{zi4} + +\RequirePackage{hyperref} +\RequirePackage{microtype} + + +%\AtBeginDocument{ +% \hypersetup{ +% pdftitle={\@title}, +% pdfauthor={\@author}, +% pdfkeywords={\@keywords} +% } +%} + + +\def\deadline#1{\gdef\@deadline{#1}} +%\deadline{} + +\newcommand{\teaser}[1]{\gdef\@teaser{#1}} +%\teaser{} + +\renewcommand{\maketitle}{% +\begin{center} + \@ifundefined{@teaser}{\vspace*{12ex}}{ + \small + \@teaser + \vspace*{10ex} \\ + } + \textsf{\bfseries\huge\@title} \\ + \@ifundefined{@deadline}{}{ + \vspace{1ex} + \textsf{Deadline: \@deadline} \\ + } + \vspace{7ex} +\end{center} +} + + + +\RequirePackage{math} + +\RequirePackage{csquotes} +\RequirePackage{collectbox} +\RequirePackage{xspace} +\RequirePackage{listings} +\RequirePackage{color} + +\usepackage[backend=biber,style=numeric,sorting=nyt,maxbibnames=99]{biblatex} + +\definecolor{dkgreen}{rgb}{0,0.6,0} +\definecolor{gray}{rgb}{0.5,0.5,0.5} +\definecolor{mauve}{rgb}{0.58,0,0.82} +\definecolor{dkred}{rgb}{0.6,0.0,0} +\definecolor{teal}{rgb}{0.0,0.5,0.5} +\definecolor{turquoise}{rgb}{0.1,0.60,0.60} + + +\lstdefinelanguage{GLSL} +{ + morekeywords=[1]{const, in, out, attribute, uniform, varying, buffer, shared, centroid, sample, patch}, + morekeywords=[4]{void, bool, int, uint, float, double, vec2, vec3, vec4, dvec2, dvec3, dvec4, bvec2, bvec3, bvec4, ivec2, ivec3, ivec4, uvec2, uvec3, uvec4, mat2, mat3, mat4, mat2x2, mat2x3, mat2x4, mat3x2, mat3x3, mat3x4, mat4x2, mat4x3, mat4x4, dmat2, dmat3, dmat4, dmat2x2, dmat2x3, dmat2x4, dmat3x2, dmat3x3, dmat3x4, dmat4x2, dmat4x3, dmat4x4}, + morekeywords=[5]{sampler1D, image1D, sampler2D, image2D, sampler3D, image3D, samplerCube, imageCube, sampler2DRect, image2DRect, sampler1DArray, image1DArray, sampler2DArray, image2DArray, samplerBuffer, imageBuffer, sampler2DMS, image2DMS, sampler2DMSArray, image2DMSArray, samplerCubeArray, imageCubeArray, sampler1DShadow, sampler2DShadow, sampler2DRectShadow, sampler1DArrayShadow, sampler2DArrayShadow, samplerCubeShadow, samplerCubeArrayShadow, isampler1D, iimage1D, isampler2D, iimage2D, isampler3D, iimage3D, isamplerCube, iimageCube, isampler2DRect, iimage2DRect, isampler2DArray, iimage2DArray, isamplerBuffer, iimageBuffer, isampler2DMS, iimage2DMS, isampler2DMSArray, iimage2DMSArray, isamplerCubeArray, iimageCubeArray, usampler1D, uimage1D, usampler2D, uimage2D, usampler3D, uimage3D, usamplerCube, uimageCube, usampler2DRect, uimage2DRect, usampler2DArray, uimage2DArray, usamplerBuffer, uimageBuffer, usampler2DMS, uimage2DMS, usampler2DMSArray, uimage2DMSArray, usamplerCubeArray, uimageCubeArray, atomic_uint} + morecomment=[l]{//}, + morecomment=[s]{/*}{*/}, +} + +\lstdefinelanguage{WavefrontOBJ} +{ + morecomment=[l]{\#} +} + + +\lstdefinestyle{listing} +{ +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1]\color{blue}, + keywordstyle=[4]\color{blue}, + keywordstyle=[5]\color{blue}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=single, + numbers=left, + numberstyle=\ttfamily\small\color{gray}, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false, +} + +\lstdefinestyle{inlinecode}{% +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1], %\color{black}, + keywordstyle=[4], %\color{black}, + keywordstyle=[5], %\it\color{black}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=none, + numbers=none, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false +} + +\lstdefinestyle{declaration}{% +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1]\color{blue}, + keywordstyle=[4]\color{blue}, + keywordstyle=[5]\it\color{blue}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=none, + numbers=none, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false +} + +\lstnewenvironment{declaration}[1][C++]{% + \lstset{style=declaration,language=#1}% + \collectbox{% + \begin{center}% + \BOXCONTENT% + \end{center}% + }\bgroup +} +{ +\egroup +} + +\lstnewenvironment{declarationleft}[1][C++]{% + \lstset{style=declaration,language=#1}% + \collectbox{% + \begin{flushleft}% + \BOXCONTENT% + \end{flushleft}% + }\bgroup +} +{ +\egroup +} + +\lstnewenvironment{code}[1][C++]{% + \lstset{style=listing,language=#1}% +}{} + +\newcommand{\icode}[1]{\texttt{#1}} +\newcommand{\id}[1]{\texttt{#1}} +\newcommand{\type}[1]{\texttt{#1}} + +\newcommand{\filename}[1]{«\texttt{#1}»} +\newcommand{\fspath}[1]{«\texttt{#1}»} + +\newcommand{\term}[1]{\emph{#1}} + +\newcommand{\eg}{e.\,g.\xspace} +\newcommand{\ie}{i.\,e.\xspace} +\newcommand{\cf}{cf.\xspace} +\newcommand{\etc}{etc.\xspace} +\newcommand{\etal}{et~al.\xspace} +\newcommand{\na}{n.\,a.\xspace} +\newcommand{\naive}{na\"{\i}ve\xspace} + + diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/submission.log b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/submission.log new file mode 100644 index 0000000000000000000000000000000000000000..5904845c6b5a4d050217b3769713f36cadce1c9a --- /dev/null +++ b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/submission.log @@ -0,0 +1,1975 @@ +This is pdfTeX, Version 3.14159265-2.6-1.40.21 (TeX Live 2020/Debian) (preloaded format=pdflatex 2022.1.28) 23 FEB 2022 16:25 +entering extended mode + restricted \write18 enabled. + %&-line parsing enabled. +**submission.tex +(./submission.tex +LaTeX2e <2020-10-01> patch level 4 +L3 programming layer <2021-01-09> xparse <2020-03-03> + +! LaTeX Error: Missing \begin{document}. + +See the LaTeX manual or LaTeX Companion for explanation. +Type H <return> for immediate help. + ... + +l.1 ...mplemented something if it is not obvious.} + +You're in trouble here. Try typing <return> to proceed. +If that doesn't work, type X <return> to quit. + +LaTeX Font Info: Font shape `OT1/cmtt/bx/n' in size <10> not available +(Font) Font shape `OT1/cmtt/m/n' tried instead on input line 1. + +Overfull \hbox (38.72212pt too wide) in paragraph at lines 1--2 +[]\OT1/cmr/bx/n/10 Put + [] + + +Overfull \hbox (5.59023pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 a + [] + + +Overfull \hbox (25.8832pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 short + [] + + +Overfull \hbox (23.91653pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 PDF + [] + + +Overfull \hbox (10.48607pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 or + [] + + +Overfull \hbox (20.28462pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 text + [] + + +Overfull \hbox (14.8541pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 file + [] + + +Overfull \hbox (28.74983pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 called + [] + + +Overfull \hbox (68.2494pt too wide) in paragraph at lines 1--2 +\OT1/cmtt/m/n/10 submission<X> + [] + + +Overfull \hbox (19.48601pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 into + [] + + +Overfull \hbox (22.6249pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 your + [] + + +Overfull \hbox (13.4166pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 git + [] + + +Overfull \hbox (21.02768pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 root + [] + + +Overfull \hbox (13.4166pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 di- + [] + + +Overfull \hbox (18.95131pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 rec- + [] + + +Overfull \hbox (21.02768pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 tory + [] + + +Overfull \hbox (18.36794pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 and + [] + + +Overfull \hbox (24.3415pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 state + [] + + +Overfull \hbox (11.97908pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 all + [] + + +Overfull \hbox (16.13187pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 the + [] + + +Overfull \hbox (30.73038pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 points + [] + + +Overfull \hbox (20.92348pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 that + [] + + +Overfull \hbox (17.8888pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 you + [] + + +Overfull \hbox (26.51375pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 think + [] + + +Overfull \hbox (17.8888pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 you + [] + + +Overfull \hbox (32.64703pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 should + [] + + +Overfull \hbox (18.68741pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 get. + [] + + +Overfull \hbox (22.11931pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 This + [] + + +Overfull \hbox (22.26515pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 does + [] + + +Overfull \hbox (16.61102pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 not + [] + + +Overfull \hbox (23.31934pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 need + [] + + +Overfull \hbox (10.22217pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 to + [] + + +Overfull \hbox (11.97911pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 be + [] + + +Overfull \hbox (24.27765pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 long. + [] + + +Overfull \hbox (22.17487pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 Also + [] + + +Overfull \hbox (25.07626pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 men- + [] + + +Overfull \hbox (19.80545pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 tion + [] + + +Overfull \hbox (16.13187pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 the + [] + + +Overfull \hbox (22.84016pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 code + [] + + +Overfull \hbox (22.5846pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 files, + [] + + +Overfull \hbox (29.97209pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 where + [] + + +Overfull \hbox (17.8888pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 you + [] + + +Overfull \hbox (16.61102pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 im- + [] + + +Overfull \hbox (18.68741pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 ple- + [] + + +Overfull \hbox (37.05537pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 mented + [] + + +Overfull \hbox (28.97345pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 some- + [] + + +Overfull \hbox (26.1943pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 thing + [] + + +Overfull \hbox (6.7083pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 if + [] + + +Overfull \hbox (7.66663pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 it + [] + + +Overfull \hbox (7.7305pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 is + [] + + +Overfull \hbox (16.61102pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 not + [] + + +Overfull \hbox (15.97214pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 ob- + [] + + +Overfull \hbox (13.09715pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 vi- + [] + + +Overfull \hbox (19.86932pt too wide) in paragraph at lines 1--2 +\OT1/cmr/bx/n/10 ous. + [] + + +! LaTeX Error: Missing \begin{document}. + +See the LaTeX manual or LaTeX Companion for explanation. +Type H <return> for immediate help. + ... + +l.3 T + o store or submit your code, please use our own, institute-hosted submi... + +You're in trouble here. Try typing <return> to proceed. +If that doesn't work, type X <return> to quit. + +Missing character: There is no T in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no - in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no G in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no b in font nullfont! +! Undefined control sequence. +l.3 ...wn, institute-hosted submission Gitlab \url + {https://submission.cg.tuw... +The control sequence at the end of the top line +of your error message was never \def'ed. If you have +misspelled it (e.g., `\hobx'), type `I' and the correct +spelling (e.g., `I\hbox'). Otherwise just continue, +and I'll forget about whatever was undefined. + +Missing character: There is no h in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no : in font nullfont! +Missing character: There is no / in font nullfont! +Missing character: There is no / in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no Y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no v in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no T in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no v in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no Y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no x in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no ' in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no k in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no O in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no k in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no v in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no E in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no . in font nullfont! + +Overfull \hbox (20.0pt too wide) in paragraph at lines 3--9 +[] + [] + + +Overfull \hbox (31.49973pt too wide) in paragraph at lines 3--9 +\OT1/cmtt/m/n/10 master + [] + + +Overfull \hbox (68.2494pt too wide) in paragraph at lines 3--9 +\OT1/cmtt/m/n/10 submission<X> + [] + + +Overfull \hbox (15.74986pt too wide) in paragraph at lines 3--9 +\OT1/cmtt/m/n/10 <X> + [] + + +Overfull \hbox (57.7495pt too wide) in paragraph at lines 3--9 +\OT1/cmtt/m/n/10 submission1 + [] + + +! LaTeX Error: Missing \begin{document}. + +See the LaTeX manual or LaTeX Companion for explanation. +Type H <return> for immediate help. + ... + +l.10 I + f you push to a \texttt{submission} branch, the server will trigger au... + +You're in trouble here. Try typing <return> to proceed. +If that doesn't work, type X <return> to quit. + +Missing character: There is no I in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no v in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no Y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no k in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no G in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no L in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no " in font nullfont! +Missing character: There is no C in font nullfont! +Missing character: There is no I in font nullfont! +Missing character: There is no / in font nullfont! +Missing character: There is no C in font nullfont! +Missing character: There is no D in font nullfont! +Missing character: There is no > in font nullfont! +Missing character: There is no P in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no " in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no I in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no k in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no v in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no x in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no v in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no I in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no v in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no k in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no " in font nullfont! +Missing character: There is no C in font nullfont! +Missing character: There is no I in font nullfont! +Missing character: There is no / in font nullfont! +Missing character: There is no C in font nullfont! +Missing character: There is no D in font nullfont! +Missing character: There is no " in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no k in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no " in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no " in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no Y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no ' in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no v in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no T in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no g in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no T in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no v in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no v in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no k in font nullfont! +Missing character: There is no . in font nullfont! + +Overfull \hbox (20.0pt too wide) in paragraph at lines 10--16 +[] + [] + + +Overfull \hbox (52.49954pt too wide) in paragraph at lines 10--16 +\OT1/cmtt/m/n/10 submission + [] + + +! LaTeX Error: Missing \begin{document}. + +See the LaTeX manual or LaTeX Companion for explanation. +Type H <return> for immediate help. + ... + +l.17 ...eated from your code and CMake setup only} + . Examples of files that a... + +You're in trouble here. Try typing <return> to proceed. +If that doesn't work, type X <return> to quit. + +Missing character: There is no . in font nullfont! +Missing character: There is no E in font nullfont! +Missing character: There is no x in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no v in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no : in font nullfont! + +Overfull \hbox (51.72342pt too wide) in paragraph at lines 17--18 +[]\OT1/cmr/bx/n/10 Please + [] + + +Overfull \hbox (26.19429pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 make + [] + + +Overfull \hbox (20.93184pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 sure + [] + + +Overfull \hbox (10.22217pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 to + [] + + +Overfull \hbox (25.63875pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 NOT + [] + + +Overfull \hbox (18.36794pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 add + [] + + +Overfull \hbox (16.61102pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 un- + [] + + +Overfull \hbox (20.60406pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 nec- + [] + + +Overfull \hbox (13.6402pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 es- + [] + + +Overfull \hbox (20.93181pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 sary + [] + + +Overfull \hbox (19.39017pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 files + [] + + +Overfull \hbox (40.35397pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 (project + [] + + +Overfull \hbox (22.68044pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 fold- + [] + + +Overfull \hbox (17.73741pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 ers, + [] + + +Overfull \hbox (23.1596pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 tem- + [] + + +Overfull \hbox (16.29158pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 po- + [] + + +Overfull \hbox (21.13184pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 rary + [] + + +Overfull \hbox (24.27765pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 com- + [] + + +Overfull \hbox (22.78462pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 piler + [] + + +Overfull \hbox (13.84023pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 re- + [] + + +Overfull \hbox (30.79425pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 sults), + [] + + +Overfull \hbox (10.1263pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 as + [] + + +Overfull \hbox (22.6249pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 your + [] + + +Overfull \hbox (15.8124pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 ap- + [] + + +Overfull \hbox (16.61102pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 pli- + [] + + +Overfull \hbox (14.53462pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 ca- + [] + + +Overfull \hbox (19.80545pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 tion + [] + + +Overfull \hbox (17.8888pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 will + [] + + +Overfull \hbox (11.97911pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 be + [] + + +Overfull \hbox (18.95131pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 cre- + [] + + +Overfull \hbox (21.72209pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 ated + [] + + +Overfull \hbox (23.58322pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 from + [] + + +Overfull \hbox (22.6249pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 your + [] + + +Overfull \hbox (22.84016pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 code + [] + + +Overfull \hbox (18.36794pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 and + [] + + +Overfull \hbox (35.83313pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 CMake + [] + + +Overfull \hbox (27.0568pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 setup + [] + + +Overfull \hbox (21.40266pt too wide) in paragraph at lines 17--18 +\OT1/cmr/bx/n/10 only + [] + +Missing character: There is no C in font nullfont! +Missing character: There is no M in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no k in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no L in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no x in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! + +Overfull \hbox (40.56921pt too wide) in paragraph at lines 19--20 +\OT1/cmr/bx/n/10 changed + [] + + +Overfull \hbox (10.48607pt too wide) in paragraph at lines 19--20 +\OT1/cmr/bx/n/10 or + [] + + +Overfull \hbox (30.0276pt too wide) in paragraph at lines 19--20 +\OT1/cmr/bx/n/10 added + [] + +Missing character: There is no c in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no ( in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no , in font nullfont! +Missing character: There is no . in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no ) in font nullfont! + +Overfull \hbox (40.56921pt too wide) in paragraph at lines 20--21 +\OT1/cmr/bx/n/10 changed + [] + + +Overfull \hbox (10.48607pt too wide) in paragraph at lines 20--21 +\OT1/cmr/bx/n/10 or + [] + + +Overfull \hbox (30.0276pt too wide) in paragraph at lines 20--21 +\OT1/cmr/bx/n/10 added + [] + +Missing character: There is no t in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no v in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no l in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no s in font nullfont! + +Overfull \hbox (40.56921pt too wide) in paragraph at lines 21--22 +\OT1/cmr/bx/n/10 changed + [] + + +Overfull \hbox (10.48607pt too wide) in paragraph at lines 21--22 +\OT1/cmr/bx/n/10 or + [] + + +Overfull \hbox (30.0276pt too wide) in paragraph at lines 21--22 +\OT1/cmr/bx/n/10 added + [] + +Missing character: There is no M in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no k in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no k in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no p in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no y in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no u in font nullfont! +Missing character: There is no b in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no d in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no c in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no v in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no s in font nullfont! +Missing character: There is no i in font nullfont! +Missing character: There is no n in font nullfont! +Missing character: There is no t in font nullfont! +Missing character: There is no h in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no f in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no a in font nullfont! +Missing character: There is no m in font nullfont! +Missing character: There is no e in font nullfont! +Missing character: There is no w in font nullfont! +Missing character: There is no o in font nullfont! +Missing character: There is no r in font nullfont! +Missing character: There is no k in font nullfont! +Missing character: There is no . in font nullfont! +) +! Emergency stop. +<*> submission.tex + +*** (job aborted, no legal \end found) + + +Here is how much of TeX's memory you used: + 25 strings out of 481126 + 488 string characters out of 5911897 + 269648 words of memory out of 5000000 + 17086 multiletter control sequences out of 15000+600000 + 403906 words of font info for 29 fonts, out of 8000000 for 9000 + 59 hyphenation exceptions out of 8191 + 19i,1n,15p,322b,132s stack positions out of 5000i,500n,10000p,200000b,80000s +! ==> Fatal error occurred, no output PDF file produced! diff --git a/assignments_2022/assignment3_sampling_materials_bits_and_bytes/submission.tex b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/submission.tex new file mode 100644 index 0000000000000000000000000000000000000000..a09694482def0459eb910179f0214058dc7c34db --- /dev/null +++ b/assignments_2022/assignment3_sampling_materials_bits_and_bytes/submission.tex @@ -0,0 +1,23 @@ +\textbf{Put a short PDF or text file called \texttt{submission<X>} into your git root directory and state all the points that you think you should get. This does not need to be long. Also mention the code files, where you implemented something if it is not obvious.} + +To store or submit your code, please use our own, institute-hosted submission Gitlab \url{https://submission.cg.tuwien.ac.at}. +You will receive a mail with your account and assignment repository as soon as they are ready. +The \texttt{master} branch is for development only. +You should push there while you are experimenting with the assignment and don't want to lose your work. +Once your solution works and you believe it is ready to be graded, please use the branch \texttt{submission<X>} where \texttt{<X>} is the assignment number. +E.g., in order to submit your solution for the first assignment, push to \texttt{submission1}. + +If you push to a \texttt{submission} branch, the server will trigger automatic compilation and some testing for your code. +You can track the state of new submissions being processed on the GitLab page for your repository under "CI/CD > Pipelines". +If a stage fails, click on it to receive additional output and system information from the executing server. +If everything worked, you will shortly find a report with your test results in the "CI/CD" pipeline section, when checking the artifacts of the "report" stage. +You can submit multiple times until the deadline, but don't clog the system by, e.g., using the submission server for debugging. +The last submission that was pushed before the deadline counts, regardless of the results from automatic testing. They are only meant for your convenience and to provide some automated feedback. + +\textbf{Please make sure to NOT add unnecessary files (project folders, temporary compiler results), as your application will be created from your code and CMake setup only}. Examples of files that are usually relevant: +\begin{itemize} + \item \textbf{changed or added} CMakeLists.txt files + \item \textbf{changed or added} code files (.h, .cpp) + \item \textbf{changed or added} test cases if you want to show off advanced solutions +\end{itemize} +Make sure to keep the directory structure in your submitted archive the same as in the framework. diff --git a/assignments_2022/assignment4_project/figures/Bild1.png b/assignments_2022/assignment4_project/figures/Bild1.png new file mode 100644 index 0000000000000000000000000000000000000000..c2afb8f6ca7c926524097641078101f47e9df9f6 Binary files /dev/null and b/assignments_2022/assignment4_project/figures/Bild1.png differ diff --git a/assignments_2022/assignment4_project/figures/Bild2.png b/assignments_2022/assignment4_project/figures/Bild2.png new file mode 100644 index 0000000000000000000000000000000000000000..a8c19efdbaf3e1409cd2336589e2661ba38fa014 Binary files /dev/null and b/assignments_2022/assignment4_project/figures/Bild2.png differ diff --git a/assignments_2022/assignment4_project/figures/Bild3.png b/assignments_2022/assignment4_project/figures/Bild3.png new file mode 100644 index 0000000000000000000000000000000000000000..62d3122d8ed48875044697a53795a76ad40a5b19 Binary files /dev/null and b/assignments_2022/assignment4_project/figures/Bild3.png differ diff --git a/assignments_2022/assignment4_project/figures/ajax_dl_surface.png b/assignments_2022/assignment4_project/figures/ajax_dl_surface.png new file mode 100644 index 0000000000000000000000000000000000000000..522d3060181bc4fc3e7dcb7863db115babc90530 Binary files /dev/null and b/assignments_2022/assignment4_project/figures/ajax_dl_surface.png differ diff --git a/assignments_2022/assignment4_project/figures/ajax_dl_surface_ind.png b/assignments_2022/assignment4_project/figures/ajax_dl_surface_ind.png new file mode 100644 index 0000000000000000000000000000000000000000..b410ad08f6e6429e1bae600f42e4b4712354b137 Binary files /dev/null and b/assignments_2022/assignment4_project/figures/ajax_dl_surface_ind.png differ diff --git a/assignments_2022/assignment4_project/figures/cbox-dielectric_pt_nee.png b/assignments_2022/assignment4_project/figures/cbox-dielectric_pt_nee.png new file mode 100644 index 0000000000000000000000000000000000000000..18321a987edd3eb4749d477f5685c80fe1fb2b03 Binary files /dev/null and b/assignments_2022/assignment4_project/figures/cbox-dielectric_pt_nee.png differ diff --git a/assignments_2022/assignment4_project/figures/cbox-mirror_pt_nee.png b/assignments_2022/assignment4_project/figures/cbox-mirror_pt_nee.png new file mode 100644 index 0000000000000000000000000000000000000000..4cae579f3b4138162c6cb30a973e82fac9d6798e Binary files /dev/null and b/assignments_2022/assignment4_project/figures/cbox-mirror_pt_nee.png differ diff --git a/assignments_2022/assignment4_project/figures/cbox_pt_low.png b/assignments_2022/assignment4_project/figures/cbox_pt_low.png new file mode 100644 index 0000000000000000000000000000000000000000..82c46c5ddb8c198a918597fd3de4b9fd2ba39a74 Binary files /dev/null and b/assignments_2022/assignment4_project/figures/cbox_pt_low.png differ diff --git a/assignments_2022/assignment4_project/figures/cbox_pt_low_alias.png b/assignments_2022/assignment4_project/figures/cbox_pt_low_alias.png new file mode 100644 index 0000000000000000000000000000000000000000..22af0dfab7ce4296e5ad987ca7d61ad21a505046 Binary files /dev/null and b/assignments_2022/assignment4_project/figures/cbox_pt_low_alias.png differ diff --git a/assignments_2022/assignment4_project/figures/cornell_box.png b/assignments_2022/assignment4_project/figures/cornell_box.png new file mode 100644 index 0000000000000000000000000000000000000000..3b973c23a9043ba0e303aa04587ad2a0e703f22e Binary files /dev/null and b/assignments_2022/assignment4_project/figures/cornell_box.png differ diff --git a/assignments_2022/assignment4_project/figures/dielectric.png b/assignments_2022/assignment4_project/figures/dielectric.png new file mode 100644 index 0000000000000000000000000000000000000000..52d84eccf3ef79845232ba3102fe06590ce6a8fc Binary files /dev/null and b/assignments_2022/assignment4_project/figures/dielectric.png differ diff --git a/assignments_2022/assignment4_project/figures/phong.png b/assignments_2022/assignment4_project/figures/phong.png new file mode 100644 index 0000000000000000000000000000000000000000..6c01253a00e60aa9f12c86f52fc5d95e719b3625 Binary files /dev/null and b/assignments_2022/assignment4_project/figures/phong.png differ diff --git a/assignments_2022/assignment4_project/figures/warptest_phong_BSDF_with_rot.png b/assignments_2022/assignment4_project/figures/warptest_phong_BSDF_with_rot.png new file mode 100644 index 0000000000000000000000000000000000000000..230925fc3845f7fce7131c7994cff5d6f3806d19 Binary files /dev/null and b/assignments_2022/assignment4_project/figures/warptest_phong_BSDF_with_rot.png differ diff --git a/assignments_2022/assignment4_project/figures/warptest_phong_BSDF_with_rot_and_diffuse.png b/assignments_2022/assignment4_project/figures/warptest_phong_BSDF_with_rot_and_diffuse.png new file mode 100644 index 0000000000000000000000000000000000000000..1564e344443ae2ce31bcdc515d8dc844b4d0033c Binary files /dev/null and b/assignments_2022/assignment4_project/figures/warptest_phong_BSDF_with_rot_and_diffuse.png differ diff --git a/assignments_2022/assignment4_project/figures/warptest_phong_BSDF_without_rot.png b/assignments_2022/assignment4_project/figures/warptest_phong_BSDF_without_rot.png new file mode 100644 index 0000000000000000000000000000000000000000..a53d851464e05dbaee9c3751192f9eb8905a6ae0 Binary files /dev/null and b/assignments_2022/assignment4_project/figures/warptest_phong_BSDF_without_rot.png differ diff --git a/assignments_2022/assignment4_project/figures/warptest_phong_specular.png b/assignments_2022/assignment4_project/figures/warptest_phong_specular.png new file mode 100644 index 0000000000000000000000000000000000000000..beffeeb3e6e1f37d357c1f6aeefbfc994166920c Binary files /dev/null and b/assignments_2022/assignment4_project/figures/warptest_phong_specular.png differ diff --git a/assignments_2022/assignment4_project/main.tex b/assignments_2022/assignment4_project/main.tex new file mode 100644 index 0000000000000000000000000000000000000000..a9681b90e78c758b1058287428dcd339bb719c05 --- /dev/null +++ b/assignments_2022/assignment4_project/main.tex @@ -0,0 +1,331 @@ +\documentclass{rtg} + +\usepackage{amsmath} +\usepackage{graphicx} +\usepackage{xspace} +\usepackage{xcolor} +\usepackage{subcaption} +\newcommand{\OpenGL}{OpenGL\xspace} +\newcommand*\diff{\mathop{}\!\mathrm{d}} +\newcommand{\f}[1]{\operatorname{#1}} +\newcommand{\todo}[1]{\color{red}{\textbf{#1}}} + +\title{Assignment 4: Materials and Appearance} +\deadline{2020-07-02 23:59}%2020-05-13 23:59 +\teaser{ +\hspace*{\fill} +\includegraphics[trim={1cm 0cm 1cm 0cm},clip,width=0.32\linewidth]{figures/Bild1.png} +\hfill +\includegraphics[trim={1cm 0cm 1cm 0cm},clip,width=0.32\linewidth]{figures/Bild2.png} +\hfill +\includegraphics[trim={1.5cm 0cm 1.5cm 0cm},clip,width=0.32\linewidth]{figures/Bild3.png} +\hspace*{\fill} +\label{fig:figintro} +} + +\setcounter{section}{0} + +\begin{document} + +\maketitle + +In this assignment, you will introduce more complex materials than the completely diffuse ones that we handled up until now. You should extend your path tracing solution to support multiple BSDFs, such as mirrors and dielectrics. +Finally, you should try your hand at low-discrepancy sampling and applying different filters to benefit from powerful image reconstruction filters. + +In this final assignment, you are also encouraged to participate in the last competition for the best scenes: show us what great test scenes you can come up with, given the tools provided in the course of the assignments (indirect illumination, mirrors, see-through materials) or any of the features you implemented in addition! + +\textbf{We have updated the \texttt{assignments} repository. Please merge all upstream changes before starting to work.} +\begin{verbatim} +git checkout master +git pull +git merge submission3 # just to be sure +git push # just in case something fails, make a backup +git remote add upstream git@submission.cg.tuwien.ac.at:rendering-2020/assignments.git +git pull upstream master +# resolve any merge conflict, or just confirm the merge. +git push +\end{verbatim} + +\subsection*{Antialiasing (2 Points)} +\begin{figure}[h!] + \hspace{\fill} + \begin{subfigure}{0.48\linewidth} + \includegraphics[width=\linewidth]{figures/cbox_pt_low_alias} + \caption{Sampling pixel center only} + \end{subfigure} + \hfill + \begin{subfigure}{0.48\linewidth} + \includegraphics[width=\linewidth]{figures/cbox_pt_low} + \caption{Sampling over entire pixel} + \end{subfigure} + \hspace{\fill} +\end{figure} +Before we get down to business, let's first get rid of aliasing in our renderings. Until now, we have only ever shot our rays through the center of the pixels. If you have a lower-resolution display or zoomed in on your renderings, you probably saw that they are somewhat jaggy because of this (look at sharp edges, like the bottom of the front box)! We can quickly fix that by running minimalistic antialiasing for the whole pixel: in \texttt{main.cpp}, instead of shooting rays always through the pixel center, make it so that the rays can sample the full pixel width and height! +Also make sure that your changes are stored in \texttt{pixelSample} and then passed to \texttt{block.put}. This will be important later. + +\section{Materials (15 Points + 15 Bonus Points)} +\begin{figure}[h!] + \hspace{\fill} + \begin{subfigure}{0.48\linewidth} + \includegraphics[width=\linewidth]{figures/cbox-mirror_pt_nee} + \caption{Rendering with mirror materials} + \end{subfigure} + \hfill + \begin{subfigure}{0.48\linewidth} + \includegraphics[width=\linewidth]{figures/cbox-dielectric_pt_nee} + \caption{Rendering with mirrors and dielectrics} + \end{subfigure} + \hspace{\fill} +\end{figure} +\subsection{The Dielectric BSDF (10 Points)} +A dielectric BSDF can be used to model transparent objects like glass, diamonds or water. +Implement it according to the lecture on materials or perhaps the course book \href{http://www.pbr-book.org/3ed-2018/Reflection_Models/Specular_Reflection_and_Transmission.html}{PBRT}. +Use the BSDF in \texttt{dielectric.cpp} to make your solution accessible from scene files. +Note that different source use different conventions for the directions and indices of refraction that they reference. You can use any convention you like, but the setup of Nori prefers that \texttt{bRec.wi} should be the negative view ray direction. +The dielectric BSDF cannot give you the medium the view ray is coming from and the one it goes to, you should figure this out yourself. It only provides the index of refraction on the exterior and the interior of the object with the given material. + +One important note: before, we offset our rays before continuing with the next bounce in the direction of the surface normal. But, if you actually \textbf{enter} an object, this is not a good idea! Instead, offset your rays along the negative surface normal. Also, if you want your dielectrics to work with next event estimation, you basically have to treat a hit with them like a hit with a mirror material, because it only reflects / refracts in a single direction. + +While working on dielectrics, you might wonder what the \texttt{BSDFQueryRecord::eta} is for. This is only really necessary when you perform Russian Roulette with throughput. +When light switches media (e.g. vacuum $\rightarrow$ glass), the radiance it carries changes (see slides for details). +This change of density should be included in the BSDF weight that you return from the BSDF \texttt{sample} method. +But, if you use Russian Roulette with throughput, then this may erroneously affect your decision to stop, since the throughput is now no longer strictly going down with every bounce, but may in- or decrease somewhat randomly as you switch between media. +We can counter this by keeping track of the relative eta in addition to the throughput. +After each sampling / evaluation of the BSDF, we can update \texttt{eta *= bRec.eta}, and use it to modify the Russian Roulette survival probability to remove the influence on the estimated throughput from switching between media. For this to remain stable in all scenes, make sure that the other supported materials (diffuse, mirror) set a proper \texttt{bRec.eta = 1} to avoid unexpected behavior. + +\subsection{Next Event Estimation and the Mirror BSDF (5 Points)} +In Nori, you will find a perfect mirror material, which needs special care: +When you are on a surface and compute an outgoing sample, the direction is fixed by the reflection law. +As mentioned during the lecture, this is because the mirror direction distribution is a Dirac delta function (Nori calls them \textbf{discrete} PDFs or measures). +The key conjecture is that no random hemisphere sampling method could ever hit the singular reflection vector for an incoming view ray by accident, so BSDF sampling is imperative for mirror materials. +Only the \texttt{sample} function can be guaranteed to pick the unique and correct reflection direction for the next bounce. +The \texttt{Mirror} class accounts for that by always returning 0 in the \texttt{pdf} function and 0 as the colour when calling \texttt{eval}, and 1 in the \texttt{sample} function if the surface is reflects the view ray. + +If you want mirror materials to play nice with NEE, you need to take special care: for any direction that is not explicitly the reflection vector, the sampling probability is 0, so you simply can't do light source sampling on mirrors. But if you just ignore direct light on mirror materials, the light sources will be missing in mirror reflections! You can achieve 5 points if you make mirror materials work with NEE. + +\subsection{Adding a Microfact BSDF (10 Bonus Points)} + +For some bonus points, you can implement a more complex Microfacet material model, according to the steps outlined in Assignment 5, Part 1 found on the \href{https://wjakob.github.io/nori/#pa5}{Nori webpage}. +This BSDF should give you a linear blend between a diffuse and a Torrance-Sparrow-based specular model. Note that some of the notes on the webpage do not apply: first, there is no default fresnel implementation in our framework; adding it is part of the assignment for implementing dielectrics. Second, the microfacet BRDF and its distribution will not be tested automatically on the server. + +\section{Sampling and Appearance (10 Points + 15 Bonus Points)} + +\subsection{Low-Discrepancy Sampling (9 Points + 10 Bonus Points)} +\begin{figure}[h!] + \hspace{\fill} + \begin{subfigure}{0.45\linewidth} + \includegraphics[width=\linewidth]{figures/ajax_dl_surface_ind} + \caption{Direct lighting with independent sampler} + \end{subfigure} + \hfill + \begin{subfigure}{0.45\linewidth} + \includegraphics[width=\linewidth]{figures/ajax_dl_surface} + \caption{Direct lighting with Halton sampler} + \end{subfigure} + \hspace{\fill} +\end{figure} +Add an additional Halton-based sample generator named \texttt{halton} to your solution. The sampler should be able to produce 2D and 1D sequences, based on Halton low-discrepancy sequences that use the radical inverse. For 2D samples, use a combined base-11,13 Halton sequence and for 1D, use a base-7 Halton sequence. To minimize repeating patterns, you should initialize your Halton sampler states (use three separate state variables) to random values (\texttt{rand()}). Try your implementation on the light surface sampling scene. Usually, such simple samplers should only be used for individual effects (e.g., picking subpixel coordinates for rays), not the full rendering procedure, but direct lighting is simple enough, so it actually works out ok. If you want to break it, you can try it on full path tracing scenes or change 2D sampling to use base-2,3 instead and see what happens! + +For 10 bonus points, implement a sophisticated Halton-based sampling strategy that actually can replace the independent sampler completely! Hints and suggestions for making it work are described in the \href{https://www.pbr-book.org/3ed-2018/Sampling_and_Reconstruction/The_Halton_Sampler}{course book}. Make sure that your renderings with Halton converge to the same result as with the independent sampler! + +\subsection{Support for Filtering (1 Point)} +When you fixed aliasing and computed output colors by integrating values over the whole pixel, you basically used a pixel-sized box filter. +This is easy to implement, but really not a good choice for filtering: the box filter is sometimes jokingly referred to as the worst filter available. +To get support for a few different filters, you need to implement the corresponding suppport in Nori. +Once done, you should experiment with different filters and sample counts, to see what a difference they can make. + +Apart from the theory behind it, which is not too complex, the \textbf{implementation} for supporting separable filters in a tiled renderer is not trivial (it's not that hard either), so we provide the missing code here: +\begin{verbatim} + void ImageBlock::put(const Point2f &_pos, const Color3f &value) { + if (!value.isValid()) { + /* If this happens, go fix your code instead of removing this warning ;) */ + cerr << "Integrator: computed an invalid radiance value: " + << value.toString() << endl; + return; + } + + /* Convert to pixel coordinates within the image block */ + Point2f pos( + _pos.x() - 0.5f - (m_offset.x() - m_borderSize), + _pos.y() - 0.5f - (m_offset.y() - m_borderSize)); + + /* Compute the rectangle of pixels that will need to be updated */ + BoundingBox2i bbox( + Point2i((int) std::ceil(pos.x() - m_filterRadius), + (int) std::ceil(pos.y() - m_filterRadius)), + Point2i((int) std::floor(pos.x() + m_filterRadius), + (int) std::floor(pos.y() + m_filterRadius))); + bbox.clip(BoundingBox2i(Point2i(0, 0), + Point2i((int) cols() - 1, + (int) rows() - 1))); + + /* Lookup values from the pre-rasterized filter */ + for (int x=bbox.min.x(), idx = 0; x<=bbox.max.x(); ++x) + m_weightsX[idx++] = m_filter[(int) (std::abs(x-pos.x()) * m_lookupFactor)]; + for (int y=bbox.min.y(), idx = 0; y<=bbox.max.y(); ++y) + m_weightsY[idx++] = m_filter[(int) (std::abs(y-pos.y()) * m_lookupFactor)]; + + /* Add the colour valuel after filtering to the current estimate. + * Color4f extends the Color3f value by appending a 1. Therefore, + * in the 4th component we are automatically accumulating the filter + * weight. */ + for (int y=bbox.min.y(), yr=0; y<=bbox.max.y(); ++y, ++yr) + for (int x=bbox.min.x(), xr=0; x<=bbox.max.x(); ++x, ++xr) + coeffRef(y, x) += Color4f(value) * m_weightsX[xr] * m_weightsY[yr]; + } +\end{verbatim} + +\subsection{Tone Mapping (5 Bonus Points)} +There is already a basic type of tone mapping in Nori (computations are in float, output is in 8bit integer). Identify that code and extend it with the \href{http://www.cmap.polytechnique.fr/~peyre/cours/x2005signal/hdr_photographic.pdf}{Reinhard operator} for tone mapping, or use something similarly effective. + +\section{Create your own Scene (5 Easy Points + 30 Bonus Points)} + +We would ask you to support us and future participants by preparing comprehensive test scenes that we can use in the next year, for features that you particularly liked. Perhaps you just want to get a little variation in (some of you may not want to see any more bunnies...). Preparing a useful scene will earn you 5 points (awarded only once per person). Scenes should only require a reasonable amount of processing power to be useful for students during development. + +If, however, you also want to go beyond, to the realm where samples don't matter, feel free to get artistic! We will be holding a competition for who can come up with the most impressive scene: you can prepare scenes by combining individual models (please make sure they are not heavily copyrighted) and features that you implemented (mandatory or bonus) in custom Nori test scenes. Aim to get the most impressive renderings that you can manage! We will pick a winner, whose work will earn her/him 30 bonus points, as well as the honor of being exhibited on the course homepage. If you want to participate, this should be an extra scene in addition to the "useful" scene for future students. + +Unless you want to keep them a secret, we encourage you to show off your scenes in TUWEL while you design and refine them to get some feedback! + +\section{I'm all done, now what?} +There is a copious amount of additional bonus points up for grabs this time, check the following sections for details. In addition, you can also find papers or effects on your own and implement them. +We will be generous with bonus points (although you won't really need them anymore if you do that). +If you would like to go for something really ambitious but need an incentive, talk to us, we can give you more time and another 3 ECTS. + +Another thing to keep in mind: if you stick out of the crowd, it is likely we would recommend you for a PhD position either here or at one of the more specialised labs. + +\section{Bonus Tasks (Loads of Points)} + +\subsection{More Materials} +The topic of materials does not stop at the microfacet model. There is a wide range of more complex aspects of objects' physical appearance, and the resulting rendering solutions can become very sophisticated. \href{http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.468.9506&rep=rep1&type=pdf}{Background: Physics and Math of Shading by Naty Hoffman} is a nice didactic introduction and contains a lot of in-depth information. +It is a good read even if you don't want to implement anything! +Naty also has course presentations hosted on Youtube for you to access. +\href{http://www.pbr-book.org/3ed-2018/contents.html}{Our course book} also has a lot of information on materials and even some code (but be aware that the notation and conventions might be different to what Nori uses). + +Ideas for bonus tasks with materials: +\begin{itemize} + \item Implement the (not physically-based) Phong BSDF for glossy materials (see Appendix, 10 Points) + \item Support NEE + MIS with dielectric materials by implementing \href{https://www.ics.uci.edu/~yug10/projects/translucent/papers/Hanika_et_al-2015-Computer_Graphics_Forum.pdf}{manifold next event estimation} (50 Points) + \item A physically correct gold BSDF (all effects described by Naty Hoffman, 20 Points) + \item Fourier Basis BSDFs (from the book, 10 Points) + \item Subsurface scattering (SSS, your own research, 50 Points) +\end{itemize} + +\subsection{More Sampling} +\begin{itemize} + \item Support MIS with mirror materials (10 Points) + \item Adaptive sampling and reconstruction to get more out of the samples you take (e.g. \href{http://graphics.ucsd.edu/~henrik/papers/multidimensional_adaptive_sampling/multidimensional_adaptive_sampling.pdf}{MDAS}, \href{https://cseweb.ucsd.edu/~ravir/Overbeck2009AWR.pdf}{AWR}. 250 Points) + \item Path guiding (2 pass unbiased algorithm, first cast photons into the scene and record important 'incoming directions'. Then, use them for importance sampling. 300 Points) + \item A basic path tracer on the GPU (CUDA, GLSL, HLSL... should be unbiased and support diffuse and specular BRDFs at least. 300 Points) +\end{itemize} + +\subsection{Other Ideas} +\begin{itemize} + \item Textures (UVs are already loaded, you'd need to extend the xml, 40 Points) + \item Light tracing (start the path from the light and connect it to the camera via NEE. You'd have to change stuff in the camera, scene, and main loop. The most important thing would be to hold an additional image block for the whole image plane, because the the ray can hit any pixel. We could give some more hints in TUWEL, just ask! 80 Points) + \item Bidirectional Path Tracing (Light tracing is a good start, we can help in TUWEL. 160 Points) + \item Participating Media (You would have to do your own research. 320 Points) +\end{itemize} + + +\section*{Submission format} + +%To be announced. +\input{submission.tex} + +\section*{Words of wisdom} +\begin{itemize} +\item If you are having trouble with performance, consider changing the resolution and/or number of samples for your test cases. +\item If you have questions, please use TUWEL, but refrain from posting critical code sections. +\item You are encouraged to write your own test cases to experiment with challenging scenarios. +\item Tracing rays is expensive. You don't want to render high resolution images or complex scenes for testing. You may also want to avoid the \texttt{Debug} mode if you don't actually need it (use a release with debug info build!). +\item To reduce the waiting time, Nori runs multi-threaded by default. To make debugging easier, you will want to set the number of threads to 1. To do so, simply execute Nori with the additional arguments \texttt{-t 1}. +\end{itemize} + +\section*{Appendix: The Phong BSDF} +The Phong reflection model is one of the oldest ones. +The original Phong was not even energy conserving, therefore we will implement the modified Phong \href{https://www.cs.princeton.edu/courses/archive/fall03/cs526/papers/lafortune94.pdf}{(Lafortune and Willems, 1994)}. +That report might be a bit hard to read (but doable, and there are some additional variance reducing improvements), so we will distill everything important into a summary. + +Phong is a glossy BSDF, consisting of a diffuse and specular part. The BSDF equation is: +\begin{align} + \f{f_r}(x, v, \omega) &= \f{f_{r,d}}(x, v, \omega) + \f{f_{r,s}}(x, v, \omega) \\ + &= k_d p_d \frac{1}{\pi} + k_s (1-p_d) \frac{n + 2}{2 \pi} \max(0, \cos^n \alpha), +\end{align} +where $\alpha$ is the angle between the perfect specular reflection $r_v$ and $\omega$, $k_d$, and $k_s$ are diffuse and specular albedo, $p_d$ is the percentage of diffuse reflection (as opposed to specular) and $n$ is the shininess (specular exponent). + +The modified phong is not realistic throughout all possible parameter ranges, but it is simple and relatively easy to implement. +As with the diffuse BSDF, we need an evaluation, a sampling, and a pdf function. +It should be straight-forward to write the evaluation function, sampling is a bit harder. + +Because we want to be efficient, we will again try to importance sample this BSDF. At the beginning, we stochastically choose between sampling diffuse and specular part based on $p_d$. +The diffuse part is sampled the same way as with the diffuse BSDF (cosine weighted hemisphere sampling). +The specular (or rather "glossy") part has the following steps: +\begin{itemize} + \item Implement a sample warper for the phong specular lobe. + \item Rotate that lobe, so that $z+$ points into the direction of the perfect reflection vector. + \item Reject all samples that would go below the surface, into the object (careful, see implementation details below). +\end{itemize} + + +\paragraph*{Specular Warping and Pdf} +We can generate samples with the Pdf +\begin{align} + \f{pdf}(\omega) = \frac{n+1}{2 \pi} \cos^n(\alpha) +\end{align} +by using the following warping +\begin{align} + (x, y, z) = \left( \sqrt{1-\xi_1^{\frac{2}{n+1}}} \cos(2\pi\xi_2), \sqrt{1-\xi_1^{\frac{2}{n+1}}} \sin(2\pi\xi_2), \sqrt{1-x^2 - y^2} \right) +\end{align} +You should be able to type that directly into the newly added functions in \texttt{warp.cpp}. Note that this PDF (and the corresponding samples) do not exactly match the specular part of the Phong BSDF. However, sampling it exactly is difficult (perhaps even impossible), so we use a good-enough approximation that mimics the overall function shape. + +\begin{figure}[h!] + \centering + \includegraphics[width=0.9\linewidth]{figures/warptest_phong_specular} + \caption{Phong specular sampling} + \label{fig:warptestphongspecular} +\end{figure} +\begin{figure}[h!] + \centering + \includegraphics[width=0.9\linewidth]{figures/warptest_phong_BSDF_without_rot} + \caption{Phong BSDF without rotation} + \label{fig:warptestphongbsdfwithoutrot} +\end{figure} + + +\begin{figure} + \centering + \includegraphics[width=0.9\linewidth]{figures/warptest_phong_BSDF_with_rot} + \caption{Phong Specular BSDF with rotation} + \label{fig:warptestphongbsdfwithrot} +\end{figure} +\begin{figure} + \centering + \includegraphics[width=0.9\linewidth]{figures/warptest_phong_BSDF_with_rot_and_diffuse} + \caption{Phong BSDF with rotation and diffuse part} + \label{fig:warptestphongbsdfwithrotanddiffuse} +\end{figure} + +\paragraph*{Rotation} +We need to rotate our samples to $r_v$ now, but first we need the direction of perfect reflection $r_v$. +You can copy the steps to compute it from \texttt{mirror.cpp}. +Now, you could construct a rotation matrix based on the angles of the reflection direction. +But that would require expensive calls to $\arccos$ etc. +It is much easier and faster to create an orthonormal basis from the reflection vector. +We even have that already in Nori in the \texttt{Frame} class, usually used to map between world and local shading frame. + +Let's say, the reflection direction is the normal of a reflection frame. +Then our warped sample is also in the reflection frame, and we call \textit{toWorld()} to rotate it into our shading frame. + +Constructing that frame requires the reflection vector (goes in through the 3rd parameter) and 2 vectors orthogonal to it. +The cross product between the reflection vector and a non-parallel vector gives one orthogonal vector, and another cross product the other. The reflection vector will be one axis of the frame. Find a stable way to construct the remaining two axes for an orthonormal basis around the reflection vector. + +\paragraph*{Implementation Details} +\begin{itemize} + \item You need to implement things in \texttt{warp.cpp} and \texttt{phong.cpp}. Use warptest for testing, there is not only a test for the warp, but for the whole BRDF as well. + \item $\cos^n \alpha$ becomes unstable for large exponents, but using our importance sampling method, it appears in the pdf as well, so it cancels out. Use that in your \textit{sample} function. Do not try to do MIS between diffuse/specular part (I tried, it doesn't work). + \item Rejection sampling: Do not create a new sample if the one you got is below the surface after rotation. Instead, clamp the contribution to zero, you can easily do that via the $\cos \theta$ term, which belongs to the BSDF now. The reason is, that it wouldn't be possible to compute a correct pdf value if you did "\texttt{do x = sample(); while(is\_bad(x))}". +\end{itemize} + +\end{document} + + diff --git a/assignments_2022/assignment4_project/math.sty b/assignments_2022/assignment4_project/math.sty new file mode 100644 index 0000000000000000000000000000000000000000..baee2134995a388ef323cba87c6efc1f9b5c9677 --- /dev/null +++ b/assignments_2022/assignment4_project/math.sty @@ -0,0 +1,40 @@ + + + +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{math}[2013/10/22 v0.1 vector math] + +\usepackage{amsmath} +\usepackage{amssymb} +\usepackage{amsfonts} + + +\DeclareMathOperator{\const}{const} + +\DeclareMathOperator{\ld}{ld} + +\newcommand{\mvec}[1]{\begin{bmatrix}#1\end{bmatrix}} +\newcommand{\mmat}[1]{\begin{bmatrix}#1\end{bmatrix}} + +\renewcommand{\vec}[1]{\mathrm{\mathbf{#1}}} +\newcommand{\mat}[1]{\mathrm{\mathbf{#1}}} + +\newcommand{\T}[1]{{#1}^T} + +\newcommand{\abs}[1]{\left|#1\right|} + +\newcommand{\length}[1]{\left\|#1\right\|} +\newcommand{\nrm}[1]{\frac{#1}{\length{#1}}} + +\newcommand{\cross}{\times} + +\newcommand{\expect}[1]{\E\left\{#1\right\}} + +\newcommand{\qed}{\hfill\ensuremath{\Box}} + +\newcommand{\N}{\mathbb{N}} +\newcommand{\R}{\mathbb{R}} +\newcommand{\Z}{\mathbb{Z}} + +\newcommand{\wildcard}{{}\cdot{}} + diff --git a/assignments_2022/assignment4_project/rtg.bib b/assignments_2022/assignment4_project/rtg.bib new file mode 100644 index 0000000000000000000000000000000000000000..f45c230ad9f1e17d93c9247ee993e6cefa4f129c --- /dev/null +++ b/assignments_2022/assignment4_project/rtg.bib @@ -0,0 +1,20 @@ + +@book{rtr, + title = {Real-Time Rendering}, + edition = {3}, + author = {Akenine-Möller, Tomas and Haines, Eric and Hoffman, Naty}, + isbn = {978-1-56881-424-7}, + year = {2008}, + publisher = {A K Peters} +} + +@book{lengyel2004mathematics, + title = {Mathematics for 3D Game Programming and Computer Graphics}, + edition = {2}, + author = {Lengyel, Eric}, +% editor = {Pallai, David}, +% series = {Game Development Series}, + isbn = {1-58450-277-0}, + year = {2004}, + publisher = {Charles River Media} +} diff --git a/assignments_2022/assignment4_project/rtg.cls b/assignments_2022/assignment4_project/rtg.cls new file mode 100644 index 0000000000000000000000000000000000000000..58e74c5de8958af257916c9a0015e8ed3de3f47f --- /dev/null +++ b/assignments_2022/assignment4_project/rtg.cls @@ -0,0 +1,188 @@ + + + +\NeedsTeXFormat{LaTeX2e} +\ProvidesClass{rtg}[2013/09/16 v0.1 rtg document] + + +\LoadClass[a4paper,11pt,parskip]{scrartcl} + +\addtokomafont{caption}{\small} +\setcapindent{0pt} + + +\RequirePackage[utf8]{inputenc} +\RequirePackage[T1]{fontenc} + +\RequirePackage[english]{babel} + +\RequirePackage{fouriernc} +\RequirePackage{helvet} +\RequirePackage{zi4} + +\RequirePackage{hyperref} +\RequirePackage{microtype} + + +%\AtBeginDocument{ +% \hypersetup{ +% pdftitle={\@title}, +% pdfauthor={\@author}, +% pdfkeywords={\@keywords} +% } +%} + + +\def\deadline#1{\gdef\@deadline{#1}} +%\deadline{} + +\newcommand{\teaser}[1]{\gdef\@teaser{#1}} +%\teaser{} + +\renewcommand{\maketitle}{% +\begin{center} + \@ifundefined{@teaser}{\vspace*{12ex}}{ + \small + \@teaser + \vspace*{10ex} \\ + } + \textsf{\bfseries\huge\@title} \\ + \@ifundefined{@deadline}{}{ + \vspace{1ex} + \textsf{Deadline: \@deadline} \\ + } + \vspace{7ex} +\end{center} +} + + + +\RequirePackage{math} + +\RequirePackage{csquotes} +\RequirePackage{collectbox} +\RequirePackage{xspace} +\RequirePackage{listings} +\RequirePackage{color} + +\usepackage[backend=biber,style=numeric,sorting=nyt,maxbibnames=99]{biblatex} + +\definecolor{dkgreen}{rgb}{0,0.6,0} +\definecolor{gray}{rgb}{0.5,0.5,0.5} +\definecolor{mauve}{rgb}{0.58,0,0.82} +\definecolor{dkred}{rgb}{0.6,0.0,0} +\definecolor{teal}{rgb}{0.0,0.5,0.5} +\definecolor{turquoise}{rgb}{0.1,0.60,0.60} + + +\lstdefinelanguage{GLSL} +{ + morekeywords=[1]{const, in, out, attribute, uniform, varying, buffer, shared, centroid, sample, patch}, + morekeywords=[4]{void, bool, int, uint, float, double, vec2, vec3, vec4, dvec2, dvec3, dvec4, bvec2, bvec3, bvec4, ivec2, ivec3, ivec4, uvec2, uvec3, uvec4, mat2, mat3, mat4, mat2x2, mat2x3, mat2x4, mat3x2, mat3x3, mat3x4, mat4x2, mat4x3, mat4x4, dmat2, dmat3, dmat4, dmat2x2, dmat2x3, dmat2x4, dmat3x2, dmat3x3, dmat3x4, dmat4x2, dmat4x3, dmat4x4}, + morekeywords=[5]{sampler1D, image1D, sampler2D, image2D, sampler3D, image3D, samplerCube, imageCube, sampler2DRect, image2DRect, sampler1DArray, image1DArray, sampler2DArray, image2DArray, samplerBuffer, imageBuffer, sampler2DMS, image2DMS, sampler2DMSArray, image2DMSArray, samplerCubeArray, imageCubeArray, sampler1DShadow, sampler2DShadow, sampler2DRectShadow, sampler1DArrayShadow, sampler2DArrayShadow, samplerCubeShadow, samplerCubeArrayShadow, isampler1D, iimage1D, isampler2D, iimage2D, isampler3D, iimage3D, isamplerCube, iimageCube, isampler2DRect, iimage2DRect, isampler2DArray, iimage2DArray, isamplerBuffer, iimageBuffer, isampler2DMS, iimage2DMS, isampler2DMSArray, iimage2DMSArray, isamplerCubeArray, iimageCubeArray, usampler1D, uimage1D, usampler2D, uimage2D, usampler3D, uimage3D, usamplerCube, uimageCube, usampler2DRect, uimage2DRect, usampler2DArray, uimage2DArray, usamplerBuffer, uimageBuffer, usampler2DMS, uimage2DMS, usampler2DMSArray, uimage2DMSArray, usamplerCubeArray, uimageCubeArray, atomic_uint} + morecomment=[l]{//}, + morecomment=[s]{/*}{*/}, +} + +\lstdefinelanguage{WavefrontOBJ} +{ + morecomment=[l]{\#} +} + + +\lstdefinestyle{listing} +{ +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1]\color{blue}, + keywordstyle=[4]\color{blue}, + keywordstyle=[5]\color{blue}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=single, + numbers=left, + numberstyle=\ttfamily\small\color{gray}, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false, +} + +\lstdefinestyle{inlinecode}{% +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1], %\color{black}, + keywordstyle=[4], %\color{black}, + keywordstyle=[5], %\it\color{black}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=none, + numbers=none, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false +} + +\lstdefinestyle{declaration}{% +% language={C++}, + basicstyle=\ttfamily\small, + keywordstyle=[1]\color{blue}, + keywordstyle=[4]\color{blue}, + keywordstyle=[5]\it\color{blue}, + commentstyle=\color{dkgreen}, + stringstyle=\color{mauve}, + frame=none, + numbers=none, + stepnumber=1, + tabsize=2, + showspaces=false, + showstringspaces=false +} + +\lstnewenvironment{declaration}[1][C++]{% + \lstset{style=declaration,language=#1}% + \collectbox{% + \begin{center}% + \BOXCONTENT% + \end{center}% + }\bgroup +} +{ +\egroup +} + +\lstnewenvironment{declarationleft}[1][C++]{% + \lstset{style=declaration,language=#1}% + \collectbox{% + \begin{flushleft}% + \BOXCONTENT% + \end{flushleft}% + }\bgroup +} +{ +\egroup +} + +\lstnewenvironment{code}[1][C++]{% + \lstset{style=listing,language=#1}% +}{} + +\newcommand{\icode}[1]{\texttt{#1}} +\newcommand{\id}[1]{\texttt{#1}} +\newcommand{\type}[1]{\texttt{#1}} + +\newcommand{\filename}[1]{«\texttt{#1}»} +\newcommand{\fspath}[1]{«\texttt{#1}»} + +\newcommand{\term}[1]{\emph{#1}} + +\newcommand{\eg}{e.\,g.\xspace} +\newcommand{\ie}{i.\,e.\xspace} +\newcommand{\cf}{cf.\xspace} +\newcommand{\etc}{etc.\xspace} +\newcommand{\etal}{et~al.\xspace} +\newcommand{\na}{n.\,a.\xspace} +\newcommand{\naive}{na\"{\i}ve\xspace} + + diff --git a/assignments_2022/assignment4_project/submission.tex b/assignments_2022/assignment4_project/submission.tex new file mode 100644 index 0000000000000000000000000000000000000000..fdfd347a80270437ef684877bdad53ba3653da5c --- /dev/null +++ b/assignments_2022/assignment4_project/submission.tex @@ -0,0 +1,23 @@ +\textbf{Put a short PDF or text file called \texttt{submission<X>} into your git root directory and state all the points that you think you should get. This does not need to be long. Also mention the code files, where you implemented something if it is not obvious.} + +To store or submit your code, please use our own, institute-hosted submission Gitlab \url{https://submission.cg.tuwien.ac.at}. +You will receive a mail with your account and assignment repository as soon as they are ready. +The \texttt{master} branch is for development only. +You should push there while you are experimenting with the assignment and don't want to lose your work. +Once your solution works and you believe it is ready to be graded, please use the branch \texttt{submission<X>} where \texttt{<X>} is the assignment number. +E.g., in order to submit your solution for the fourth assignment, push to \texttt{submission4}. + +If you push to a \texttt{submission} branch, the server will trigger automatic compilation and some testing for your code. +You can track the state of new submissions being processed on the GitLab page for your repository under "CI/CD > Pipelines". +If a stage fails, click on it to receive additional output and system information from the executing server. +If everything worked, you will shortly find a report with your test results in the "CI/CD" pipeline section, when checking the artifacts of the "report" stage. +You can submit multiple times until the deadline, but don't clog the system by, e.g., using the submission server for debugging. +The last submission that was pushed before the deadline counts, regardless of the results from automatic testing. They are only meant for your convenience and to provide some automated feedback. + +\textbf{Please make sure to NOT add unnecessary files (project folders, temporary compiler results), as your application will be created from your code and CMake setup only}. Examples of files that are usually relevant: +\begin{itemize} + \item \textbf{changed or added} CMakeLists.txt files + \item \textbf{changed or added} code files (.h, .cpp) + \item \textbf{changed or added} test cases if you want to show off advanced solutions +\end{itemize} +Make sure to keep the directory structure in your submitted archive the same as in the framework.