Directional light shadows 平行光阴影 光照系列9

本文详细介绍了Unity中平行光阴影(Directional Light Shadows)的问题,如透视锯齿,以及如何通过阴影级联(Shadow Cascades)和阴影距离优化来改善效果。内容涵盖阴影级联的工作原理、视觉化调整以及阴影Pancaking技术,以减少阴影粉刺。
摘要由CSDN通过智能技术生成

Directional light shadows 平行光阴影

本文档主要是对Unity官方手册的个人理解与总结(其实以翻译记录为主:>)
仅作为个人学习使用,不得作为商业用途,欢迎转载,并请注明出处。
文章中涉及到的操作都是基于Unity2018.3版本
参考链接:https://docs.unity3d.com/Manual/DirLightShadows.html

A directional light typically simulates sunlight and a single light can illuminate the whole of a scene. This means that the shadow map will often cover a large portion of the scene at once and this makes the shadows susceptible to a problem called perspective aliasing. Perspective aliasing means that shadow map pixels seen close to the camera look enlarged and chunky compared to those farther away.
方向光通常模拟阳光,一盏光灯可以照亮整个场景。这意味着阴影映射通常会同时覆盖场景的大部分,这使得阴影容易受到透视锯齿问题的影响。透视锯齿意味着,与远处的像素相比,靠近相机的阴影贴图像素看起来更大更粗。
在这里插入图片描述
Shadows in the distance (A) have an appropriate resolution, whereas shadows close to camera (B) show perspective aliasing.
距离(A)处的阴影具有适当的分辨率,而距离(B)处的阴影具有透视锯齿。

Perspective aliasing is less noticeable when you are using soft shadows and a high resolution for the shadow map. However, using these features will increase demands on the graphics hardware and so framerate might suffer.
当你使用软阴影和高分辨率的阴影映射时,透视锯齿不太明显。然而,使用这些特性会增加对图形硬件的需求,因此帧速率可能会受到影响。

Shadow cascades 阴影级联

The reason perspective aliasing occurs is that different areas of the shadow map are scaled disproportionately by the camera’s perspective. The shadow map from a light needs to cover only the part of the scene visible to the camera, which is defined by the camera’s view frus

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值