\documentclass[10pt,a4paper]{article} % Packages \usepackage{fancyhdr} % For header and footer \usepackage{multicol} % Allows multicols in tables \usepackage{tabularx} % Intelligent column widths \usepackage{tabulary} % Used in header and footer \usepackage{hhline} % Border under tables \usepackage{graphicx} % For images \usepackage{xcolor} % For hex colours %\usepackage[utf8x]{inputenc} % For unicode character support \usepackage[T1]{fontenc} % Without this we get weird character replacements \usepackage{colortbl} % For coloured tables \usepackage{setspace} % For line height \usepackage{lastpage} % Needed for total page number \usepackage{seqsplit} % Splits long words. %\usepackage{opensans} % Can't make this work so far. Shame. Would be lovely. \usepackage[normalem]{ulem} % For underlining links % Most of the following are not required for the majority % of cheat sheets but are needed for some symbol support. \usepackage{amsmath} % Symbols \usepackage{MnSymbol} % Symbols \usepackage{wasysym} % Symbols %\usepackage[english,german,french,spanish,italian]{babel} % Languages % Document Info \author{racheleva} \pdfinfo{ /Title (computer-graphics-5.pdf) /Creator (Cheatography) /Author (racheleva) /Subject (Computer Graphics 5 Cheat Sheet) } % Lengths and widths \addtolength{\textwidth}{6cm} \addtolength{\textheight}{-1cm} \addtolength{\hoffset}{-3cm} \addtolength{\voffset}{-2cm} \setlength{\tabcolsep}{0.2cm} % Space between columns \setlength{\headsep}{-12pt} % Reduce space between header and content \setlength{\headheight}{85pt} % If less, LaTeX automatically increases it \renewcommand{\footrulewidth}{0pt} % Remove footer line \renewcommand{\headrulewidth}{0pt} % Remove header line \renewcommand{\seqinsert}{\ifmmode\allowbreak\else\-\fi} % Hyphens in seqsplit % This two commands together give roughly % the right line height in the tables \renewcommand{\arraystretch}{1.3} \onehalfspacing % Commands \newcommand{\SetRowColor}[1]{\noalign{\gdef\RowColorName{#1}}\rowcolor{\RowColorName}} % Shortcut for row colour \newcommand{\mymulticolumn}[3]{\multicolumn{#1}{>{\columncolor{\RowColorName}}#2}{#3}} % For coloured multi-cols \newcolumntype{x}[1]{>{\raggedright}p{#1}} % New column types for ragged-right paragraph columns \newcommand{\tn}{\tabularnewline} % Required as custom column type in use % Font and Colours \definecolor{HeadBackground}{HTML}{333333} \definecolor{FootBackground}{HTML}{666666} \definecolor{TextColor}{HTML}{333333} \definecolor{DarkBackground}{HTML}{4FAB44} \definecolor{LightBackground}{HTML}{F4F9F3} \renewcommand{\familydefault}{\sfdefault} \color{TextColor} % Header and Footer \pagestyle{fancy} \fancyhead{} % Set header to blank \fancyfoot{} % Set footer to blank \fancyhead[L]{ \noindent \begin{multicols}{3} \begin{tabulary}{5.8cm}{C} \SetRowColor{DarkBackground} \vspace{-7pt} {\parbox{\dimexpr\textwidth-2\fboxsep\relax}{\noindent \hspace*{-6pt}\includegraphics[width=5.8cm]{/web/www.cheatography.com/public/images/cheatography_logo.pdf}} } \end{tabulary} \columnbreak \begin{tabulary}{11cm}{L} \vspace{-2pt}\large{\bf{\textcolor{DarkBackground}{\textrm{Computer Graphics 5 Cheat Sheet}}}} \\ \normalsize{by \textcolor{DarkBackground}{racheleva} via \textcolor{DarkBackground}{\uline{cheatography.com/217931/cs/48020/}}} \end{tabulary} \end{multicols}} \fancyfoot[L]{ \footnotesize \noindent \begin{multicols}{3} \begin{tabulary}{5.8cm}{LL} \SetRowColor{FootBackground} \mymulticolumn{2}{p{5.377cm}}{\bf\textcolor{white}{Cheatographer}} \\ \vspace{-2pt}racheleva \\ \uline{cheatography.com/racheleva} \\ \end{tabulary} \vfill \columnbreak \begin{tabulary}{5.8cm}{L} \SetRowColor{FootBackground} \mymulticolumn{1}{p{5.377cm}}{\bf\textcolor{white}{Cheat Sheet}} \\ \vspace{-2pt}Not Yet Published.\\ Updated 28th April, 2026.\\ Page {\thepage} of \pageref{LastPage}. \end{tabulary} \vfill \columnbreak \begin{tabulary}{5.8cm}{L} \SetRowColor{FootBackground} \mymulticolumn{1}{p{5.377cm}}{\bf\textcolor{white}{Sponsor}} \\ \SetRowColor{white} \vspace{-5pt} %\includegraphics[width=48px,height=48px]{dave.jpeg} Measure your website readability!\\ www.readability-score.com \end{tabulary} \end{multicols}} \begin{document} \raggedright \raggedcolumns % Set font size to small. Switch to any value % from this page to resize cheat sheet text: % www.emerson.emory.edu/services/latex/latex_169.html \footnotesize % Small font. \begin{multicols*}{3} \begin{tabularx}{5.377cm}{x{2.23965 cm} x{2.73735 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{UNIT 5}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{PART A} \tn % Row Count 1 (+ 1) % Row 1 \SetRowColor{white} {\bf{chromaticity}} & quality of a color (hue/saturation) \tn % Row Count 3 (+ 2) % Row 2 \SetRowColor{LightBackground} {\bf{chromaticity diagram}} & visual representation of all perceivable colors; mixture of colors + comparison \tn % Row Count 7 (+ 4) % Row 3 \SetRowColor{white} {\bf{RGB}} & additive color model; combining at full intensity produces white \tn % Row Count 10 (+ 3) % Row 4 \SetRowColor{LightBackground} {\bf{YIQ}} & Y - luminance component; grayscale information \tn % Row Count 13 (+ 3) % Row 5 \SetRowColor{white} {\bf{CMY}} & subtractive(from reflected white) color model; mixing inks/dyes/pigments; \tn % Row Count 17 (+ 4) % Row 6 \SetRowColor{LightBackground} {\bf{HSV/HLS}} & H - Hue (pure color); HSV - single hexcone; HLS - double hexcone\{\{nl\}\}S - saturation (vibrancy)\{\{nl\}\}V - value(brightness) \tn % Row Count 23 (+ 6) % Row 7 \SetRowColor{white} {\bf{key frame systems}} & important frames (keyframes); start and end; intermediate frames \seqsplit{(tweening/in-betweening)} \tn % Row Count 28 (+ 5) % Row 8 \SetRowColor{LightBackground} {\bf{Bitmap animation}} & manipulating pixels/blocks (Frame-buffer animation) \tn % Row Count 31 (+ 3) \end{tabularx} \par\addvspace{1.3em} \vfill \columnbreak \begin{tabularx}{5.377cm}{x{2.23965 cm} x{2.73735 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{UNIT 5 (cont)}} \tn % Row 9 \SetRowColor{LightBackground} {\bf{Design of Animation Sequences}} & outline the storyboard or script.\{\{nl\}\}define motion sequence, objects, and keyframe positions. \tn % Row Count 5 (+ 5) % Row 10 \SetRowColor{white} {\bf{motion specification}} & define how objects move and transform over time; paths, kinematics, dynamics \tn % Row Count 9 (+ 4) \hhline{>{\arrayrulecolor{DarkBackground}}--} \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{HSV preferred over RGB when selecting hue, brightness and vibrancy} \tn \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{1.9908 cm} x{2.9862 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{RGB to YIQ}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{Y=0.299R+0.587G+0.114B} \tn % Row Count 1 (+ 1) % Row 1 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{\seqsplit{I=0.5959R−0.2746G−0.3213B}} \tn % Row Count 2 (+ 1) % Row 2 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{\seqsplit{Q=0.2115R−0.5227G+0.3112B}} \tn % Row Count 3 (+ 1) % Row 3 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{{\bf{Advantages of YIQ}}} \tn % Row Count 4 (+ 1) % Row 4 \SetRowColor{LightBackground} 1. Bandwidth efficiency & more for Y; less for I \& Q \tn % Row Count 6 (+ 2) % Row 5 \SetRowColor{white} 2. Monochrome compatibility & Y carries brightness \tn % Row Count 8 (+ 2) % Row 6 \SetRowColor{LightBackground} 3. Perceptual separation & matches human vision \tn % Row Count 10 (+ 2) % Row 7 \SetRowColor{white} 4. Reduced interference & improved signal quality (separating luminance \& chrominance) \tn % Row Count 13 (+ 3) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{2.14011 cm} x{2.83689 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{HSV}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{H (Hue): Base color (0°–360°) \{\{nl\}\}S (Saturation): Color intensity (0–100\%) \{\{nl\}\}V (Value): Brightness (0–100\%)} \tn % Row Count 3 (+ 3) % Row 1 \SetRowColor{white} {\bf{Steps for Palette Creation}} & Step 1 – Choose Fixed Hue\{\{nl\}\}Step 2 – Vary Saturation\{\{nl\}\}Step 3 – Vary Value\{\{nl\}\}Step 4 – Generate Color Grid/Matrix \tn % Row Count 9 (+ 6) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{2.4885 cm} x{2.4885 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{CMY to RGB}} \tn % Row 0 \SetRowColor{LightBackground} Red (R) = M + Y \{\{nl\}\}Green (G) = C + Y \{\{nl\}\}Blue (B) = C + M & C absorbs Red \{\{nl\}\}M absorbs Green \{\{nl\}\}Y absorbs Blue \tn % Row Count 4 (+ 4) % Row 1 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{mixing two primary colors subtracts two wavelengths of light, leaving only the color perceived as their overlap (a secondary color: R, G, or B).} \tn % Row Count 7 (+ 3) \hhline{>{\arrayrulecolor{DarkBackground}}--} \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{works by absorbing light} \tn \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{p{0.4977 cm} p{0.4977 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{Characteristics of light}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{Wavelength: defines hue (color) \{\{nl\}\}Intensity: defines brightness \{\{nl\}\}Additive Nature: combines to form white → basis for RGB} \tn % Row Count 3 (+ 3) % Row 1 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{{\bf{Impact on RGB}}} \tn % Row Count 4 (+ 1) % Row 2 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{{\bf{Structure}}} \tn % Row Count 5 (+ 1) % Row 3 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{Based on Red, Green, Blue (human cone sensitivity)} \tn % Row Count 6 (+ 1) % Row 4 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{Represented as a 3D color cube} \tn % Row Count 7 (+ 1) % Row 5 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{{\bf{Operation}}} \tn % Row Count 8 (+ 1) % Row 6 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{Additive mixing: R+G+B=white; (0,0,0)=black} \tn % Row Count 9 (+ 1) % Row 7 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{varying intensity values (0–255)} \tn % Row Count 10 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}--} \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{Directly used in display devices (monitors, TVs)} \tn \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{2.4885 cm} x{2.4885 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{Raster and Keyframe animation}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{Raster Animation}} & {\bf{Key-Frame Animation}} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} Definition: Frame-by-frame images & Definition: Store key frames, generate in-betweens \tn % Row Count 5 (+ 3) % Row 2 \SetRowColor{LightBackground} Data Structures: Bitmap frames, frame buffer & Data Structures: Key frames, control points, interpolation (linear/spline) \tn % Row Count 9 (+ 4) % Row 3 \SetRowColor{white} Process: Each frame stored and displayed sequentially & Process: Interpolate intermediate frames between key frames \tn % Row Count 12 (+ 3) % Row 4 \SetRowColor{LightBackground} Storage: high & Storage: low \tn % Row Count 13 (+ 1) % Row 5 \SetRowColor{white} Motion realism: exact & Motion realism: smooth \tn % Row Count 15 (+ 2) % Row 6 \SetRowColor{LightBackground} Editing: Difficult & Editing Easy: \tn % Row Count 16 (+ 1) % Row 7 \SetRowColor{white} Short, detailed animations & Long animations with smooth motion \tn % Row Count 18 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{p{0.4977 cm} p{0.4977 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{Chromaticity diagram}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{{\bf{Represents Visible Color Range}}} \tn % Row Count 1 (+ 1) % Row 1 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{2D slice, 3D color plane; isolate hue and saturation} \tn % Row Count 3 (+ 2) % Row 2 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{horseshoe-shaped boundary; pure spectral colors} \tn % Row Count 4 (+ 1) % Row 3 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{line of purples: non-spectral colors (mistures; connects red + blue)} \tn % Row Count 6 (+ 2) % Row 4 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{Interior = all visible color combinations} \tn % Row Count 7 (+ 1) % Row 5 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{{\bf{Meaning of Points}}} \tn % Row Count 8 (+ 1) % Row 6 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{Each point = specific color (hue (angle) + saturation (distance from center)} \tn % Row Count 10 (+ 2) % Row 7 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{Center → white/gray (achromatic)} \tn % Row Count 11 (+ 1) % Row 8 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{Boundary points = maximum saturation for that hue} \tn % Row Count 12 (+ 1) % Row 9 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{lines between points - mixture} \tn % Row Count 13 (+ 1) % Row 10 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{{\bf{Placement of Primary Colors}}} \tn % Row Count 14 (+ 1) % Row 11 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{Primaries (RGB) are fixed points inside diagram (not at extremes; form a triangle)} \tn % Row Count 16 (+ 2) % Row 12 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{triangle formed shows color gamut (subset colors)} \tn % Row Count 17 (+ 1) % Row 13 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{{\bf{Limitations:}}} \tn % Row Count 18 (+ 1) % Row 14 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{Limited gamut (triangle ≠ full diagram) \{\{nl\}\}Primaries not at extremes \{\{nl\}\}Cannot represent all visible colors} \tn % Row Count 21 (+ 3) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{fig. 1}} \tn \SetRowColor{LightBackground} \mymulticolumn{1}{p{5.377cm}}{\vspace{1px}\centerline{\includegraphics[width=5.1cm]{/web/www.cheatography.com/public/uploads/racheleva_1777358120_Screenshot 2026-04-28 120344.png}}} \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{2.4885 cm} x{2.4885 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{Keyframe vs. Procedural}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{Keyframe}} & {\bf{Procedural}} \tn % Row Count 1 (+ 1) % Row 1 \SetRowColor{white} Control: High (artistic, stylized motion) & Control: Limited (function-driven) \tn % Row Count 4 (+ 3) % Row 2 \SetRowColor{LightBackground} Realism: Depends on animator & Realism: High (follows physics) \tn % Row Count 6 (+ 2) % Row 3 \SetRowColor{white} Computation: Low runtime, high manual effort & Computation: Higher runtime, easy parameter changes \tn % Row Count 9 (+ 3) % Row 4 \SetRowColor{LightBackground} more control/style & less control/style \tn % Row Count 10 (+ 1) % Row 5 \SetRowColor{white} Best for stylized animation & Best for realistic motion \tn % Row Count 12 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{2.63781 cm} x{2.33919 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{HLS vs. HSV}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{HLS}} & {\bf{HSV}} \tn % Row Count 1 (+ 1) % Row 1 \SetRowColor{white} Uses Lightness (L) & Uses Value (V) \tn % Row Count 2 (+ 1) % Row 2 \SetRowColor{LightBackground} Pure color at L = 50\% & Pure color at V = 100\% \tn % Row Count 4 (+ 2) % Row 3 \SetRowColor{white} L controls brightness + contrast clearly & Less intuitive for contrast control \tn % Row Count 6 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}--} \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{HLS : better for harmony (consistent palette), contrast + more reliable \newline HLS is more logical and error-proof for UI design due to better control over lightness and contrast} \tn \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{2.4885 cm} x{2.4885 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{Squash \& Stretch}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{{\bf{Idea:}} Deform mesh based on velocity \& impact, not uniform scaling} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{{\bf{Algorithm}}} \tn % Row Count 3 (+ 1) % Row 2 \SetRowColor{LightBackground} Step 1 – Calculate Deformation Axis & normalized velocity vector \tn % Row Count 5 (+ 2) % Row 3 \SetRowColor{white} Step 2 – Determine Deformation Magnitude: & scalar factor from object's speed (impact - sudden velocity change) \tn % Row Count 9 (+ 4) % Row 4 \SetRowColor{LightBackground} Step 3 – Apply Volume-Preserving Deformation: & Scale along axis by k, others by 1/√k → volume preserved \tn % Row Count 12 (+ 3) % Row 5 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{At impact → use surface normal} \tn % Row Count 13 (+ 1) % Row 6 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{{\bf{Parameters}}} \tn % Row Count 14 (+ 1) % Row 7 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{Mesh vertices; Velocity; Impact normal; Deformation factor (k); Damping/stiffness} \tn % Row Count 16 (+ 2) % Row 8 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{{\bf{Mathematical foundation}}} \tn % Row Count 17 (+ 1) % Row 9 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{affine transformations; volume conservation} \tn % Row Count 18 (+ 1) % Row 10 \SetRowColor{LightBackground} \mymulticolumn{2}{x{5.377cm}}{directional scaling matrix} \tn % Row Count 19 (+ 1) % Row 11 \SetRowColor{white} \mymulticolumn{2}{x{5.377cm}}{spring-damper model} \tn % Row Count 20 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} % That's all folks \end{multicols*} \end{document}