↓↓↓Basic Animation System Overview
https://drive.google.com/file/d/1jaMs7x90m6BdRUqMLE8LsUIm4V4s5vCD/view?usp=sharing
:Basic Lagrange Animation System
PointPositionに直接変化量を持たせて現行位置を更新する。
int
main
{
for
(
int
i; iterate>= i; i++;)
{
vector Pos = currentPos;
vector v = (velocity*TimeInterval)*i;
//i = dt
@P = Pos +v;
}
}
:Basic Euler Animation System
voxelに変化量を持たせてそれらを参照し更新する。
int
main
{
for
(
int
i; iterate>= i; i++;)
{
vector Pos = currentPos;
vector v = (voxel_Velocity * TimeInterval)*i;
//voxel_Velocity = Sampling current_VelocityData
//i = dt
@P = Pos +v;
}
}
↓↓↓Volume Displacement Overview
int
main
{
vector idxPos = dnesityPosition;
vector directiornalVector = normalize(gradient(density))*(amount*lengthnormalize(gradient(density)));
vector pushUp = idxPos + directiornalVector
float
density = voxelTrace_density(pushUp);
return
density;
}
↓↓↓CameraSpace Advection Overview
int
main
{
vector Pos = dnesityPosition;
vector advectvelocity = cross(getvoxelvelocity,CameraSpace_Turbulence) *(1/FPS)*Timestep;
vector PositionSample_A = advectvelocity+ Pos;
vector PositionSample_B =(getvoxelvelocity(PositionSample_A) *(1/FPS)*Timestep;
Pos += PositionSample_B;
density = voxelTrace_density(Pos);
return
density;
}
↓↓↓Sample Hip File
コメント
コメントを投稿