so continuing our journey we need to 继续我们需要的旅程
actually bring more liquid into this and 实际上为此带来了更多的液体
the way we're gonna do it in this lesson 我们将在本课中采用的方式
is not the way we did it last lesson 不是我们上一课的方式
last lesson we used a volume source by 上一课我们使用了音量源
source is cool for like having water 来源很酷，就像喝水一样
pour into something you know things of 倒入你知道的东西
that nature for simulations that are 那种模拟的本质
part of a larger simulation like ocean 像海洋这样的大型模拟的一部分
stuff also does this but again for us a 东西也这样做，但对我们来说再一次
river that has what are coming in and 河里有什么东西进来的
what are going out it's really great to 什么东西真的很棒
use this thing on the flip side over 在翻转侧使用这个东西
here called use boundary layer mmm use 这里称为使用边界层mmm使用
boundary layer basically allows us to 边界层基本上允许我们
specify a padding away from the boundary 指定远离边界的填充
so the boundary is of course the box the 所以边界当然就是盒子了
literal boundary versus M the maximum 字面边界与M的最大值
one I should say and we can say like if 一个我应该说，我们可以说，如果
this is XY and Z and lower padding 这是XY和Z以及较低的填充
meaning the lower you know the negative 意思是你知道负面越低
x negative Y negative Z sides and upper x负Y负Z侧和上部
padding is the positive ones then let's 填充是积极的，然后让我们
say the lower negative the lower X means 说较低的负数，较低的X意味着
that if I were to say oh I don't know 如果我要说哦我不知道
point five point five units into the 点五点五进入
simulation from this side every single 从这方面模拟每一个
sub step it will look at whatever we 子步骤它会看看我们做什么
have listed here and I'm going to turn 在这里列出，我要转
this on to apply boundary velocities 这是为了应用边界速度
because we want to do this for sourcing 因为我们想做这个来采购
water and also for sourcing the velocity 水，也用于提供速度
of it it will look in point five from 它将从第五点开始
here and it will replace whatever it 在这里，它将取代它
finds with particles that it will it'll 用粒子发现它会发现它
basically it'll find an SDF surface it 基本上它会找到一个SDF表面
will fill it with particles based on you 将填充基于您的粒子
know our particle separation here and 在这里知道我们的粒子分离
then it will also sample the velocity 然后它也将采样速度
volume in that same space to give those 同一空间的体积给予那些
brand new particles a reason to live now 全新的颗粒是现在生活的理由
as opposed to the volume source method 而不是音量源方法
that we started to talk about here which 我们开始在这里讨论哪个
certainly 当然
so sources flip and things of that 所以来源翻转和事情
nature but what it does at least by 自然，但它至少做了什么
default is it will kind of Union the 默认是会有点联盟了
incoming fluid with the fluid that's 流体流入的液体
already there now there are ways around 已经存在，现在有办法解决
that but this is just a nice clean way 但这只是一个很好的干净方式
of doing it anyway because that's is 无论如何，这样做是因为那是
what this is meant for it replaces it 这意味着它取代它
and then it's so if you always have this 如果你总是有这个，那就是这样
particles pushing in from the side and 颗粒从侧面推入
then you'll also have particles exiting 然后你也会有粒子退出
from this side and the pressure 从这方面和压力
calculation in general will kind of have 计算一般都会有
like a suction on this end and a push in 就像在这一端的吸力和推进
a pressure pushing on this end so we'll 为此我们将推动这方面的压力
have a nice flowing river I'm gonna say 我会说，有一条漂流的河流
actually 0.5 on both of these I want 实际上我希望这两个都是0.5
point 5 on the X here and the point 5 这里的X点5和点5
like I said as these kind of suction on 就像我说的那样吸气
that now I'll give you an idea so if I 现在，如果我，我会给你一个想法
just press play now nothing is happening 只是按下播放，现在什么也没发生
because there is nothing here but for 因为这里什么也没有
the sake of argument I could put the 为了争论，我可以把
initial state here and you'll see over 这里的初始状态，你会看到
here I mean you'll see that it happening 在这里，我的意思是你会看到它发生了
here it is the first point 5 units its 这里是第一点5个单位
sampling this one remember there is 对此进行抽样记得有
actually a surface here which is what 实际上这里的表面是什么
this is looking for a surface volume 这是寻找表面体积
which we do have so it's just looking at 我们确实拥有它只是看着它
the first point 5 here and again plain 第一点5这里又一次平淡
as day 作为一天
it is bringing them in now what is not 它现在把它们带入了什么不是
doing really is they're not really 真的是他们不是真的
moving there it looks like they're 在那里移动它看起来像是他们
moving they're not actually moving 移动它们实际上并没有移动
they're just being scattered in 他们只是被分散了
different locations on every frame 每一帧都有不同的位置
that's why you don't see what are 这就是为什么你不明白是什么
literally moving into this though 虽然真的进入了这个
they're just coming in but they have no 他们只是进来但他们没有
velocity there's no velocity volume if I 速度如果我没有速度音量
were to put this here - well that 把它放在这里 - 好吧
doesn't change the fact it's no velocity 并没有改变它没有速度的事实
volume so we need to come up with maybe 因此我们需要想出一些
even a better initial state surface and 甚至更好的初始状态表面和
also a velocity volume so it would like 它也是一个速度体积
to start from this I just want to chop 从这开始我只想砍
off all this in middle stuff because 在中间的东西，所有这一切，因为
although it does a good enough job at 虽然它做得很好
only sampling this area when I have 我有时只对这个区域进行采样
higher resolution Sims later on and 更高分辨率的模拟人生后来和
these will change every frame as I 这些将像我一样改变每一帧
change the velocity field and the actual 改变速度场和实际
shape of the incoming liquid every frame 每帧输入液体的形状
I don't want to have to recalculate all 我不想重新计算所有
this every frame but I can just 每一帧，但我可以
recalculate these little trimmings at 重新计算这些小装饰品
the edge so I might drop a box down 边缘，所以我可能会放下一个盒子
that's gonna represent the rest of the 这将代表剩下的
fluid set and what I mean by that is I'm 流体集和我的意思是我
gonna grab the box size paste that I 要抓住我的盒子大小的粘贴
want the Box Center paste that so you 想要Box Center粘贴那么你
can see so far it's you know it's the 可以看到目前为止，你知道它是
same it is the same as the pounds and 同样它和磅和
now I need to accommodate that fact that 现在我需要适应那个事实
we need to push in a little bit on the 我们需要推进一点点
sides let me use a bound because that's 让我使用绑定，因为那是
essentially what this is doing you can 基本上你正在做的事情
see lower padding lower padding it's the 看到较低的填充物较低的填充物就是这样的
same nomenclature so I'm gonna say pays 相同的命名法，所以我会说付钱
relative references here you'll see it's 相对参考，你会看到它
making it bigger they showed up this 使它更大他们出现了这个
year so I of course just need to do the 那么我当然只需要这样做
opposite now I'm gonna do them for all 现在，我要为所有人做这件事
of them even though we know we're only 即使我们知道我们只是
really gonna do with the X but for the 真的要用X而不是
sake of completeness we now have a 为了完整起见，我们现在有一个
robust solution that you can use if you 您可以使用的强大解决方案
wanted to remake this cool so we have 我想重拍这个很酷的东西
essentially our entire simulation - the 基本上我们的整个模拟 -
bounding area as is compared to this 边界区域与此相比较
which was our initial thing here so 这是我们最初的事情
really all's we need to do is V to be 真的，我们需要做的就是V
combined here to make that and then a 结合起来制作那个然后一个
rather be be from polygons to make that 而是来自多边形来做到这一点
then V to be combined to do that 然后将V组合起来做到这一点
subtraction 减法
let's actually start from this one 让我们从这个开始吧
because this one has already has the 因为这个已经有了
subtraction from the collider so go from 从对撞机减去所以从
that to that STS difference and there 那个STS的区别就在那里
you go now we have a much smaller area 你现在去，我们的面积要小得多
that we can play with here so the first 我们可以在这里玩第一个
thing we'll do is let's work on the the 我们要做的就是让我们继续努力
surface the new surface I mean the 表面新表面我的意思是
incoming source surface so let's convert 传入的源表面让我们转换
this to polygons the resolution is tied 这对于多边形而言，分辨率是相关的
to it gets its very low resolution 它的分辨率非常低
because that's what we're dealing with 因为那就是我们正在处理的事情
right now you know as we change this 现在你知道我们改变这个
everything's going to change 一切都会改变
so I'll even keep it like that for now 所以我现在就保持这样
it's just so we have more to work with 它只是让我们有更多的工作
so what I want to do here is I'll chop a 所以我想在这里做的是我会砍掉一个
mountain down to kind of mess with that 山下到那种乱七八糟的东西
now this we want to be tied to the time 现在我们想要与时间联系在一起
so I could say like literally time and 所以我可以说像字面上的时间和
now it's animated over time it doesn't 现在，随着时间的推移它不会动画
move very fast so we'll probably want to 移动非常快，所以我们可能会想要
multiply it by some number like so and 将它乘以某个数字，如此和
now it just looks like it's a slice of 现在看起来它只是一片
water we're just getting like a you know 水，我们就像你知道的那样
there's a slice of it in space now we 现在我们在太空中有一片它
don't want to move this high up some to 不想把这个高涨一些
like 0.1 and maybe if we have the 像0.1，也许我们有
element size be smaller so that's pretty 元素大小更小，所以很漂亮
good the only thing to be too crazy most 好的唯一一件事太疯狂了
of our simulation will happen anyway 无论如何我们的模拟都会发生
regardless of the incoming craziness 不管传入的疯狂
here but just enough to to have it start 在这里，但足以让它开始
off to be something a little bit more 关闭更多的东西
interesting let's do the whirly again 有趣的是让我们再次做个响亮的事
cuz I like it so that's cool maybe want 因为我喜欢它，所以很酷也许想要
to Center noise for in this case yeah 在这种情况下，中心噪音是的
just keep it a little bit bigger it's 只是保持它更大一点
probably fine so there you go 可能没问题，所以你去
we can now do a flip source here in fact 我们现在可以在这里做一个翻转源
we can just use copy the same one from 我们可以使用复制相同的
before like so because it has all the 之前是因为它拥有全部
same stuff set up for it already somehow 已经以某种方式为它设置了相同的东西
it got moved very go now this being a 现在它变得非常感动了
PDB you know it's not storing all the PDB你知​​道它不存储所有的
data in between these two so this is a 这两者之间的数据所以这是一个
lot more efficient especially again at 效率更高，特别是在
these higher resolutions that we'll be 这些更高的分辨率，我们将成为
getting into so it's pretty cool I'm 进入，所以我很酷
gonna put a null here and say this is 在这里放一个空，说这是
the serf I'll say this is the maybe the 农奴我会说这可能是
boundary serf that's cool and what else 边界农奴这很酷，还有什么
we need we're gonna want the to make of 我们需要我们想要的
velocities also now as again we get to 现在我们再次进入速度
higher resolutions later on I don't we 后来更高的分辨率我不是
don't need necessarily for our incoming 不一定需要我们来的
velocity field to be so insanely 速度场是如此疯狂
detailed because you know these this was 详细，因为你知道这些
going to get pretty small later on I 我以后会变得很小
just want generally a velocity that is 只想要一个速度
sending it this way and is maybe 以这种方式发送它也许是
perturbed a little bit so we don't have 有点不安，所以我们没有
to go too crazy on that front I'm gonna 我会在那个方面过于疯狂
say let's do eight points from volume we 说让我们从量我们做八点
can start it from well actually we start 实际上我们可以从良好的开始
from this it's there you go and it makes 从这里开始，你就去了
a nice little grid of points and of 一个很好的小网格点和
course we would normally think to do 我们通常认为这样做
particle separation here but like I said 粒子分离在这里，但像我说的那样
I want to just do it manually I say this 我想手动做，我说这个
here what I have here is a high enough 这里我所拥有的是足够高的
resolution because like at this distance 分辨率，因为就像在这个距离
you know like that's enough I don't want 你知道这就是我不想要的
to reek we're gonna have to recalculate 我们将不得不重新计算
this on every frame as you can see and I 你可以看到我和每一帧
want to keep it fast I don't want this 想要保持快速我不想要这个
to impact my simulation time so I'm 影响我的模拟时间，所以我
gonna hide everything else here for a 要把这里的一切都隐藏起来
minute okay 分钟好的
and we want to turn on ad scale 我们想要打开广告比例
attribute which will make a P scale here 将在此处制作P比例的属性
this will be important because we're 这很重要，因为我们是
gonna want to stamp whatever the data we 要记住我们的数据
put on this we're gonna put a velocity 戴上这个，我们要加速
per point on here let's just do it 在这里的每一点让我们这样做
I'm gonna make an attribute angle and 我要做一个属性角度和
I'll say hey the velocity is equal to 我会说嘿速度等于
some channel vector vector channel and 一些通道矢量矢量通道和
we'll say call it something clever like 我们会说它叫做聪明的东西
velocity so whatever this is the V is 速度，所以不管这是什么
gonna be what should this be well it 应该是什么应该好呢
should probably be the same as to what 应该与什么相同
we already had the initial ones being so 我们已经有了最初的那些
I'm gonna paste that here so now 我现在要贴在这里
everybody you can see if I click the 如果我点击，你可以看到每个人
velocity visualizer they now have that 他们现在有速度可视化
and if I were to attribute rest or 如果我要归因于休息或
volume rastros attributes what I was 卷rastros归因于我
trying to say before is that the scale 之前试图说的是规模
attribute here will mean that though 这里的属性将意味着
each particle will contribute into the 每个粒子都会贡献出来
final volume that we're making here the 我们在这里制作的最后一卷
size of the particle to the size is just 粒子大小只是大小
how far it is essentially from its 它到底有多远
neighbors so here we are we say 邻居所以我们在这里说
rasterize that V attribute the voxel 栅格化V属性体素
size might as well just be the same as 大小也可能与之相同
what it already is here so copy that one 它已经在这里复制那一个
so remember we're not doing this in 所以记住我们不是这样做的
terms of the simulation one we're just 我们只是模拟的术语
doing we're doing this one at a fixed in 我们在固定的地方做这个
a fixed way we can do a volume trail and 我们可以通过固定的方式进行音量跟踪
a volume slice to visualize what we just 一个体积切片，可视化我们的内容
made so here's a slice and here's a 这是一片切片，这是一个
trail 落后
there we go so we have a Velata field 我们去了，所以我们有一个Velata场
they're all just pointing to the right 他们都只是指向右边
and we can be assured that whatever 我们可以放心，无论如何
we're doing here is happening over here 我们在这里正在做的事情发生在这里
also but I'm just going to look at this 还有，但我只想看看这个
side so right now they're all pointing 所以现在他们都指向了
the same direction what you can do is we 我们可以做同样的方向
can do a noise attribute noise and say 可以做噪音属性噪音说
put that after our Wrangler here and 把它放在我们的牧马人之后
just say let's just add to the velocity 只是说让我们只是增加速度
something so I'm gonna definitely want 所以我一定会想要的东西
to Center this I wouldn't worry too much 以此为中心我不会太担心
about this but just make the element 关于这个，但只是制作元素
size kind of smaller maybe this is fine 大小那么小也许这很好
just something to kind of you know break 只是有点你知道休息的东西
it up a little bit and even one and it's 它有点甚至一个，它是
mostly looks like you know a that is 大多数看起来像你知道的那样
moving to the right if you were to just 如果你只是向右移动
break this connection here and there was 在这里打破这种联系
no velocity and now we just have like a 没有速度，现在我们就像一个
purely interesting we should make this 纯粹有趣我们应该做到这一点
be animated as well so this is how you 也是动画，所以这就是你
would just make an interesting velocity 会产生一个有趣的速度
field in the first place but we mostly 首先是我们的领域，但我们大多数
want ours to be governed by by this 希望我们受此约束
again so I'm gonna remake that here copy 再来，所以我要重拍这里的副本
that onto here it should mostly be 在这里它应该主要是
moving to the right and just be broken 向右移动，只是被打破
up a little bit now this is just the 现在这只是一点点
visualizer this is the actual volume it 可视化器这是它的实际体积
looks like fog here which doesn't really 看起来像雾这里并不是真的
do as much good which is why we did that 做多少好事，这就是我们这样做的原因
but we can be rest assured that it is 但我们可以放心，它是
actually nice so we've done it we have 实际上很好，所以我们已经做到了
now incoming liquid area and incoming 现在进入的液体区域和进入
liquid velocities and these are gonna be 液体速度和这些将是
the things that we point to in our thing 我们在事物中指出的事情
over here so coming back to our flip 在这里，所以回到我们的翻转
solver we can say the boundary velocity 求解器我们可以说边界速度
for velocity volume and we can put 对于速度体积，我们可以把
boundary surface for here 边界面为这里
and now I'll just keep it the our new 现在我只是把它当作新的
resolution that we set it to if you 如果你我们设定的决议
didn't do it it's at point zero five now 没有这样做现在是零点五
so let's see we got and sure enough 所以，让我们看到我们得到了足够的肯定
we have new particles coming in old 我们有新的颗粒进入旧的
particles going out it's a circle of 走出它的粒子是一圈
life the more the longer we let it sit 生活越久，我们就越坐
this is kind of what I was talking about 这就是我所说的
earlier with our having a pre sim you 早些时候我们有一个pre sim你
know it starts in this unnatural calm 知道它开始于这种不自然的平静
state like this but obviously it's a 这样的状态，但显然它是一个
moving River so it's not gonna look like 移动河，所以它看起来不会像
that the longer it goes it eventually 它最终会越久
kind of settles into the the interesting 有点沉淀到有趣的
shapes and waves that it wants to be 它想要的形状和波浪
based on the actual geometry of our 基于我们的实际几何
River Basin so much of the result of our 流域这么多我们的结果
River sim is going to be based off of River sim将基于
where we put the colliders what the 我们把碰撞器放在哪里了
riverbed looks like I mean it's really 河床看起来像我的意思是真的
everything how shallow the river is you 这条河有多浅浅
can't just have the river look like 不能只是让河流看起来像
however you want the river is reacting 但是你希望这条河正在起作用
to colliders that's everything so when 对于碰撞者而言，这一切都是如此
you're done your river will naturally 你自然完成了你的河流
have to look a little different than 必须看起来有点不同
mine because you'll have your colliders 我的，因为你会有你的对手
probably be in a slightly different spot 可能是在一个稍微不同的地方
but in any case so that's pretty cool 但无论如何这样很酷
let's actually go put more kleiers in to 让我们真的去做更多的克莱尔
make it more interesting 让它更有趣