当前位置:网站首页>Pit of smoothstep node in shadergraph
Pit of smoothstep node in shadergraph
2022-06-30 04:57:00 【LintonL】
ShaderGraph in SmoothStep node , Introduction in the document :
If input In The value of is in the input Edge1 and Edge2 Between the values of , return 0 and 1 Between the smooth Hermite interpolation results . If input In The value of is less than the input Step1 Value , return 0; If it's greater than the input Step2 Value , return 1.
This node is similar to Lerp node , But there are two significant differences . First , When using this node , User specified range , The return value is between 0 and 1 Between . This can be seen as related to Lerp node contrary . secondly , This node uses smooth Hermite interpolation , Instead of linear interpolation . This means that the interpolation will gradually speed up from the beginning , And slow down near the end . This is for creating natural animations 、 Fade in, fade out and other transitions are very useful .
Specific reference Smoothstep node | Shader Graph | 10.5.0
then , I encountered a problem when making case contact

How does this figure pass through SmoothStep Node to get the gradient bar , After many tests, I got the result , Not necessarily right , Some big guys know the principle , We can discuss .
Pictured above ,edge1 Is the coordinates of the model itself Y value , Values for 0 to 1,edge2 by Offset value , For an externally adjustable threshold ( Control where the black belt appears ),In The value is Offset Subtract one -0.5 to 0 A value of ( Controls the width of the black band in the graph ), If you do not change the value , Then only edge1 It is changing. ,edge1 from 0 Change to 1 The process of ,edge1 The value of edge2 near ,edge1 and edge2 The distance is getting smaller and smaller , And because of In The value of is always higher than edge2 A small fixed value ( Width ), So the final output is getting closer edge1 Of , namely in It changes from white to black ( See the node explanation above , In between , Is from the closer edge1,in Values tend to 0, On the contrary, it tends to 1, And not linear ), In this case ,edge1 from 0 Change to In Value can explain . From the following figure , After the results are flipped , Obviously , The lower half is gradient , Not solid .
And then there was edge1 Greater than In The value of , That's it In Less than edge1, return 0; Here's the picture , I did the result Step operation , Less than 0.01 Of , This is the part .

Then why did it turn white again , This is what I have been thinking about before , He when edge1>edge2 When , He can't form an interval , Greater than edge2 by 1, Less than edge1 by 0, Between the two is 0-1 change , These three cases are combined , There are intersections , There will be less than edge1, More than dege2, What is the result of this situation , After my test , The conclusion is that ,In Value close to which , It is the output value of which to follow , Here's the picture .


thus , This operation is also fully explained , And the results are consistent with the actual display .
边栏推荐
- Static keyword
- Approaching history, introduction to the London Guard Museum
- A collection of errors encountered in machine learning with unity
- brew安装nvm报nvm command not found解决方案
- Detailed explanation of the process of "flyingbird" small game (camera adjustment and following part)
- Solution to the 292 week match of Li Kou
- A must see cruise experience in Bangkok: visit the Mekong River and enjoy the scenery on both sides of the river
- Using the command line to convert JSON to dart file in fluent
- The most comprehensive summary notes of redis foundation + advanced project in history
- National Museum of Singapore - give you spiritual and physical satisfaction
猜你喜欢

Solution to Autowired annotation warning

The golden deer, a scenic spot in London -- a sailing museum that tells vivid sailing stories

MySQL query gadget (I) replace a property value of the object in the JSON array in the JSON format string field

Why does the computer have no network after win10 is turned on?

Connect to the database and run node JS running database shows that the database is missing

Efficiency test of adding and querying ArrayList and LinkedList

Recommended cultural landmarks of these tourist attractions in Bangkok

【Paper】2019_ Consensus Control of Multiple AUVs Recovery System Under Switching Topologies and Time D

What to do when the alicloud SSL certificate expires

Exploration of unity webgl
随机推荐
力扣2049:统计最高分的节点数目
LxC and LXD container summary
Deep learning ----- different methods to realize inception-10
[UGV] schematic diagram of UGV version 32
MySQL查询小工具(一)json格式的字符串字段中,替换json数组中对象的某个属性值
redis集群概念
Unity3d Google Earth
National Museum of Singapore - give you spiritual and physical satisfaction
Unity download and installation website
Solution to Autowired annotation warning
One interview question a day the difference between B tree and b+ tree
Deeply understand the function calling process of C language
【Paper】2019_ Distributed Cooperative Control of a High-speed Train
003-JS-DOM-Attr-innerText
Unit screenshot saved on the phone
一条命令运行rancher
Unity script life cycle and execution sequence
Preorder traversal of Li Kou 589:n fork tree
Unreal 4 learning notes - set player birth point
HTC vive cosmos development - handle button event