Unity3D图像后处理特效——Depth of Field 3.4
Depth of Field 3.4 is a common postprocessing effect that simulates the properties of a camera lens. The name refers to the fact that the effect has had significant performance and feature improvements in Unity 3.4.
景深3.4特效是一种常见的模拟相机透镜的后处理特效。它的名字反映了在Unity3.4中该特效有了重要特性增强以及性能增强。
In real life, a camera can only focus sharply on an object at a specific distance; objects nearer or farther from the camera will be somewhat out of focus. The blurring not only gives a visual cue about an object's distance but also introduces bokeh which is the term for pleasing visual artifacts that appear around bright areas of the image as they fall out of focus.
现实生活中,相机可以只专注特定距离的物体;更近或更远的物体将会出现一定的失焦现象。模糊不仅提供了一个关于物体距离的视觉提示,同时也带来了散景(bokeh)效果,这种效果是由图片中明亮失焦物体而产生的。
An example of the new Depth of Field effect can be seen in the following images, displaying the results of a defocused foreground and a defocused background. Notice how the foreground blur overlaps with the rest while the background doesn't.
新的景深效果显示如下面的图片,一个显示前景散焦效果,另一个显示背景散焦的效果。可以看到前景的模糊区域会蔓延,并与其他部分重叠,而背景模糊则不会。
只是附近的管道是在聚焦区域
景深效果中的前景模糊与背景模糊
You might also consider using theTilt Shift effect for a more straightforward but less sophisticated depth-of-field effect.
As with the otherimage effects, this effect is only available in Unity Pro and you must have the Pro Standard Assets installed before it becomes available.
您还可能会考虑使用Tilt Shift效果来得到更加直接但简单的景深效果。和其他图像特效一样,该特效只能在Unity Pro上进行使用,并且在使用之前必须安装Pro Standard Assets。
Properties 属性
General Settings 一般设置 |
|
Resolution 分辨率 |
Determines the internal render target sizes. A lower resolution will result in faster rendering and lower memory requirements. 确定内部渲染目标的大小。较低的分辨率将导致更快地渲染效率和较低的内存要求 |
Quality 质量 |
The quality level. Choose between the faster OnlyBackground or the higher-quality BackgroundAndForeground which calculates the depth-of-field defocus for both areas separately. 质量级别。在OnlyBackground和BackgroundAndForeground之间进行选择。前者更快,后者质量更高。 |
Simple tweak 简单调整 |
Switches to a simpler focal model. 调整到简单的聚焦模型 |
Visualize focus 可视焦点 |
This shows the focal plane in the game view to assist learning and debugging. 在游戏中显示当前的聚焦平面,从而来帮助学习和调试。 |
Enable bokeh 开启散景 |
This will generate more realistic lens blurs where very bright parts are scaled and overlap. 这将生成更真实的透镜模糊效果,对很明亮的地方进行缩放与区域重叠。 |
Focal Settings 聚焦设置 |
|
Focal distance 聚焦距离 |
The distance to the focal plane from the camera position in world space. 在世界空间中焦平面到相机的距离 |
Object Focus 物体聚焦 |
Determine the focal distance using a target object in the scene. 使用场景中的目标物体来决定的聚焦距离 |
Smoothness 光滑度 |
The smoothness when transitioning from out-of-focus to in-focus areas. 从失焦区域到聚焦区域的光滑度 |
Focal size 聚焦尺寸 |
The size of the in-focus area. 聚焦区域的尺寸 |
Blur 模糊 |
|
Blurriness 模糊次数 |
How many iterations are used when blurring the various buffers (each iteration requires processing time). 模糊各种缓存的迭代次数(每次迭代都需要一定的处理时间) |
Blur spread 模糊半径 |
The blur radius. This is resolution-independent, so you may need to readjust the value for each required resolution. 模糊半径,这是与分辨率相关的,所以您需要对于每个特定的分辨率重新设定该值。 |
Bokeh Settings 散景设定 |
|
Destination 目标 |
Enabling foreground and background blur increases rendering time but gives more realistic results. 开启前景和背景模糊,虽然会增加渲染时间,但会得到更加真实的效果。 |
Intensity 亮度 |
Blend intensity used as bokeh shapes are being accumulated. This is a critical value that always needs to be carefully adjusted. 使用模拟的散景形状来混合亮度。这是一个很关键的数值,需要谨慎调整。 |
Min luminance 最小亮度 |
The luminance threshold below which pixels will not have bokeh artifacts applied. 亮度阈值,小于该值的像素将不产生散景效果。 |
Min contrast 最小对比度 |
The contrast threshold below which pixels will not have bokeh artifacts applied. The significance of this is that you usually only need bokeh shapes in areas of high frequency (ie, cluttered or "noisy" areas of image) since they are otherwise nearly invisible. Performance will be improved if you use this parameter to avoid generating unnecessary bokeh artifacts. 对比度阈值,小于该值的像素将不产生散景效果。该值的重要意义在于你通常只想场景中一些高频率地方(即图片中的噪声区域)产生散景效果,否则他们将几乎无法看见。如果您使用该值,将提升渲染性能,因为这样做可以避免生成一些不必要的散景效果。 |
Downsample 下采样 |
The size of the internal render target used for accumulating bokeh shapes. 模拟散景形状的内部渲染目标的尺寸 |
Size 尺寸 |
The maximum bokeh size. Will be modulated by the amount of defocus (Circle of Confusion). 最大的散景效果尺寸。可以通过散焦程度来进行调整(模糊圈) |
Bokeh Texture 散景纹理 |
The texture defining the bokeh shapes. 定义散景形状的纹理 |
Note that since the bokeh effect is created by drawing triangles per pixel, it can drastically affect your framerate, especially if it's not adjusted optimally. Adjust theSize, Min luminance, Min contrast,Downsample and Resolution to improve performance. Also, since the screen is darkened before the bokeh shapes are applied, you should use an appropriateBlurriness level to remove possible artefacts.
请注意由于散景效果的创建是通过在每个像素上渲染三角形,所以会大幅度地影响您的帧速率,特别是在没有进行优化调整的时候。您可以调整大小、最小亮度、最小对比度、下采样和分辨率来提高性能。此外,由于在使用散景形状之前场景会变暗,所以您应该使用合适的模糊级别来去除可能产生的瑕疵。
Hardware support 硬件支持
This effect requires a graphics card with pixel shaders (3.0) or OpenGL ES 2.0. Additionally, depth texture support is required. PC: NVIDIA cards since 2004 (GeForce 6), AMD cards since 2005 (Radeon X1300), Intel cards since 2006 (GMA X3000); Mobile: OpenGL ES 2.0 with depth texture support; Consoles: Xbox 360, PS3.
这个特效需要显卡拥有像素着色器(3.0)或者OpenGL ES 2.0,同时需要支持深度纹理。台式机:2004年以后的NVIDIA显卡(GeForce6),2005年以后的AMD显卡(Radeon X1300),2006年以后的Intel卡(GMA X3000);移动设备:OpenGL ES 2.0并支持深度纹理;控制台: Xbox 360、 PS3。
All image effects automatically disable themselves when they can not run on end-users graphics card.
所有图像特效如果无法在用户显卡上运行时将会自动被关闭。
Unity3D图像后处理特效——Depth of Field 3.4的更多相关文章
- 景深(Depth of Field)
http://www.cnblogs.com/cxrs/archive/2013/03/22/DepthOfFeild.html 景深(Depth of Field) 什么是景深? 所谓景深,就是当焦 ...
- 基于光线追踪的渲染中景深(Depth of field)效果的实现
图形学离线渲染中常用的透视摄像机模型时根据小孔成像的原理建立的,其实现通常是从向成像平面上发射ray,并把trace这条ray的结果作为成像平面上对应交点的采样结果.即: 图片来自<Fundam ...
- Win8 Metro(C#)数字图像处理--2.73一种背景图像融合特效
原文:Win8 Metro(C#)数字图像处理--2.73一种背景图像融合特效 /// <summary> /// Image merge process. /// </summar ...
- 虚幻UE4的后处理特效介绍 http://www.52vr.com/thread-31215-1-1.html
转载 虚幻UE4提供了后处理特效的功能,可以实现景深,光溢出,色调调整,饱和度等等.要使用虚幻4的后处理,就一定要用到PostProcessVolumn,这是一种特殊的体积,可以放置在场景中的任何位置 ...
- opencv滤镜-使用opencv实现各种图像滤镜特效
图像处理-滤镜 链接:https://mangoroom.cn/opencv/image-processing-filter.html opencv滤镜-实现晕影vignetting效果 链接:htt ...
- [ZZ] 景深效果(Depth of Field) , Pass1 将场景渲染到一个RenderTarget,做为清晰版, Pass2: BluredRT , Pass3: WDepth = Depth / Far_Z_Clip
http://blog.csdn.net/xoyojank/article/details/1883520 什么是景深效果? 景深效果,简称DOF,在人眼跟光学摄像设备上很常见.如下图: 简单地来 ...
- yebis error ---depth of field
前几天在墙外无法登陆cnblogs...导致很多blogs就没写了 有几篇比较值得记下来的,但是我已经不记得了,应该和sao有关scalable ambient obscurance 我似乎回忆起一点 ...
- unity3d 摄像机抖动特效
摄像机抖动特效 在须要的地方调用CameraShake.Shake()方法就能够
- DragSelectRecyclerView 长按滑动多选图像android特效
高仿Google相册多选效果,长按某一item后然后滑动选择到任意item,效果很不错,适合相册页面多选部分效果. 本例子主要是自定义DragSelectRecyclerView通过如下展示gridv ...
随机推荐
- mysql 遍历方式
mysql遍历方式可以使用while,loop和repeat来实现,示例如下: BEGIN ; # WHILE DO ; END WHILE; # SELECT i; # LOOP optLoop:L ...
- 报表统计——java实现查询某年某月每天数据,没数据补0
一般图表绘制例如echarts等,返回数据格式都大同小异.重点是利用sql或者java实现数据格式的转型,接下来是关键部分: 1.前提:提供的工具方法——获取某月有多少天 //通过年份和月份确定该月的 ...
- 聚类算法之K-means
想想常见的分类算法有决策树.Logistic回归.SVM.贝叶斯等.分类作为一种监督学习方法,要求必须事先明确知道各个类别的信息,并且断言所有待分类项都有一个类别与之对应.但是很多时候上述条件得不到满 ...
- 孙悟空的七十二变是那般?--java类型的七十二变揭秘
故事背景 在<西游记>原著第六回,孙悟空大闹天宫反下界,玉帝派十万天兵围剿,却被打得落花流水.玉帝不得不放下架子,请自己外甥二郎神回来支援.孙悟空与二郎神本事差不多,两人斗得不分胜负,但二 ...
- 【Linux】Linux中的0644 和 0755的权限
Linux 系统中采用三位十进制数表示权限,如0755, 0644ABCD A- 0, 表示十进制B-用户C-组用户D-其他用户 利用 ls -l可以查看文件的权限 --- -> 0 (n ...
- CSS技巧 (1) · 结构和布局
前言 这一篇主要是总结关于结构和布局的一些技巧,不管什么,一个网页上来,最重要的是先确定他的结构和布局,实现基本的布局之后,我们再进行局部的优化和交互特效. 这一篇主要讲 关于 自适应内部元素 的内 ...
- [WP8.1]给Pivot的Header加上颜色
先上个效果图 以前想实现这个给Pivot加颜色时只找到8的,通过参考8的实现方式,8.1的实现如下,在Pivot的样式上做一些修改,如下图的红框处 另外如果要改Pivot的Header里文字的颜色又要 ...
- eclipse 的使用
eclipse 的官方下载:https://www.eclipse.org/downloads/ 安装时选择 :Eclipse IDE for Java EE Developers 设置: 1. 编 ...
- 介绍ArcGIS中各种数据的打开方法——tin(栅格文件)
4.加载栅格文件 栅格数据是GIS中重要的数据源之一,如卫星图像.扫描的地图.照片等. 栅格数据常见的格式有Bmp.Tiff.Jpg.Grid等. 添加栅格数据主要使用Rasterlayer 组件类, ...
- Kali升级2018&&2019
0X01修改更新源 vim /etc/apt/sources.list #中科大 deb http://mirrors.ustc.edu.cn/kali kali-rolling main non-f ...