(244 intermediate revisions by 5 users not shown)
Riadok 1: Riadok 1:
 
[[File:cg2_2014.png]]
 
[[File:cg2_2014.png]]
= Computer Graphics 2 =
+
= Advanced Computer Graphics =
  
 
== What you Need to Pass ==
 
== What you Need to Pass ==
Riadok 18: Riadok 18:
  
 
* Grades
 
* Grades
** A = 92-100
+
    A = 92-100
** B = 84-91
+
    B = 84-91
** C = 76-83
+
    C = 76-83
** D = 68-75
+
    D = 68-75
** E = 60-67
+
    E = 60-67
** Fx = 0-59
+
    Fx = 0-59
  
* [[https://docs.google.com/spreadsheet/ccc?key=0AguOJecPQwoSdGFjc2N0UllGWENnLXhjc2E0bzFYU0E&usp=sharing|VIEW RESULTS]]
+
*[https://docs.google.com/spreadsheets/d/18Tfi-5vJ4gdAGtF0Ky2CZIIpwV0SebF79pmZQySh1Oc/edit?usp=sharing '''VIEW RESULTS''']
* [https://moodle.uniba.sk/fmfi Final Term by Modddle Ecetronic test (18.5.2015 8:10 in B)
+
*[https://moodle.uniba.sk/course/view.php?id=2164 Final Term] by Comenius University Moodle Electronic test 16.5 8:00 )
 +
* Before the test exam you can try to solve many tests from the graphics page, is you can pass the example test then you have big chance to pass the test exam.
  
 
* Schedule
 
* Schedule
** Mon (8:10) - Room A (lecture)
+
** Mon (15:40) - Online MS Teams (lecture)
** Wed (16:30) - Room I-H3 (seminar)
+
** Wed (8:10) - (excercises)
 
+
  
 
=== Materials to read ===  
 
=== Materials to read ===  
Riadok 38: Riadok 38:
 
* http://www.amazon.com/Mathematics-Computer-Graphics-Undergraduate-Science/dp/1849960224
 
* http://www.amazon.com/Mathematics-Computer-Graphics-Undergraduate-Science/dp/1849960224
 
* http://www.martinus.sk/?uItem=19688 - Moderni Pocitacova Grafika
 
* http://www.martinus.sk/?uItem=19688 - Moderni Pocitacova Grafika
 
 
----
 
----
 +
=== Lecture00 "Introduction to Computer Graphics" ===
 +
* Computer Graphics Applications
  
=== Lecture01 "Introduction to Computer Graphics" ===
+
=== Lecture01 "Graphics Pipeline" ===
 +
* What is The Graphics Pipeline
 +
* Vertex Shader
 +
* Primitive Assembly
 +
* Tessellation Shaders
 +
* Geometry Shader
 +
* Geometry Postprocessing and Rasterization
 +
* Fragment Shader
 +
* Frame Buffer Operations
 +
* http://www.lighthouse3d.com/tutorials/glsl-core-tutorial/pipeline33/
 +
* Lecture notes: [[media:cg2_lesson00.pdf|lesson00.pdf]] [https://docs.google.com/presentation/d/1Gc0a1VoGR096N1aO7Y_11GCc3k-Jpm8jEGzQ5qgpL3Q/edit?usp=sharing]
 +
* Téma: Zobrazovací kanál. Grafická pipeline moderného hardvéru, framebuffer, buffer objekty, používané súradnicové priestory, druhy shader programov, druhy optimalizačných techník (view frustum, occlusion, backface culling), príklad shader programov.
  
 
=== Lecture02 "Ray Tracing 1." ===
 
=== Lecture02 "Ray Tracing 1." ===
* TayTracong Pipeline
+
* RayTracing Pipeline
 
* Lecture notes: [[media:cg2_lesson01.pdf|lesson01.pdf]]
 
* Lecture notes: [[media:cg2_lesson01.pdf|lesson01.pdf]]
  
Riadok 59: Riadok 71:
 
* Lecture notes: [[media:cg2_lesson02.pdf|lesson02.pdf]]
 
* Lecture notes: [[media:cg2_lesson02.pdf|lesson02.pdf]]
 
* Poznámky v Slovenčine k téme [[media:cg2_DatoveStruktury.pdf|Dátové Štruktúry]] a [[media:cg2_Kd-tree.pdf|Kd-tree]].  
 
* Poznámky v Slovenčine k téme [[media:cg2_DatoveStruktury.pdf|Dátové Štruktúry]] a [[media:cg2_Kd-tree.pdf|Kd-tree]].  
* Štátnicová téma: Kanál metódy sledovania lúča. (definícia lúča, popis metódy sledovania lúča, generovanie lúča, pochod po lúči (ray traversal), prienik lúča s trojuholníkom, stromová štruktúra lúčov (ray tree) a jej použitie na výpočet lokálnej farby, problém presnosti priesečníkov)
+
* Téma: Kanál metódy sledovania lúča a porovnanie s Radiosity metódou. (definícia lúča, definícia tieňového lúča, popis metódy sledovania lúča, generovanie lúča, pochod po lúči (ray traversal), prienik lúča s trojuholníkom, stromová štruktúra lúčov (ray tree) a jej použitie na výpočet lokálnej farby, problém presnosti priesečníkov). Metóda sledovania lúča na GPU, urýchľovacie techniky.
  
 +
=== Lecture05 "Shading." ===
 +
* OPENGL Light sources
 +
* Shading Phong model
 +
* First time meeting with Rendering Equation
 +
* Book chapter Shading: [[media:Shading.pdf|shading.pdf]]
  
 +
=== Lecture06 "Light Trasport." ===
 +
* Physics behind ray tracing
 +
* Physical light quantities
 +
* Visual perception of light
 +
* Light sources
 +
* Light transport simulation: Rendering Equation
 +
* Lecture notes: [[media:cg2_lesson05.pdf|lesson05.pdf]]
 +
* Téma: Fyzikálny osvetlovací model a výpočet farieb renderovacou rovnicou. (definícia radiancie, definícia BRDF a jej vlastnosti, fyzikálne BRDF Cook-Tarrance, definícia priestorového uhlu, napíšte renderovaciu rovnicu a vysvetlite jej členy).
 +
 +
=== Lecture07 "Radiosity." ===
 +
* Diffuse reflectance function
 +
* Radiative equilibrium between emission and absorption, escape
 +
* System of linear equations
 +
* Iterative solution Neuman series
 +
* Lecture notes: [[media:cg2_lesson05.pdf|lesson05.pdf]]
 +
* Book chapter Shading: [[media:Shading.pdf|shading.pdf]]
 +
 +
=== Lecture08 "BRDF." ===
 +
* Bidirectional Reflectance Distribution Function (BRDF)
 +
* Reflection models
 +
* Projection onto spherical basis functions
 +
* Shading Phong model, Blin-Phong model
 +
* Lecture notes: [[media:cg2_lesson07.pdf|lesson07.pdf]]
 +
* '''Homework:'''
 +
** 1. Prove that the mirror BRDF from slides [https://dai.fmph.uniba.sk/upload/1/1d/Cg2_lesson07.pdf less07] fulfills the BRDF properties: reciprocity, energy conservation, definit space, value space of BRDF
 +
** 2. Derive the equation for refracted direction Omega_r from [https://dai.fmph.uniba.sk/upload/e/eb/Shading.pdf shading] document in section 6.3.3.
 +
* Physical BRDF
 +
* Ward Reflection Model
 +
* Cook-Torrance model
 +
* Lecture notes: [[media:cg2_lesson07Phys.pdf|lesson07Phys.pdf]]
 +
 +
=== Lecture09, Lecture10 "Shadows." ===
 +
* Lecture notes: [[media:cg2_lesson08.pdf|lesson08.pdf]]
 +
* Téma: Tiene, typy tieňov (mäkké, tvrdé, statické, dynamické), typy a popis algoritmov (projekčné, tieňové objemy, tieňové mapy (shadow mapping)), spôsoby implementácie jednotlivých algoritmov, artefakty a ich odstraňovanie, príklad shader programov pre tieňové mapy. Artefakty spôsobené diskretizáciou. Tiene vo Phongovom modeli.
 +
 +
=== Lecture11,  Lecture12 "Texturing 1, 2." ===
 +
* Texture parameterization
 +
* Procedural methods
 +
* Procedural textures
 +
* Fractal landscapes
 +
* Lecture notes: [[media:cg2_lesson09.pdf|lesson09.pdf]]
 +
* Book chapter (Surface reality techniques): [[media:cg2_lessonBook09.pdf|lessonBoook09.pdf]]
 +
* Téma: Lokálne osvetľovacie modely. (tieňovanie, Phongov a Blinn-Phongov osvetlovací model, zložky (ambientna, difúzna, zrkadlová), textúrovanie a druhy textúr, mapovanie a filtrácia textúr, popísať princípy environment, bump, normal mapovania, textúrovací a tangenciálny priestor, príklad shader programov na GPU.
 +
 +
=== Lecture13 "Image Based Rendering 1." ===
 +
* Plenopticfunction
 +
* Panoramas
 +
* Concentric Mosaics
 +
* Light Field Rendering
 +
* The Lumigraph
 +
* Lecture notes: [[media:cg2_lesson10.pdf|lesson10.pdf]]
 +
* '''Homework:''' Blinn-Phong enumeration.
 +
 +
=== Lecture14 "Image Based Rendering 2." ===
 +
* Layered Depth Images
 +
* View-dependent Texture Mapping
 +
* Surface Light Fields
 +
* View Morphing
 +
* Lecture notes: [[media:cg2_lesson10.pdf|lesson10.pdf]]
 +
 +
=== Lecture15 "Ask me anything." ===
 +
* Test problem introduction
 
----
 
----
 +
= Seminars on Advanced Computer Graphics  =
  
= Seminars on Computer Graphics 2 =
+
*[https://docs.google.com/spreadsheets/d/1Pvxi5Q9Dhxl0f6qaIqP9bCUACfqhZlwy7uqgkmtEXdo/edit?usp=sharing '''VIEW RESULTS''']
 +
On Thursdays at 13:10.
  
== Rules / Info ==
+
See [https://liveuniba.sharepoint.com/:f:/s/2-AIN-12715-Pokroilpotaovgrafika/Eme5y4JAIIVJjh5fKSgryQgBPF8LIrh4mt0nWBG5vpQXPw?e=OkGBlo recordings] from previous year.
* On every seminar we will implement selected problems/algorithms related to lessons. We will '''usually - not necessary''' start with a prearranged template downloadable from this site.
+
* As a programming language we will use C#. We will use Visual C# 2010 as development environment. Alternatively you can use MonoDevelop (Linux / Mac OSX) on your own machine.
+
* Attendance at seminars is '''optional but recommended'''.
+
* Seminars are conducted by
+
** Michal Piovarči (cg2.2015.hw@gmail.com)
+
* Schedule of seminars is
+
** Wed (16:30) - Room I-H3
+
<!--
+
* Other collaborators and authors: Juraj Onderik
+
* Comment, errata, constructive criticism or suggestion - [https://docs.google.com/spreadsheet/ccc?key=0AhREYgn4NR6AdHgyemtJYWk0REt3SVJXMUdnQW5ockE&usp=sharing Make It Better]
+
-->
+
  
== Homeworks ==
+
'''Guide:''' Lukáš Gajdošech
* You can get '''max 100% per homework'''. Submission after deadline is for 0%.
+
* There is a '''min 60% of your final evaluation''' required for admission to final term.
+
* Additional activity can be awarder by '''max 10% of your final evaluation'''.
+
* Don't cheat - create instead. Any kind of cheating is punished by '''withholding 30% of your final evaluation''' for all involved students.
+
* As a homework, you will program what we could not finish during the exercise. Assignment and template will be downloadable from this site. See exercises.
+
* Homework must be submitted by email to [mailto:cg2.2015.hw@gmail.com  cg2.2015.hw@gmail.com] every week until the '''next Wednesday 16:30'''.
+
* Your submission email '''must''' have title in form 'ExNN' where NN is the number of exercise, eg. Ex05.
+
* It is required to submit '''zipped source code of your homework''' (preferably the whole solution). Do not send executable files. Homework without the source code is for 0%.
+
* Your code should be well '''formatted and commented'''. Titles of functions, classes, variables should be representative for their purpose. Homework without appropriate comments is for 0%.
+
* There are ~12 homeworks during the semester. This number can change due to holidays, tech. problems etc.
+
<!--
+
* [https://docs.google.com/spreadsheet/pub?key=0AguOJecPQwoSdFVER3BYMVhINHBnTnRGelVlUGx3eVE&single=true&gid=0&output=html Your Evaluation]
+
  
== Projects ==
+
'''Contact:''' lukas.gajdosech@fmph.uniba.sk
* There are no projects in this semester. However, if you want to implement something different than exercises you can choose e.g.:
+
** Implement photon mapping method
+
** Implement stochastic ray tracing method
+
** Implement radiosity method
+
** Implement ambient occlusion method
+
** Implement path tracing method - CUDA or openCL required
+
** Implement indirect lighting method
+
  
* '''Deadline:''' 17.5. - 23:59
+
== Info ==
 +
Each week a short guided presentation will be given.
  
* Evaluation will be calculated due to the complexity of your solution. Evaluation % will be summed into % from the exercises.
+
An assignment for every week will be finishing a template C# project. The deadline for every assingment is ''' midnight before the next successive seminar'''. The extended deadline is a week after with 0.5x penalization. Solutions to bonus assignment can be submitted anytime during the 2 weeks without the penalization.
-->
+
 
 +
=== Grading ===
 +
 
 +
* Total points from exercises make half of your final grade!
 +
* Minimum of 50% from exercises required to finish the class successfully
 +
* Late submission is for 0, no discussion
 +
 
 +
=== Project Evaluation Criteria ===
 +
 
 +
* 10 pt => Correct submission, everything works as supposed.
 +
* 6 pt => Partially correct submission, most of the things work as supposed.
 +
* 3 pt => Partially correct submission, at least one core functionality correct.
 +
* 0 pt => Incorrect submission or unsubmitted.
 +
* Penalization 0.5x when submitting in extended deadline (not for bonus).
 +
 
 +
=== Project Submittion ===
 +
 
 +
* Your code should be well '''formatted and commented'''. Titles of functions, classes, variables should be representative of their purpose.
 +
* Submission email must have the '''subject in the form of 'ACG ExNN'''' where NN is the exercise id, eg. ACG Ex05.
 +
* Solution source codes have to be '''archived and named properly 'ExNN_YourName''''
 +
* Do not archive and send executable files.
 +
* Send by email to [mailto:lukas.gajdosech@fmph.uniba.sk  lukas.gajdosech@fmph.uniba.sk].
  
 
== Exercises ==
 
== Exercises ==
  
=== Exercise00 [19.02.2014] "Introduction" ===
+
=== Exercise00 "Introduction" ===
 
* Motivation?
 
* Motivation?
 
** [http://goo.gl/5YLSxN 1st Octane], [http://goo.gl/J0E8qM 2nd Octane], [http://goo.gl/xVMEIk 3rd Octane]
 
** [http://goo.gl/5YLSxN 1st Octane], [http://goo.gl/J0E8qM 2nd Octane], [http://goo.gl/xVMEIk 3rd Octane]
 
** [http://www.fxguide.com/featured/the-state-of-rendering/ The State of Rendering 1], [http://www.fxguide.com/featured/the-state-of-rendering-part-2/ The State of Rendering 2]
 
** [http://www.fxguide.com/featured/the-state-of-rendering/ The State of Rendering 1], [http://www.fxguide.com/featured/the-state-of-rendering-part-2/ The State of Rendering 2]
 
* Theory / Reading?
 
* Theory / Reading?
** [http://www.scratchapixel.com/lessons/ Scratchapixel Lessons] - intersections, polygones, phong lighting
 
 
** [http://www.sci.utah.edu/~wald/PhD/wald_phd.pdf Ingo Wald's Thesis] - PhD. thesis about rendering, acceleration and global illumination.
 
** [http://www.sci.utah.edu/~wald/PhD/wald_phd.pdf Ingo Wald's Thesis] - PhD. thesis about rendering, acceleration and global illumination.
 
** [http://www.amazon.com/Physically-Based-Rendering-Second-Edition/dp/0123750792 Physically Based Rendering]
 
** [http://www.amazon.com/Physically-Based-Rendering-Second-Edition/dp/0123750792 Physically Based Rendering]
 
* Practice?
 
* Practice?
** [http://www.belanecbn.sk/3dtutorials/index.php?id=16 Ray Tracer in c++]
 
 
** [http://www.codeproject.com/Articles/20355/Simple-Ray-Tracing-in-C-Part-VII-Shadows Ray Tracer in c#]
 
** [http://www.codeproject.com/Articles/20355/Simple-Ray-Tracing-in-C-Part-VII-Shadows Ray Tracer in c#]
 
* Intro to c#?
 
* Intro to c#?
 
** [http://www.amazon.com/Microsoft-Visual-2010-Step/dp/0735626707 Visual c# 2010], [http://www.amazon.com/4-0-Nutshell-The-Definitive-Reference/dp/0596800959 c# 4.0 in a Nutshell]
 
** [http://www.amazon.com/Microsoft-Visual-2010-Step/dp/0735626707 Visual c# 2010], [http://www.amazon.com/4-0-Nutshell-The-Definitive-Reference/dp/0596800959 c# 4.0 in a Nutshell]
** [http://www.dofactory.com/ShortCutKeys/ShortCutKeys.aspx Visual Shortcuts], [http://www.shortcutworld.com/en/win/SharpDevelop_4.0.html SharpDevelop Short cuts]
+
** [https://www.dofactory.com/visual-studio-shortcuts Visual Studio Shortcuts], [http://www.shortcutworld.com/en/win/SharpDevelop_4.0.html SharpDevelop Short cuts]
** Exercise "Vectors and Matrices" - [http://www.dai.fmph.uniba.sk/w/CG1_2013/en CG1]
+
* [[media:CG2.Ex00.pdf | Seminar slides]]
+
<!--
+
=== Exercise01 [26.02.2014] "Ray Casting" ===
+
* Implement a camera class suitable for the ray casting method. As usual you should use a similar functionality as in the sample application. Application should specifically be able to:
+
** Render the scene (objects are movable).
+
** Move the camera in a 3D space.
+
** Change the camera's field of view (larger angle = more space to render), see Blender camera.
+
* Try to change the color of the intersected object due to distance from the camera
+
* ''''[2 bonus %]:'''
+
** Create a camera which will rotate around defined point P (target) along a sphere with r = 1. You can use ideas from the Blender camera system and / or two-angle camera in openGL. Camera should use some sort of interactivity (2 angles) and targeted point P should be movable. Bonus camera can be created in a separated solution or you can change the structure in the template to implement two different cameras.
+
* [http://www.sccg.sk/~hudak/CG2/Ex01.Sample.zip Sample] | [http://www.sccg.sk/~hudak/CG2/Ex01.Template.zip Template]
+
* '''Deadline: 12.3 - 17:20'''
+
  
=== Exercise02 [12.03.2014] "Primitives" ===
 
* Improve your tracer by adding a few primitives (ring, sphere, AABB box, triangle) [http://mrl.nyu.edu/~dzorin/rend05/lecture1a.pdf]  [http://www.scratchapixel.com/lessons/3d-basic-lessons/lesson-9-ray-triangle-intersection/barycentric-coordinates/] [http://geomalgorithms.com/a04-_planes.html#Barycentric-Coordinate-Compute]. Each object should be movable. As usual you should use a similar functionality as in the sample application.
 
* ''''[1 bonus %]:'''
 
** Create also a cylinder and a cone primitives
 
* [http://www.sccg.sk/~hudak/CG2/Ex02.Sample.zip Sample] | [http://www.sccg.sk/~hudak/CG2/Ex02.Template.zip Template]
 
  
=== Exercise03 [19.03.2014] "Shader & Shading & Shadow" ===
+
=== Exercise01 "Vectors and Matrices" ===
* Improve your tracer by adding shaders, shadows and lights. Implement checker and phong shader, sun light and hard shadows. Compute normals to each primitive in the point of intersection. As usual you should use a similar functionality as in the sample application.
+
'''Deadline (no extended deadline): ''' 22.2.2023 at 23:59
* [http://www.sccg.sk/~hudak/CG2/Ex03.Sample.zip Sample] | [http://www.sccg.sk/~hudak/CG2/Ex03.Template.zip Template]
+
  
=== Exercise04 [26.03.2014] "Lights & Shadows" ===
+
'''Asignment:'''
* Improve your tracer by adding a point light, spot light [http://wiki.blender.org/index.php/Doc:2.6/Manual/Lighting/Lamps/Spot] and an area light. In the case of point and spot light, define the light as a point with hard shadows and linear/quadratic light attenuation [http://wiki.blender.org/index.php/Doc:2.6/Manual/Lighting/Lights/Light_Attenuation]. Area light could be defined by Lights x Lights point lights. Area light should also be able to produce soft shadows.
+
Create a simple application for vector(4x1) and matrix operations(4x4).
* [http://www.sccg.sk/~hudak/CG2/Ex04.Sample.zip Sample] | [http://www.sccg.sk/~hudak/CG2/Ex04.Template.zip Template]
+
Use struct properties, functions and/or operators. Create a calculator, check your equations and results.
 +
Add implementation to theese files in folder ''./Mathematics/'' : ''Vector4.cs'', ''MathEx.cs'', and ''Matrix44.cs''.
  
=== Exercise05 [02.04.2014] "More About Shaders" ===
+
'''[2 bonus %]:'''
* Improve your tracer by adding a few procedural shaders: noise, turbulence / clouds / marble, stripes, gradient, wood. For inspiration and additional material start here - [http://wiki.blender.org/index.php/Doc:2.6/Manual/Textures/Types/Procedural]. As usual you should use a similar functionality as in the sample application.
+
Vector operations "/" (vector projection) and "^" (modulation product).
* ''''[2 bonus %]:'''  
+
 
** Create a voronoi shader
+
For a help, see [https://chortle.ccsu.edu/vectorlessons/vectorindex.html this reminder on linear algebra] and/or useful [http://learnwebgl.brown37.net/transformations2/transformations_matrices.html tutorial on transformation matrices].
* [http://www.sccg.sk/~hudak/CG2/Ex05.Sample.zip Sample] | [http://www.sccg.sk/~hudak/CG2/Ex05.Template.zip Template]
+
*[[media:CG1.Ex01.Sample.zip|Sample]] | [[media:CG1.Ex01.Template.zip‎|Template]]
 +
 
 +
=== Exercise02 "Ray Casting" ===
 +
'''Deadline:''' 1.3.2022 at 23:59
 +
'''Extended deadline:''' 8.3.2022 at 23:59
 +
 
 +
[https://docs.google.com/presentation/d/1qfbRX35LpC72wCmBLcaftWsIUqFF7Ej6fBn4NGFoKMc/edit?usp=sharing Seminar slides]
 +
 
 +
'''Asignment:'''
 +
Implement basic ray casting and the intersection of ray and plane. Define the camera class and implement a simple ray-casting procedure.
 +
* [[media:CG2.Ex01.Sample.zip | Sample]] | [[media:CG2.Ex01.Template.zip | Template]]
 +
 
 +
=== Exercise03 "Primitives" ===
 +
'''Deadline:''' 8.3.2023 at 23:59
 +
'''Extended deadline:''' 15.3.2023 at 23:59
 +
 
 +
[https://docs.google.com/presentation/d/1QqosOvNF8QMCX_AvhbjhgO2Kbc1ehBI6aomLubBKpdQ/edit?usp=sharing Seminar Slides]
 +
 
 +
'''Asignment:'''
 +
Improve your tracer by adding new primitive object types: box, sphere, and ring.
 +
* [[media:CG2.Ex02.Sample.zip | Sample]] | [[media:CG2.Ex02.Template.zip | Template]]
 +
 
 +
'''Resources:'''
 +
[http://geomalgorithms.com/a04-_planes.html#Barycentric-Coordinate-Compute Planes, triangles, and distances],
 +
[http://www.realtimerendering.com/intersections.html Intersection algorithms]
 +
 
 +
'''Bonus [3 bonus % (1 for each)]:'''
 +
Create also a triangle, cylinder, and cone primitives and add them to the tracer. Also, create a new scene where you present the primitive(s).
 +
 
 +
=== Exercise04 "Shaders, Shading and Shadows" ===
 +
'''Deadline:''' 15.3.2023 at 23:59
 +
'''Extended deadline:''' 22.3.2023 at 23:59
 +
 
 +
[https://docs.google.com/presentation/d/1q_n3gjcUHZ8Nr7ma6EJXmE9RJxMHj1bmysQnKQwzb3U/edit?usp=sharing Seminar Slides]
 +
 
 +
'''Asignment:'''
 +
Improve your tracer by implementing Phong and checker shaders, directional light, and hard shadows. Compute normals of each primitive at the point of intersection. As usual, you should get a similar functionality as in the sample application.
 +
* [[media:CG2.Ex03.Sample.zip | Sample]] | [[media:CG2.Ex03.Template.zip | Template]]
 +
 
 +
=== Exercise05 "Light Types" ===
 +
'''Deadline:''' 22.3.2023 at 23:59
 +
'''Extended deadline:''' 29.3.2023 at 23:59
 +
 
 +
[https://docs.google.com/presentation/d/1BefIrufgieVVjSyr5R65CKWFwuxBaj2CGhXIx_58CNA/edit?usp=sharing Seminar Slides]
 +
 
 +
'''Asignment:'''
 +
Improve your tracer by adding a point, spot and an area light types. In the case of point and spotlight, define the light as a point with hard shadows and linear/quadratic light attenuation [http://wiki.blender.org/index.php/Doc:2.6/Manual/Lighting/Lights/Light_Attenuation]. Area light could be defined by Lights x Lights point lights. Area light should also be able to produce "soft" shadows.
 +
* [[media:CG2.Ex04.Sample.zip | Sample]] | [[media:CG2.Ex04.Template.zip | Template]]
 +
 
 +
'''[2 bonus %]:'''
 +
Write an equation for illumination computed by sample code from seminar slides
 +
 
 +
=== Exercise06 "Shaders" ===
 +
'''Deadline:''' 5.4.2023 at 23:59
 +
'''Extended deadline:''' 12.4.2023 at 23:59
 +
 
 +
[https://docs.google.com/presentation/d/1nJxdeN_NfT_45Fn7z_d-Vh3sS-NZcYWbRslSPudYKxw/edit?usp=sharing Seminar Slides]
 +
 
 +
'''Asignment:'''
 +
Improve your tracer by adding a few more shaders: Toon, Gradient, Cook-Torrance, and Oren-Nayar.
 +
* [[media:CG2.Ex05.Sample.zip|Sample]] | [[media:CG2.Ex05.Template.zip|Template]]
 +
 
 +
'''[2 bonus %]:'''  
 +
Implement [http://cseweb.ucsd.edu/~ravir/6998/papers/p265-ward.pdf Ward Shader] [ [[media:Spheres.PNG|Example]] ].
 +
* Generate tangent space for each point on the sphere
 +
* Remember to keep the same orientation of tangent space at each point
 +
 
 +
=== Exercise07 "Reflections" ===
 +
'''Deadline:''' 19.4.2023 at 23:59
 +
'''Extended deadline:''' 26.4.2023 at 23:59
 +
 
 +
[https://docs.google.com/presentation/d/1GNhGJqi-ELtQMMUU2RvHqTa_0U2oJQLHEyAh-dvIzoQ/edit?usp=sharing Seminar Slides]
 +
 
 +
'''Asignment:'''
 +
Improve your tracer by adding reflections for rendering mirror-like materials.
 +
* [[media:CG2.Ex06.Sample.zip | Sample]] | [[media:CG2.Ex06.Template.zip | Template]]
 +
 
 +
=== Exercise08 "Transparency" ===
 +
'''Deadline:''' 26.4.2023 at 23:59
 +
'''Extended deadline:''' 3.5.2023 at 23:59
 +
 
 +
[https://docs.google.com/presentation/d/1XxI2xLD8UFpLSICbP5f09biCb8DAaxrM0nmxto2-bL4/edit?usp=sharing Seminar Slides]
 +
 
 +
'''Asignment:'''
 +
Improve your tracer by adding reflections and refractions for rendering glass materials.
 +
* [[media:CG2.Ex06.Sample.zip | Sample]] | [[media:CG2.Ex07.Template.zip | Template]]
 +
 
 +
'''[2 bonus %]:'''
 +
Implement fresnel effect.
 +
 
 +
=== Exercise09 "Postprocessing" ===
 +
'''Deadline (no extended deadline): ''' 10.5.2023 at 23:59
 +
 
 +
[https://docs.google.com/presentation/d/1CxRs7VM0ZEMMq-m4BCklmpTWJyFDQDb_XPunFWeFtMU/edit?usp=sharing Seminar slides]
 +
 
 +
'''Asignment:'''
 +
Add supersampling antialiasing [http://en.wikipedia.org/wiki/Supersampling] and implement blur. Users can scale the intensity of blur [http://www.blackpawn.com/texts/blur/default.html].
 +
* [[media:CG2.Ex08.Sample.zip | Sample]] | [[media:CG2.Ex08.Template.zip | Template]]
 +
 
 +
'''[2 bonus %]:'''
 +
Implement DOF. You can use the definition from blur to create a fake DOF. A user can define a point of sharpness and the intensity of the effect.
 +
 
 +
=== Exercise10 "Textures" ===
 +
'''Deadline (no extended deadline): ''' 24.5.2023 at 23:59
 +
 
 +
[https://docs.google.com/presentation/d/1mA_sgdu19f3hnHEnVZysXyVv_s-H-M20BkBYPoVQGJw/edit?usp=sharing Seminar slides]
 +
 
 +
'''Asignment:'''
 +
The time has come to finalize your project. Use textures in your ray tracer [https://quixel.com/megascans/] [http://www.crazybump.com/]. Implement plane, and normal mapping [http://www.opengl-tutorial.org/intermediate-tutorials/tutorial-13-normal-mapping/]. Your results should be similar to the given sample.
 +
* [[media:CG2.Ex09.Sample.zip | Sample]] | [[media:CG2.Ex09.Template.zip | Template]]
 +
 
 +
'''Tutorial:'''
 +
* Define class Sampler and its descendants: class ColorSampler(only color) and class TextureSampler(also texture). Texture sampler should use some sort of sampling (clamp) and some sort of filtering (nearest neighbor).
 +
* Define class TextureMapping and its descendants: class PlaneMapping and class NormalMapping.
 +
* Improve phong shader to include sample point from the texture.
 +
 
 +
'''[1 bonus %]:'''
 +
Implement sphere mapping [http://4.bp.blogspot.com/-X5yJU7L87b4/Tuph1yIE64I/AAAAAAAAAOg/n36HVurEtxs/s1600/adadad.png].
 +
 
 +
=== Exercise11 (optional/voluntary) "Acceleration Structures" ===
 +
[https://dai.fmph.uniba.sk/upload/e/e0/Cg2_Kd-tree.pdf  Seminar slides]
 +
 
 +
'''Asignment:'''
 +
Implement accelerating structure for ray tracing. The structure is KD Trees + surface area heuristic (SAH). The dimension is 2. As usual you should use a similar functionality as in the sample application.
 +
* Physically based rendering could help [http://www.amazon.com/Physically-Based-Rendering-Second-Edition/dp/0123750792]
 +
* [[media:Ex11.Sample.zip | Sample]] | [[media:Ex11.Template.zip | Template]]
 +
 
 +
<!--
  
=== Exercise06 [09.04.2014] "Even More About Shaders" ===
+
'''[1 bonus %]:'''  
* Improve your tracer by adding reflections and refractions to render mirror and glass objects. As usual you should use a similar functionality as in the sample application.
+
Implement repeat and mirror texture sampling and bilinear texture filtering.
* ''''[1 bonus %]:'''  
+
** Implement fresnel effect
+
* [http://www.sccg.sk/~hudak/CG2/Ex06.Sample.zip Sample] | [http://www.sccg.sk/~hudak/CG2/Ex06.Template.zip Template]
+
  
=== Exercise07 [16.04.2014] "The One About Acceleration" ===
+
=== Exercise11 "The One About Acceleration" ===
 
* Implement accelerating structure for ray tracing. The structure is KD Trees + surface area heuristic (SAH) [http://www.sccg.sk/~durikovic/classes/CG2/Handouts/CG03-kdtrees.pdf] (4.4.2). The dimension is 2. Go. As usual you should use a similar functionality as in the sample application [http://www.sccg.sk/~durikovic/classes/CG2/Handouts/CG03RT-II.pdf].
 
* Implement accelerating structure for ray tracing. The structure is KD Trees + surface area heuristic (SAH) [http://www.sccg.sk/~durikovic/classes/CG2/Handouts/CG03-kdtrees.pdf] (4.4.2). The dimension is 2. Go. As usual you should use a similar functionality as in the sample application [http://www.sccg.sk/~durikovic/classes/CG2/Handouts/CG03RT-II.pdf].
 
* Physically based rendering could help [http://www.amazon.com/Physically-Based-Rendering-Second-Edition/dp/0123750792]
 
* Physically based rendering could help [http://www.amazon.com/Physically-Based-Rendering-Second-Edition/dp/0123750792]
Riadok 171: Riadok 348:
 
** Improve acceleration with KD Trees and SAH. Use it in 3D ray tracer for rendering mesh. Implement mesh loader and load the mesh from external source (e.g. stanford bunny - .obj format). You can use the standard mesh definition - everyting is a triangle.
 
** Improve acceleration with KD Trees and SAH. Use it in 3D ray tracer for rendering mesh. Implement mesh loader and load the mesh from external source (e.g. stanford bunny - .obj format). You can use the standard mesh definition - everyting is a triangle.
 
** '''Special bonus deadline:''' 17.5. - 23:59
 
** '''Special bonus deadline:''' 17.5. - 23:59
 
=== Exercise08 [30.04.2014] "Postprocessing" ===
 
* Improve your raytracer by adding supersampling SSAA / FSAA [http://en.wikipedia.org/wiki/Supersampling].
 
* Implement blur. User can scale the intensity of blur [http://www.blackpawn.com/texts/blur/default.html]
 
* '''[2 bonus %]:'''
 
** Implement DOF. You can use definition from blur to create a fake DOF. User can define a point of sharpness and the intensity of the effect.
 
* [http://www.sccg.sk/~hudak/CG2/Ex08.Sample.zip Sample] | [http://www.sccg.sk/~hudak/CG2/Ex08.Template.zip Template]
 
* '''Deadline:''' 7.5. - 17:20
 
 
=== Exercise09 [07.05.2014] "Textures" ===
 
* The time has come to use textures in your ray tracer [http://dev.quixel.se/megascans] [http://www.crazybump.com/]
 
* Implement 3 kinds of texture mapping: plane, sphere [http://4.bp.blogspot.com/-X5yJU7L87b4/Tuph1yIE64I/AAAAAAAAAOg/n36HVurEtxs/s1600/adadad.png] and normal mapping [http://wiki.polycount.com/NormalMap/]
 
* Tutorial
 
** Define class Sampler and its descendants: class ColorSampler(only color) and class TextureSampler(also texture). Texture sampler should use some sort of sampling (clamp) and some sort of filtering (nearest neighbor)
 
** Define class TextureMapping and its descendants: class PlaneMapping, class SphereMapping and class NormalMapping
 
** Improve phong shader to include sample point from the texture
 
* Your results should be similar to the given sample
 
* '''[1 bonus %]:'''
 
** Implement repeat and mirror texture sampling and bilinear texture filtering (classic deadline)
 
 
* '''[3 special bonus %]:'''  
 
* '''[3 special bonus %]:'''  
 
** Implement mesh loader and load the mesh from external source (e.g. stanford bunny - .obj format). You can use the standard mesh definition - everyting is a triangle. Implement UV mapping (uv coordinates from .obj format) and smooth shading on mesh.
 
** Implement mesh loader and load the mesh from external source (e.g. stanford bunny - .obj format). You can use the standard mesh definition - everyting is a triangle. Implement UV mapping (uv coordinates from .obj format) and smooth shading on mesh.
 
** '''Special bonus deadline:''' 17.5. - 23:59
 
** '''Special bonus deadline:''' 17.5. - 23:59
* [http://www.sccg.sk/~hudak/CG2/Ex09.Sample.zip Sample] | [http://www.sccg.sk/~hudak/CG2/Ex09.Template.zip Template]
 
  
=== Exercise10 [14.05.2014] "Laboratory Experiment" ===
+
=== Exercise05 "More About Shaders" ===
* Could we imitate materials from the real world?
+
* Improve your tracer by adding a few procedural shaders: noise, turbulence / clouds / marble, stripes, gradient, wood. For inspiration and additional material start here - [http://wiki.blender.org/index.php/Doc:2.6/Manual/Textures/Types/Procedural]. As usual you should use a similar functionality as in the sample application.
** [http://img291.imageshack.us/img291/4066/failani.png Anisotropic], [http://rhinotoday.com/wp-content/uploads/2012/03/keyshot-render-paint-sphere.jpg Carpaint], [http://1.bp.blogspot.com/_TCqLkmUciss/TPMGTwQwteI/AAAAAAAAALI/ZO5RQt60E6k/s1600/Glass_Balls_Color-1280x800.jpg Translucent], [http://graphics.ucsd.edu/~henrik/papers/photon_diffusion/milk_photon_diffusion.jpg Semi-translucent]
+
* ''''[2 bonus %]:'''  
* Yes we can and we will. Choose a sample paint and
+
** Create a voronoi shader
** Measure its '''color in Lab''' and Convert to '''RGB''' - [http://www.easyrgb.com/index.php?X=CALC Easy RGB]
+
* [http://www.sccg.sk/~hudak/CG2/Ex05.Sample.zip Sample] | [http://www.sccg.sk/~hudak/CG2/Ex05.Template.zip Template]
** Measure '''gloss value''' in different conditions
+
* Write your results: Template
+
** Fill out [https://docs.google.com/spreadsheet/ccc?key=0AhREYgn4NR6AdFZSTXdyd0NSUG1xSlplY0hxRG96V2c&usp=sharing online form] with selected results (during the seminar)
+
** Guidelines are in the [http://www.sccg.sk/~hudak/CG2/CG2.Ex10.Template.doc template]
+
** Submit your results as a regular submission by mail
+
** '''Deadline:''' 17.5. - 23:59
+
  
=== [21.05.2014] "Final Term" ===
+
=== ExerciseChicken "The One About Chickens" ===
 +
* [[media:CG2.ExChicken.pdf‎ | Chicken slides]]
 +
* Improve your chickener by adding a few more shaders: Chicken, Cooked-Chicken, Chicken-Nyan. As usual, you should use a similar functionality as in the sample application.
 +
 
 +
=== ExerciseLab "Laboratory Experiment" ===
 +
Could we imitate materials from the real world?
 +
[http://rhinotoday.com/wp-content/uploads/2012/03/keyshot-render-paint-sphere.jpg Carpaint],
 +
[http://1.bp.blogspot.com/_TCqLkmUciss/TPMGTwQwteI/AAAAAAAAALI/ZO5RQt60E6k/s1600/Glass_Balls_Color-1280x800.jpg Translucent],
 +
Yes, we can, and we will!
 +
 
 +
'''Asignment:'''
 +
[https://docs.google.com/document/d/1FqxzjfmSg71wpO9b0RnK-pSFYy5lSL_CVjXq-Lpg_hI/edit?usp=sharing LAB assignment document]
 +
* Submit your results as a regular submission by mail
 +
 
 +
=== AMA "Ask Me Anything" ===
 +
Send your questions in advance to homework email
 +
 
 +
[https://docs.google.com/presentation/d/1RtsxHpjtC_Rfh3tKd7u4cQYNqi71lvOP7XUnzlI-rS4/edit#slide=id.p29 Slides]
 +
 
 +
=== Final Term "Final Term" ===
 +
* Final test in moodle
 +
* Oral exam afterwards for successful students
 +
 
 +
''' Bonus [2 bonus %]:'''
 +
Create a camera that will rotate around defined point P (target) among a sphere with r = 1. You can use ideas from the Blender camera system and/or two-angle camera in OpenGL. The camera should use some sort of interactivity (2 angles) and targeted point P should be movable. Bonus camera can be created in a separate solution or you can change the structure in the template to implement two different cameras.
 +
* [http://youtu.be/1twa3CJOEfA?t=1m49s Example Camera Movement]
 +
-->

Aktuálna revízia z 16:39, 19. február 2024

Cg2 2014.png

Advanced Computer Graphics

What you Need to Pass

  • Attend lessons. One missed +0 points. 2 missed 0 points, 3 missed 0 points, 4 and more is Fx.
  • Project and exercise (mandatory, 10+50 points).
  • Solve all homework problems (mandatory each one >=30%, 10 points)
  • Pass final term (mandatory, 20 points) You will need to solve several problems discussed during lessons.
  • Pass oral/written exam: (mandatory, +20 points)
  • Summary
    • Attendance = 0 or -100 (Fx)
    • Exercise = +50..0
    • Bonus = +10..0 (optional)
    • Homework = +10..4 or +4..0 (Fx)
    • Final term = +20..0
    • Oral/written exam = +20..0
  • Grades
   A = 92-100
   B = 84-91
   C = 76-83
   D = 68-75
   E = 60-67
   Fx = 0-59
  • VIEW RESULTS
  • Final Term by Comenius University Moodle Electronic test 16.5 8:00 )
  • Before the test exam you can try to solve many tests from the graphics page, is you can pass the example test then you have big chance to pass the test exam.
  • Schedule
    • Mon (15:40) - Online MS Teams (lecture)
    • Wed (8:10) - (excercises)

Materials to read


Lecture00 "Introduction to Computer Graphics"

  • Computer Graphics Applications

Lecture01 "Graphics Pipeline"

  • What is The Graphics Pipeline
  • Vertex Shader
  • Primitive Assembly
  • Tessellation Shaders
  • Geometry Shader
  • Geometry Postprocessing and Rasterization
  • Fragment Shader
  • Frame Buffer Operations
  • http://www.lighthouse3d.com/tutorials/glsl-core-tutorial/pipeline33/
  • Lecture notes: lesson00.pdf [1]
  • Téma: Zobrazovací kanál. Grafická pipeline moderného hardvéru, framebuffer, buffer objekty, používané súradnicové priestory, druhy shader programov, druhy optimalizačných techník (view frustum, occlusion, backface culling), príklad shader programov.

Lecture02 "Ray Tracing 1."

Lecture03 "Ray Tracing 2."

Lecture04 "Ray Tracing 3."

  • Ray Tracing Acceleration
  • Data structure: grids, BVH, Kd-tree, Directional Partitioning
  • Dynamic Scenes
  • Beam and Cone Tracing
  • Packet Tracing
  • Lecture notes: lesson02.pdf
  • Poznámky v Slovenčine k téme Dátové Štruktúry a Kd-tree.
  • Téma: Kanál metódy sledovania lúča a porovnanie s Radiosity metódou. (definícia lúča, definícia tieňového lúča, popis metódy sledovania lúča, generovanie lúča, pochod po lúči (ray traversal), prienik lúča s trojuholníkom, stromová štruktúra lúčov (ray tree) a jej použitie na výpočet lokálnej farby, problém presnosti priesečníkov). Metóda sledovania lúča na GPU, urýchľovacie techniky.

Lecture05 "Shading."

  • OPENGL Light sources
  • Shading Phong model
  • First time meeting with Rendering Equation
  • Book chapter Shading: shading.pdf

Lecture06 "Light Trasport."

  • Physics behind ray tracing
  • Physical light quantities
  • Visual perception of light
  • Light sources
  • Light transport simulation: Rendering Equation
  • Lecture notes: lesson05.pdf
  • Téma: Fyzikálny osvetlovací model a výpočet farieb renderovacou rovnicou. (definícia radiancie, definícia BRDF a jej vlastnosti, fyzikálne BRDF Cook-Tarrance, definícia priestorového uhlu, napíšte renderovaciu rovnicu a vysvetlite jej členy).

Lecture07 "Radiosity."

  • Diffuse reflectance function
  • Radiative equilibrium between emission and absorption, escape
  • System of linear equations
  • Iterative solution Neuman series
  • Lecture notes: lesson05.pdf
  • Book chapter Shading: shading.pdf

Lecture08 "BRDF."

  • Bidirectional Reflectance Distribution Function (BRDF)
  • Reflection models
  • Projection onto spherical basis functions
  • Shading Phong model, Blin-Phong model
  • Lecture notes: lesson07.pdf
  • Homework:
    • 1. Prove that the mirror BRDF from slides less07 fulfills the BRDF properties: reciprocity, energy conservation, definit space, value space of BRDF
    • 2. Derive the equation for refracted direction Omega_r from shading document in section 6.3.3.
  • Physical BRDF
  • Ward Reflection Model
  • Cook-Torrance model
  • Lecture notes: lesson07Phys.pdf

Lecture09, Lecture10 "Shadows."

  • Lecture notes: lesson08.pdf
  • Téma: Tiene, typy tieňov (mäkké, tvrdé, statické, dynamické), typy a popis algoritmov (projekčné, tieňové objemy, tieňové mapy (shadow mapping)), spôsoby implementácie jednotlivých algoritmov, artefakty a ich odstraňovanie, príklad shader programov pre tieňové mapy. Artefakty spôsobené diskretizáciou. Tiene vo Phongovom modeli.

Lecture11, Lecture12 "Texturing 1, 2."

  • Texture parameterization
  • Procedural methods
  • Procedural textures
  • Fractal landscapes
  • Lecture notes: lesson09.pdf
  • Book chapter (Surface reality techniques): lessonBoook09.pdf
  • Téma: Lokálne osvetľovacie modely. (tieňovanie, Phongov a Blinn-Phongov osvetlovací model, zložky (ambientna, difúzna, zrkadlová), textúrovanie a druhy textúr, mapovanie a filtrácia textúr, popísať princípy environment, bump, normal mapovania, textúrovací a tangenciálny priestor, príklad shader programov na GPU.

Lecture13 "Image Based Rendering 1."

  • Plenopticfunction
  • Panoramas
  • Concentric Mosaics
  • Light Field Rendering
  • The Lumigraph
  • Lecture notes: lesson10.pdf
  • Homework: Blinn-Phong enumeration.

Lecture14 "Image Based Rendering 2."

  • Layered Depth Images
  • View-dependent Texture Mapping
  • Surface Light Fields
  • View Morphing
  • Lecture notes: lesson10.pdf

Lecture15 "Ask me anything."

  • Test problem introduction

Seminars on Advanced Computer Graphics

On Thursdays at 13:10.

See recordings from previous year.

Guide: Lukáš Gajdošech

Contact: lukas.gajdosech@fmph.uniba.sk

Info

Each week a short guided presentation will be given.

An assignment for every week will be finishing a template C# project. The deadline for every assingment is midnight before the next successive seminar. The extended deadline is a week after with 0.5x penalization. Solutions to bonus assignment can be submitted anytime during the 2 weeks without the penalization.

Grading

  • Total points from exercises make half of your final grade!
  • Minimum of 50% from exercises required to finish the class successfully
  • Late submission is for 0, no discussion

Project Evaluation Criteria

  • 10 pt => Correct submission, everything works as supposed.
  • 6 pt => Partially correct submission, most of the things work as supposed.
  • 3 pt => Partially correct submission, at least one core functionality correct.
  • 0 pt => Incorrect submission or unsubmitted.
  • Penalization 0.5x when submitting in extended deadline (not for bonus).

Project Submittion

  • Your code should be well formatted and commented. Titles of functions, classes, variables should be representative of their purpose.
  • Submission email must have the subject in the form of 'ACG ExNN' where NN is the exercise id, eg. ACG Ex05.
  • Solution source codes have to be archived and named properly 'ExNN_YourName'
  • Do not archive and send executable files.
  • Send by email to lukas.gajdosech@fmph.uniba.sk.

Exercises

Exercise00 "Introduction"


Exercise01 "Vectors and Matrices"

Deadline (no extended deadline): 22.2.2023 at 23:59

Asignment: Create a simple application for vector(4x1) and matrix operations(4x4). Use struct properties, functions and/or operators. Create a calculator, check your equations and results. Add implementation to theese files in folder ./Mathematics/ : Vector4.cs, MathEx.cs, and Matrix44.cs.

[2 bonus %]: Vector operations "/" (vector projection) and "^" (modulation product).

For a help, see this reminder on linear algebra and/or useful tutorial on transformation matrices.

Exercise02 "Ray Casting"

Deadline: 1.3.2022 at 23:59 Extended deadline: 8.3.2022 at 23:59

Seminar slides

Asignment: Implement basic ray casting and the intersection of ray and plane. Define the camera class and implement a simple ray-casting procedure.

Exercise03 "Primitives"

Deadline: 8.3.2023 at 23:59 Extended deadline: 15.3.2023 at 23:59

Seminar Slides

Asignment: Improve your tracer by adding new primitive object types: box, sphere, and ring.

Resources: Planes, triangles, and distances, Intersection algorithms

Bonus [3 bonus % (1 for each)]: Create also a triangle, cylinder, and cone primitives and add them to the tracer. Also, create a new scene where you present the primitive(s).

Exercise04 "Shaders, Shading and Shadows"

Deadline: 15.3.2023 at 23:59 Extended deadline: 22.3.2023 at 23:59

Seminar Slides

Asignment: Improve your tracer by implementing Phong and checker shaders, directional light, and hard shadows. Compute normals of each primitive at the point of intersection. As usual, you should get a similar functionality as in the sample application.

Exercise05 "Light Types"

Deadline: 22.3.2023 at 23:59 Extended deadline: 29.3.2023 at 23:59

Seminar Slides

Asignment: Improve your tracer by adding a point, spot and an area light types. In the case of point and spotlight, define the light as a point with hard shadows and linear/quadratic light attenuation [2]. Area light could be defined by Lights x Lights point lights. Area light should also be able to produce "soft" shadows.

[2 bonus %]: Write an equation for illumination computed by sample code from seminar slides

Exercise06 "Shaders"

Deadline: 5.4.2023 at 23:59 Extended deadline: 12.4.2023 at 23:59

Seminar Slides

Asignment: Improve your tracer by adding a few more shaders: Toon, Gradient, Cook-Torrance, and Oren-Nayar.

[2 bonus %]: Implement Ward Shader [ Example ].

  • Generate tangent space for each point on the sphere
  • Remember to keep the same orientation of tangent space at each point

Exercise07 "Reflections"

Deadline: 19.4.2023 at 23:59 Extended deadline: 26.4.2023 at 23:59

Seminar Slides

Asignment: Improve your tracer by adding reflections for rendering mirror-like materials.

Exercise08 "Transparency"

Deadline: 26.4.2023 at 23:59 Extended deadline: 3.5.2023 at 23:59

Seminar Slides

Asignment: Improve your tracer by adding reflections and refractions for rendering glass materials.

[2 bonus %]: Implement fresnel effect.

Exercise09 "Postprocessing"

Deadline (no extended deadline): 10.5.2023 at 23:59

Seminar slides

Asignment: Add supersampling antialiasing [3] and implement blur. Users can scale the intensity of blur [4].

[2 bonus %]: Implement DOF. You can use the definition from blur to create a fake DOF. A user can define a point of sharpness and the intensity of the effect.

Exercise10 "Textures"

Deadline (no extended deadline): 24.5.2023 at 23:59

Seminar slides

Asignment: The time has come to finalize your project. Use textures in your ray tracer [5] [6]. Implement plane, and normal mapping [7]. Your results should be similar to the given sample.

Tutorial:

  • Define class Sampler and its descendants: class ColorSampler(only color) and class TextureSampler(also texture). Texture sampler should use some sort of sampling (clamp) and some sort of filtering (nearest neighbor).
  • Define class TextureMapping and its descendants: class PlaneMapping and class NormalMapping.
  • Improve phong shader to include sample point from the texture.

[1 bonus %]: Implement sphere mapping [8].

Exercise11 (optional/voluntary) "Acceleration Structures"

Seminar slides

Asignment: Implement accelerating structure for ray tracing. The structure is KD Trees + surface area heuristic (SAH). The dimension is 2. As usual you should use a similar functionality as in the sample application.