Commit d1e8ce2e authored by Gaurav Kukreja's avatar Gaurav Kukreja

Final Presentation with OpenGL interop

Signed-off-by: 's avatarGaurav Kukreja <gmkukreja@gmail.com>
parent 1f67342c
......@@ -28,35 +28,59 @@
\@writefile{nav}{\headcommand {\beamer@subsectionpages {1}{2}}}
\@writefile{nav}{\headcommand {\slideentry {1}{0}{3}{3/3}{}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {3}{3}}}
\bibcite{}{\hyperlink {beamerbib}{Chan, 2005}}
\@writefile{toc}{\beamer@sectionintoc {2}{Algorithm}{4}{0}{2}}
\@writefile{nav}{\headcommand {\sectionentry {2}{Algorithm}{4}{Algorithm}{0}}}
\@writefile{nav}{\headcommand {\beamer@sectionpages {3}{3}}}
\@writefile{nav}{\headcommand {\beamer@subsectionpages {3}{3}}}
\@writefile{toc}{\beamer@sectionintoc {3}{CUDA Implementation}{4}{0}{3}}
\@writefile{nav}{\headcommand {\sectionentry {3}{CUDA Implementation}{4}{CUDA Implementation}{0}}}
\@writefile{nav}{\headcommand {\beamer@sectionpages {4}{3}}}
\@writefile{nav}{\headcommand {\beamer@subsectionpages {4}{3}}}
\@writefile{toc}{\beamer@sectionintoc {4}{Optimizations}{4}{0}{4}}
\@writefile{nav}{\headcommand {\sectionentry {4}{Optimizations}{4}{Optimizations}{0}}}
\@writefile{nav}{\headcommand {\beamer@sectionpages {4}{3}}}
\@writefile{nav}{\headcommand {\beamer@subsectionpages {4}{3}}}
\@writefile{toc}{\beamer@subsectionintoc {4}{1}{Texture Memory}{4}{0}{4}}
\@writefile{nav}{\headcommand {\beamer@subsectionentry {0}{4}{1}{4}{Texture Memory}}\headcommand {\beamer@subsectionpages {4}{3}}}
\@writefile{toc}{\beamer@subsectionintoc {4}{2}{OpenGL Interoperability}{4}{0}{4}}
\@writefile{nav}{\headcommand {\beamer@subsectionentry {0}{4}{2}{4}{OpenGL Interoperability}}\headcommand {\beamer@subsectionpages {4}{3}}}
\@writefile{nav}{\headcommand {\slideentry {4}{2}{1}{4/4}{OpenGL Interoperability}{0}}}
\@writefile{toc}{\beamer@subsectionintoc {2}{1}{Binary Image Segmentation}{4}{0}{2}}
\@writefile{nav}{\headcommand {\beamer@subsectionentry {0}{2}{1}{4}{Binary Image Segmentation}}\headcommand {\beamer@subsectionpages {4}{3}}}
\@writefile{nav}{\headcommand {\slideentry {2}{1}{1}{4/4}{Binary Image Segmentation}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {4}{4}}}
\@writefile{nav}{\headcommand {\slideentry {4}{2}{2}{5/5}{OpenGL Interoperability}{0}}}
\@writefile{nav}{\headcommand {\slideentry {2}{1}{2}{5/5}{Binary Image Segmentation}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {5}{5}}}
\@writefile{nav}{\headcommand {\slideentry {4}{2}{3}{6/6}{OpenGL Interoperability}{0}}}
\bibcite{}{\hyperlink {beamerbib}{Chan, 2004}}
\@writefile{toc}{\beamer@subsectionintoc {2}{2}{Grayscale Image Segmentation}{6}{0}{2}}
\@writefile{nav}{\headcommand {\beamer@subsectionentry {0}{2}{2}{6}{Grayscale Image Segmentation}}\headcommand {\beamer@subsectionpages {4}{5}}}
\@writefile{nav}{\headcommand {\slideentry {2}{2}{1}{6/6}{Grayscale Image Segmentation}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {6}{6}}}
\bibcite{p1}{\hyperlink {beamerbibp1}{Smith, 2012}}
\@writefile{nav}{\headcommand {\slideentry {4}{2}{4}{7/7}{OpenGL Interoperability}{0}}}
\@writefile{nav}{\headcommand {\slideentry {2}{2}{2}{7/7}{Grayscale Image Segmentation}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {7}{7}}}
\@writefile{nav}{\headcommand {\slideentry {4}{2}{5}{8/8}{OpenGL Interoperability}{0}}}
\@writefile{toc}{\beamer@subsectionintoc {2}{3}{Primal-Dual Method}{8}{0}{2}}
\@writefile{nav}{\headcommand {\beamer@subsectionentry {0}{2}{3}{8}{Primal-Dual Method}}\headcommand {\beamer@subsectionpages {6}{7}}}
\@writefile{nav}{\headcommand {\slideentry {2}{3}{1}{8/8}{Primal-Dual Method}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {8}{8}}}
\@writefile{nav}{\headcommand {\beamer@partpages {1}{8}}}
\@writefile{nav}{\headcommand {\beamer@subsectionpages {4}{8}}}
\@writefile{toc}{\beamer@sectionintoc {3}{CUDA Implementation}{9}{0}{3}}
\@writefile{nav}{\headcommand {\sectionentry {3}{CUDA Implementation}{9}{CUDA Implementation}{0}}}
\@writefile{nav}{\headcommand {\beamer@sectionpages {4}{8}}}
\@writefile{nav}{\headcommand {\beamer@documentpages {8}}}
\@writefile{nav}{\headcommand {\def \inserttotalframenumber {8}}}
\@writefile{nav}{\headcommand {\beamer@subsectionpages {8}{8}}}
\@writefile{nav}{\headcommand {\slideentry {3}{0}{2}{9/9}{}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {9}{9}}}
\@writefile{toc}{\beamer@sectionintoc {4}{Optimizations}{10}{0}{4}}
\@writefile{nav}{\headcommand {\sectionentry {4}{Optimizations}{10}{Optimizations}{0}}}
\@writefile{nav}{\headcommand {\beamer@sectionpages {9}{9}}}
\@writefile{nav}{\headcommand {\beamer@subsectionpages {9}{9}}}
\@writefile{toc}{\beamer@subsectionintoc {4}{1}{Texture Memory}{10}{0}{4}}
\@writefile{nav}{\headcommand {\beamer@subsectionentry {0}{4}{1}{10}{Texture Memory}}\headcommand {\beamer@subsectionpages {10}{9}}}
\@writefile{nav}{\headcommand {\slideentry {4}{1}{1}{10/10}{Texture Memory}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {10}{10}}}
\@writefile{toc}{\beamer@subsectionintoc {4}{2}{OpenGL Interoperability}{11}{0}{4}}
\@writefile{nav}{\headcommand {\beamer@subsectionentry {0}{4}{2}{11}{OpenGL Interoperability}}\headcommand {\beamer@subsectionpages {10}{10}}}
\@writefile{nav}{\headcommand {\slideentry {4}{2}{1}{11/11}{OpenGL Interoperability}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {11}{11}}}
\@writefile{nav}{\headcommand {\slideentry {4}{2}{2}{12/12}{OpenGL Interoperability}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {12}{12}}}
\@writefile{nav}{\headcommand {\slideentry {4}{2}{3}{13/13}{OpenGL Interoperability}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {13}{13}}}
\@writefile{nav}{\headcommand {\slideentry {4}{2}{4}{14/14}{OpenGL Interoperability}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {14}{14}}}
\bibcite{p1}{\hyperlink {beamerbibp1}{Smith, 2012}}
\@writefile{nav}{\headcommand {\slideentry {4}{2}{5}{15/15}{OpenGL Interoperability}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {15}{15}}}
\@writefile{nav}{\headcommand {\slideentry {4}{2}{6}{16/16}{OpenGL Interoperability}{0}}}
\@writefile{nav}{\headcommand {\beamer@framepages {16}{16}}}
\@writefile{nav}{\headcommand {\beamer@partpages {1}{16}}}
\@writefile{nav}{\headcommand {\beamer@subsectionpages {11}{16}}}
\@writefile{nav}{\headcommand {\beamer@sectionpages {10}{16}}}
\@writefile{nav}{\headcommand {\beamer@documentpages {16}}}
\@writefile{nav}{\headcommand {\def \inserttotalframenumber {16}}}
This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013/Debian) (format=pdflatex 2013.12.8) 3 APR 2014 00:41
This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013/Debian) (format=pdflatex 2013.12.8) 3 APR 2014 00:51
entering extended mode
restricted \write18 enabled.
%&-line parsing enabled.
......@@ -721,7 +721,11 @@ File: listings.cfg 2013/06/27 1.5pre1 listings configuration
))
Package: listings 2013/07/10 1.5 (Carsten Heinz)
(./segmentation.aux)
(./segmentation.aux
LaTeX Warning: Label `' multiply defined.
)
\openout1 = `segmentation.aux'.
LaTeX Font Info: Checking defaults for OML/cmm/m/it on input line 97.
......@@ -911,21 +915,52 @@ LaTeX Font Warning: Font shape `OT1/cmss/m/n' in size <4> not available
] [3
] [4
]
LaTeX Font Info: Try loading font information for U+msa on input line 156.
(/usr/share/texlive/texmf-dist/tex/latex/amsfonts/umsa.fd
File: umsa.fd 2013/01/14 v3.01 AMS symbols A
)
LaTeX Font Info: Try loading font information for U+msb on input line 156.
(/usr/share/texlive/texmf-dist/tex/latex/amsfonts/umsb.fd
File: umsb.fd 2013/01/14 v3.01 AMS symbols B
) [4
</usr/share/texmf/tex/latex/beamer/base/art/beamericonarticle.pdf>] [5
]pdfTeX warning (ext4): destination with the same identifier (name{beamerbib})
has been already used, duplicate ignored
<to be read again>
\relax
l.181 \end{frame}
[6
] [7
] [8
] [9
] [10
] [11
]
\openout4 = `segmentation.vrb'.
(./segmentation.vrb) [5
(./segmentation.vrb) [12
]
\openout4 = `segmentation.vrb'.
(./segmentation.vrb) [6
] [7
(./segmentation.vrb) [13
</usr/share/texmf/tex/latex/beamer/base/art/beamericonarticle.pdf>] [8
] [14
] [15
] [16
]
\tf@nav=\write6
......@@ -937,40 +972,50 @@ LaTeX Font Warning: Font shape `OT1/cmss/m/n' in size <4> not available
\tf@snm=\write8
\openout8 = `segmentation.snm'.
Package atveryend Info: Empty hook `BeforeClearDocument' on input line 205.
Package atveryend Info: Empty hook `AfterLastShipout' on input line 205.
Package atveryend Info: Empty hook `BeforeClearDocument' on input line 314.
Package atveryend Info: Empty hook `AfterLastShipout' on input line 314.
(./segmentation.aux)
Package atveryend Info: Executing hook `AtVeryEndDocument' on input line 205.
Package atveryend Info: Executing hook `AtEndAfterFileList' on input line 205.
Package atveryend Info: Executing hook `AtVeryEndDocument' on input line 314.
Package atveryend Info: Executing hook `AtEndAfterFileList' on input line 314.
Package rerunfilecheck Info: File `segmentation.out' has not changed.
(rerunfilecheck) Checksum: FF876777A43808A9642B5E643C4137BB;328.
(rerunfilecheck) Checksum: 82B476FB54F33F9F264559288F073C1D;548.
LaTeX Font Warning: Size substitutions with differences
(Font) up to 1.0pt have occurred.
Package atveryend Info: Empty hook `AtVeryVeryEnd' on input line 205.
LaTeX Warning: There were multiply-defined labels.
Package atveryend Info: Empty hook `AtVeryVeryEnd' on input line 314.
)
Here is how much of TeX's memory you used:
17139 strings out of 495031
314323 string characters out of 6181531
442393 words of memory out of 5000000
19928 multiletter control sequences out of 15000+600000
7356 words of font info for 27 fonts, out of 8000000 for 9000
17255 strings out of 495031
316018 string characters out of 6181531
445066 words of memory out of 5000000
20004 multiletter control sequences out of 15000+600000
12762 words of font info for 47 fonts, out of 8000000 for 9000
14 hyphenation exceptions out of 8191
49i,19n,60p,401b,1154s stack positions out of 5000i,500n,10000p,200000b,80000s
</usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmss10.pfb></us
r/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmss12.pfb></usr/shar
e/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmss17.pfb></usr/share/texl
ive/texmf-dist/fonts/type1/public/amsfonts/cm/cmss8.pfb></usr/share/texlive/tex
mf-dist/fonts/type1/public/amsfonts/cm/cmss9.pfb></usr/share/texlive/texmf-dist
/fonts/type1/public/amsfonts/cm/cmssbx10.pfb></usr/share/texlive/texmf-dist/fon
ts/type1/public/amsfonts/cm/cmssi9.pfb></usr/share/texlive/texmf-dist/fonts/typ
e1/public/amsfonts/cm/cmtt8.pfb>
Output written on segmentation.pdf (8 pages, 99869 bytes).
</usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmex10.pfb></us
r/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmmi10.pfb></usr/shar
e/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmr10.pfb></usr/share/texli
ve/texmf-dist/fonts/type1/public/amsfonts/cm/cmr8.pfb></usr/share/texlive/texmf
-dist/fonts/type1/public/amsfonts/cm/cmss10.pfb></usr/share/texlive/texmf-dist/
fonts/type1/public/amsfonts/cm/cmss12.pfb></usr/share/texlive/texmf-dist/fonts/
type1/public/amsfonts/cm/cmss17.pfb></usr/share/texlive/texmf-dist/fonts/type1/
public/amsfonts/cm/cmss8.pfb></usr/share/texlive/texmf-dist/fonts/type1/public/
amsfonts/cm/cmss9.pfb></usr/share/texlive/texmf-dist/fonts/type1/public/amsfont
s/cm/cmssbx10.pfb></usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm
/cmssi10.pfb></usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmss
i8.pfb></usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmssi9.pfb
></usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmsy10.pfb></usr
/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmsy8.pfb></usr/share/
texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmtt8.pfb>
Output written on segmentation.pdf (16 pages, 187804 bytes).
PDF statistics:
348 PDF objects out of 1000 (max. 8388607)
312 compressed objects within 4 object streams
24 named destinations out of 1000 (max. 500000)
91 words of extra memory for PDF output out of 10000 (max. 10000000)
670 PDF objects out of 1000 (max. 8388607)
615 compressed objects within 7 object streams
44 named destinations out of 1000 (max. 500000)
115 words of extra memory for PDF output out of 10000 (max. 10000000)
......@@ -11,26 +11,45 @@
\headcommand {\sectionentry {2}{Algorithm}{4}{Algorithm}{0}}
\headcommand {\beamer@sectionpages {3}{3}}
\headcommand {\beamer@subsectionpages {3}{3}}
\headcommand {\sectionentry {3}{CUDA Implementation}{4}{CUDA Implementation}{0}}
\headcommand {\beamer@sectionpages {4}{3}}
\headcommand {\beamer@subsectionpages {4}{3}}
\headcommand {\sectionentry {4}{Optimizations}{4}{Optimizations}{0}}
\headcommand {\beamer@sectionpages {4}{3}}
\headcommand {\beamer@subsectionpages {4}{3}}
\headcommand {\beamer@subsectionentry {0}{4}{1}{4}{Texture Memory}}\headcommand {\beamer@subsectionpages {4}{3}}
\headcommand {\beamer@subsectionentry {0}{4}{2}{4}{OpenGL Interoperability}}\headcommand {\beamer@subsectionpages {4}{3}}
\headcommand {\slideentry {4}{2}{1}{4/4}{OpenGL Interoperability}{0}}
\headcommand {\beamer@subsectionentry {0}{2}{1}{4}{Binary Image Segmentation}}\headcommand {\beamer@subsectionpages {4}{3}}
\headcommand {\slideentry {2}{1}{1}{4/4}{Binary Image Segmentation}{0}}
\headcommand {\beamer@framepages {4}{4}}
\headcommand {\slideentry {4}{2}{2}{5/5}{OpenGL Interoperability}{0}}
\headcommand {\slideentry {2}{1}{2}{5/5}{Binary Image Segmentation}{0}}
\headcommand {\beamer@framepages {5}{5}}
\headcommand {\slideentry {4}{2}{3}{6/6}{OpenGL Interoperability}{0}}
\headcommand {\beamer@subsectionentry {0}{2}{2}{6}{Grayscale Image Segmentation}}\headcommand {\beamer@subsectionpages {4}{5}}
\headcommand {\slideentry {2}{2}{1}{6/6}{Grayscale Image Segmentation}{0}}
\headcommand {\beamer@framepages {6}{6}}
\headcommand {\slideentry {4}{2}{4}{7/7}{OpenGL Interoperability}{0}}
\headcommand {\slideentry {2}{2}{2}{7/7}{Grayscale Image Segmentation}{0}}
\headcommand {\beamer@framepages {7}{7}}
\headcommand {\slideentry {4}{2}{5}{8/8}{OpenGL Interoperability}{0}}
\headcommand {\beamer@subsectionentry {0}{2}{3}{8}{Primal-Dual Method}}\headcommand {\beamer@subsectionpages {6}{7}}
\headcommand {\slideentry {2}{3}{1}{8/8}{Primal-Dual Method}{0}}
\headcommand {\beamer@framepages {8}{8}}
\headcommand {\beamer@partpages {1}{8}}
\headcommand {\beamer@subsectionpages {4}{8}}
\headcommand {\sectionentry {3}{CUDA Implementation}{9}{CUDA Implementation}{0}}
\headcommand {\beamer@sectionpages {4}{8}}
\headcommand {\beamer@documentpages {8}}
\headcommand {\def \inserttotalframenumber {8}}
\headcommand {\beamer@subsectionpages {8}{8}}
\headcommand {\slideentry {3}{0}{2}{9/9}{}{0}}
\headcommand {\beamer@framepages {9}{9}}
\headcommand {\sectionentry {4}{Optimizations}{10}{Optimizations}{0}}
\headcommand {\beamer@sectionpages {9}{9}}
\headcommand {\beamer@subsectionpages {9}{9}}
\headcommand {\beamer@subsectionentry {0}{4}{1}{10}{Texture Memory}}\headcommand {\beamer@subsectionpages {10}{9}}
\headcommand {\slideentry {4}{1}{1}{10/10}{Texture Memory}{0}}
\headcommand {\beamer@framepages {10}{10}}
\headcommand {\beamer@subsectionentry {0}{4}{2}{11}{OpenGL Interoperability}}\headcommand {\beamer@subsectionpages {10}{10}}
\headcommand {\slideentry {4}{2}{1}{11/11}{OpenGL Interoperability}{0}}
\headcommand {\beamer@framepages {11}{11}}
\headcommand {\slideentry {4}{2}{2}{12/12}{OpenGL Interoperability}{0}}
\headcommand {\beamer@framepages {12}{12}}
\headcommand {\slideentry {4}{2}{3}{13/13}{OpenGL Interoperability}{0}}
\headcommand {\beamer@framepages {13}{13}}
\headcommand {\slideentry {4}{2}{4}{14/14}{OpenGL Interoperability}{0}}
\headcommand {\beamer@framepages {14}{14}}
\headcommand {\slideentry {4}{2}{5}{15/15}{OpenGL Interoperability}{0}}
\headcommand {\beamer@framepages {15}{15}}
\headcommand {\slideentry {4}{2}{6}{16/16}{OpenGL Interoperability}{0}}
\headcommand {\beamer@framepages {16}{16}}
\headcommand {\beamer@partpages {1}{16}}
\headcommand {\beamer@subsectionpages {11}{16}}
\headcommand {\beamer@sectionpages {10}{16}}
\headcommand {\beamer@documentpages {16}}
\headcommand {\def \inserttotalframenumber {16}}
\BOOKMARK [2][]{Outline0.1}{Introduction}{}% 1
\BOOKMARK [2][]{Outline0.2}{Algorithm}{}% 2
\BOOKMARK [2][]{Outline0.3}{CUDA Implementation}{}% 3
\BOOKMARK [2][]{Outline0.4}{Optimizations}{}% 4
\BOOKMARK [3][]{Outline0.4.1.4}{Texture Memory}{Outline0.4}% 5
\BOOKMARK [3][]{Outline0.4.2.4}{OpenGL Interoperability}{Outline0.4}% 6
\BOOKMARK [3][]{Outline0.2.1.4}{Binary Image Segmentation}{Outline0.2}% 3
\BOOKMARK [3][]{Outline0.2.2.6}{Grayscale Image Segmentation}{Outline0.2}% 4
\BOOKMARK [3][]{Outline0.2.3.8}{Primal-Dual Method}{Outline0.2}% 5
\BOOKMARK [2][]{Outline0.3}{CUDA Implementation}{}% 6
\BOOKMARK [2][]{Outline0.4}{Optimizations}{}% 7
\BOOKMARK [3][]{Outline0.4.1.10}{Texture Memory}{Outline0.4}% 8
\BOOKMARK [3][]{Outline0.4.2.11}{OpenGL Interoperability}{Outline0.4}% 9
......@@ -271,8 +271,24 @@ What is Interoperability?
\begin{lstlisting}
cudaGraphicsMapResources(1, &pixels_CUDA, 0);
cudaGraphicsResourceGetMappedPointer(&d_pixels, &size, pixels_CUDA);
\end{lstlisting}
\item Pass CUDA pointer as parameter for kernel. The kernel writes to the buffer in \textbf{RGBA8} format.
\item After kernel execution, unmap pixel buffer.
\begin{lstlisting}
cudaGraphicsUnmapResources(1, &pixels_CUDA, 0);
\end{lstlisting}
\item Draw buffer
\begin{lstlisting}
glDrawPixels(w, h, GL_RGBA, GL_UNSIGNED_BYTE, 0);
\end{lstlisting}
\end{itemize}
\end{frame}
\begin{frame}
\frametitle{Challenges for OpenGL Interop}
\begin{itemize}
\item Converting float representation of gray scale pixel data in kernel, to unsigned four channel RGBA exected by OpenGL.
\item Using OpenGL interop with Qt for making GUI.
\end{itemize}
\end{frame}
......
\beamer@endinputifotherversion {3.24pt}
\beamer@sectionintoc {1}{Introduction}{3}{0}{1}
\beamer@sectionintoc {2}{Algorithm}{4}{0}{2}
\beamer@sectionintoc {3}{CUDA Implementation}{4}{0}{3}
\beamer@sectionintoc {4}{Optimizations}{4}{0}{4}
\beamer@subsectionintoc {4}{1}{Texture Memory}{4}{0}{4}
\beamer@subsectionintoc {4}{2}{OpenGL Interoperability}{4}{0}{4}
\beamer@subsectionintoc {2}{1}{Binary Image Segmentation}{4}{0}{2}
\beamer@subsectionintoc {2}{2}{Grayscale Image Segmentation}{6}{0}{2}
\beamer@subsectionintoc {2}{3}{Primal-Dual Method}{8}{0}{2}
\beamer@sectionintoc {3}{CUDA Implementation}{9}{0}{3}
\beamer@sectionintoc {4}{Optimizations}{10}{0}{4}
\beamer@subsectionintoc {4}{1}{Texture Memory}{10}{0}{4}
\beamer@subsectionintoc {4}{2}{OpenGL Interoperability}{11}{0}{4}
......@@ -4,6 +4,14 @@
\begin{lstlisting}
cudaGraphicsMapResources(1, &pixels_CUDA, 0);
cudaGraphicsResourceGetMappedPointer(&d_pixels, &size, pixels_CUDA);
\end{lstlisting}
\item Pass CUDA pointer as parameter for kernel. The kernel writes to the buffer in \textbf{RGBA8} format.
\item After kernel execution, unmap pixel buffer.
\begin{lstlisting}
cudaGraphicsUnmapResources(1, &pixels_CUDA, 0);
\end{lstlisting}
\item Draw buffer
\begin{lstlisting}
glDrawPixels(w, h, GL_RGBA, GL_UNSIGNED_BYTE, 0);
\end{lstlisting}
\end{itemize}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment