官术网_书友最值得收藏!

How it works...

Now that we've seen how the previous settings affect our scene, let's take some time aside to go over the theory behind them all. We will start explaining the very last parameter we've tweaked: the Screen Percentage.

The specifics behind this technique are quite simple: instead of rendering the scene at a fixed resolution, which would usually match that of our screens, we instead render at a different one. This second number needs to then be transformed back into the initial screen resolution, as that is a fixed variable. We are therefore left with two possible scenarios: if the initial resolution is greater than the one we are rendering the game image at, we would be talking about upscaling. If we are, on the other hand, rendering at a higher pixel density than that of our displays we get what is known as Supersampling. 

Upscaling is cheaper to render, as the engine needs to deal with a lower amount of pixels. The resulting image is of a lower quality than what we would if we weren't using this technique. Supersampling, on the other hand, takes advantage of the extra pixel count to create a higher quality image at the expense of being more demanding in terms of performance. It can be used as an anti-aliasing technique, as we are effectively reconstructing the image through this method.

Continuing with the topic of AA, let's focus once again on the different implementations that Unreal has decided to implement. There are four in total: the already-seen Supersampling, Temporal AA, FXAA, and MSAA. This last method is only available when we are using the forward renderer or developing for mobile platforms, which isn't the default state Unreal is targeting. Each method has its strengths and weaknesses, which we'll try to mention next.

FXAA is the cheapest AA method. It is one that was developed by nVidia, and it works on the rendered image that the engine outputs and not on the geometry of our levels. Because of that, it sometimes blurs the textures or operates beyond just the jagged edges we want to tweak so it can introduce unintended consequences. SSAA, or Supersampling anti aliasing, is the technique that we described before we first rendered the scene at a higher resolution and then downsampled it using an averaging filter, which makes the transition between pixels more smooth and greatly reduces jaggies. 

MSAA works in a similar way to SSAA, but in an optimized way. Instead of sampling the whole scene by rendering it at a higher resolution, MSAA takes different samples by just focusing on overlapping areas of the level. This saves up on performance while still achieving a great anti-aliasing result.

Finally, Temporal AA is a new actor in the anti-aliasing world. It is the one we use by default in Unreal, and it is a mix of a temporal filter solution, hardware anti-aliasing, and custom algorithms that work throughout the scene. It isn't as cheap to enable as FXAA, but the quality is much better overall. Choosing between one or the other is a matter of what you are trying to achieve with your project.

主站蜘蛛池模板: 天镇县| 德化县| 钦州市| 巫溪县| 正安县| 临城县| 灵石县| 霍邱县| 汝城县| 安阳市| 宝应县| 普陀区| 东乌珠穆沁旗| 班玛县| 罗城| 衡东县| 岳普湖县| 紫金县| 鄯善县| 鹰潭市| 鲁甸县| 鄂尔多斯市| 宜川县| 永修县| 青龙| 五河县| 湘潭市| 留坝县| 社会| 金溪县| 新巴尔虎右旗| 原平市| 泰和县| 英吉沙县| 陕西省| 藁城市| 肃宁县| 黄骅市| 河曲县| 葵青区| 墨脱县|