Mesh Filter & Mesh Render

Mesh Filter

  The Mesh Filter takes a mesh from your assets and passes it to the Mesh Renderer for rendering on the screen.

  Mesh Filter决定使用哪一个Mesh。Mesh Filter只有一个参数,就是指定Mesh。

  

  When importing mesh assets, Unity automatically creates a Skinned Mesh Renderer if the mesh is skinned, or a Mesh Filter along with a Mesh Renderer, if it is not.

Mesh Render

  The Mesh Renderer takes the geometry from the Mesh Filter and renders it at the position defined by the object's Transform component.

  Mesh Render 负责渲染 Mesh Filter 指定的 Mesh,在 Transform 的位置渲染这个Mesh。

  

  Mesh Render参数主要指定是否产生和接受阴影,以及使用了Meterial。

  Meshes imported from 3D packages can use multiple Materials.  Each submesh will use one material from the materials list. If there are more materials assigned to the Mesh Renderer than there are submeshes in the mesh, the first submesh will be rendered with each of the remaining materialsone on top of the next. At a cost of performance, this will let you set up multi-pass rendering on that submesh. Fully opaque materials, however, will simply overwrite the previous layers, costing performance for no advantage.

  如果有多个Meterial,并且Meterial数量多过Submesh的数量,则第一个Mesh会使用自己对应的meterial以及剩下的meterial。排最后的meterial会被前面的meterial覆盖或混合。

  一个GameObejct如果拥有多个Material,则Unity会将多个Material转化为多个Pass。

转载于:https://www.cnblogs.com/Dearmyh/p/10685356.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值