Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我目前正在学习立方体映射,我找到了这个教程:http ://www.keithlantz.net/2011/10/lighting-and-environment-mapping-with-glsl/他通过与转置的倒数相乘来变换法线向量Model矩阵。我想知道为什么他不乘以转置矩阵的逆ModelView矩阵而是Model矩阵?
Model
ModelView
立方体贴图是在字空间中定义的,看来作者也希望在字空间中具有纹理坐标。
请注意,一个法线被转换为视图空间 - 用于照明,第二个仅用于在立方体贴图中查找。
两个链接供参考: