记NatureManufacture Shaders/Mobile Water River在Mobile平台上像素化表现的Bug

本文探讨了一种Shader导致的严重像素化问题,并详细解释了如何通过改变UV坐标系统来解决模型缩放引起的UV插值精度问题。

表现为一格一格严重的像素化;

原Shader使用了一张默认的纹理
[HideInInspector] _texcoord( "", 2D ) = "white" {}
然后在surf中,使用了i.uv_texcoord进行UV运算; 这样就和模型的UV关联上了,当模型缩放的特别大,或者本地坐标系特别大
那么uv的插值会出现精度问题;即相邻的一段像素采样(命中)了同一个像素点

修正后的uv坐标系统使用worldPos坐标系统进行转换
即 float2 uv_texcoord = i.worldPos.xz / _WaterScale;
问题得到解决.

 

 

Interaction, wind, and better shading for your vegetation. Nature Shaders is a collection of shaders for your vegetation that brings you player interaction, wind simulations, better quality shading, and more. You can easily convert and import models from any source, such as SpeedTree, Megascans, or other assets from the Unity Asset Store. Nature Shaders’ unique algorithm automatically analyzes the models and materials and converts them for you. The shaders are built upon a shader-framework that is trusted and used by over 25,000 developers. You can expect polished, easy-to-use, and well-optimized shaders, with extensive documentation. Supports all platforms and all render pipelines The shaders work out-of-the-box in all render pipelines, without any additional setup. You can use your vegetation models in all render pipelines, even if the vegetation was not created for that specific pipeline. One-click Setup Just click on a prefab and convert it to a Nature Asset, and the prefab and materials are converted and configured for you automatically. FEATURES ――― Interaction Push down grass, have plants sway, and leave a trail behind objects. Any object in the scene can interact with vegetation. The only thing you need to do is add a collider to the object. Wind Simulate the wind passing through your vegetation, from calm days to violent storms. Translucency Simulate light passing through leaves. This results in more realistic lighting that shades your vegetation correctly in all lighting conditions. Color Correction Change the color of vegetation using accurate color correction methods. You can even add color variations for the same vegetation throughout the scene. Perspective Correction Tilt grass away from the camera when looked at from a top-down perspective. This creates a more dense and realistic look. Dynamic Masking Remove vegetation within a specific area, or reduce the density. Useful to hide vegetation under buildings, to let the player cut gr
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值