当前位置:网站首页>Games101 Lesson 7 shading 1 Notes
Games101 Lesson 7 shading 1 Notes
2022-07-06 07:23:00 【Fenghou Qimen L】
To color 1
One 、 The depth of the cache (Z-buffering)
(1) Painter algorithm : Like an oil painter painting , Draw the farthest first , Paint and cover from far to near .
① Painter's algorithm works in most cases , You need to arrange the distance first .
② But if there is partial coverage of each other , There will be problems with the painter's Algorithm , Here's the picture .
(2) The depth of the cache 
① The depth of the cache Z-buffer The algorithm records the depth of each pixel , In addition to recording the color of each pixel , The depth of each pixel is also recorded .
② The pseudo code of deep cache is as follows .
③ An example of deep caching is as follows .
④ The complexity of the deep cache algorithm is O(n).
Two 、 To color (Shading)
(1) Coloring in this course refers to applying different materials to objects .
(2) A simple coloring model :Blinn-Phong Reflectance Model
① Highlights are shown from top to bottom 、 Diffuse reflection 、 Three parts of ambient light .
(3) Shading point
① These inputs are required : Observation direction 、 normal 、 The direction of the light 、 Surface parameters ( Such as color 、 Brightness, etc ).
② Observation direction 、 normal 、 The illumination directions are unit vectors .
③ Shading discussed in this section does not consider shadows .
3、 ... and 、 Diffuse reflection (Diffuse Reflection)
(1) Definition of diffuse reflection 
① Light will be reflected evenly to all angles .
② The color is the same in all observation directions .
(2) The energy that light at different angles can accept 
(3) Light attenuation 
① The farther away the point is, the energy of light will be attenuated .
② For example, light radiates a circle , The length of the circumference near , The circumference in the distance is long , According to the conservation of energy , Distant points should get less energy .
(4)Lambertian Shading
① Combined with the energy received by light at different angles and the light attenuation formula, the coloring of a point can be obtained .
(5) Different diffuse reflection coefficients kd Examples of different coloring situations obtained .
reference
Course video link : GAMES101 Lecture07 Shading 1
边栏推荐
- Bloom taxonomy
- Résumé de la structure du modèle synthétisable
- word设置目录
- chrome查看页面fps
- Typescript function definition
- LeetCode Algorithm 2181. Merge nodes between zero
- Cookie技术&Session技术&ServletContext对象
- Wechat brain competition answer applet_ Support the flow main belt with the latest question bank file
- ORACLE列转行--某字段按指定分隔符转多行
- L'auteur est mort? Ai utilise l'art pour conquérir l'humanité
猜你喜欢

Lesson 12 study notes 2022.02.11

How are the open source Netease cloud music API projects implemented?

杰理之BLE【篇】

Set picture annotation in markdown

升级版手机检测微信工具小程序源码-支持多种流量主模式

Oracle database 11gr2 uses TDE transparent data encryption to report an error ora28353. If you run to close the wallet, you will report an error ora28365. If you run to open the wallet, you will repor

Path analysis model

Crawling exercise: Notice of crawling Henan Agricultural University

Oracle column to row -- a field is converted to multiple rows according to the specified separator
![When the Jericho development board is powered on, you can open the NRF app with your mobile phone [article]](/img/3e/3d5bff87995b4a9fac093a6d9f9473.png)
When the Jericho development board is powered on, you can open the NRF app with your mobile phone [article]
随机推荐
Multithreading and concurrent programming (2)
Oracle database 11gr2 uses TDE transparent data encryption to report an error ora28353. If you run to close the wallet, you will report an error ora28365. If you run to open the wallet, you will repor
Ble of Jerry [chapter]
Sélectionnez toutes les lignes avec un symbole dans Word et changez - les en titre
Babbitt | metauniverse daily must read: the group image of Chinese Internet enterprises pouring into metauniverse: "there are only various survival desires, and there is no ambition for forward-lookin
Word delete the contents in brackets
Chrome view page FPS
Upgraded wechat tool applet source code for mobile phone detection - supports a variety of main traffic modes
How MySQL merges data
Yield method of tread
超级浏览器是指纹浏览器吗?怎样选择一款好的超级浏览器?
How Navicat imports MySQL scripts
TypeScript void 基础类型
MVVM of WPF
智能终端设备加密防护的意义和措施
变量的命名规则十二条
Cookie Technology & session Technology & ServletContext object
Excel的相关操作
leetcode841. Keys and rooms (medium)
Structure summary of SystemVerilog integrable model