Skip to content

Commit

Permalink
Configure tikz externalize
Browse files Browse the repository at this point in the history
This should speed up local build process
  • Loading branch information
StuckiSimon committed Aug 13, 2024
1 parent 1baf9b1 commit 3164cf1
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 0 deletions.
2 changes: 2 additions & 0 deletions report/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@
*.bbl
*.blg
*.run.xml
*.auxlock

main.pdf
main.txt

__latexindent_temp.tex
3 changes: 3 additions & 0 deletions report/externalized-figures/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
*.md5
*.dpth
*.pdf
19 changes: 19 additions & 0 deletions report/parts/theory.tex
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ \subsubsection{Vectors}

\begin{figure}[H]
\centering
\tikzsetnextfilename{cross-product}
\begin{tikzpicture}
\coordinate (O) at (0,0);
\coordinate (P) at (0,1);
Expand Down Expand Up @@ -82,6 +83,7 @@ \subsubsection{Triangle}

\begin{figure}[H]
\centering
\tikzsetnextfilename{q-u-v-parameterization}
\begin{tikzpicture}
\draw[fill=lightgray] (0,0) coordinate[label=below:$Q$] (q) --
(2,1) coordinate[label=right:$v$] (v) --
Expand Down Expand Up @@ -135,6 +137,7 @@ \subsubsection{Integral}

\begin{figure}[H]
\centering
\tikzsetnextfilename{integral}
\begin{tikzpicture}
\begin{axis}[
width=0.4\textwidth,
Expand Down Expand Up @@ -193,6 +196,7 @@ \subsubsection{Probability Theory}
\begin{figure}[H]
\begin{subfigure}[b]{0.4\textwidth}
\centering
\tikzsetnextfilename{pdf-theory}
\begin{tikzpicture}
\begin{axis}[
width=4cm,
Expand All @@ -218,6 +222,7 @@ \subsubsection{Probability Theory}
\hfill
\begin{subfigure}[b]{0.4\textwidth}
\centering
\tikzsetnextfilename{cdf-theory}
\begin{tikzpicture}
\begin{axis}[
width=4cm,
Expand Down Expand Up @@ -249,6 +254,7 @@ \subsubsection{Bachmann-Landau Notation}

\begin{figure}[H]
\centering
\tikzsetnextfilename{big-o-visualization}
\begin{tikzpicture}
\begin{axis}[
width=0.4\textwidth,
Expand Down Expand Up @@ -352,6 +358,7 @@ \subsubsection{Generalization}
\begin{figure}[H]
\centering
\begin{subfigure}[t]{0.45\textwidth}
\tikzsetnextfilename{reflection-lobe-intro-diffuse}
\begin{tikzpicture}
\coordinate (A) at (0,3);
\coordinate (AA) at (1,2);
Expand Down Expand Up @@ -379,6 +386,7 @@ \subsubsection{Generalization}
\end{subfigure}
\hfill
\begin{subfigure}[t]{0.45\textwidth}
\tikzsetnextfilename{reflection-lobe-intro-specular}
\begin{tikzpicture}
\coordinate (A) at (0,3);
\coordinate (AA) at (1,2);
Expand Down Expand Up @@ -495,6 +503,7 @@ \subsection{Ray Tracing}
\centering
\begin{subfigure}[t]{0.45\textwidth}
\centering
\tikzsetnextfilename{recursive-ray-tracing}
\begin{tikzpicture}
\coordinate (A) at (0,2);
\coordinate (AB) at (0.5,1.5);
Expand Down Expand Up @@ -542,6 +551,7 @@ \subsection{Ray Tracing}
\hfill
\begin{subfigure}[t]{0.45\textwidth}
\centering
\tikzsetnextfilename{recursive-tree}
\begin{tikzpicture}
\coordinate (A0) at (0,1);
\coordinate (A0A) at (0,0.75);
Expand Down Expand Up @@ -624,6 +634,7 @@ \subsubsection{Monte Carlo Integration}
\begin{figure}[H]
\centering
\begin{subfigure}[t]{0.45\textwidth}
\tikzsetnextfilename{material-sampling-bad}
\begin{tikzpicture}
\coordinate (A) at (0,3);
\coordinate (AA) at (1,2);
Expand Down Expand Up @@ -659,6 +670,7 @@ \subsubsection{Monte Carlo Integration}
\end{subfigure}
\hfill
\begin{subfigure}[t]{0.45\textwidth}
\tikzsetnextfilename{material-sampling-good}
\begin{tikzpicture}
\coordinate (A) at (0,3);
\coordinate (AA) at (1,2);
Expand Down Expand Up @@ -703,6 +715,7 @@ \subsubsection{Monte Carlo Integration}
\begin{figure}[H]
\centering
\begin{subfigure}[t]{0.45\textwidth}
\tikzsetnextfilename{light-sampling-bad}
\begin{tikzpicture}
\coordinate (A) at (0,3);
\coordinate (AA) at (1,2);
Expand Down Expand Up @@ -736,6 +749,7 @@ \subsubsection{Monte Carlo Integration}
\end{subfigure}
\hfill
\begin{subfigure}[t]{0.45\textwidth}
\tikzsetnextfilename{light-sampling-good}
\begin{tikzpicture}
\coordinate (A) at (0,3);
\coordinate (AA) at (1,2);
Expand Down Expand Up @@ -1030,6 +1044,7 @@ \subsubsection{Core Concepts}

\begin{figure}[H]
\centering
\tikzsetnextfilename{webgpu-arch}
\begin{tikzpicture}[
abstract/.style={rectangle, draw=rblue, ultra thick, fill=rbblue, inner sep=0.4cm},
concrete/.style={rectangle, draw=rgreen, ultra thick, fill=rbgreen, inner sep=0.4cm},
Expand Down Expand Up @@ -1187,6 +1202,7 @@ \subsection*{Runtime Formats}
\begin{figure}[H]
\centering
\resizebox{0.6\textwidth}{!}{
\tikzsetnextfilename{gltf-hierarchy}
\begin{tikzpicture}[
unused/.style={rectangle, draw=gray, ultra thick, inner sep=0.2cm, text width=2.5cm, align=center},
structure/.style={rectangle, draw=rblue, ultra thick, fill=rbblue, inner sep=0.2cm, text width=2.5cm, align=center},
Expand Down Expand Up @@ -1249,6 +1265,7 @@ \subsection{BxDF}
\begin{figure}[H]
\centering
\begin{subfigure}[t]{0.45\textwidth}
\tikzsetnextfilename{reflection-retroreflective}
\begin{tikzpicture}
\coordinate (A) at (0,3);
\coordinate (AA) at (1,2);
Expand Down Expand Up @@ -1278,6 +1295,7 @@ \subsection{BxDF}
\end{subfigure}
\hfill
\begin{subfigure}[t]{0.45\textwidth}
\tikzsetnextfilename{reflection-glossy}
\begin{tikzpicture}
\coordinate (A) at (0,3);
\coordinate (AA) at (1,2);
Expand Down Expand Up @@ -1371,6 +1389,7 @@ \subsubsection{Formalism}

\begin{figure}[H]
\centering
\tikzsetnextfilename{open-pbr}
\begin{tikzpicture}[
every node/.style={font=\small},
layer/.style={draw, minimum height=1.4cm, minimum width=2.5cm, anchor=south west, text width=2cm, align=center},
Expand Down
3 changes: 3 additions & 0 deletions report/preamble.tex
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,9 @@
\usepgfplotslibrary{fillbetween}
\tikzset{every picture/.style={/utils/exec={\bfseries}}}

\usetikzlibrary{external}
\tikzexternalize[prefix=externalized-figures/]

% Draw arc centered on point
% Syntax: [draw options] (center) (initial angle:final angle:radius)
% Source: https://tex.stackexchange.com/questions/66216/draw-arc-in-tikz-when-center-of-circle-is-specified
Expand Down

0 comments on commit 3164cf1

Please sign in to comment.