project raytracing. content goals idea of raytracing ray casting – therory – practice raytracing...
TRANSCRIPT
![Page 1: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/1.jpg)
Project Raytracing
![Page 2: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/2.jpg)
Content• Goals• Idea of Raytracing• Ray Casting
– Therory– Practice
• Raytracing– Theory– Light model– Practice
• Output images• Conclusion
![Page 3: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/3.jpg)
SpecificationsRay tracer depends on how to represent objects
Parametric equation for precision, not rapidity
Develop a Ray Tracer in order to explore a new intersection algorithm
Two teams :
- for mathematics
- for code
![Page 4: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/4.jpg)
Main principleCreate 3D pictures
Mathematical equation
Throw ray from eye to pixels
Not FROM source light: TO it
Number of reflections
Great pictures but slow
![Page 5: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/5.jpg)
AlgorithmsRay casting
- first method
- no bounce
Ray tracing
- from eye to pixels
- reflection
- refraction
- shadow
![Page 6: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/6.jpg)
Fields of useAnimation studio
Pixar: with parsimony
→ light effects
Video games
→ with triangles
→ faster and great
![Page 7: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/7.jpg)
Ray casting
For each pixel:
● Shoot a ray from the observer to the position of the pixel
● Test if the ray hits an object in the scene
● If there is a hit:
the color of this pixel will be the color of the object● If there is no hit:
the pixel receives the color of the background
![Page 8: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/8.jpg)
Ray casting
What do we need ?● A position for the observer (eye, camera)● A direction/object to look at (and a « way
up »)● An object to show on screen● A representation of the 2D screen in the 3D
space
![Page 9: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/9.jpg)
Ray casting
![Page 10: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/10.jpg)
Our Ray Caster
![Page 11: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/11.jpg)
From Ray Casting to Ray Tracing
![Page 12: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/12.jpg)
From Ray Casting to Ray Tracing
We add :● Lights
ambient, diffuse, specular● Shadows● Reflexion
=> recursion : another ray is shot from the intersection
● Material properties
ambient, diffuse, and specular coefficients
![Page 13: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/13.jpg)
Lightmodel• Used: Phong reflection model• 3 types of light: ambient, diffuse, specular
=
![Page 14: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/14.jpg)
Ambient and Diffuse
The coefficient is specific for a material
![Page 15: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/15.jpg)
Specular
![Page 16: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/16.jpg)
Shadows• Only add diffuse and
specular light, if a lightsource is visible
• Test for intersections between a point on the sphere and the lightsource
![Page 17: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/17.jpg)
From Ray Casting to Ray Tracing
We add :● Lights
ambient, diffuse, specular● Shadows● Reflexion
=> recursion : another ray is shot from the intersection
● Material properties
ambient, diffuse, and specular coefficients
![Page 18: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/18.jpg)
![Page 19: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/19.jpg)
![Page 20: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/20.jpg)
![Page 21: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/21.jpg)
![Page 22: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/22.jpg)
![Page 23: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/23.jpg)
![Page 24: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/24.jpg)
![Page 25: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/25.jpg)
Video link 1
![Page 26: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/26.jpg)
Video link 2
![Page 27: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/27.jpg)
Interesting modules● Positionning of the screen in 3D space● The RayTracer class
● That's the core of the program (light model)● Shadows
● The use of inheritance to compute intersections● Obtaining an animation
● Camera and lights movement● Export a sequence of images, make a movie
● The Draughtboard
![Page 28: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/28.jpg)
![Page 29: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/29.jpg)
Difficulties
- math libraries- C++, compilation, building environment- Screen implementation- Unexpected results (debugging)
![Page 30: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/30.jpg)
Achievements
Light effectsAnimation renderingDifferent shapesAntialiasing
![Page 31: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/31.jpg)
ImprovementsRefraction and transparencyTextures and noiseDepth of FieldImage mappingBounding VolumeRadiometry (power, energy, radiance...)Photon mapping
![Page 32: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/32.jpg)
Thanks!
Thank you for your attention!
![Page 33: Project Raytracing. Content Goals Idea of Raytracing Ray Casting – Therory – Practice Raytracing – Theory – Light model – Practice Output images Conclusion](https://reader036.vdocuments.net/reader036/viewer/2022062314/56649e915503460f94b965ba/html5/thumbnails/33.jpg)
Questions?