All math discussed in the Graphics course (INFOGR) summarized. Based on the lectures and the book Fundamentals of Computer Graphics (ISBN: 978-1-4822-2941-7)
, Rendering Creating shaded images from 3D models
- Image-order rendering (ray tracing): each pixel considered in turn, taking into account all
objects that influence that pixel
- Object-order rendering (rasterization): each object considered in turn and the pixels
influenced by that object are updated
Vectors
Scalar Quantity represented by a magnitude (single number)
Point Entity describing a location (x, y, z)
Vector Quantity requiring a magnitude and a direction
- Points and vectors are represented using a cartesian coordinate system
2 2 2
- Magnitude/Norm (length) of a vector: ||𝑣|| = 𝑣1 + 𝑣2 +... + 𝑣𝑖
Normalisation Setting the magnitude to 1 by dividing each part of the vector by the magnitude
1
- ^𝑣 = · [𝑣1, 𝑣2, ... , 𝑣𝑖] ⇒ ||𝑣|| = 1
||𝑣||
- Normalized vector ^𝑣 is the unit vector of 𝑣
Basis Union of vectors form a basis for a given dimension if the angle between them is > 0, i.e.
in 3D it would consist of^𝑥 = [1, 0, 0], ^𝑦 = [0, 1, 0] and ^𝑧 = [0, 0, 1]
- The basis is orthogonal if the basis vectors form an angle of 90°
- If the basis vectors both have a unit length of 1 and are orthogonal, it’s orthonormal
- A vector [𝑣𝑥, 𝑣𝑦] can be represented as the linear combination of ^𝑥 and ^𝑦 by
𝑣𝑥 · ^𝑥 + 𝑣𝑦 · ^𝑦
- To find the coordinates of a point 𝑃 in some other basis defined by â and ^𝑏,
you calculate 𝑝 · â + 𝑝 · ^𝑏c if the basis is orthonormal
Vector operations
- Addition/subtraction: 𝑢 ± 𝑣 = [𝑢 ± 𝑣 , 𝑢 ± 𝑣 , ... , 𝑢 ± 𝑣 ]
1 1 2 2 𝑖 𝑖
- Scalar multiplication: 𝑙 · 𝑣 = [𝑙 · 𝑣 , 𝑙 · 𝑣 , ... , 𝑙 · 𝑣 ]
1 2 𝑖
- Dot product: 𝑢 · 𝑣 = 𝑢 𝑣 + 𝑢 𝑣 +... + 𝑢 𝑣
1 1 2 2 𝑖 𝑖
- Alternatively, 𝑢 · 𝑣 = ||𝑢|| · ||𝑣|| · 𝑐𝑜𝑠(θ) where θ is the angle between 𝑢 and𝑣
2
- 𝑢 · 𝑢 = ||𝑢||
- Projection of one vector on another (𝑡 = 𝑐 · 𝐷)
- Think directional multiplication, only multiplications in the same direction count
◦
- Two vectors are orthogonal if their dot product is 0 (θ = 90 ; perpendicular)
- Cross product: 𝑎 × 𝑏 = [𝑎𝑦𝑏𝑧 − 𝑎𝑧𝑏𝑦, 𝑎𝑧𝑏𝑥 − 𝑎𝑥𝑏𝑧, 𝑎𝑥𝑏𝑦 − 𝑎𝑦𝑏𝑥] (calculator)
- Anticommutative (𝑎 × 𝑏 = − 𝑏 × 𝑎) and non-associative (
𝑎 × (𝑏 × 𝑐) ≠ (𝑎 × 𝑏) × 𝑐)
- ||𝑎 × 𝑏|| = ||𝑎|| · ||𝑏|| · 𝑠𝑖𝑛(θ)
- 𝑎 and 𝑏 are parallel iff 𝑎 × 𝑏 = 0
1
The benefits of buying summaries with Stuvia:
Guaranteed quality through customer reviews
Stuvia customers have reviewed more than 700,000 summaries. This how you know that you are buying the best documents.
Quick and easy check-out
You can quickly pay through credit card or Stuvia-credit for the summaries. There is no membership needed.
Focus on what matters
Your fellow students write the study notes themselves, which is why the documents are always reliable and up-to-date. This ensures you quickly get to the core!
Frequently asked questions
What do I get when I buy this document?
You get a PDF, available immediately after your purchase. The purchased document is accessible anytime, anywhere and indefinitely through your profile.
Satisfaction guarantee: how does it work?
Our satisfaction guarantee ensures that you always find a study document that suits you well. You fill out a form, and our customer service team takes care of the rest.
Who am I buying these notes from?
Stuvia is a marketplace, so you are not buying this document from us, but from seller Suniht. Stuvia facilitates payment to the seller.
Will I be stuck with a subscription?
No, you only buy these notes for $9.78. You're not tied to anything after your purchase.