C# 클래스 LostPolygon.DynamicWaterSystem.LinearWaveEqueationSolver

Linear wave equation solver. This is the core of interactive simulation.
파일 보기 프로젝트 열기: caffeinatedguy/Limbs 1 사용 예제들

공개 메소드들

메소드 설명
Solve ( float field, float fieldNew, float fieldSpeed, byte fieldObstruction, Vector2Int gridSize, float timeDelta, float damping, float &maxValue ) : void

Performs the wave simulation step.

메소드 상세

Solve() 공개 정적인 메소드

Performs the wave simulation step.
public static Solve ( float field, float fieldNew, float fieldSpeed, byte fieldObstruction, Vector2Int gridSize, float timeDelta, float damping, float &maxValue ) : void
field float /// Represents the current simulation state. ///
fieldNew float /// Represents the updated simulation state. ///
fieldSpeed float /// Represents the simulation state difference. ///
fieldObstruction byte /// Array of bool indicating whether the water is obstructed by an object. \n /// true means the grid node is obstructed by an object, so the simulation is not updated; /// false means the grid node is not obstructed, and the simulation can proceed freely. ///
gridSize Vector2Int /// Actual simulation grid resolution. ///
timeDelta float /// Time delta in seconds. ///
damping float /// Damping value. Must be clamped to the 0-1 range. ///
maxValue float /// Value representing maximal absolute wave height. ///
리턴 void