Direct3D9的学习历程二:Direct3D9中的灯光

博客介绍了Direct3D相关知识,它支持方向、点、聚光灯光源三种光源模型,光源可发射环境光、漫反射光和镜面反射光。还说明了表面材质决定光与表面的交互效果,顶点法向量用于定义顶点方向,帮助Direct3D确定光照射顶点的角度。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Direct3D supports three light source models: directional lights,point lights, and spot lights. Light sources emit three types of light:ambient light, diffuse light, and specular light.

Direct3D支持三种光源模型:方向光源,点光源,聚光灯光源。这些光源可以发射出三种光:环境光,漫反射光,镜面反射光。

The material of a surface defines how light interacts with the sur-face that it strikes (that is, how much light is reflected andabsorbed, thus determining the color of the surface).

一个表面的材质被定义为当一束光穿过这个表面时会产生什么样的效果。(多少光被反射和多少光被吸收是取决于该表面的颜色)

Vertex normals are used to define the orientation of a vertex. They are used so that Direct3D can determine the angle at which a ray of light strikes the vertex. In some cases, the vertex normal is equal to the normal of the triangle that it forms, but this is not usually the case when approximating smooth surfaces (e.g., spheres,cylinders).

顶点法向量常常被定义为一个顶点的方向。Direct3D使用它们来决定一束光穿过顶点的角度。在某些情况下,顶点法向量就等于它所构成的三角形面的法向量,但是在曲面上这种情况并不是常常一致的。(如球体,圈体)

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值